All of lore.kernel.org
 help / color / mirror / Atom feed
* [Bug 60606] New: vga_switcheroo / new Radeon DPM code mess up fbcon
@ 2013-07-22 19:55 bugzilla-daemon
  2013-07-22 20:16 ` [Bug 60606] " bugzilla-daemon
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: bugzilla-daemon @ 2013-07-22 19:55 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=60606

            Bug ID: 60606
           Summary: vga_switcheroo / new Radeon DPM code mess up fbcon
           Product: Drivers
           Version: 2.5
    Kernel Version: 3.11.0-rc2
          Hardware: All
                OS: Linux
              Tree: Mainline
            Status: NEW
          Severity: normal
          Priority: P1
         Component: Video(DRI - non Intel)
          Assignee: drivers_video-dri@kernel-bugs.osdl.org
          Reporter: sebastien.fievet@free.fr
        Regression: No

Created attachment 106987
  --> https://bugzilla.kernel.org/attachment.cgi?id=106987&action=edit
radeon switch OFF / switch ON experiment

I am the happy owner of an hybrid Intel core i5 480M / AMD Radeon 6550M latop.
- IGP is Intel ironlake
- DGD is AMD radeon 6550M

I just installed kernel 3.11.0-rc2.
switching the discrete GPU OFF via the vgaswticheroo works from within X or
from the console :
  echo OFF > /sys/kernel/debug/vgaswitcheroo/switch
  cat /sys/kernel/debug/vgaswitcheroo/switch 
  0:IGD:+:Pwr:0000:00:02.0
  1:DIS: :Pwr:0000:02:00.0
  2:DIS-Audio: :Pwr:0000:02:00.1

I then tried to switch the radeon back ON from the console with X down :
  echo ON > /sys/kernel/debug/vgaswitcheroo/switch

It messed up the console display : screen turned to dominant grey scattered
with coloured pixels making it unreadable, forcing me to reboot.
The attachment is the excerpt of my kern.log file for my radeon switch OFF /
switch ON experiment.

switch off is at [   76.634983]
switch on is at  [ 2167.936488] or [ 2167.936517] 

I also noticed :
[    5.457569] ACPI Warning: \_SB_.PCI0.GFX0._DSM: Argument #4 type mismatch -
Found [Integer], ACPI requires [Package] (20130517/nsarguments-95)
[    5.457739] ACPI Warning: \_SB_.PCI0.GFX0._DSM: Argument #4 type mismatch -
Found [Integer], ACPI requires [Package] (20130517/nsarguments-95)

which seems to be related to vgaswitcheroo setup, but I don't know if it's
relevant or not.

Let me know if you need anything else.
thanks for your help,
Seb.

-- 
You are receiving this mail because:
You are watching the assignee of the bug.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug 60606] vga_switcheroo / new Radeon DPM code mess up fbcon
  2013-07-22 19:55 [Bug 60606] New: vga_switcheroo / new Radeon DPM code mess up fbcon bugzilla-daemon
@ 2013-07-22 20:16 ` bugzilla-daemon
  2013-08-05 12:33 ` bugzilla-daemon
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: bugzilla-daemon @ 2013-07-22 20:16 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=60606

--- Comment #1 from Sebastien Fievet <sebastien.fievet@free.fr> ---
I did proofread my report, but missed a obvious mistake :

  cat /sys/kernel/debug/vgaswitcheroo/switch 
  0:IGD:+:Pwr:0000:00:02.0
  1:DIS: :Pwr:0000:02:00.0
  2:DIS-Audio: :Pwr:0000:02:00.1

  echo OFF > /sys/kernel/debug/vgaswitcheroo/switch
  cat /sys/kernel/debug/vgaswitcheroo/switch 
  0:IGD:+:Pwr:0000:00:02.0
  1:DIS: :Off:0000:02:00.0
  2:DIS-Audio: :Off:0000:02:00.1

all apologies.

-- 
You are receiving this mail because:
You are watching the assignee of the bug.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug 60606] vga_switcheroo / new Radeon DPM code mess up fbcon
  2013-07-22 19:55 [Bug 60606] New: vga_switcheroo / new Radeon DPM code mess up fbcon bugzilla-daemon
  2013-07-22 20:16 ` [Bug 60606] " bugzilla-daemon
