[i915] screen is flickering in Ubuntu 22.04 (until i915.enable_dc=0 intel_idle.max_cstate=2 are added)

Bug #1970426 reported by Nikolai Kotsifas
160
This bug affects 35 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Triaged
High
Unassigned

Bug Description

After I updated to 22.04 sometimes (about 3 ~ 4 times a day) the screen starts glitching and flickering like in the attached video and it doesn't stop until I move the cursor.

Description: Ubuntu 22.04 LTS
Release: 22.04
wayland

processor: Intel® Core™ i5-8265U CPU @ 1.60GHz × 8
graphics: Mesa Intel® UHD Graphics 620 (WHL GT2)

Revision history for this message
Nikolai Kotsifas (nikolai-kotsifas) wrote :
Revision history for this message
lotuspsychje (lotuspsychje) wrote :

thank you for reporting this bug and make Ubuntu better!

Please change the packagename of this bug from 'ubuntu' to linux(Ubuntu) (target the kernel)

then run apport-collect 1970426 from your terminal

thanks!

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in ubuntu:
status: New → Confirmed
Revision history for this message
Esteban Knöbl (estebanknobl) wrote :

I'm also experiencing this issue. Fresh install, same graphics.

Revision history for this message
Johannes Stöckelmaier (jostoe) wrote :

I can also confirm that I experience this issue.

Before, I used Ubuntu 21.04 with Wayland, similar hardware/settings and the corresponding kernel of 21.04 and never had this issue once.
After a fresh install of 22.04 it came up around once per hour.

When running "dmesg -T", the occurrence of the issue corresponds with error:
[Fri Apr 29 13:10:21 2022] i915 0000:00:02.0: [drm] *ERROR* CPU pipe A FIFO underrun

I tried to set:
intel_idle.max_cstate=4
i915.enable_psr=0
It probably reduces the frequency the issue comes up but does not fix it.

sudo lshw -c video
  *-display
       description: VGA compatible controller
       product: Skylake GT2 [HD Graphics 520]
       vendor: Intel Corporation
       physical id: 2
       bus info: pci@0000:00:02.0
       logical name: /dev/fb0
       version: 07
       width: 64 bits
       clock: 33MHz
       capabilities: pciexpress msi pm vga_controller bus_master cap_list rom fb
       configuration: depth=32 driver=i915 latency=0 resolution=2560,1440
       resources: irq:130 memory:e0000000-e0ffffff memory:c0000000-dfffffff ioport:e000(size=64) memory:c0000-dffff

Revision history for this message
Ferenc Hegedus (ferihegedus) wrote :

I also have the same issue on Kubuntu 22.04. I have used Kubuntu 21.10 with X and Wayland mixed, without any issues.

> neofetch
           `.:/ossyyyysso/:. feri@yoga370
        .:oyyyyyyyyyyyyyyyyyyo:` ------------
      -oyyyyyyyodMMyyyyyyyysyyyyo- OS: Kubuntu 22.04 LTS x86_64
    -syyyyyyyyyydMMyoyyyydmMMyyyyys- Host: 20JJS0WH00 ThinkPad Yoga 370
   oyyysdMysyyyydMMMMMMMMMMMMMyyyyyyyo Kernel: 5.15.0-27-generic
 `oyyyydMMMMysyysoooooodMMMMyyyyyyyyyo` Uptime: 4 hours, 47 mins
 oyyyyyydMMMMyyyyyyyyyyyysdMMysssssyyyo Packages: 2705 (dpkg), 7 (snap)
