Bug 32350 - [RADEON:KMS:RS480:X200M] laptop screen goes crazy after unplugging power adapter
Summary: [RADEON:KMS:RS480:X200M] laptop screen goes crazy after unplugging power adapter
Status: RESOLVED MOVED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/R100 (show other bugs)
Version: unspecified
Hardware: Other All
: high major
Assignee: Default DRI bug account
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 32399
  Show dependency treegraph
 
Reported: 2010-12-13 09:00 UTC by Edgar Villanueva
Modified: 2019-09-18 18:40 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
Xorg log (220.30 KB, patch)
2010-12-13 09:00 UTC, Edgar Villanueva
Details | Splinter Review
dmessage log (122.92 KB, text/plain)
2010-12-13 09:01 UTC, Edgar Villanueva
Details
dmsg without any quirks (122.89 KB, text/plain)
2010-12-13 11:07 UTC, Edgar Villanueva
Details
dmesg output after resume (17.64 KB, text/plain)
2010-12-13 13:12 UTC, Edgar Villanueva
Details
Xorg log showing KMS usage (77.55 KB, application/octet-stream)
2010-12-14 15:22 UTC, Edgar Villanueva
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Edgar Villanueva 2010-12-13 09:00:32 UTC
Created attachment 41066 [details] [review]
Xorg log

Using Fedora 14 and radeon DRI driver.

After unplugging the power adapter the screen starts flashing corrupted video. 
Looks like stair stepping effect.
Comment 1 Edgar Villanueva 2010-12-13 09:01:16 UTC
Created attachment 41067 [details]
dmessage log
Comment 2 Edgar Villanueva 2010-12-13 09:02:57 UTC
Currently laptop not usable without power plugged in.
Comment 3 Alex Deucher 2010-12-13 09:06:45 UTC
Is this only an issue after resume or always?
Comment 4 Edgar Villanueva 2010-12-13 09:14:26 UTC
Rebooted machine to make sure. Definitely after resume.

I made a change to the hal quirks as suspend was not working.
I added s3_bios and s3_mode and that solved my problem.

Any suggestions on what to look out for?

     <match key="system.hardware.product" contains_outof="OmniBook XE3 G;R3200;nx5000;nx7000;nc6120;nx6325;2510p;NX6325;Nx6325">
        <merge key="power_management.quirk.vbe_post" type="bool">true</merge>
        <merge key="power_management.quirk.vbestate_restore" type="bool">true</merge>
        <merge key="power_management.quirk.s3_bios" type="bool">true</merge>
        <merge key="power_management.quirk.s3_mode" type="bool">true</merge>
      </match>
Comment 5 Jerome Glisse 2010-12-13 09:36:29 UTC
Don't add s3_bios & s3_mode this breaks KMS, real issue here is to make your resume works with KMS.
Comment 6 Jerome Glisse 2010-12-13 09:38:18 UTC
What's the issue with suspend without the s3* ? Black screen ? if so can you log in through ssh and get kernel log ? for kernel log please boot with drm.debug=15 or echo 15 to /sys/module/drm/parameters/debug as root before suspending.
Comment 7 Edgar Villanueva 2010-12-13 10:19:38 UTC
Tried a few experiments and here is what I found so far.

- My problem with suspend is only when I switch between dual and single monitor setups.  If I don't switch pm-suspend works with the following quirks
vbe_post,   vbestate_restore.  I did this 3 times but I need to try 10 times to be sure. My test is just sudo pm-suspend.

- After suspend if I pull out the power adapter I get the same "screen goes crazy problem". Which means it's not related to s3 quirks.
Comment 8 Jerome Glisse 2010-12-13 10:34:51 UTC
Please no vbe* stuff it's the same it breaks kms, don't change default fedora configuration it designed to work if it doesn't explain the issue.
Comment 9 Edgar Villanueva 2010-12-13 11:07:35 UTC
Created attachment 41079 [details]
dmsg without any quirks

dmesg after setting debug to 15 right after reboot.
no quirks

Still same issues. 
Probably can't try more than 1 time.

I see some spurious audio hardware message. I'm wondering if this has to do with the hang.... Different issue just pointing it out.

