From Fedora Project Wiki

Description

This test case test GPU switching feature in some laptops. Both Optimus (nVidia + Intel) and PowerXpress (ATI + Intel) are supported.

Setup

Enable nVidia Optimus or ATI PowerXpress in your BIOS setup.

Check if you have both graphics available: lspci | grep 'VGA'

Add the following line to /etc/fstab:

none            /sys/kernel/debug debugfs defaults 0 0

Mount debugfs: mount /sys/kernel/debug

How to test

  1. Check which GPU you are using right now: glxinfo | grep 'OpenGL renderer' Usually integrated GPU (Intel) is default.
  2. Switch to discrete graphics: echo "DDIS" > /sys/kernel/debug/vgaswitcheroo/switch.
  3. Restart X. Usually logout and login back to session is enough.
  4. Check which GPU you are using: glxinfo | grep 'OpenGL renderer' It should be discrete GPU (nVidia or ATI)
  5. Switch to integrated graphics: echo "DIGD" > /sys/kernel/debug/vgaswitcheroo/switch.
  6. Restart X. Usually logout and login back to session is enough.
  7. Check which GPU you are using: glxinfo | grep 'OpenGL renderer' It should be integrated GPU (Intel).

Expected Results

  1. You should successfully switch between GPUs when X restarts, without freezes, graphical artefacts or etc.
  2. Desktop should work with both GPUs. Applications known to work in single GPU mode should work in hybrid graphics modes as well.