CVE-2019-0154 caused major power problem, pls backport upstream's fix

Bug #1856653 reported by Tim Richardson
36
This bug affects 7 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

https://gitlab.freedesktop.org/drm/intel/issues/614
the fix released as CVE-2019-0154 increases idle power consumption on intel i915 6th gen and later.
That's because the GPU does not enter RC6 any more.

For example, my Thinkpad P50 (6th gen) idles at 9w with current 5.3 kernels. Previously, it idled at 5W.
Effects on a T480 (8th gen) are less dramatic but still significant.

5.5RC1 has the maintainer's second pass at this, which restores RC6 idling

The maintainer's patch for 5.3 is here:
 https://gitlab.freedesktop.org/drm/intel/issues/614#note_366057

I have applied this to tag Ubuntu-hwe-5.3.0-25.27~18.04.2 and it builds. I am testing it now.

I think it would be very helpful to backport this if you can.

Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:

apport-collect 1856653

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
description: updated
Revision history for this message
Tim Richardson (tim-richardson) wrote : Re: CVE-2019-0154 caused major power problem, pls backport maintainers fix

logs not applicable

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
summary: - CVE-2019-0154 caused major power problem, pls backport maintainers fix
+ CVE-2019-0154 caused major power problem, pls backport maintainer's fix
summary: - CVE-2019-0154 caused major power problem, pls backport maintainer's fix
+ CVE-2019-0154 caused major power problem, pls backport upstream's fix
information type: Public → Public Security
information type: Public Security → Private Security
Alex Murray (alexmurray)
information type: Private Security → Public
Revision history for this message
Tim Richardson (tim-richardson) wrote :

If the power-saving patch is backported,will this be updated? I'm on own patched kernel so I won't notice.
It's an awful problem, by the way, it harms battery life on any laptop with intel graphics from 2016 or later.

Revision history for this message
Tim Richardson (tim-richardson) wrote :

PS I've been running on hwe 5.3 from Ubuntu's kernel git repository for a few weeks, with the patch linked above, and it is stable on my Thinkpad T480.

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Is applying snippet [1] alone fixes the issue?

[1] https://gitlab.freedesktop.org/drm/intel/issues/614#note_366057

Revision history for this message
Tim Richardson (tim-richardson) wrote :

Yes, that little patch applies cleanly to every 5.3 hwe build I've done (about five I'd say)
To be clear:

diff --git a/drivers/gpu/drm/i915/gt/intel_lrc.c b/drivers/gpu/drm/i915/gt/intel_lrc.c
index 82b7ace62d97..b18f281d5d12 100644
--- a/drivers/gpu/drm/i915/gt/intel_lrc.c
+++ b/drivers/gpu/drm/i915/gt/intel_lrc.c
@@ -510,7 +510,11 @@ execlists_user_begin(struct intel_engine_execlists *execlists,
 inline void
 execlists_user_end(struct intel_engine_execlists *execlists)
 {
+ struct intel_engine_cs *engine =
+ container_of(execlists, typeof(*engine), execlists);
+
        execlists_clear_active(execlists, EXECLISTS_ACTIVE_USER);
+ mod_delayed_work(engine->i915->wq, &engine->i915->gem.retire_work, 0);
 }

 static inline void

Revision history for this message
Tim Richardson (tim-richardson) wrote :

Also, please note the upstream bug discussion also includes patches for 5.4
It seems that 5.4 is destined for 20.04. So far 5.4 upstream is still using the first release of this patch, which means 5.4 has the i915 RC6 bug. 5.4 is a LTS kernel bug so it strange to me, but please, I hope you can consider making sure that 20.04 does not launch with this nasty power regression.

Revision history for this message
Tim Richardson (tim-richardson) wrote :

Confirming that a fix has been backported to 20.04, currently in the proposed kernel. I'm testing it, the power usage is great.

Revision history for this message
Tim Richardson (tim-richardson) wrote :

not 'a fix', the intel maintainer's 5.4 patch has been applied by the ubuntu devs.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.