Bug 32003

Summary: [arrandale] flicker after KMS turns on, hp probook 5320m
Product: xorg Reporter: Rene Peinthor <peinthor>
Component: Driver/intelAssignee: Carl Worth <cworth>
Status: RESOLVED FIXED QA Contact: Xorg Project Team <xorg-team>
Severity: major    
Priority: medium Keywords: NEEDINFO
Version: git   
Hardware: x86-64 (AMD64)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Bug Depends on: 32005    
Bug Blocks:    
Attachments:
Description Flags
dmesg output with drm.debug=0xe
none
xorg log with flicker
none
xrandr --verbose
none
dmesg output 2.6.36.1 with no flicker none

Description Rene Peinthor 2010-11-30 09:05:32 UTC
As I have a black screen with the current 2.6.36 arch linux kernel as soon as KMS kicks in.

 I tried a recent git kernel 2.6.37-rc3, there I got a picture but I have a constant flicker all over the screen. This happens in KMS text and in xorg.
It's very very annoying and not really usable.
Comment 1 Chris Wilson 2010-12-01 11:26:58 UTC
This is likely to be yet another broken eDP machine. dmesg (with drm.debug=0xe), Xorg.log, xrandr, and intel_reg_dumper would be useful to confirm that and to rule out any other obvious bug.

If it is eDP related, this will probably help:

commit 3cf2efb1a7c68d55d60dcb2ed9609e1a2fc25952
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Mon Nov 29 10:09:55 2010 +0000

    Revert "drm/i915/dp: use VBT provided eDP params if available"

which is in -fixes and working its way upstream.
Comment 2 Rene Peinthor 2010-12-01 23:57:32 UTC
Created attachment 40727 [details]
dmesg output with drm.debug=0xe
Comment 3 Rene Peinthor 2010-12-01 23:59:08 UTC
Created attachment 40728 [details]
xorg log with flicker
Comment 4 Rene Peinthor 2010-12-01 23:59:42 UTC
Created attachment 40729 [details]
xrandr --verbose
Comment 5 Rene Peinthor 2010-12-02 00:01:09 UTC
reverting "drm/i915/dp: use VBT provided eDP params if available" didn't help, still the same behavior.

i'll try to bisect and find the commit responsibly for this bug.
Comment 6 Rene Peinthor 2010-12-02 00:07:36 UTC
Created attachment 40731 [details]
dmesg output 2.6.36.1 with no flicker
Comment 7 Rene Peinthor 2010-12-02 03:29:07 UTC
I found the commit responsibly for the flicker:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=549f7365820a212a1cfd0871d377b1ad0d1e5723

However this commit also fixes the blank screen problem I have/had.

Another way I fixed the blank screen problem is described here:
https://bugs.freedesktop.org/show_bug.cgi?id=32005
Comment 8 Chris Wilson 2010-12-02 03:41:45 UTC
(In reply to comment #7)
> I found the commit responsibly for the flicker:
> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=549f7365820a212a1cfd0871d377b1ad0d1e5723

You are 100% convinced that your bisection is correct? Even on a second read, that appears perfectly innocuous for your hardware.
Comment 9 Rene Peinthor 2010-12-02 04:21:40 UTC
I'm sorry I mixed something up checking out correct branches. This commit isn't the faulty one, will reinvestigate.
Comment 10 Rene Peinthor 2010-12-02 23:10:51 UTC
I couldn't find the exact commit so far, but I have a small range of commits which introduced the flicker.

I have no flicker with this commit:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=814948adec172dbc41252b1815e4e83aedfe91b9

but the display remains black a long time, but I don't know the cause of that because I had to patch the function "static void intel_dp_dpms(struct drm_encoder *encoder, int mode)" to see anything at all.

The next commit I could see something again, but WITH flicker was:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=01cb9ea633ddf3e8770dfe7851e88610087098bc

leaving following commits for the flicker issue:
* 01cb9ea633ddf3e8770dfe7851e88610087098bc "drm/i915/dp: eDP power sequencing fixes"
* 5c5313c8db9bfb549e080fc4cb0a4c3c2aa7a73d "drm/i915: fix CPU vs PCH eDP confusion"
* 1d85036278f1b3eb3b7c5db805e5c4c847d1415d "drm/i915: remove broken intel_pch_has_edp function"

I also tried to revert some of the commits and build with 7f8232826842b27525857615262f50fe66c84dd7. With following results:
* reverted 5c5313c8db9bfb549e080fc4cb0a4c3c2aa7a73d "drm/i915: fix CPU vs PCH eDP confusion" - still flicker
* reverted 01cb9ea633ddf3e8770dfe7851e88610087098bc "drm/i915/dp: eDP power sequencing fixes" - just a black screen for me, no chance to see a flicker ;)
* reverted 1d85036278f1b3eb3b7c5db805e5c4c847d1415d "drm/i915: remove broken intel_pch_has_edp function" - didn't try yet, because it doesn't look like its responsible for the flicker. but i will try as soon i have time.
Comment 11 Chris Wilson 2010-12-07 03:32:21 UTC
I think the first step here is to resolve bug 32005 so we have a semi-working base upon which to investigate.
Comment 12 Jesse Barnes 2011-01-17 10:44:54 UTC
This one could be fixed by "drm/i915: skip FDI & PCH enabling for DP_A" on intel-gfx.
Comment 13 Rene Peinthor 2011-01-17 11:05:19 UTC
(In reply to comment #12)
> This one could be fixed by "drm/i915: skip FDI & PCH enabling for DP_A" on
> intel-gfx.

Sorry I'm not able to find this commit. Can you point me to this patch/repo/branch/whatever?

Thanks!
Comment 14 Chris Wilson 2011-01-19 05:49:04 UTC
All the relevant patches are now in drm-intel-next: http://git.kernel.org/?p=linux/kernel/git/ickle/drm-intel.git
Comment 15 Rene Peinthor 2011-01-20 02:33:59 UTC
Sadly I couldn't directly use the drm-intel-next branch, as of now 2.6.38-rc1 doesn't boot on my laptop. But this seems to be completely unrelated to the intel-gfx driver.

I used
891cc2283216bf76f387546f0e220caf8ce9fbf9 Merge branch 'drm-intel-fixes' of git://git./linux/kernel/git/ickle/drm-intel
as base and patched the following patches:
0001-drm-i915-Use-ACPI-OpRegion-to-determine-lid-status.patch
0002-drm-i915-don-t-enable-plane-pipe-and-PLL-prematurely.patch
0003-drm-i915-add-pipe-plane-enable-disable-functions.patch
0004-drm-i915-add-panel-lock-assertion-function.patch
0005-drm-i915-add-PLL-enable-disable-functions.patch
0006-drm-i915-add-PCH-DPLL-enable-disable-functions.patch
0007-drm-i915-assert-panel-is-unlocked-before-writing-tra.patch
0008-drm-i915-add-transcoder-enable-disable-functions.patch
0009-drm-i915-factor-out-FDI-disable-and-add-FDI-assertio.patch
0010-drm-i915-set-phase-sync-pointer-override-enable-befo.patch
0011-drm-i915-skip-FDI-PCH-enabling-for-DP_A.patch

And no flicker anymore!

How likely is a fix for 2.6.37 for this? or do I have to backport the needed patches on my own?
Comment 16 Chris Wilson 2011-01-20 02:43:04 UTC
I had one regression report of that series, hence why I put them into -next rather than directly into -fixes. For the time being that's where they will stay, so stick with your working kernel or continue to apply that merge.

-next will be tracking the rc kernels so should become bootable as soon as mainline does, if that is a consolation.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.