Sunday, October 04, 2009


DRM for Radeon HD 4650,4750 & PVOPS Kernel 2.6.31.1


The most recent features of Jeremy Fitzhardinge kernel have been enabled and
tested at Xen 3.5 Dom0 on top of Ubuntu Karmic Koala (Beta) Server.
Xen host been built reboots directly into Gnome Desttop environment on the
box with Core2Quad CPU, 8 GB RAM, Radeon HD 4X50 Video Card. Tuning 2.6.31.1
described in details bellow with snapshots of every configuration step been
taken. Deployment Xen Unstable to Ubuntu Karmic Server environment was done
in same way as [1] and is also briefly documented. Xen 3.5 Dom0 with 2.6.31.1
pvops kernel has been verified via F12 (rawhide) PV DomU install.


First – install on Uubuntu 9.10 Server all packages required for Xen build:-

apt-get install libcurl4-openssl-dev \
xserver-xorg-dev \
python2.6-dev \
mercurial gitk \
build-essential \
libncurses5-dev \
uuid-dev gawk \
gettext texinfo bcc

Second step :-

# cd /usr/src
# hg clone http://xenbits.xensource.com/xen-unstable.hg
# cd xen-unstable.hg
Set in Config.mk
PYTHON = python
PYTHON_PREFIX_ARG =
# make xen
# make tools
# make install-xen
# make install-tools

Tuning Config.mk results Xen packages to be placed into /usr/local/lib/python2.6/dist-packages due to Changeset 19594 in xen-unstable.hg. Otherwise, Xen packages would go to /usr/lib/python2.6/site-packages, which is not default location for python 2.6 on Ubuntu 9.10 ( vs F11,F12 ). Thus you won’t be able to start xend in Dom0.
Kernel tuning to turn on Xen Dom0 Support and DRM support for Radeon Video Card.

# git clone git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen.git linux-2.6-xen
# cd linux-2.6-xen
# make menuconfig
















# make -j(x)(number_of_kernels)
# make modules_install install
# mkinitramfs -o /boot/initrd-2.6.31.1.img 2.6.31.1

Update file /etc/default/grub as follows

GRUB_DEFAULT=0
# GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=10
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console
# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
GRUB_DISABLE_LINUX_UUID=true
# Uncomment to disable generation of recovery mode menu entrys
#GRUB_DISABLE_LINUX_RECOVERY="true"
GRUB_CMDLINE_LINUX=""

Update /etc/grub.d/40_cutom as follows

#!/bin/sh
exec tail -n +3 $0
# This file is an example on how to add custom entries
menuentry "Xen 3.4 / Ubuntu 9.10 kernel 2.6.31-rc6 pvops" {
insmod ext2
set root=(hd1,1)
multiboot (hd1,1)/xen-3.5.gz
module (hd0,13)/vmlinuz-2.6.31.1
module (hd0,13)/initrd-2.6.31.1.img
}

Then run

# update-grub

To generate grub.cfg entry for loading Xen Host and reboot via new grub2 entry





Setup F12 PV DomU

# wget http://download.fedora.redhat.com/pub/fedora/linux/development/x86_64/os/isolinux/vmlinuz
# wget http://download.fedora.redhat.com/pub/fedora/linux/development/x86_64/os/isolinux/initrd.img

Create installation profile

name="VMF12PV"
memory=2048
disk = ['phy:/dev/sdc7,xvda,w' ]
vif = [ 'bridge=eth1' ]
vfb = [ 'type=vnc,vncunused=1']
kernel = "/home/boris/fedora/vmlinuz"
ramdisk = "/home/boris/fedora/initrd.img"
vcpus=2
on_reboot = 'restart'
on_crash = 'restart'


# xm create f12.install
# vncviewer localhost:0









Runtime profile

name="VMF12"
memory=2048
kernel="/home/boris/vmlinuz-2.6.31.1-56.fc12.x86_64"
ramdisk="/home/boris/initramfs-2.6.31.1-56.fc12.x86_64.img"
disk = ['phy:/dev/sdc7,xvda,w' ]
vif = [ 'bridge=eth1' ]
root="/dev/mapper/vg_fedora-lv_root ro"
vfb = [ 'type=vnc,vncunused=1']
vcpus=2
on_reboot = 'restart'
on_crash = 'restart'