Random flickering on displayoutput?

Both my old laptop and my mediacenter had this problem.
The source of the problem on my systems is the new and improved Intel driver that makes use of the IOMMU (which is rather a tricky thing to do by the way).

On my 22.04 installs I removed the HWE packages so I reverted automatically to an older kernel and this solved the issue.

This is ofcourse not the most common way to solve this but it is the easiest way, and it survives kernelupdates.

Coincidentally but unrelated: Some other people with nVidia GPUs had the same issue. What they all have in common is kernel 6.8.0-40

So, if you have this problem and this kernel, use another kernel

to summarise:

  1. If you encounter this on a 24.04 install, try installing the HWE packages to force your system to use a newer kernel.
  2. If you encounter this on a 22.04 install, try removing the HWE packages to force your system to use an older kernel.

(I did not encounter this problem on my 24.04 installs but your milage may vary.)

EDIT: I realize I've been incredibly vague in this message
What I did was:

sudo apt purge linux-image-generic-hwe-22.04
sudo apt install linux-image-generic

Which would help you too if you are on 22.04

If you want to get rid of 6.8.0 on 24.04 you should do:

sudo apt purge linux-image-generic
sudo apt install linux-image-generic-hwe-24.04
3 Likes

Since I updated my mediacenter to 24.04, I got the impression that a newer kernel than 6.8.0-40 will not be a solution to this problem so I searched for a more definitive solution for the random flickering on displayoutput and found something that works for me.
(This solution works only for intel, not for nVidia)

sudo pluma /etc/default/grub

change

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

to

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash i915.enable_dc=0 intel_idle.max_cstate=2"

save this and issue the command

sudo update-grub

and since we are cleaning up anyway, we can also get rid of some unused and ancient legacy cruft (optional)

sudo apt remove xserver-xorg-video-intel

I found this solution on the following links:

https://www.linux.org/threads/flashing-screen-on-linux-mint-22-with-intel-uhd620-graphics.51476/

https://forums.linuxmint.com/viewtopic.php?t=427916

3 Likes

Better solution

Since the above solution works but at the cost of more energy consumption, it is not really ideal for laptops so I kept on searching for a better way to get rid of the flickering.
The following /etc/default/grub line worked for me.
Use this instead of the line mentioned in the previous post:

 GRUB_CMDLINE_LINUX_DEFAULT="quiet splash i915.enable_psr=0"

EDIT: I also upgraded my old Acer Swift One to 24.04 but this line didn't work on that laptop. The line mentioned in the previous post however, did.

3 Likes

Best solution

Since I also upgraded my old Acer Swift One to 24.04 but the "better solution" did not work, I had to fall back on the first mentioned solution.
It works perfectly but I deemed it unacceptable for a laptop because of battery life. So I kept on searching for a solution that, besides solving the problem, also behaves a bit more battery friendly and I found what I was looking for:

Use this instead of the line mentioned in the previous post:

 GRUB_CMDLINE_LINUX_DEFAULT="quiet splash intel_iommu=igfx_off"

The only drawback is that the GPU no longer can provide GPU-passthrough under virtualisation, which is (in my usecase) perfectly acceptable.

2 Likes

I noticed flickering on my intel laptop after upgrading to UM 24.04.1. I'll have to give this a go when I have time (it's an older laptop used for backups and such).

I'm curious how you quantified the battery drain.

Oh, I didn't quantify it.

But:

"i915.enable_dc=0" disables GPU powermanagement
"intel_idle.max_cstate=2" prevents a too deep sleep state.

Both will, for these reasons alone, theoretically result in higher energy consumption and although I do not know how much the impact would be, I'd rather try to avoid that.

Since the flickering started after intel added some IOMMU options to the driver, it seems that "intel_iommu=igfx_off" is exactly the right solution for this case.

1 Like

Thanks. I'll try to come up with some numbers. I've found that charging the battery to full and then measuring the wattage use usually works, but the granularity is only to the tenth of a watt.

Thanks again for giving us options.

2 Likes

I had been wondering what had been causing my screen to suddenly flicker. Never considered it was the update. Thanks for the solution; have not had the flicker since.

1 Like

Welcome, @GeekBone to the community!

1 Like