-yyyyyyyydMysyyyyyyyyyyyyyysdMMMMMysyyy- Shell: bash 5.1.16
oyyyysoodMyyyyyyyyyyyyyyyyyyydMMMMysyyyo Resolution: 1920x1080
yyysdMMMMMyyyyyyyyyyyyyyyyyyysosyyyyyyyy DE: Plasma 5.24.4
yyysdMMMMMyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy WM: KWin
oyyyyysosdyyyyyyyyyyyyyyyyyyydMMMMysyyyo WM Theme: Aritim-Dark
-yyyyyyyydMysyyyyyyyyyyyyyysdMMMMMysyyy- Theme: Aritim-Dark [Plasma], Materia-Manjaro-Dark-gtk [GTK2/3]
 oyyyyyydMMMysyyyyyyyyyyysdMMyoyyyoyyyo Icons: ePapirus-Dark [Plasma], ePapirus-Dark [GTK2/3]
 `oyyyydMMMysyyyoooooodMMMMyoyyyyyyyyo Terminal: konsole
   oyyysyyoyyyysdMMMMMMMMMMMyyyyyyyyo Terminal Font: Ubuntu Mono 11
    -syyyyyyyyydMMMysyyydMMMysyyyys- CPU: Intel i7-7500U (4) @ 3.500GHz
      -oyyyyyyydMMyyyyyyysosyyyyo- GPU: Intel HD Graphics 620
        ./oyyyyyyyyyyyyyyyyyyo/. Memory: 2185MiB / 15762MiB
           `.:/oosyyyysso/:.`

> sudo lshw -c video
  *-display
       description: VGA compatible controller
       product: HD Graphics 620
       vendor: Intel Corporation
       physical id: 2
       bus info: pci@0000:00:02.0
       logical name: /dev/fb0
       version: 02
       width: 64 bits
       clock: 33MHz
       capabilities: pciexpress msi pm vga_controller bus_master cap_list rom fb
       configuration: depth=32 driver=i915 latency=0 resolution=1920,1080
       resources: irq:134 memory:db000000-dbffffff memory:80000000-9fffffff ioport:e000(size=64) memory:c0000-dffff

Revision history for this message
Ionut Negru (blackjohnny) wrote (last edit ):

In my case I think it flickers badly because of the "Night Light" feature that is not working properly. Once I disable the feature, the flicker is less annoying.

RE: after a restart with the "Night Light" feature disabled the flicker is gone.

tags: added: jammy
affects: ubuntu → linux (Ubuntu)
tags: added: flicker i915
summary: - screen suddenly starts flickering after update
+ [i915] screen suddenly starts flickering after update
tags: added: wayland wayland-session
Revision history for this message
Daniel van Vugt (vanvugt) wrote : Re: [i915] screen suddenly starts flickering after update

Sounds like the common factor is Intel Gen9 GPUs?

https://en.wikipedia.org/wiki/List_of_Intel_graphics_processing_units#Gen9

Revision history for this message
Anaggh S (anaggh) wrote (last edit ):

Affects Xubuntu 22.04 (Fresh Install) too on Lenovo Ideapad 330s (Intel(R) Core(TM) i5-8250U CPU @ 1.60GHz)

EDIT: Workaround is here: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1958191/comments/26

---

After about 11 days of using 22.04 release, it lead to major loss of productivity due to the flickering. Got headaches. This should have been a release blocker.

I was curious if it affected Debian Unstable on their latest kernel (Linux 5.17.0-1-amd64 #1 SMP PREEMPT Debian 5.17.3-1 (2022-04-18) x86_64 GNU/Linux) and installed it. No flickering on Debian. Seems like it is a Ubuntu only bug.

---

Below is a list of attempts I tried to fix flicker that DID NOT work during the 11 days of using Xubuntu 22.04:

* GRUB Param `i915.enable_psr=0` workaround https://wiki.archlinux.org/title/intel_graphics#Screen_flickering
* `intel_idle.max_cstate=4` option to grub param https://gitlab.freedesktop.org/drm/intel/-/issues/5569
* Use latest kernel from ubuntu team (linux-oem-22.04)
* Use different kernel with `mainline` app - https://github.com/bkw777/mainline
```
* 5.17.5 - Did not fix.
* 5.16.20 - Did not fix.
* 5.15.36 - Did not fix.
```
* remove package `xserver-xorg-video-intel` https://en.itsmeit.net/how-to-fix-google-chrome-screen-flickering-on-ubuntu.html

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

> This should have been a release blocker.

This bug was not reported until 5 days after release. And searching for similar bugs I can only find one possible duplicate (bug 1958191 also an i5-8250U) that was reported before release. So at most only one person reported it before release, that I can find.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Bug 1958191 mentions that kernel parameter intel_idle.max_cstate=4 fixed it.

Revision history for this message
Nikolai Kotsifas (nikolai-kotsifas) wrote :

I can confirm that neither of the following fixed the bug:

GRUB Param `i915.enable_psr=0` did not fix
`intel_idle.max_cstate=4` did not fix
`intel_idle.max_cstate=0`did not fix
x11 session did not fix

Also, I noticed that when the screen starts flickering it only stops if I move the cursor, if I type on my keyboard the flickering continues.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Nikolai, did you also remember to run:

  sudo update-grub

after each change to the kernel parameters?

Revision history for this message
Nikolai Kotsifas (nikolai-kotsifas) wrote :

Yes, I did.

Revision history for this message
Nikolai Kotsifas (nikolai-kotsifas) wrote :

After a flickering occurs the following message appears on the Log:

i915 0000:00:02.0: [drm] *ERROR* CPU pipe A FIFO underrun
kernel device: +pci:0000:00:02.0
priority: 3

Revision history for this message
Johannes Stöckelmaier (jostoe) wrote (last edit ):

I did the following changes and am now flicker-free for two days:

In file /etc/default/grub I added to parameter GRUB_CMDLINE_LINUX_DEFAULT:
i915.enable_dc=0
intel_idle.max_cstate=2

then:
sudo update-grub
reboot

I will report in a week if this indeed fixes the flickering or if it just happens less often.
I never had night-light enabled.

Revision history for this message
Null Void (angrypixel) wrote :

I am having exactly same issue as first post and until mouse pointer moved away, it wont stop glitching. My machine specs:

  *-display
       description: VGA compatible controller
       product: CometLake-U GT2 [UHD Graphics]
       vendor: Intel Corporation
       physical id: 2
       bus info: pci@0000:00:02.0
       logical name: /dev/fb0
       version: 02
       width: 64 bits
       clock: 33MHz
       capabilities: pciexpress msi pm vga_controller bus_master cap_list rom fb
       configuration: depth=32 driver=i915 latency=0 resolution=1920,1080
       resources: irq:139 memory:90000000-90ffffff memory:80000000-8fffffff ioport:3000(size=64) memory:c0000-dffff

processor Intel(R) Core(TM) i7-10610U CPU @ 1.80GHz
display CometLake-U GT2 [UHD Graphics]

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I want to say the evidence is mounting for this being Gen9-GPU-specific (which covers CPU generations 6 through 10-U). But also that's probably just the range of Intel CPUs that most people have anyway.

https://en.wikipedia.org/wiki/List_of_Intel_graphics_processing_units#Gen9

It certainly doesn't affect all Intel CPUs in that range because I haven't experienced the bug yet.

Revision history for this message
Oibaf (oibaf) wrote :

It happens also on my laptop:
Intel(R) Core(TM) i7-7500U CPU @ 2.70GHz

Also note that the bug tags says wayland, but I am running Ubuntu Mate under Xorg (no Wayland).

Revision history for this message
Ferenc Hegedus (ferihegedus) wrote :

Yes I have the same CPU as mentioned earlier, and I'm also using X as it is default with Kubuntu 22.04.

Revision history for this message
Vladimir (volnes88) wrote :

Have a same issue with my MSI GF63 laptop Intel Core i5-9300H

Revision history for this message
Daniel van Vugt (vanvugt) wrote : Re: [i915] screen is flickering in Ubuntu 22.04

Could someone please identify what the last kernel version WITHOUT the bug was?

https://kernel.ubuntu.com/~kernel-ppa/mainline/?C=M;O=D

summary: - [i915] screen suddenly starts flickering after update
+ [i915] screen is flickering in Ubuntu 22.04
tags: added: regression-release
Changed in linux (Ubuntu):
importance: Undecided → High
tags: added: rls-jj-incoming
Revision history for this message
Vladimir (volnes88) wrote :

Well I can say only about 20.04.04 there was 5.13 hwe kernel without that flickering.
After I upgraded to 22.04 with 5.15, problem starts.

Revision history for this message
Nikolai Kotsifas (nikolai-kotsifas) wrote :

In file /etc/default/grub I added to parameter GRUB_CMDLINE_LINUX_DEFAULT:
i915.enable_dc=0
intel_idle.max_cstate=2

updated grub and now I'm flicker free for a few days.

The last kernel without the flickering for me was the kernel that shipped with 21.10

Revision history for this message
dom21121 (dom21121) wrote : Re: [Bug 1970426] Re: [i915] screen is flickering in Ubuntu 22.04

The last kernel without the flickering for me was the kernel that
shipped with 21.10

-> same

Le 05/05/2022 à 17:13, Nikolai Kotsifas a écrit :
> The last kernel without the flickering for me was the kernel that
> shipped with 21.10

summary: - [i915] screen is flickering in Ubuntu 22.04
+ [i915] screen is flickering in Ubuntu 22.04 (until i915.enable_dc=0
+ intel_idle.max_cstate=2 are added)
Changed in linux (Ubuntu):
status: Confirmed → Triaged
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Seems to be the same issue so I think this can be marked as a duplicate of bug 1958191 now.

tags: removed: rls-jj-incoming
Revision history for this message
kjur (kjur) wrote :

Also happening on Xubuntu 22.04 (which it's not Wayland) o the same UHD Graphics.

Revision history for this message
Manuel Pégourié-Gonnard (mpg) wrote :

Same here, after upgrading from 20.04 on my ThinkPad E460 which had been working fine for years.

lshw | grep -A2 display

        *-display
             description: VGA compatible controller
             product: Skylake GT2 [HD Graphics 520]
--
           *-display
                description: Display controller
                product: Topaz XT [Radeon R7 M260/M265 / M340/M360 / M440/M445 / 530/535 / 620/625 Mobile]

uname -a

Linux siegel 5.15.0-27-generic #28-Ubuntu SMP Thu Apr 14 04:55:28 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

Revision history for this message
Gaurav Gupta (gauravdce07) wrote :

I am also getting the same screen flickering issue after fresh installation of Ubuntu 22.04 LTS running on xorg (x11).
CPU in my case is:
          Intel(R) Core(TM) i5-6200U CPU @ 2.30GHz
          vendor: Intel Corp.
          physical id: 1
          bus info: cpu@0
          version: 6.78.3
          size: 2406MHz
          capacity: 2800MHz
GPU:
          product: GK208BM [GeForce 920M]
          vendor: NVIDIA Corporation

Is there any reliable solution to this bug ?

Revision history for this message
Manuel Pégourié-Gonnard (mpg) wrote :

> Is there any reliable solution to this bug ?

It looks like the following is working for everyone so far:

1. Edit /etc/default/grub to add append i915.enable_dc=0 intel_idle.max_cstate=2 to the contents of GRUB_CMDLINE_LINUX_DEFAULT (so, unless you've edited it before, the line looks like GRUB_CMDLINE_LINUX_DEFAULT="quiet splash i915.enable_dc=0 intel_idle.max_cstate=2")
2. sudo update-grub
3. reboot

I've been flicker-free ever since I've done that, while the flickering was relatively frequent before that.

Alternatively, running a 5.13 kernel should work too.

Revision history for this message
Null Void (angrypixel) wrote :

Flickering is still happening even after appending GRUB_CMDLINE_LINUX_DEFAULT, its more prominent when I have blinking cursor for example, it more frequent when I work in eclipse IDE ..

I am on:
Kernel: 5.15.0-30-generic
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash i915.enable_dc=0 intel_idle.max_cstate=2"

Specs:
CPU: processor Intel(R) Core(TM) i7-10610U CPU @ 1.80GHz
Display: CometLake-U GT2 [UHD Graphics]

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

This bug is closed as a duplicate of bug 1958191. If the suggested workaround doesn't work for you then please open a new bug by running:

  ubuntu-bug linux

Revision history for this message
Abdul Wahhab (rock5436) wrote :

I face same issue. I'm using Acer Aspire 7
graphics 1: Intel UHD Graphics
graphics 2: GTX 1650

I used 20.04 and I'm happy with it but it only install python 3.8 and while 3.10 is out so after official release of 22.04 I installed 22.04 (fresh install). But now I'm facing screen flickering. I'm using multi-boot so thanks to that I can use windows 11 for my development purpose. I'm disappointed because its official LTS release. It should be more stable and I can't find previous versions on ubuntu site. Now thanks to windows terminal to assist PowerShell v7.x developments in windows become good but I still love Linux than windows but due to annoying bugs I had to change my workspace to windows.

Revision history for this message
aikotoba (aikotoba) wrote :

Got the same error on my AMD laptop, and the processing method for inter has no effect on it.It is known that the screen flickers more frequently when the memory usage is high.
It's config:
OS: Ubuntu 22.04.1 LTS x86_64
Host: 82L7 Lenovo XiaoXinAir 14+ ACN 2021
DE: GNOME 42.2
CPU: AMD Ryzen 5 5600U with Radeon Graphics (12) @ 4.289GHz
GPU: AMD ATI 04:00.0 Cezanne

Revision history for this message
Shashank VRSN Sabniveesu (fossterer) wrote :

I do think the duplicate status is wrong

My issue is that only when mouse pointer is moved to bottom portion of screen, I see a flicker/repaint issue.

I'm on 5.19.0-23-generic (Ubuntu 22.10) and adding the said options `i915.enable_dc=0 intel_idle.max_cstate=2` did not work.

Only adding `i915.enable_psr=0"` worked as I noted in [this](https://github.com/ljvmiranda921/comments.ljvmiranda921.github.io/issues/41#issuecomment-1328125275)

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Shashank,