ec 13 14:04:35 evillanueva kernel: [  982.233015] ALSA sound/pci/hda/hda_intel.c:659: spurious response 0x0:0x0, last cmd=0x6f0900
Dec 13 14:04:35 evillanueva kernel: [  982.233015] ALSA sound/pci/hda/hda_intel.c:659: spurious response 0x0:0x0, last cmd=0x6f0900
Dec 13 14:04:35 evillanueva kernel: [  982.233015] ALSA sound/pci/hda/hda_intel.c:659: spurious response 0x0:0x0, last cmd=0x6f0900
Dec 13 14:04:35 evillanueva kernel: [  982.233015] ALSA sound/pci/hda/hda_intel.c:659: spurious response 0x0:0x0, last cmd=0x6f0900
Dec 13 14:04:35 evillanueva kernel: [  982.233015] ALSA sound/pci/hda/hda_intel.c:659: spurious response 0x0:0x0, last cmd=0x6f0900
Dec 13 14:04:35 evillanueva kernel: [  982.233015] ALSA sound/pci/hda/hda_intel.c:659: spurious response 0x0:0x0, last cmd=0x6f0900
Dec 13 14:04:35 evillanueva kernel: [  982.233015] ALSA sound/pci/hda/hda_intel.c:659: spurious response 0x0:0x0, last cmd=0x6f0900
Dec 13 14:04:35 evillanueva kernel: [  982.233015] ALSA sound/pci/hda/hda_intel.c:659: spurious response 0x0:0x0, last cmd=0x6f0900
Dec 13 14:04:41 evillanueva ntpd_intres[3203]: parent died before we finished, exiting
[
Comment 10 Jerome Glisse 2010-12-13 11:32:45 UTC
drm.debug=15 is too verbose. do drm.debug=4 and please describe the issue with suspend resume & attach _full_ dmesg after resume
Comment 11 Edgar Villanueva 2010-12-13 13:12:23 UTC
Created attachment 41085 [details]
dmesg output after resume

dmesg output for the following problem.

- startup laptop
- suspend
- resume
- pull power adapter
- video goes crazy.
- plug power adapter again 
- video stabilizes.
Comment 12 Edgar Villanueva 2010-12-13 13:13:40 UTC
One more piece of info.
I tried to go to nomodeset in the kernel on bootup but that causes X to crash.
If this isn't normal let me know and I'll file a bug.
Comment 13 Edgar Villanueva 2010-12-13 13:46:08 UTC
More updates with nomodeset and radeon.modeset=0

  - Power adapter problem is still there, so it looks like the problem is independent of KMS.

  - Suspend/resume works consistently (no hang) if I add nomodeset and radeon.modeset=0 But....

  - There is a crash when using KDE and mesa when using effects. I disabled effects and no more crash.

Yikes i'm dreading my update from fedora 11 -> 14! :) Looks like regressions with the radeon driver. If someone is really interested in fixing any of this use me while you got me to test provide info.
Comment 14 Edgar Villanueva 2010-12-13 13:48:33 UTC
With no modeset firefox and thunderbird have rendering issues. When you scroll the screen  only updates partially or doesn't update at all.
Comment 15 Edgar Villanueva 2010-12-13 22:17:00 UTC
Tried some more experiments.
- Hibernate doesn't cause the crazyness problem after unplugging the power.  I guess it fully resets the video.
- Tried the latest ati source for the latest radeon driver. Same issues.
- Tried the 6.13.2 ati source. Same issues.
- after hibernate or suspend  redraw is messed up as mentioned in comment 14. If you resize a window it doesn't get updated, same with scrolling. You have to force window update by switching to another window and back. I guess this is an X or driver problem. Happens with all versions of drivers I tried.
Comment 16 Edgar Villanueva 2010-12-14 06:31:12 UTC
Went back to the source of 6.12.3 which is close to what I use to use on fedora 11. Same problems across the board. Can't even use nomodesetting with that. X crashes.
Comment 17 Alex Deucher 2010-12-14 07:06:47 UTC
6.12.x does not support KMS, you need 6.13.x for KMS.
Comment 18 Edgar Villanueva 2010-12-14 13:35:34 UTC
Tried latest ati driver from master. Here are results:
   - pm-hibernate - works, no longer has window refresh problems. Ok with unplugging power adapter.
   - pm-suspend - When it doesn't hang, no refresh problems. Has the crazy issue when unplugging power. When it hangs I can't log into my machine to see what's going on as it passed network interface module suspend.
Comment 19 Edgar Villanueva 2010-12-14 13:37:54 UTC
So we are back to the main issue + 1.
   - After suspend if you unplug the power the video device goes crazy. When you plug the power back in it's ok.
   - Most of the time now with the latest driver I'm luck if I can suspend at all. It hangs the machine pretty far down the process. I'm inclined to say it's the driver because it's not as bad with older versions. I can mostly suspend at least 1 time successfully.
Comment 20 Jerome Glisse 2010-12-14 13:47:59 UTC
Using KMS ?
Comment 21 Edgar Villanueva 2010-12-14 14:44:35 UTC
Yes, using KMS.
Comment 22 Edgar Villanueva 2010-12-14 15:22:40 UTC
Created attachment 41124 [details]
Xorg log showing KMS usage
Comment 23 Edgar Villanueva 2010-12-14 15:49:50 UTC
Slightly different question. I'm noticing some waviness on the screen, especially on a second monitor connected to VGA-0.  Anybody know what might be causing this. Sorry to side track...
Comment 24 Alex Deucher 2010-12-14 15:59:48 UTC
(In reply to comment #23)
> Slightly different question. I'm noticing some waviness on the screen,
> especially on a second monitor connected to VGA-0.  Anybody know what might be
> causing this. Sorry to side track...

Probably bad display watermark setup or the monitor doesn't like the pll dividers.
Comment 25 Edgar Villanueva 2010-12-14 16:15:54 UTC
Anyway to fix that? I looked at the radeon options and neither seems to be the right thing. (LVDS or TDMS PLL) ?

(In reply to comment #24)
> (In reply to comment #23)
> > Slightly different question. I'm noticing some waviness on the screen,
> > especially on a second monitor connected to VGA-0.  Anybody know what might be
> > causing this. Sorry to side track...
> 
> Probably bad display watermark setup or the monitor doesn't like the pll
> dividers.
Comment 26 Alex Deucher 2010-12-14 16:19:07 UTC
(In reply to comment #25)
> Anyway to fix that? I looked at the radeon options and neither seems to be the
> right thing. (LVDS or TDMS PLL) ?

Please open a new bug for that issue so we don't confuse this one.
Comment 27 Edgar Villanueva 2010-12-17 17:59:05 UTC
Did the following test to see if it was a DRI or driver problem.
startup runlevel 1. No X.
pm-suspend

resume.
Screen goes crazy.
Comment 28 Edgar Villanueva 2011-01-31 20:53:13 UTC
I'm still having lots of troubles and I found this particular bug/patch.

http://kerneltrap.org/mailarchive/linux-kernel/2010/6/17/4584404

I'm using 2.6.35.10-74.fc14.x86_64 so this patch should be in there.
My suspend and hibernate behave just like Rafaels does and I essentially have the same machine he does.

Did the patch make it in everywhere?
Comment 29 Alex Deucher 2011-02-01 18:26:30 UTC
(In reply to comment #27)
> Did the following test to see if it was a DRI or driver problem.
> startup runlevel 1. No X.
> pm-suspend
> 
> resume.
> Screen goes crazy.

Does the screen have issues when you unplug the power adapter if the radeon driver is not loaded at all (blacklist the radeon drm and don't start X)?  Sounds to me like a platform issue (maybe ACPI?) rather than a driver issue.
Comment 30 Edgar Villanueva 2011-02-01 22:40:32 UTC
Tried that but it's hard to tell whether it works because when I resume the screen is blank. I need to get the quirks back. Ugg..

Up to fedora 11 kernel 2.6.30 I everything worked perfectly. So I have a hard time believing it's an ACPI issue.
Unfortunately I went from fedora 11 to 14  and didn't validate everything in between.  I tried to go back to non DRM/KMS but that causes X/KDE to crash.

What's weird is from everything I can tell this is working for Rafael and I believe I'm using the same exact machine HP Nx6325.

It's really not only this issue. Suspend to ram is pretty much useless as it hangs more often than not during suspend. Hibernate has the same issue but it works more often than not.

I was hoping everything was related but from the messages you probably don't think they are.



(In reply to comment #29)
> (In reply to comment #27)
> > Did the following test to see if it was a DRI or driver problem.
> > startup runlevel 1. No X.
> > pm-suspend
> > 
> > resume.
> > Screen goes crazy.
> 
> Does the screen have issues when you unplug the power adapter if the radeon
> driver is not loaded at all (blacklist the radeon drm and don't start X)? 
> Sounds to me like a platform issue (maybe ACPI?) rather than a driver issue.
Comment 31 Alex Deucher 2011-02-01 23:04:13 UTC
(In reply to comment #30)
> Tried that but it's hard to tell whether it works because when I resume the
> screen is blank. I need to get the quirks back. Ugg..
> 
> Up to fedora 11 kernel 2.6.30 I everything worked perfectly. So I have a hard
> time believing it's an ACPI issue.

Lots of things in the kernel changed between 2.6.30 and newer kernels, including acpi.  It could also be some hardware component that's starting to fail since your upgrade to F14.  You might also want to try an older or newer kernel (try 2.6.37 or 2.6.38-rcX for example) on your F14 install to see if you have better luck; it may be a problem specific to the F14 kernels.   At the very least it may help narrow down the problem area.  Another thing to try would be to verify that F11 still works (thus not a hw problem) and then bisect between that kernel and more recent one to try and track down when the problem started.
Comment 32 Edgar Villanueva 2011-02-03 06:48:53 UTC
Hi Alex,

I'll go on this mission.
Question:  What's the best way to get an older kernel on fedora?
Looking for a source package that I can get the spec file for to deal with any fedora specific issues.
Comment 33 Alex Deucher 2011-02-03 16:57:11 UTC
(In reply to comment #32)
> Hi Alex,
> 
> I'll go on this mission.
> Question:  What's the best way to get an older kernel on fedora?
> Looking for a source package that I can get the spec file for to deal with any
> fedora specific issues.

The best bet is to check out Linus' git tree and then use the fedora kernel config.  Using the git tree you can check out any kernel version you want and bisect to track down the problematic commit if you track down a working version.

I'm not sure if what kernel versions fedora makes available as binaries; probably only newer ones for testing.  You could try one of those first.
Comment 34 Edgar Villanueva 2011-02-07 19:44:26 UTC
2.6.34.8 exhibits the same problems.

I found the kernel source for fedora 11 that worked but then I realized that I didn't use DRM there as I had problems.

I build the 2.6.30 anyway and hopefully can test it soon. Thought there might be issues as there are some glibc dependancies I don't understand.
Comment 35 GitLab Migration User 2019-09-18 18:40:19 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/mesa/mesa/issues/278.


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.