33

I have a Lenovo ThinkPad t460s here. It is the NVMe PCI SSD version. The CPU is i7 6600U (Skylake 6th generation) with Intel HD 520.

About a month ago (beginning March 2016), I installed Ubuntu GNOME 16.04 Beta 1. Everything, besides the known issues (Touchpad Physical Button Problems, Lid Close Problems) seemed to work fine.

At this time, I was using the kernel version 4.4.0-7. A few days later, there were several kernel updates (4.4.0-12, 4.4.0-14 and 4.4.0-15). Suddenly, I was experiencing screen flickering. It was really ugly, and I couldn't work anymore. So, I did downgrade the kernel version to 4.4.0-7 and put it on hold (via apt-mark hold). The screen flickering disappeared. Now, I have some graphic artifacts when browsing (firefox, chromium). I think I managed to get rid of these by disabling "smooth scrolling" options.

Is anyone else experiencing similar issues? Or has anyone already found a solution to this problem?

PS: I was installing Ubuntu GNOME 16.04 Final Beta a few days ago and get to try kernel version 4.4.0-16, which has solved the issue with the physical buttons of the touchpad. But unfortunately, the Screen Flickering was not solved. So, I went back to kernel version 4.4.0-7, as described above, again.

  • 2
    I'm very glad to see this. I was starting to worry that my new bought machine (ThinkPad t460s) had a hardware issue. I can corroborate this. Sometimes I get a flicker of distortion, other times it's a flicker of all out blackness. How severe was the flickering for you? For me it's maybe once every other minute that I get some flicker, it does not seem to be related to any input from my side. – Morten Frisch Apr 13 '16 at 12:43
  • It was very severe. Every few seconds. I couldn't work. – hakunamatata Apr 18 '16 at 11:14
  • I'm just curious if the flickering is like this in the video: youtube.com/watch?v=TqAljJ0U5Pc – nasser alshammari Apr 23 '16 at 21:38
  • I have a Lenovo Yoga 13 (Ubuntu + Gnome3) and I get a similar problem. similar to the video above. Its about as frequent but the flicker tends to be the entire tab bar in chrome or menu bar in my editor. It happen more when I mouse over some element of the UI. I upgrade my kernel to 4.5.6 and it happens less now. But hasn't gone away. – eSniff Jul 24 '16 at 20:15

17 Answers 17

24

@brianjcohen led me in the right direction. The Bug report on chromium had some good discussions on some background on the issue, but apparently it's somewhat of an x.org issue with Intel driver options. You can reference it here if you'd like:

https://bugs.chromium.org/p/chromium/issues/detail?id=606152#c63

To fix it, create or edit the file at /usr/share/X11/xorg.conf.d/20-intel.conf as root with the following:

Section "Device"
    Identifier "Intel Graphics"
    Driver "intel"
    Option "AccelMethod" "sna"
    Option "TearFree" "true"
    Option "DRI" "3"
EndSection
  • From the discussion, the AccelMethod should by default be sna, but apparently not explicitly setting it as such could cause X to crash. sna is definitely faster than downgrading it to uxa.
  • TearFree helps prevent tears in video rendering
  • DRI is a method on how the driver renders things, I think this was the key option. You can find out a whole bunch on what it is here: https://en.wikipedia.org/wiki/Direct_Rendering_Infrastructure#DRI3
  • You can also read the man page at man 4 intel
  • these settings fixed flickering in chrome but problems in skype remained. "uxa" fixed both – Anton Suslov Sep 2 '16 at 15:18
  • Doing this caused massive CPU load to compiz and xorg after a reboot – MattBoothDev Sep 20 '16 at 10:04
  • Fixed my Chromium issues, Xorg does increase CPU load but only when the screen is updating. Chromium can also take up to one CPU core (i7-7700T) for full-screen video, but I don't know if that's a change from the previous behavior because I hadn't checked. – Coderer May 26 '17 at 6:49
  • This worked for me on HP EliteBook 850 G3 and my issues were with the screen in general regardless of the application. Dual monitors connected via docking station. Now, it's all smooth and fast, no extra CPU used either. – Ron Smith Aug 2 '18 at 0:12
