MANUAL SWITCHING AND MANUAL POWER CONTROL(9)
โจ Manual switching and manual power control โจ
okay so bestie, this is the Kernel API Manual, section 9, and it is literally all about Manual switching and manual power control. slay. ๐ซถ
๐ธ the mode + the magic file ๐ธ
in this mode of use, the file /sys/kernel/debug/vgaswitcheroo/switch can be read to retrieve the current vga_switcheroo state, and commands can be written to it to change the state. โจ
the file appears as soon as two GPU drivers and one handler have registered with vga_switcheroo. iconic.
๐ commands it understands ๐
OFFโ power off the device not in use. ๐คONโ power on the device not in use. โกIGDโ switch to the integrated graphics device. power on the integrated GPU if necessary, power off the discrete GPU. prerequisite is that no user space processes (e.g.Xorg,alsactl) have opened device files of the GPUs or the audio client. if the switch fails, the user may invokelsof(8)orfuser(1)on/dev/dri/and/dev/snd/controlC1to identify processes blocking the switch. ๐DISโ switch to the discrete graphics device. ๐ฎDIGDโ delayed switch to the integrated graphics device. this will perform the switch once the last user space process has closed the device files of the GPUs and the audio client. โณDDISโ delayed switch to the discrete graphics device. โณMIGDโ mux-only switch to the integrated graphics device. does not remap console or change the power state of either gpu. if the integrated GPU is currently off, the screen will turn black. if it is on, the screen will show whatever happens to be in VRAM. either way, the user has to blindly enter the command to switch back. ๐๐MDISโ mux-only switch to the discrete graphics device. ๐
๐ซถ little caveats ๐ซถ
for GPUs whose power state is controlled by the driver's runtime pm, the ON and OFF commands are a no-op (see next section). ๐
โ ๏ธ for muxless machines, theIGD/DIS,DIGD/DDISandMIGD/MDIScommands should not be used. periodt.
๐ SEE ALSO ๐
- Kernel file
./drivers/gpu/vga/vga_switcheroo.cOverview(9) - struct
vga_switcheroo_client(9) - struct
vgasr_priv(9) vga_switcheroo_register_handler(9)vga_switcheroo_unregister_handler(9)vga_switcheroo_handler_flags(9)vga_switcheroo_register_client(9)vga_switcheroo_register_audio_client(9)vga_switcheroo_client_probe_defer(9)vga_switcheroo_get_client_state(9)vga_switcheroo_unregister_client(9)vga_switcheroo_client_fb_set(9)vga_switcheroo_lock_ddc(9)vga_switcheroo_unlock_ddc(9)vga_switcheroo_process_delayed_switch(9)Driver power control(9)vga_switcheroo_init_domain_pm_ops(9)
mwah ๐ this cutie page is sourced from ./drivers/gpu/vga and dated October 2026. go off, bestie. ๐
๐ฆ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms