LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   Missing vga_switcheroo userspace interface (http://www.linuxquestions.org/questions/slackware-14/missing-vga_switcheroo-userspace-interface-4175436951/)

sanjioh 11-13-2012 10:17 AM

Missing vga_switcheroo userspace interface
 
Hi everybody,

I'm trying to turn off the Radeon 7730m in my notebook (Dell Inspiron 15R SE or model 7520), without much success.
I know it has a mux-less kind of switchable graphics, so the point here at the moment is just managing to turn off the discrete board and use only the integrated one (hd4000).
AFAIK, the way to go is vga_switcheroo. So this is what i did (Slackware 14, huge kernel 3.2.29):

- blacklist radeon module (/etc/modprobe.d/blacklist.conf with the line: blacklist radeon)
- fstab with the line:
none /sys/kernel/debug debugfs defaults 0 0
to mount debugfs at boot
- modprobe radeon after boot (I can read in /var/log/messages something similar to:
Jul 4 12:44:00 darkstar kernel: [ 8.609135] VGA switcheroo: detected switching method \_SB_.PCI0.GFX0.ATPX handle)

At this point, I should be able to:

cat /sys/kernel/debug/vgaswitcheroo/switch

Instead, /sys/kernel/debug doesn't contain any vgaswitcheroo directory (the mount is working because I can see other directories inside).

What am I missing? I can provide any kind of log if that could help.

Thanks a lot!

tuxbg 11-14-2012 05:53 AM

Quote:

Originally Posted by sanjioh (Post 4828496)
Hi everybody,

I'm trying to turn off the Radeon 7730m in my notebook (Dell Inspiron 15R SE or model 7520), without much success.
I know it has a mux-less kind of switchable graphics, so the point here at the moment is just managing to turn off the discrete board and use only the integrated one (hd4000).
AFAIK, the way to go is vga_switcheroo. So this is what i did (Slackware 14, huge kernel 3.2.29):

- blacklist radeon module (/etc/modprobe.d/blacklist.conf with the line: blacklist radeon)
- fstab with the line:
none /sys/kernel/debug debugfs defaults 0 0
to mount debugfs at boot
- modprobe radeon after boot (I can read in /var/log/messages something similar to:
Jul 4 12:44:00 darkstar kernel: [ 8.609135] VGA switcheroo: detected switching method \_SB_.PCI0.GFX0.ATPX handle)

At this point, I should be able to:

cat /sys/kernel/debug/vgaswitcheroo/switch

Instead, /sys/kernel/debug doesn't contain any vgaswitcheroo directory (the mount is working because I can see other directories inside).

What am I missing? I can provide any kind of log if that could help.

Thanks a lot!


Look this http://en.gentoo-wiki.com/wiki/Vga_switcheroo

sanjioh 11-14-2012 06:55 AM

hi, thanks for your answer.
unfortunately I've already read that guide (among others) again and again, but with no success.
I'm following every step (see list in my previous post), but no /sys/kernel/debug/vgaswitcheroo directory appears.

may the huge kernel be the reason?

thanks again!

tuxbg 11-14-2012 08:07 AM

Why are you modprobing radeon module?
If i understand you corectly you wont to disable ati am i right?
Create this file in /etc/modprobe.d/radeon.conf or in lilo nomodeset
or in /etc/modprobe.d/radeon.conf add these lines options radeon modeset=0

sanjioh 11-14-2012 09:25 AM

Apparently, vga_switcheroo interface appears upon loading of the radeon module, and only if both boards (intel and amd) have modesetting enabled.
The blacklisting prevents the radeon module to be loaded at boot, causing a blank screen.
So, to my understanding, the procedure is:

- boot with radeon blacklisted
- modprobe radeon -> vga_switcheroo interface enables
- turn off ati board witch echo OFF > /sys/kernel/debug/vga_switcheroo/switch

I'm stuck at point 2.


EDIT: source: https://wiki.archlinux.org/index.php/Hybrid_graphics

colorpurple21859 11-14-2012 09:25 AM

What does lsmod show. Do not set use nomodeset/modeset=0 and do not blacklist radeon. For vgaswitcheroo to work need the radeon drive to be there during boot up.

sanjioh 11-14-2012 09:28 AM

hi colorpurple21859,
thanks for your reply.
I'll post the result of lsmod as soon as I go home from work.
Are you sure that radeon module shouldn't be blacklisted?

colorpurple21859 11-14-2012 09:32 AM

Yes I have a HP laptop with hd6770m ati graphics and I use the radeon driver.

colorpurple21859 11-14-2012 09:34 AM

I put the
Code:

echo OFF > /sys/kernel/debug/vga_switcheroo/switch
in the /etc/rc.d/rc.local to turn off the discrete card during bootup.

sanjioh 11-14-2012 09:35 AM

Yes, that was my idea too.
I'll try and let you know :)

sanjioh 11-15-2012 10:17 AM

Mhh, maybe the solution is simpler than I thought:
http://kernelnewbies.org/Linux_3.4#h...7c6f87702c3d9a

I'll jump directly to Kernel 3.6.6 (using Pat's config for 3.6-rc4 as a base) and see how it goes.

:)

Didier Spaier 11-15-2012 04:44 PM

Not sure it can help but I just posted an how-to. Just to be sure I would type as root:
Code:

grep switcheroo /var/log/messages
and see what I come up with.

sanjioh 11-17-2012 07:00 PM

hi, fortunately my guess was right, and I was dumb enough not to read about which kernel version supported my board. kernel 3.6.6 works fine and I have /sys/kernel/debug/vgaswitcheroo/switch interface, so I can turn the discrete chip off.

does anybody know if some special action is required upon suspend/resume/reboot/shutdown? i'd like to avoid blank screens or worst :)

thanks!

GmeSalazar 07-30-2013 09:41 PM

I came across the same issue today. For documentation purposes, I think it's worth posting a possible solution. Check [1] out (edit).

---------- Post added 07-30-13 at 09:42 PM ----------

[1] http://blog.desdelinux.net/vgaswitch...das-en-debian/


All times are GMT -5. The time now is 05:01 PM.