|Summary:||New PM-Code produces white screen on laptop display on startup on an radeon x700|
|Product:||Drivers||Reporter:||Jan Kreuzer (kontrollator)|
|Component:||Video(DRI - non Intel)||Assignee:||drivers_video-dri|
|Severity:||normal||CC:||alexdeucher, maciej.rutecki, rjw|
|Bug Depends on:|
Description Jan Kreuzer 2010-07-14 17:57:06 UTC
After the merge of the new-pm code for radeon it get an all white screen on my laptop display as soon as kms gets activated. Before the merge it worked as long as i used radeon.dynpm=1 as boot parameter (without this parameter i also get an all white screen with earlier kernels). I can work around it with an vbetool dpms off / on cycle (which uses bios routines i think), i tried all options / combinations of radeon.hw_i2c and radeon.new_pll without success. I also get an all white laptop-screen as soon as i change resolutions on my display, this also can be workaround with an vbetool dpms off / on cycle. This also happens in the non-kms-case with the xorg-driver whenever i change resolutions, in the old days i could workaround it with the MonitorLayout "LVDS, none" option, however this option is long gone. Chipset is an mobility radeon x700 pcie, pci-id is: 1002:5653 Please tell me what more information is needed. Thank you Jan Kreuzer
Comment 1 Alex Deucher 2010-07-14 18:14:13 UTC
What kernel are you using? Can you bisect what exact commit broke it? I seem to recall that you had this issue before on older kernels and it just starting working at some point. I don't think the pm code is to blame per se, as it's not enabled by default. Also, note that dynpm is no longer a valid module parameter with the new pm code.
Comment 2 Jan Kreuzer 2010-07-15 05:04:26 UTC
Currently on airlieds drm-radeon-testing, but the same happens with mainline. I did an bisect run before, i will attach the log. However just reverting the commit didnt help, so i dont think the log is right. I also think that new pm-code is not to blame, i guess that activativing the old code on boot time with the dynpm option led to an longer initializing time of the chipset. I am not an programmer, but looked at the code of r420.c, the old code kicked in after the initialize of the clocks, maybe more time is needed there ? But maybe i am wrong, i added about 50 printks after radeon_get_clock_info(rdev->ddev); sometimes it works no, sometimes not. I had the issue since the beginning of radeon-kms, it started working after i used the dynpm option at boot time, never without.
Comment 4 Jan Kreuzer 2010-07-20 08:33:28 UTC
Looking at fdo-bug 22755 i found another way to put the screen into an usable stae after resolution switch: xrandr -s 1024x768; xrandr --output LVDS --off; xrandr --output LVDS --auto works (i think it is the same call as vbetool dpms off / on). Without turning the output off and on i get the white screen. Whats the difference between boot-time initialization of the screen (which does not work) and the initialization with the xrandr off / on call (which works) ?
Comment 5 Alex Deucher 2010-07-20 16:08:48 UTC
(In reply to comment #4) > Looking at fdo-bug 22755 i found another way to put the screen into an usable > stae after resolution switch: > xrandr -s 1024x768; xrandr --output LVDS --off; xrandr --output LVDS --auto > works (i think it is the same call as vbetool dpms off / on). > Without turning the output off and on i get the white screen. Whats the > difference between boot-time initialization of the screen (which does not > work) > and the initialization with the xrandr off / on call (which works) ? Nothing. Both use the same path in the driver. I suspect this is a timing issue with the LVDS. Your system probably needs a longer/shorter delay somewhere in the LVDS dpms code. Can you try adjusting the delays in radeon_legacy_lvds_dpms() in radeon_legacy_encoders.c? Can you also try something like this: diff --git a/drivers/gpu/drm/radeon/radeon_legacy_encoders.c b/drivers/gpu/drm/radeon/radeon_legacy_encoders.c index bad77f4..5688a0c 100644 --- a/drivers/gpu/drm/radeon/radeon_legacy_encoders.c +++ b/drivers/gpu/drm/radeon/radeon_legacy_encoders.c @@ -108,6 +108,7 @@ static void radeon_legacy_lvds_dpms(struct drm_encoder *encoder, int mode) udelay(panel_pwr_delay * 1000); WREG32(RADEON_LVDS_GEN_CNTL, lvds_gen_cntl); WREG32_PLL(RADEON_PIXCLKS_CNTL, pixclks_cntl); + udelay(panel_pwr_delay * 1000); break; }
Comment 6 Rafael J. Wysocki 2010-07-21 21:36:15 UTC
Handled-By : Alex Deucher <firstname.lastname@example.org>
Comment 7 Jan Kreuzer 2010-07-21 22:22:51 UTC
Adding the udelay as mentioned in your patch solves the whitescreen on startup and on resolution switching on latest linux-git and on latest drm-radeon-testing, so this seems to be the right fix. Thank you. I Will close the bug as soon its commited to mainline.
Comment 8 Alex Deucher 2010-07-21 23:39:28 UTC
I've sent the patch to Dave.
Comment 9 Jan Kreuzer 2010-07-23 07:42:08 UTC
Fixed in commit 15cb02c0a0338ee724bf23e31c7c410ecbffeeba