Page MenuHomeFreeBSD

i915: disable GEN6_MBCTL write in gen6_init_clock_gating
ClosedPublic

Authored by emaste on Mar 17 2016, 6:01 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Nov 1, 2:47 PM
Unknown Object (File)
Oct 1 2024, 7:40 PM
Unknown Object (File)
Oct 1 2024, 4:49 PM
Unknown Object (File)
Sep 14 2024, 5:44 PM
Unknown Object (File)
Sep 12 2024, 1:56 AM
Unknown Object (File)
Sep 8 2024, 9:33 PM
Unknown Object (File)
Sep 8 2024, 8:58 AM
Unknown Object (File)
Sep 8 2024, 7:34 AM
Subscribers

Details

Summary

This came from Linux commit b4ae3f22d238617ca11610b29fde16cf8c0bc6e0 which is implicated in Sandy Bridge power consumption issues (albeit under different conditions).

On my Thinkpad X220 at rS296910 I see the following power consumption numbers (on a memstick image with a few services running and no packages installed).

  • After booting and logging in as root: 11W
  • After kldload i915kms: 21W
  • After suspend + resume: 11W

With this patch I see 11W in all three cases.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

emaste retitled this revision from to i915: disable GEN6_MBCTL write in gen6_init_clock_gating.
emaste updated this object.
emaste edited the test plan for this revision. (Show Details)
emaste added a reviewer: dumbbell.
emaste added subscribers: cem, kib.

John, can you give this a try on your X220? You reported no issue w/o the patch but I want to make sure this doesn't introduce some other regression.

sys/dev/drm2/i915/intel_pm.c
3702–3704 ↗(On Diff #14399)

will delete these mixed up comment lines

cem added a reviewer: cem.
This revision is now accepted and ready to land.Mar 17 2016, 6:17 PM

That's great news, thank you!

I added to minor comments inline.

sys/dev/drm2/i915/intel_pm.c
3676 ↗(On Diff #14399)

Instead of #if 0, I use #ifdef FREEBSD_WIP to comment out code specifically on FreeBSD. For example:
https://github.com/freebsd/freebsd-base-graphics/blob/master/sys/dev/drm2/i915/i915_gem.c#L1380-L1388

3677 ↗(On Diff #14399)

Could you please prefix the first line of your comment with NOTE Linux<->FreeBSD: ?

I use that to really identify code which differs from Linux on purpose. For instance:
https://github.com/freebsd/freebsd-base-graphics/blob/master/sys/dev/drm2/i915/i915_gem.c#L1101-L1103

dumbbell edited edge metadata.
This revision now requires changes to proceed.Mar 17 2016, 7:04 PM
emaste edited edge metadata.

Use #ifdef FREEBSD_WIP and NOTE Linux<->FreeBSD: as suggested by @dumbbell.

dumbbell edited edge metadata.
This revision is now accepted and ready to land.Mar 17 2016, 7:38 PM

Thanks for the review. I'll commit in a day or two if there are no reports of regressions (and hopefully confirmation that it fixes the issue for others).

This revision was automatically updated to reflect the committed changes.