public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] switching between "nvidia / nouveau" drivers
@ 2013-02-24  4:30 Joseph
  2013-02-25 15:10 ` Paul Hartman
  0 siblings, 1 reply; 4+ messages in thread
From: Joseph @ 2013-02-24  4:30 UTC (permalink / raw
  To: gentoo-user

I'm trying to prevent next disaster with nvidia driver/kernel combination.
I'm running "nvidia" driver and installed "nouveau" as module.  If for any reason nvidia or nouveau will stop working I want to just run a sript and use other one.

Here is my configuration:

cat /etc/modprobe.d/blacklist.conf
blacklist nouveau

cat /etc/X11/xorg.conf
Section "Device"
     Identifier "Nvidia card"
     Driver     "nvidia"
EndSection

eselect opengl list
Available OpenGL implementations:
   [1]   nvidia *
   [2]   xorg-x11

In order to switch it to "nouveau" I would need to unload the nvidia module, but I can not do it when it is in use so I need to stop "xdm" first, am I correct? 

/etc/init.d/xdm stop (X crashes at this moment)
modprobe -r nvidia
mv /etc/modprobe.d/blacklist.conf /etc/modprobe.d/blacklist.conf_backup
mv /etc/X11/xorg.conf  /etc/X11/xorg.conf_nvidia
eselect opengl set xorg-x11
modprobe nouveau
mv /etc/X11/xorg.conf_nouveau /etc/X11/xorg.conf
/etc/init.d/xdm start (at this moment I should have login screen)

Did I miss anything? Will it work if I put it into a bash script?

-- 
Joseph


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

* Re: [gentoo-user] switching between "nvidia / nouveau" drivers
  2013-02-24  4:30 [gentoo-user] switching between "nvidia / nouveau" drivers Joseph
@ 2013-02-25 15:10 ` Paul Hartman
  2013-02-25 15:34   ` Paul Hartman
  2013-02-25 19:14   ` Joseph
  0 siblings, 2 replies; 4+ messages in thread
