Lekensteyn
2011-Dec-17 12:14 UTC
[Nouveau] properly check for _DSM function support and Optimus support for vga_switcheroo
Hello guys, I've prepared a patch based on my findings for the bbswitch module (https://github.com/Lekensteyn/acpi-stuff/tree/master/bbswitch). This adds a proper check whether a _DSM function is supported or not and make OFF / ON for vga_switcheroo work for nVidia Optimus models. The patch is based against the mainline kernel. It has been tested on my Clevo B7130 laptop running kernel 3.2 which has a GT425M dGPU: # cat /sys/kernel/debug/vgaswitcheroo/switch 0:IGD:+:Pwr:0000:00:02.0 1:DIS: :Pwr:0000:01:00.0 # tee /sys/kernel/debug/vgaswitcheroo/switch <<<OFF OFF # cat /sys/kernel/debug/vgaswitcheroo/switch 0:IGD:+:Pwr:0000:00:02.0 1:DIS: :Off:0000:01:00.0 # tee /sys/kernel/debug/vgaswitcheroo/switch <<<ON ON # cat /sys/kernel/debug/vgaswitcheroo/switch 0:IGD:+:Pwr:0000:00:02.0 1:DIS: :Pwr:0000:01:00.0 The iGPU/dGPU LEDS on the keyboard also change as a result. Regards, Peter -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.freedesktop.org/archives/nouveau/attachments/20111217/cec063c2/attachment.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: nouveau-switcheroo-optimus.patch Type: text/x-diff Size: 8639 bytes Desc: not available URL: <http://lists.freedesktop.org/archives/nouveau/attachments/20111217/cec063c2/attachment.patch>
Lekensteyn
2011-Dec-17 22:50 UTC
[Nouveau] properly check for _DSM function support and Optimus support for vga_switcheroo
Hello guys, I've prepared a patch based on my findings for the bbswitch module (https://github.com/Lekensteyn/acpi-stuff/tree/master/bbswitch). This adds a proper check whether a _DSM function is supported or not and make OFF / ON for vga_switcheroo work for nVidia Optimus models. The patch is based against the mainline kernel. It has been tested on my Clevo B7130 laptop running kernel 3.2 which has a GT425M dGPU: # cat /sys/kernel/debug/vgaswitcheroo/switch 0:IGD:+:Pwr:0000:00:02.0 1:DIS: :Pwr:0000:01:00.0 # tee /sys/kernel/debug/vgaswitcheroo/switch <<<OFF OFF # cat /sys/kernel/debug/vgaswitcheroo/switch 0:IGD:+:Pwr:0000:00:02.0 1:DIS: :Off:0000:01:00.0 # tee /sys/kernel/debug/vgaswitcheroo/switch <<<ON ON # cat /sys/kernel/debug/vgaswitcheroo/switch 0:IGD:+:Pwr:0000:00:02.0 1:DIS: :Pwr:0000:01:00.0 The iGPU/dGPU LEDS on the keyboard also change as a result. A second patch to make the device stay off after suspend is in progress. Regards, Peter -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.freedesktop.org/archives/nouveau/attachments/20111217/f6ccae88/attachment.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: nouveau-switcheroo-optimus.patch Type: text/x-diff Size: 8639 bytes Desc: not available URL: <http://lists.freedesktop.org/archives/nouveau/attachments/20111217/f6ccae88/attachment.patch>
Seemingly Similar Threads
- [Bug 86503] New: Discrete card seems to be powered on even if reported as Off
- [Bug 108058] New: After resuming from suspend, discrete GPU is powered on and can't be turned off
- [Bug 70895] New: BUG: soft lockup - CPU#0 stuck for 22s! [Xorg:1292] after disable descrete card with switcheroo
- [Bug 98398] Vgaswitcharoo fails to turn off GPU properly
- [Bug 70875] New: [NVC0] NOUVEAU(0): [drm] failed to set drm interface version