@ 2013-08-05 12:33 ` bugzilla-daemon
  2013-08-08  7:00 ` bugzilla-daemon
  2013-08-08 10:10 ` bugzilla-daemon
  3 siblings, 0 replies; 5+ messages in thread
From: bugzilla-daemon @ 2013-08-05 12:33 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=60606

--- Comment #2 from Sebastien Fievet <sebastien.fievet@free.fr> ---
After a *lot* of googling effort, I managed to narrow down and find a
workaround to this bug.
- First, my mistake was to have an xorg.conf.d directory defining the video
drivers. 
  Letting X auto detect the driver was the necessary first step.

- Second I applied the "drm/i915: do not disable backlight on vgaswitcheroo
switch off" patch referenced in
https://bugs.freedesktop.org/show_bug.cgi?id=59785
  It made switching from IGD to discrete functional, but switching away from
IGD with discrete OFF was still screwing up the display.

- Finally, I found
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1077675, which was
reporting the exact same bug as I was experiencing.
  Same hardware, same issue. Same workaround : echoing MIGD to
/sys/kernel/debug/vgaswitcheroo/switch restores display when discrete is
  switched back ON

- I am now on 3.11.0-rc4 + drm/i915 patch and everything works fine (with the
workaround)

Conclusion :
  1. DPM is not involved at all.
  2. Switcheroo doesn't fully support Acer 3820TG hybrid (muxed) laptop out of
the box, but workaround exists.

If anyone wants to investigate further, I'll be glad to provide any relevant
information.
Thanks,
Seb.

-- 
You are receiving this mail because:
You are watching the assignee of the bug.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug 60606] vga_switcheroo / new Radeon DPM code mess up fbcon
  2013-07-22 19:55 [Bug 60606] New: vga_switcheroo / new Radeon DPM code mess up fbcon bugzilla-daemon
  2013-07-22 20:16 ` [Bug 60606] " bugzilla-daemon
  2013-08-05 12:33 ` bugzilla-daemon
@ 2013-08-08  7:00 ` bugzilla-daemon
  2013-08-08 10:10 ` bugzilla-daemon
  3 siblings, 0 replies; 5+ messages in thread
From: bugzilla-daemon @ 2013-08-08  7:00 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=60606

--- Comment #3 from Jani Nikula <jani.nikula@intel.com> ---
Sebastien, to confirm, you need "drm/i915: do not disable backlight on
vgaswitcheroo switch off" to be able to switch from IGD to DIS? So having that
is an improvement? And without that, the workarounds won't help?

-- 
You are receiving this mail because:
You are watching the assignee of the bug.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug 60606] vga_switcheroo / new Radeon DPM code mess up fbcon
  2013-07-22 19:55 [Bug 60606] New: vga_switcheroo / new Radeon DPM code mess up fbcon bugzilla-daemon
                   ` (2 preceding siblings ...)
  2013-08-08  7:00 ` bugzilla-daemon
@ 2013-08-08 10:10 ` bugzilla-daemon
  3 siblings, 0 replies; 5+ messages in thread
From: bugzilla-daemon @ 2013-08-08 10:10 UTC (permalink / raw)
  To: dri-devel

https://bugzilla.kernel.org/show_bug.cgi?id=60606

--- Comment #4 from Sebastien Fievet <sebastien.fievet@free.fr> ---
(In reply to Jani Nikula from comment #3)
I reverted the patch and double checked. The workaround is enough for me.
What I do is :
1. echo OFF > /sys/kernel/debug/vgaswitcheroo/switch at init time with a rc
script. Hence I always start on the IGD with the DIS OFF : 
  cat /sys/kernel/debug/vgaswitcheroo/switch
  0:DIS: :Off:0000:02:00.0
  1:DIS-Audio: :Off:0000:02:00.1
  2:IGD:+:Pwr:0000:00:02.0

2. to switch from IGD to DIS I do :
  for cmd in "ON MIGD DDIS"; do
    echo $cmd > /sys/kernel/debug/vgaswitcheroo/switch
  done
The screen flickers a bit during the OFF -> ON -> MIGD transition
  cat /sys/kernel/debug/vgaswitcheroo/switch
  0:DIS: :Pwr:0000:02:00.0
  1:DIS-Audio: :Pwr:0000:02:00.1
  2:IGD:+:Pwr:0000:00:02.0

3.I logout/login to X. To switch back to IGD I do :
  for cmd in "ON DIGD"; do
    echo $cmd > /sys/kernel/debug/vgaswitcheroo/switch
  done
The screen doesn't flicker.

=> I can cycle through IGD and DIS at will.

When testing your patch I was starting with both IGD and DIS ON. So initial
conditions were different :-(. Then :
1. echo DDIS > /sys/kernel/debug/vgaswitcheroo/switch worked, while without
your patch it didn't.
2. logout/login to X
  echo DIGD > /sys/kernel/debug/vgaswitcheroo/switch worked.
3. logout/login to X
  echo DDIS > /sys/kernel/debug/vgaswitcheroo/switch screwed up the display.

So I think I have been abused by the favourable initial conditions I used when
testing your patch. Let me know if you need anything else.

-- 
You are receiving this mail because:
You are watching the assignee of the bug.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-08-08 10:10 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-22 19:55 [Bug 60606] New: vga_switcheroo / new Radeon DPM code mess up fbcon bugzilla-daemon
2013-07-22 20:16 ` [Bug 60606] " bugzilla-daemon
2013-08-05 12:33 ` bugzilla-daemon
2013-08-08  7:00 ` bugzilla-daemon
2013-08-08 10:10 ` bugzilla-daemon

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.