8

UPDATE: Yesterday, I freshly installed Ubuntu GNOME 16.04. It came with an up to date kernel version: 4.4.0-18. It seems to have solved the Screen Flickering issue for me (at least until now). Aditionally, the physical buttons of the touchpad work as intended (i.e. scrolling and drag & drop are working). There seems to be some Screen Tearing in web browsers (firefox and chromium). But it really is not comparable to the Screen Flickering issue before. In firefox, I managed to get rid off the Screen Tearing by disabling "smooth scrolling" option. Unfortunately, the same procedure doesn't seem to help in chromium.

  • I'm running 4.4.0-18 and the flickering seems to have stopped. Although it was still present on 4.4.0-17. The new kernel seem to have solved the issue. – Morten Frisch Apr 13 '16 at 19:04
  • The previous issue with freezing upon suspension that has been an issue with the ThinkPad T460s also seems to have been solved by the 4.4.0-18 kernel update. – Morten Frisch Apr 14 '16 at 11:48
  • Interesting. I do have flickering issues with 4.4.0-18, unless I make Mike O'Connell's sna => uxa option change (see below). What resolution are you running at? – brianjcohen Apr 15 '16 at 0:43
  • 2
    Try booting into the BIOS (control-escape while the machine is running to activate function-lock, then F1 when the machine turns on) and toggle the graphics memory from the default 256mb up to 512mb. I believe this has resolved the flickering issues for me, even with SNA on. – brianjcohen Apr 19 '16 at 11:49
  • 1
    The suggestion by @brianjcohen worked for me (Lenovo ThinkPad x260). Such a simple solution - thanks! – zooglash Aug 23 '16 at 10:04
6

I had this issue on my new Lenovo X1 Carbon running stock 16.04 (4.4.0-33 kernel, Skylake GT2 graphics). I tried two of the answers above (basicdays and Mike O'Connell's) but neither worked. The former caused the graphics to be unusably slow; the latter failed to initialise the graphics at all.

In the end I solved the problem by the other method mentioned here, that is: I removed the problematic Intel-specific graphics driver. All seems good so far - no flickering in Chrome and some glitchy behaviour in other apps seems to have gone away too.

In short, run this and then reboot and all should be good:

sudo apt-get purge xserver-xorg-video-intel
5

Try:

Switching the intel driver from SNA to UXA helped me quite a bit (on a dell skylake here).

Section "Device"
   Identifier  "Intel Graphics"
   Driver      "intel"
   Option      "AccelMethod"  "uxa"
EndSection

Add this to xorg config by adding to a file in /usr/share/X11/xorg.conf.d

  • 1
    Thanks for your tip. When I tried applying it, I realized something odd. In the /usr/share/X11/xorg.conf.d directory there was no configuration file for the intel grahpics. The only configuration file for graphics was named 10-amdgpu.conf. Any idea why this could be? Should I just try removing the 10-amdgpu.conf file and replace it with another file named 20-intel.conf? – hakunamatata Apr 1 '16 at 20:19
  • Just leave the existing files alone. – Mike O'Connell Apr 7 '16 at 17:37
  • Thanks -- this seemed to solve the flickering issues. I did notice, however, that the number of available resolutions in the Display settings decreased substantially once I did this. From what I can tell about UXA and SNA without getting too deep into it, I can see why this might have happened. – brianjcohen Apr 15 '16 at 0:41
  • This "works" for me (the screen was flicker free), but it makes everything run really really slow. I checked top and the X11 server was using 85-90% of the CPU. – Ron Smith Aug 2 '18 at 0:01
2