Please log your own bug mentioning the particular model of laptop that requires i915.enable_psr=0

summary: - [i915] screen is flickering in Ubuntu 22.04 (until i915.enable_dc=0
- intel_idle.max_cstate=2 are added)
+ [i915] screen is flickering in Ubuntu 22.04 (until i915.enable_psr=0 is
+ added)
summary: - [i915] screen is flickering in Ubuntu 22.04 (until i915.enable_psr=0 is
- added)
+ [i915] screen is flickering in Ubuntu 22.04 (until i915.enable_dc=0
+ intel_idle.max_cstate=2 are added)
Revision history for this message
Zachary Laughlin (zaxlofful) wrote :

This bug happens to me on fresh install of Kubuntu 22.10. I am running AMD not Intel and have the same issue. I have yet to find a solution that works, but I am testing different configs as I type.

Here are my specs:

OS: Kubuntu 22.10
CPU: Virtual KVM 16-Core with Host Profile Applied (Ryzen 9 3950X)
RAM: 64GB
GPU: PCIE-Passthru NVIDIA RTX 3080
KVM BIOS: OVMF-UEFI (Q35)

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

This bug is a duplicate of a closed bug 1958191. Also this bug is about Intel GPUs only.

If you have any ongoing issues then please open a new bug.

Revision history for this message
Amirul Menjeni (amirulmenjeni) wrote :

