Bug 48902 - [pch ILK/SNB/IVB] poor power management if an external VGA display was connected
Summary: [pch ILK/SNB/IVB] poor power management if an external VGA display was connected
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: unspecified
Hardware: x86 (IA32) Linux (All)
: medium normal
Assignee: Jesse Barnes
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-04-18 18:23 UTC by Ouping Zhang
Modified: 2017-07-24 23:02 UTC (History)
4 users (show)

See Also:
i915 platform:
i915 features:


Attachments
intel_reg_dumper when boot (12.18 KB, text/plain)
2012-04-19 19:07 UTC, Ouping Zhang
no flags Details
intel_reg_dumper when plugging VGA (12.28 KB, text/plain)
2012-04-19 19:08 UTC, Ouping Zhang
no flags Details
intel_reg_dumper when disconnecting VGA (12.30 KB, text/plain)
2012-04-19 19:11 UTC, Ouping Zhang
no flags Details

Description Ouping Zhang 2012-04-18 18:23:37 UTC
System Environment:
--------------------------
Kernel: (drm-intel-next-queued)17038de5f16569a25343cf68668f3b657eafb00e

Bug reproduced steps: 
--------------------------
1.Boot the IVB laptop unplugged, using eDP display only, it uses about 15.5W according to wattsup power meter.

2.Connect an external display through the VGA connector and activate it ("xrandr --output VGA1 --auto"), the laptop uses 18.4W

3.Deactivate the external display ("xrandr --output VGA1 --off"), the laptop uses 17.4W

4.Disconnect the external display, the laptop uses 17.4W, the power usage stays at the level of 17.4W, never falls to the level of boot (15.5W).
However, restarting brings it back to 15.5W

Disconnect the external display and the power usage never falls back to the level of boot.
Comment 1 Chris Wilson 2012-04-19 14:27:12 UTC
Please attach intel_reg_dumper for:

1. boot,
2. after plugging in VGA
3. after disconnecting VGA.
Comment 2 Ouping Zhang 2012-04-19 19:07:42 UTC
Created attachment 60363 [details]
intel_reg_dumper when boot
Comment 3 Ouping Zhang 2012-04-19 19:08:23 UTC
Created attachment 60364 [details]
intel_reg_dumper when plugging VGA
Comment 4 Ouping Zhang 2012-04-19 19:11:27 UTC
Created attachment 60365 [details]
intel_reg_dumper when disconnecting VGA
Comment 5 Chris Wilson 2012-04-24 02:03:48 UTC
We leave what should be irrelevant state in the low bits of disabled pipe/planes/transports, but everything is disabled as expected. The only register I don't know about is:

boot:       PORT_DBG: 0x00000007 (HW DRRS off)
unattached: PORT_DBG: 0x00000307 (HW DRRS off)

I wonder what is being flagged.

Being paranoid, have you checked that the Windows driver returns to initial power configuration after the VGA is unplugged?
Comment 6 Eugeni Dodonov 2012-04-24 08:12:36 UTC
Those additional PORT_DBG bits seem to indicate that "FDIB Init Status" went from the "Pattern 1" state on boot into "Active" one after unplugging on IVB docs, but they seem to be missing from SNB ones.

So I don't know if they are bogus there or I was looking at wrong (or old) documentation for SNB.
Comment 7 Ouping Zhang 2012-04-26 00:07:27 UTC
this issue can be reproduced on IVB, SNB and Piketon.
Comment 8 Ben Widawsky 2012-04-29 18:57:19 UTC
(In reply to comment #7)
> this issue can be reproduced on IVB, SNB and Piketon.

One (In reply to comment #5)
> We leave what should be irrelevant state in the low bits of disabled
> pipe/planes/transports, but everything is disabled as expected. The only
> register I don't know about is:
> 
> boot:       PORT_DBG: 0x00000007 (HW DRRS off)
> unattached: PORT_DBG: 0x00000307 (HW DRRS off)
> 
> I wonder what is being flagged.
> 
> Being paranoid, have you checked that the Windows driver returns to initial
> power configuration after the VGA is unplugged?

It looks like we're also driving pipeB for a 1280x1024 after disconnect. I agree this shouldn't make a difference, but perhaps 0'ing out all those fields would make a difference.

Of other note to me,

Both of these are still driving the lane x2 instead of x1
FDI_TXB_CTL
FDI_RXB_CTL

has bits 8, and 9 unmasked after unplug
FDI_RXB_IMR: 0x00000cff

Finally, too lazy to investigate bits right now, but PCH_ADPA also seems worth investigating.
Comment 9 Ouping Zhang 2012-10-23 09:19:27 UTC
with the latest kernel and X11, the bug has been fixed.
(In reply to comment #8)
> (In reply to comment #7)
> this issue can be reproduced on IVB, SNB and
> Piketon.

One (In reply to comment #5)
> We leave what should be irrelevant
> state in the low bits of disabled
> pipe/planes/transports, but everything
> is disabled as expected. The only
> register I don't know about is:
> 
>
> boot:       PORT_DBG: 0x00000007 (HW DRRS off)
> unattached: PORT_DBG:
> 0x00000307 (HW DRRS off)
> 
> I wonder what is being flagged.
> 
> Being
> paranoid, have you checked that the Windows driver returns to initial
>
> power configuration after the VGA is unplugged?

It looks like we're also
> driving pipeB for a 1280x1024 after disconnect. I agree this shouldn't make
> a difference, but perhaps 0'ing out all those fields would make a
> difference.

Of other note to me,

Both of these are still driving the lane
> x2 instead of x1
FDI_TXB_CTL
FDI_RXB_CTL

has bits 8, and 9 unmasked after
> unplug
FDI_RXB_IMR: 0x00000cff

Finally, too lazy to investigate bits right
> now, but PCH_ADPA also seems worth investigating.
Comment 10 Daniel Vetter 2012-10-23 09:50:41 UTC
Thanks for the update, closing this now.

/me has no idea why all the VGA-related power wasters are suddenly all fixed ...
Comment 11 Ouping Zhang 2012-10-24 01:19:30 UTC
I also confused, when I test the bug on SNB with 14'' display, the gap power consumption is about 0.8w between plugging in VGA and disconnecting VGA, and when disconnecting VGA, the power falls to the boot.
(In reply to comment #10)
> Thanks for the update, closing this now.

/me has no idea why all the
> VGA-related power wasters are suddenly all fixed ...


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.