Running Linux 2.6.16 and Xorg 7.0 on iMac G5 rev C (iSight)

Étienne Bersac bersace03 at laposte.net
Wed Mar 22 11:11:48 EST 2006


Hello,

With the great help of Benjamin Herrenschmidt, i reach to run linux  
and Xorg on an iMac G5 rev C 20" (the iSight line) with an Ati Radeon  
X600 XT Pro (RV380). Make your backup ! You should verify each file i  
ship with this howto. Conf files are available at http:// 
bersace03.free.fr/pub/Linux/iMac%20G5/.

You need at least a 2.6.15-rc1 kernel, a Mac OS X installation and an  
install cd. (I use an ubuntu one). I advice you to make a place for  
linux before installation.

  - Get Ben's kernel at http://bersace03.free.fr/pub/iMac%20G5/ 
vmlinux.bz2 (mirror of http://gate.crashing.org/~benh/vmlinux.bz2).  
bunzip2 it at /.

  - Copy install/yaboot and initrd.gz from the installer to /. Rename  
initrd.gz to initrd-cd.gz. Copy yaboot.conf from the website to /. I  
assume you will install linux in /dev/sda5, if this is not the case,  
edit yaboot.conf

  - Insert your cd. It's time to reboot !

  - Type Option+Command+O+F at boot time. This should open the OF  
terminal.

  -  Type "boot hd:X,yaboot" where X is the number of the Mac OS X  
volume (often 3). Remember this each time you have to use yaboot  
while we have not run "ybin".

  - Choose the "cd" label at yaboot prompt. First questions should  
arrives such as language, country, etc. Then the installation should  
go on.

  - Reboot at the end of the installation, using yaboot from OF prompt.

  - Choose the "rescue" label to boot. Copy the installed initrd.gz  
to your Macintosh Volume, using an usb key/hd/whatever you want. Copy  
this initrd.gz as /initrd-hd.gz at root of your Macintosh Volume.  
Here you may have to change the /yaboot.conf to reflect the  
installation (especially the root=/dev/sda5 option). This might be  
possible to run ybin here, but i'm not sure.

  - Disable the display manager (e.g. update-rc.d -f gdm remove).

  - Now it's time to boot the installed system, still using ben's  
kernel. Choose the "hd" label at yaboot prompt. Once your system is  
booted, configure network (network-manager work fine), install build- 
essential and other good stuffs like kernel-package and fakeroot. Get  
the source ! 2.6.16 is fine. use g5_defconfig as .config and compile  
the kernel.

  - Modify /etc/yaboot.conf, add an entry for your kernel and set it  
as default (of course), add macosx option, etc.. When you are sure,  
run ybin. Now you don't need OF prompt anymore.

  - You may want to restart, but we can continue.


Next step is xorg. You need a special branch of the ati driver for  
xorg. Thanks to the new modular Xorg :)

  - Install automake-1.7, x11proto-*, xserver-xorg-dev, xlibs-dev and  
other stuff you may need to compile this. ./configure will help you.  
The CVSROOT is :pserver:anoncvs at cvs.freedesktop.org:/cvs/xorg . I  
install stuff with --prefix=/usr.

  - Checkout  and install util/macros.

  - Use ati-1-0-branch branch of the ati driver ( http:// 
webcvs.freedesktop.org/xorg/driver/xf86-video-ati/? 
only_with_tag=ati-1-0-branch ). Checkout and install it.

  - Use the xorg.conf available at http://bersace03.free.fr/pub/Linux/ 
iMac%20G5/xorg.conf . I own an iMac G5 20", so if you have the 17"  
one, you must use the result of 'parse-edid $(find /proc/device-tree - 
name EDID)'  as Screen Section, and use the resolution from xresprobe  
radeon in the PanelSize option of the Device Section. You should  
check xorg.conf and track error.

  - Pray and run your display manager (e.g. invocke-rc.d gdm start).  
If you are lucky, you will see the charming waiting cursor and then  
the dm prompt. Eurêka !!

  - If it work, enable your diplays manager with z.B. dpkg- 
reconfigure gdm.

OR

  - If you get a blank screen, try to play with radeon(4) options in  
xorg.conf. Send feedbacks. Blank screen seems to mean that you won't  
see anything while you do not reboot the box. This is where ssh is  
usefull.

This is the end of this howto.

I had had some difficulties to write this howto because i did the two  
step  with several weeks and a lot of failures between them . So i  
might have forgottent some important points. Please send feedbacks.

I really want to thank Benjamin Herrenschmidt who helps me several  
times and does great work to support those computers. Merci Benjamin !

Étienne.




More information about the Linuxppc-dev mailing list