This happens to my machine as well. The flickering appears to only happens at the left-hand side of the screen or at the bottom of the screen. I don't think I've ever seen the whole screen flicker or on other areas of the screen except on the one I've mentioned.

I've tried most of the suggestions here and online by changing the kernel parameters but to no avail.

Currently, I have `i915.enable_psr=0` set up but that only appears to reduce the symptoms not fixing the problem completely.

System info:

```
$ lsb_release -a
LSB Version: core-11.1.0ubuntu4-noarch:security-11.1.0ubuntu4-noarch
Distributor ID: Ubuntu
Description: Ubuntu 22.04.2 LTS
Release: 22.04
Codename: jammy
```

```
$ sudo lshw -C display
  *-display
       description: VGA compatible controller
       product: 2nd Generation Core Processor Family Integrated Graphics Controller
       vendor: Intel Corporation
       physical id: 2
       bus info: pci@0000:00:02.0
       logical name: /dev/fb0
       version: 09
       width: 64 bits
       clock: 33MHz
       capabilities: msi pm vga_controller bus_master cap_list rom fb
       configuration: depth=32 driver=i915 latency=0 resolution=1366,768
       resources: irq:28 memory:f0000000-f03fffff memory:e0000000-efffffff ioport:5000(size=64) memory:c0000-dffff
```

Revision history for this message
Daniel van Vugt (vanvugt) wrote (last edit ):

This bug is closed as a duplicate of another closed bug 1958191. If you have any ongoing issues then please open a new bug.

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.