An user from reddit reported that kernel 4.6.0-994-generic from the Intel DRM branch ( http://kernel.ubuntu.com/~kernel-ppa/mainline/drm-intel-nightly/current/ ) fixed his screen flickering.

  • Seems to work for me I was on 4.9.0-15 BayTrail , had a lot of flickering on i915.and using daily build 4.10.0-994 the flickering has dissapeared so far – David Walker Feb 8 '17 at 13:33
  • Spoke too soon. I am now on 4.10.0-994 and the flickering is back! – David Walker Mar 11 '17 at 20:18
2

I'm not 100% certain this is the same issue everyone else is having. But the issue I had (Lenovo T460s, Skylake running 16.04) was that I would experience single-frame flickering and occasional tearing in Google Chrome, especially if video or animated effects were on the page. The problem was not reproducible in Firefox. I was able to resolve the issue by starting Chrome with --disable-gpu-driver-bug-workarounds --enable-native-gpu-memory-buffers, followed by resetting all experimental flags to default by going to chrome://flags. The explanation, I believe, is that by default (and I'm not sure if this is Ubuntu-specific or not) there are, as the flag implies, workarounds to known GPU bugs enabled, and I think these workarounds are no longer necessary and are actually counterproductive.

More info here: https://bugs.chromium.org/p/chromium/issues/detail?id=606152

To add these startup switches to my Chrome launcher I did the following:

  1. Open the Dash and type 'chrome'.
  2. Drag the Chrome icon to any folder (I used my home folder)
  3. Right click the icon in my home folder and click Properties
  4. In the Command box, add the switches after "%U".
  5. Drag the Chrome icon to my launcher to lock it there.

Edit: I'm running 4.4.0-22.39, and I have not tried this on any other kernel releases.

2

I did find the following kernel boot parameters to try since they affect screen flicker after trying some of the noted Xorg fixes (either):

  • Disable RC6 sleep modes: i915.enable_rc6=0 OR
  • Disable Panel Self Refresh i915.enable_psr=0

More information here .

To add these, create and edit /etc/modprobe.d/i915.conf with

options i915.preliminary_hw_support=1 i915.enable_psr=0

or try

options i915.preliminary_hw_support=1 i915.enable_rc6=0

I then restarted to make use of these new module options and tested for flicker by sleep/wake cycles. None seemed to help. As for 16.10, the i915.preliminary_hw_support=1 portion may not be necessary.

  • I forgot to mention I am also using Intel's newest drivers from here for Linux. – m1st0 Jan 5 '17 at 6:15
1

I had the same problem an I ended up disabling tlp in /etc/default/tlp. changing TLP_ENABLE=1 to TLP_ENABLE=0.

It looks like power management causes the flickering.

this solution may affect your battery life.

1

Here's what I had to do to eliminate screen tearing and flickering in my Ubuntu 16.04:

sudo apt-get install xserver-xorg-video-intel libva-intel-vaapi-driver

Create and edit ~/.drirc:

<device screen="0" driver="dri2">
    <application name="Default">
    <option name="vblank_mode" value="0"/>
    </application>
 </device>

Create and edit /usr/share/X11/xorg.conf.d/20-intel.conf:

Section "Device"
  Identifier "Intel Graphics"
  Driver     "intel"
  Option     "AccelMethod" "sna"
  Option     "TearFree" "true"
  Option     "DRI" "3"
EndSection

The above almost does the trick. However, there is a persistent Kernel bug in recent Kernel versions (up from 4.0 until the latest 4.8), which produces flickering exactly like in this video: https://www.youtube.com/watch?v=TqAljJ0U5Pc.

However, if you use a really old kernel the flickering stops.

Download and install an old kernel:

wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.13.11.11-trusty/linux-image-3.13.11-03131111-generic_3.13.11-03131111.201411111336_amd64.deb
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.13.11.11-trusty/linux-headers-3.13.11-03131111_3.13.11-03131111.201411111336_all.deb
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.13.11.11-trusty/linux-headers-3.13.11-03131111-generic_3.13.11-03131111.201411111336_amd64.deb

sudo dpkg -i linux-headers-3.13.11-03131111_3.13.11-03131111.201411111336_all.deb linux-headers-3.13.11-03131111-generic_3.13.11-03131111.201411111336_amd64.deb linux-image-3.13.11-03131111-generic_3.13.11-03131111.201411111336_amd64.deb

