Announcement

Collapse
No announcement yet.

Hybrid ATI/ATI - Intel/ATI solution: small switcheroo how to

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #31
    Originally posted by rmartinez View Post
    the only thing is that when you turn off the computer with one of the cards turned off; then, when you turn on the computer again the fan runs at full speed. So, to avoid this I also made a script "switch_before_shutdown.sh".
    Since I switch off the discrete card during boot process (/etc/rc.d/c.local) the fan stays quiet.

    cya

    Comment


    • #32
      Originally posted by paul! View Post
      Since I switch off the discrete card during boot process (/etc/rc.d/c.local) the fan stays quiet.

      cya
      Thanks, it works great to avoid choosing every time the integrated card when the computer is initiated. So I did:
      Code:
      $ sudo gedit /etc/rc.d/rc.local
      And added the following lines:
      Code:
      mount -t debugfs none /sys/kernel/debug
      echo OFF > /sys/kernel/debug/vgaswitcheroo/switch
      But even though it serves to avoid choosing the initial card configuration, it does not resolve the fan problem. I made some reboots and saw that the fan running at full speed only happens when I turn off the computer (not when rebooting) while having the integrated card ON and functioning, and the discrete card OFF. To avoid this I must be with the integrated card OFF and the discrete ON and functioning, or with both cards ON.

      That is why I still need the script that before turning off the computer checks and turns ON both cards.

      Comment


      • #33
        Why don't you mount debugfs in the fstab? Also whats the output of:

        ls -l /sys/kernel/debug/vgaswitcheroo/switch

        Comment


        • #34
          Originally posted by Kano View Post
          Why don't you mount debugfs in the fstab?
          Yes, that could be a good alternative. Thanks.

          Also whats the output of:

          ls -l /sys/kernel/debug/vgaswitcheroo/switch
          -rw-r--r-- 1 root root 0 2010-03-05 09:03 /sys/kernel/debug/vgaswitcheroo/switch

          Why?

          Comment


          • #35
            Well when it would not be root:root but something in another group like video or so then you would not need root rights just in the correct group. It would be more logical to use root:video 664 or so.

            Comment


            • #36
              Originally posted by Kano View Post
              Well when it would not be root:root but something in another group like video or so then you would not need root rights just in the correct group. It would be more logical to use root:video 664 or so.
              Mmm... Good! I will try that and post after launch! Thanks.

              Comment


              • #37
                Originally posted by Kano View Post
                Well when it would not be root:root but something in another group like video or so then you would not need root rights just in the correct group. It would be more logical to use root:video 664 or so.
                I have been reading a little bit and I found this:

                Mount options for debugfs
                The debugfs file system is a pseudo file system, traditionally mounted on /sys/kernel/debug. There are no mount options. (*)

                So, if there are no options to mount debugfs, how can I mount it so that it gives other permission? I got to mount it with fstab with this line:
                Code:
                 none /sys/kernel/debug debugfs default 0 0
                But no matter what options I tested (other than "default"), it has always has same permissions. What I'm doing wrong? Or because it has no mounting options the default cannot be changed?

                Comment


                • #38
                  The permission/owner/groups are most likely set in the driver itself. Ask the author.

                  Comment


                  • #39
                    I got it!! With just this line added at rc.local you can then switch cards without being su:
                    Code:
                    chown "username" /sys/kernel/debug/vgaswitcheroo/switch
                    Now I'm almost there to make the "switch_between_cards.sh" utilizable to normal user without being su! I just have to find something to replace the "sudo killall -u 'username'" to logout...

                    Comment


                    • #40
                      That's a stupid hack but would work. Why not change the kernel code? Btw. do you know

                      kill -9 -1

                      Do not try as root!

                      Comment

                      Working...
                      X