Switch on/off nvidia card Asus UL30Vt, UL50V, UL80V laptops
One of the Linux users has found a solution to switch off the nvidia card in the UL30Vt models, which by the looks of the DSDT tables, will also work for the UL50Vt and UL80Vt models with nvidia card.
If you are using Linux on an Asus UL30Vt, or Asus UL50Vt or Asus UL80Vt, keep reading...
For Ubuntu Karmic, download and install this package:
http://launchpadlibrarian.net/384580...karmic_all.deb
Then once installed, run the following command on a terminal:
sudo modprobe nvidia_g210m_acpi
Explanation:
This method uses the ACPI P0P1.VGA._OFF method, which is the same for all 3 models.
The code file, "asus_nvidia.c" is derived from "lenovo_acpi.c" by Sylvain Joyeux.
Here is the original post and another one that adds hibernation support:
http://forum.notebookreview.com/show...postcount=1239
http://forum.notebookreview.com/show...postcount=1244
asus_nvidia.c
================================================== ======
#include <acpi/acpi.h>
#include <linux/suspend.h>
MODULE_LICENSE("GPL");
static acpi_handle root_handle;
static int kill_nvidia(void)
{
acpi_status status;
// The device handle
acpi_handle handle;
struct acpi_object_list args;
// For the return value
struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL };
status = acpi_get_handle(root_handle, "\\_SB.PCI0.P0P1.VGA._OFF", &handle);
if (ACPI_FAILURE(status))
{
printk("%s: cannot get ACPI handle: %s\n", __func__, acpi_format_exception(status));
return -ENOSYS;
}
args.count = 0;
args.pointer = NULL;
status = acpi_evaluate_object(handle, NULL, &args, &buffer);
if (ACPI_FAILURE(status))
{
printk("%s: _OFF method call failed: %s\n", __func__, acpi_format_exception(status));
return -ENOSYS;
}
kfree(buffer.pointer);
printk("%s: disabled the discrete graphics card\n",__func__);
return 0;
}
static int power_event(struct notifier_block *this, unsigned long event,
void *ptr)
{
switch (event) {
case PM_POST_HIBERNATION:
kill_nvidia();
return NOTIFY_DONE;
case PM_POST_SUSPEND:
case PM_HIBERNATION_PREPARE:
case PM_SUSPEND_PREPARE:
default:
return NOTIFY_DONE;
}
}
static struct notifier_block power_notifier = {
.notifier_call = power_event,
};
static int __init asus_nvidia(void)
{
int ret = register_pm_notifier(&power_notifier);
if (ret) return ret;
return kill_nvidia();
}
static void dummy(void)
{
}
module_init(asus_nvidia);
module_exit(dummy);
================================================== ======
Makefile
================================================== ======
ifneq ($(KERNELRELEASE),)
obj-m := asus_nvidia.o
else
KERNELDIR ?= /lib/modules/$(shell uname -r)/build
PWD := $(shell pwd)
default:
$(MAKE) -C $(KERNELDIR) M=$(PWD) $(EXTRA_FLAGS) modules
clean:
$(MAKE) -C $(KERNELDIR) M=$(PWD) $(EXTRA_FLAGS) clean
endif
================================================== ======
To compile it, simply run:
Code:
make
To install it, run as root:
Code:
cp asus_nvidia.ko /lib/modules/`uname -r`/kernel/
depmod
To try it out, run as root:
Code:
modprobe asus_nvidia
To load it on each reboot on Ubuntu, run as root:
Code:
echo asus_nvidia >>/etc/modules
That last step will be different on other distros, e.g., on Gentoo you need to append the module name to /etc/modules.autoload.d/kernel-2.6.
Re: Switch on/off nvidia card Asus UL30Vt, UL50V, UL80V laptops
Thanks! good find.
On related note, the screen brightness issue, just noticed that the brightness controls work in splashtop.
Re: Switch on/off nvidia card Asus UL30Vt, UL50V, UL80V laptops
Great :D
Works perfect in UL50VT with Debian.
Re: Switch on/off nvidia card Asus UL30Vt, UL50V, UL80V laptops
Thanks alot, makes choosing my next laptop alot easier :)
Re: Switch on/off nvidia card Asus UL30Vt, UL50V, UL80V laptops
Hi, I've make a .deb package (based on the source posted above) for nVidia GeeForce G210M module switch-off for Asus UL30VT, UL50V, UL80V laptops.
I don't have an Asus UL*0V yet, so please test it. Any feedback are welcome.
http://www.sendspace.com/file/jfzr7x
MD5: c418685c256ba4fc52970a2df2802ecf
Re: Switch on/off nvidia card Asus UL30Vt, UL50V, UL80V laptops
How do i switch nvidia on?
Edit: ... It is on by default, problem is to get it route picture to the display (and disable Intel?).
Re: Switch on/off nvidia card Asus UL30Vt, UL50V, UL80V laptops
Wow, great news, will test asap!
But, erm yes indeed, has anyone managed to get the nvidia card to work at all?
Re: Switch on/off nvidia card Asus UL30Vt, UL50V, UL80V laptops
Don't think nvidia driver supports hybrid graphics under linux.
- http://www.nvnews.net/vbulletin/show...d+power&page=3
- http://www.nvnews.net/vbulletin/showthread.php?t=116088
If im not mistaken and this is still the case we should probably poke nvidia with a stick until they cough something up.
Re: Switch on/off nvidia card Asus UL30Vt, UL50V, UL80V laptops
hi
Does this code work for me too ?
I have a dell studio xps1340 with G210m as the discrete card .
Can i switch it off this way ?
Thanks
Re: Switch on/off nvidia card Asus UL30Vt, UL50V, UL80V laptops
Quote:
Originally Posted by
blackmoon105
Hi, I've make a .deb package (based on the source posted above) for nVidia GeeForce G210M module switch-off for Asus UL30VT, UL50V, UL80V laptops.
I don't have an Asus UL*0V yet, so please test it. Any feedback are welcome.
http://www.sendspace.com/file/jfzr7x
MD5:
c418685c256ba4fc52970a2df2802ecf
The deb didn't work for me.
Here's the last few lines from it:
depmod....
DKMS: install completed.
FATAL: Module rt73 not found.
dpkg: error processiong nvidia-g210m-acpi-source (--install):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
nvidia-g210m-acpi-source
Also, I'm pretty new to linux and have always had trouble getting make to work.
I made a directory with asus_nvidia.c and Makefile, with the code copied and pasted from above. When I cd to the directory and run make, all I get is:
make: Nothing to be done for `default'.
Should I modify the make file? I'm not sure what the code in it does.
Can someone help me out? I'd love to get this nvidia card turned off until they have good drivers.
Thanks,
Marc