Fri 14 Dec 2007
XGL and Xen can mix on a T61p!
Posted by natewc under Desktop, Virtualization
![]()
I write this post from my cube-spinning phenom of a laptop, my Lenovo T61p. Owing to it’s newness, there were a few hiccups configuring SLED 10 SP1. One that caused no small annoyance was getting X working when running the Xen kernel. I tried all kinds of sax2 command line permutations to get even a basic VESA frame buffer configuration working …. all to no avail :(. Thanks to a few wikis at opensuse.org and some great pointers from some fellow geeks, I’m able to use the Nvida driver with the Xen kernel … wait for it, with XGL enabled!
In the event that you have a T61p or a laptop with a similar Nvidia card, the following steps should get you going:
1. Download the Linux 100.14.11 version of the NVIDIA graphics driver. Available here for 32-bit and here for 64-bit (AMD64/EM64T). The full *NIX Nvidia driver download page is here.
2. On a non-xen kernel (default, smp, etc.), install the driver and make sure it works. Full directions are available here. In a nutshell, make sure you have kernel-source, gcc and make installed. Drop to runlevel 3 (init 3) and run installer:
sh NVIDIA*.run
3. Download this patch: patch-xen3.0-nvidia100.14.11.txt
4. Ensure runlevel 3 is your default. Make sure these lines in /etc/inittab looks like this:
# The default runlevel is defined here
id:3:initdefault:
5. Reboot your system and load the xen kernel
6. Prepare the kernel source:
cd /usr/src/linux
cp arch/i386/defconfig.xen .config (for 32-bit or)
cp arch/x86_64/defconfig.xen .config (for 64-bit)
make oldconfig && make scripts && make prepare
7. Extract the drivers only from the Nvidia package:
sh NVIDIA* --extract-only
8. Patch the drivers:
cd NVIDIA-Linux-<arch>-100.14.11-pkg2/usr/src/nv/
patch -p1 < <path_to_patch>/patch-xen3.0-nvidia100.14.11.txt
9. Build the drivers:
CC="gcc -DNV_VMAP_4_PRESENT -DNV_SIGNAL_STRUCT_RLIM" make SYSSRC=/usr/src/linux module
10. Install the driver, rebuild the module dependencies and load the driver:
(run uname -r to determine your xen kernel-version)
cp nvidia.ko /lib/modules/<kernel-version>-xen/kernel/drivers/video/
cd /lib/modules/<kernel-version>-xen/kernel/drivers/video/
depmod -a
modprobe nvidia
11. Change to runlevel 5 to start X:
init 5
12. Once you’ve verified X is working, you can drop back to runlevel 3 and enable XGL from the command line:
(be warned: this step is optional as XGL under Xen can cause X take more than its fair share of cpu cycles)
init 3
gnome-xgl-switch --enable-xgl
init 5
13. Change default runlevel back to 5. Make sure these lines in /etc/inittab looks like this:
# The default runlevel is defined here
id:5:initdefault:
On a kernel update, you’ll need to repeat these steps (with the exception of 7&8) to get X working again. I hope there’s a kernel module package (kmp) the supports the NVIDIA® Quadro® FX 700 soon … don’t know if we’ll see official Xen support though.
Last 3 posts by natewc
- Canonical Releases On Time; Still Not Profitable... - October 30th, 2008
- XGL and Xen can mix on a T61p! - December 14th, 2007
Last 3 posts by natewc
- Canonical Releases On Time; Still Not Profitable... - October 30th, 2008
- XGL and Xen can mix on a T61p! - December 14th, 2007
Popularity: 24% [?]
7 Responses to “ XGL and Xen can mix on a T61p! ”
Comments:
Leave a Reply
You must be logged in to post a comment.
Trackbacks & Pingbacks:
-
Trackback from fsdaily.com
December 30th, 2007 at 6:18 amStory added
Your story has been submitted to fsdaily.com! Come and promote your article by voting for it here on FSDaily! Let your readers know they can vote for your story too.
-
Pingback from SLES with XEN won't start X correctly? - NOVELL FORUMS
July 4th, 2008 at 7:11 am[...] rn Hi,rnrnI managed to compile nvidia kernel module with instructions found here ..rnrnXGL and Xen can mix on a T61p!



December 16th, 2007 at 5:20 am
great article, thanks!
December 27th, 2007 at 12:48 am
How well does ACPI stuff work? Will the laptop suspend and hybernate? What about battery drainage?
December 31st, 2007 at 11:00 am
@Alain:
ACPI stuff works great for me with the standard x86_64 kernel (not the xen kernel). sleep (s2ram) works well but hibernate (s2disk) seems to have some problems though I have not spent much time on it.
January 7th, 2008 at 11:28 pm
I’m using a T61p with openSUSE 10.3 and the newest nvidia 169.07 driver. Works great in both i586 and x_86_64 default kernels.
The patch doesn’t seem to exactly right for the 169.07 driver (fails on one file), but I’ve read on the nvnews forum forums that the recent driver doesn’t really need to be patched.
I’m trying to just build based on your instructions and am getting “unable to determine the target kernel version”. Something in my /usr/src/linux prep isn’t right, but I followed your instructions. Any idea?
January 8th, 2008 at 6:39 pm
I haven’t tried openSUSE 10.3 on my T61p just yet. The patch was crafted for specific version of the Nvidia driver. There’s likely been some changes in the newer version that are causing the problem. As much as it’s hurts, you’ll probably want to use the older driver that corresponds to the patch to get things working.