From: Paul Hartman @ 2013-02-25 15:10 UTC (permalink / raw
  To: gentoo-user

On Sat, Feb 23, 2013 at 10:30 PM, Joseph <syscon780@gmail.com> wrote:
> I'm trying to prevent next disaster with nvidia driver/kernel combination.
> I'm running "nvidia" driver and installed "nouveau" as module.  If for any
> reason nvidia or nouveau will stop working I want to just run a sript and
> use other one.
>
> Here is my configuration:
>
> cat /etc/modprobe.d/blacklist.conf
> blacklist nouveau
>
> cat /etc/X11/xorg.conf
> Section "Device"
>     Identifier "Nvidia card"
>     Driver     "nvidia"
> EndSection
>
> eselect opengl list
> Available OpenGL implementations:
>   [1]   nvidia *
>   [2]   xorg-x11
>
> In order to switch it to "nouveau" I would need to unload the nvidia module,
> but I can not do it when it is in use so I need to stop "xdm" first, am I
> correct?
> /etc/init.d/xdm stop (X crashes at this moment)
> modprobe -r nvidia
> mv /etc/modprobe.d/blacklist.conf /etc/modprobe.d/blacklist.conf_backup
> mv /etc/X11/xorg.conf  /etc/X11/xorg.conf_nvidia
> eselect opengl set xorg-x11
> modprobe nouveau
> mv /etc/X11/xorg.conf_nouveau /etc/X11/xorg.conf
> /etc/init.d/xdm start (at this moment I should have login screen)
>
> Did I miss anything? Will it work if I put it into a bash script?

What about console framebuffer (if you use one) and KMS? I wonder if
you need to do something about those.


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

* Re: [gentoo-user] switching between "nvidia / nouveau" drivers
  2013-02-25 15:10 ` Paul Hartman
@ 2013-02-25 15:34   ` Paul Hartman
  2013-02-25 19:14   ` Joseph
  1 sibling, 0 replies; 4+ messages in thread
From: Paul Hartman @ 2013-02-25 15:34 UTC (permalink / raw
  To: gentoo-user

On Mon, Feb 25, 2013 at 9:10 AM, Paul Hartman
<paul.hartman+gentoo@gmail.com> wrote:
> On Sat, Feb 23, 2013 at 10:30 PM, Joseph <syscon780@gmail.com> wrote:
>> I'm trying to prevent next disaster with nvidia driver/kernel combination.
>> I'm running "nvidia" driver and installed "nouveau" as module.  If for any
>> reason nvidia or nouveau will stop working I want to just run a sript and
>> use other one.
>>
>> Here is my configuration:
>>
>> cat /etc/modprobe.d/blacklist.conf
>> blacklist nouveau
>>
>> cat /etc/X11/xorg.conf
>> Section "Device"
>>     Identifier "Nvidia card"
>>     Driver     "nvidia"
>> EndSection
>>
>> eselect opengl list
>> Available OpenGL implementations:
>>   [1]   nvidia *
>>   [2]   xorg-x11
>>
>> In order to switch it to "nouveau" I would need to unload the nvidia module,
>> but I can not do it when it is in use so I need to stop "xdm" first, am I
>> correct?
>> /etc/init.d/xdm stop (X crashes at this moment)
>> modprobe -r nvidia
>> mv /etc/modprobe.d/blacklist.conf /etc/modprobe.d/blacklist.conf_backup
>> mv /etc/X11/xorg.conf  /etc/X11/xorg.conf_nvidia
>> eselect opengl set xorg-x11
>> modprobe nouveau
>> mv /etc/X11/xorg.conf_nouveau /etc/X11/xorg.conf
>> /etc/init.d/xdm start (at this moment I should have login screen)
>>
>> Did I miss anything? Will it work if I put it into a bash script?
>
> What about console framebuffer (if you use one) and KMS? I wonder if
> you need to do something about those.

I found some info about toggling KMS and framebuffer in the nouveau wiki:

http://nouveau.freedesktop.org/wiki/KernelModeSetting


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

* Re: [gentoo-user] switching between "nvidia / nouveau" drivers
  2013-02-25 15:10 ` Paul Hartman
  2013-02-25 15:34   ` Paul Hartman
@ 2013-02-25 19:14   ` Joseph
  1 sibling, 0 replies; 4+ messages in thread
From: Joseph @ 2013-02-25 19:14 UTC (permalink / raw
  To: gentoo-user

On 02/25/13 09:10, Paul Hartman wrote:
>On Sat, Feb 23, 2013 at 10:30 PM, Joseph <syscon780@gmail.com> wrote:
>> I'm trying to prevent next disaster with nvidia driver/kernel combination.
>> I'm running "nvidia" driver and installed "nouveau" as module.  If for any
>> reason nvidia or nouveau will stop working I want to just run a sript and
>> use other one.
>>
>> Here is my configuration:
>>
>> cat /etc/modprobe.d/blacklist.conf
>> blacklist nouveau
>>
>> cat /etc/X11/xorg.conf
>> Section "Device"
>>     Identifier "Nvidia card"
>>     Driver     "nvidia"
>> EndSection
>>
>> eselect opengl list
>> Available OpenGL implementations:
>>   [1]   nvidia *
>>   [2]   xorg-x11
>>
>> In order to switch it to "nouveau" I would need to unload the nvidia module,
>> but I can not do it when it is in use so I need to stop "xdm" first, am I
>> correct?
>> /etc/init.d/xdm stop (X crashes at this moment)
>> modprobe -r nvidia
>> mv /etc/modprobe.d/blacklist.conf /etc/modprobe.d/blacklist.conf_backup
>> mv /etc/X11/xorg.conf  /etc/X11/xorg.conf_nvidia
>> eselect opengl set xorg-x11
>> modprobe nouveau
>> mv /etc/X11/xorg.conf_nouveau /etc/X11/xorg.conf
>> /etc/init.d/xdm start (at this moment I should have login screen)
>>
>> Did I miss anything? Will it work if I put it into a bash script?
>
>What about console framebuffer (if you use one) and KMS? I wonder if
>you need to do something about those.

I've solved this problem. It is not possible to switch without rebooting, so the correct procedure would be:

CORRECT PROCES TO FOLLOW to switch between nvidia and noveau.
(assuming the kernel is using "nvidia") to switch to noveau:

mv /etc/modprobe.d/blacklist.conf_nvidia /etc/modprobe.d/blacklist.conf
eselect opengl set xorg-x11
mv /etc/X11/xorg.conf_nouveau /etc/X11/xorg.conf
reboot

Assuming:
cat blacklist.conf_nouveau
blacklist nouveau

cat blacklist.conf_nvidia
blacklist nvidia

cat xorg.conf_nouveau
# uncomment when the card gets IN

Section "Device"
     Identifier "nouveau"
     Driver     "nouveau"
EndSection

at xorg.conf_nvidia
Section "Device"
     Identifier "Nvidia card"
     Driver     "nvidia"
EndSection


-- 
Joseph


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

end of thread, other threads:[~2013-02-25 19:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-24  4:30 [gentoo-user] switching between "nvidia / nouveau" drivers Joseph
2013-02-25 15:10 ` Paul Hartman
2013-02-25 15:34   ` Paul Hartman
2013-02-25 19:14   ` Joseph

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox