From b3214826507fefd74f1b2c708827d01a120820af Mon Sep 17 00:00:00 2001 From: Lekensteyn Date: Tue, 27 Dec 2011 19:46:22 +0100 Subject: [PATCH] Added README Taken from https://github.com/Lekensteyn/acpi-stuff --- README.md | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..e32db52 --- /dev/null +++ b/README.md @@ -0,0 +1,55 @@ +*Migrated from https://github.com/Lekensteyn/acpi-stuff* + +bbswitch is a kernel module which automatically detects the required ACPI calls +for two kinds of Optimus laptops. It has been verified to work with "real" +Optimus and "legacy" Optimus laptops (at least, that is how I call them). The +machines on which these tests has performed are: + +- Clevo B7130 - GT 425M ("real" Optimus, Lekensteyns laptop) +- Dell Vostro 3500 - GT 310M ("legacy" Optimus, Samsagax' laptop) + +(note: there is no need to add more supported laptops here as the universal +calls should work for every laptop model supporting either Optimus calls) + +It's preferred over manually hacking with the acpi_call module because it can +detect the correct handle preceding _DSM and has some built-in safeguards: + +- You're not allowed to disable a card if a driver (nouveau, nvidia) is loaded. +- Before suspend, the card is automatically enabled. When resuming, it's + disabled again if that was the case before suspending. Hibernation should + work, but it not tested. + +To use it, build the module first (kernel headers are required): + + make +Then load it (requires root privileges, i.e. `sudo`): + + make load +If your card is supported, there should be no error. Otherwise, you get a "No +such device" (ENODEV) error. Check your kernel log (dmesg) for more +information. + +Usage (`#` means "run with root privileges, i.e. run it prefixed with `sudo `): + +Get the status: + + # cat /proc/acpi/bbswitch + 0000:01:00.0 ON + +Turn the card off, respectively on: + + # tee /proc/acpi/bbswitch <<