Last thing to do is to make the above kernel the default one.

Edit /etc/default/grub and change/add the following line:

GRUB_DEFAULT="Advanced options for Ubuntu>Ubuntu, with Linux 3.13.11-03131111-generic"

And finally, update grub:

sudo update-grub
1

I also had the same problem on a Lenovo Yoga 2 Pro running 16.04 + Gnome Shell.

Video: https://www.youtube.com/watch?v=j_NNn1S_nX8

The screen flashing would occur after 10 minutes sometimes, or 2 hours other times. It would stop while the mouse was moving, and I was able to temporarily stop it for maybe an hour or so by switching consoles via ctrl-alt-f1. I've tried everything in this thread with no success, however I came across a bug report which mentioned changing kernels to 4.4.0-040400. I'm 12 hours in since the kernel downgrade from 4.6, and the flickering is gone!

This is the kernel I used. Simply install these, and uninstall the old kernel. http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.4-wily/

0

kernel 4.6.0-994-generic, from the link posted by Massimiliano fixed the problem for me.

I have an Acer Chromebook with a i5-5200U processor. The symptom was hat I was getting flicker when first booted up the laptop. I would have to close and open the lid a few times to fix the problem.

Since I installed 4.6.0-994-generic it works OK.

0

I have just upgraded to 16.04 from 15.10 on a Dell inspiron 3000 with nvidia geforce graphics. There was very annoying flickering. The thing that fixed it for me was to change the default screen brightness. Brighter or lower fixed it. Going back to the default level brought the flickering back.

0

I had the same Problem on a XPS 13 9350. (Kernel 4.4.0-22-generic) I dont now what the Problem is. I think It starts after installing Skype?! It was not flickering after installing ubuntu. it starts a few days later and i think it starts after installing skype? But I´m not sure ;-(

installing the latest kernel (4.6.0-040600-generic) fixed the Problem.

here is a easy way to install the latest kernel version: https://www.youtube.com/watch?v=CokrHUykkUQ

thanks by Massimiliano he brings the best tip!!!

0

I was facing the same problem here with my Dell XPS13 Intel® HD Graphics 520 (Skylake GT2). I'm running Ubuntu 16.04 Xenial and I just solved this problem in System Settings -> Software & Updates -> Additional Drivers, enabling the ' Using Processor microcode firmware for intel CPUs from intel-microcode(proprietary)' and then reboot. Hope it works for you as well!

0

Have had the same problem testing Mint 18 on Samsung 9, i7-6500u.

Consistent with the poster above who solved it by turning off tlp, I found the flickering only occurs when I use powertop to select:

"Autosuspend for unknown USB device 1-5 (8087:0a2b)

from "bad" to "good", i.e. turning on this autosuspend with "good" causes flickering, "bad" does not.

With this left to "bad" my display is stable.

0

I had a similar problem, and reached this thread seeking a solution.

While upgrading the kernel to 4.8 improved the situation, what solved it for me was installing Intel Graphics for Linux drivers:

https://01.org/linuxgraphics/downloads

Note that for Ubuntu 16.04, you need v2.0.2 and not the latest (currently v2.0.3)

https://01.org/linuxgraphics/downloads/intel-graphics-update-tool-linux-os-v2.0.2

0

Is it the one with the black lines? I have got that same issue on my samsung ultrabook, it only happens at full "1080P" resolution on my hdmi port. i've observed that this seems to happen most if the screen is really bright, mainly if there is a white background like in "Files or a web browser" but it seems its not really affected by gpu intensive apps like "playing 1080p movies" only the color or brightness sets it seems to set it off?

its not a fix but its a workaround until they release an update that fixes the issue.

Setting the resolution one down from full 1080p seems to stop it, you could try that if you still having issues :)

EDIT: Also try the kernel 4.8.10 This is the "only" kernel that permanently fix the black lines at 1080P for me with an intel HD4000 HDMI output, all other releases seem to have undone that fix from that one on, even 4.9 doesn't fix it. Use the ubuntu kernel update utility to give it a shot "Ukuu" i think its called?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.