Sound Working on Post-February 2005 12″ G4 Powerbook

The Debian Sarge net install for ppc doesn’t get sound working on the most recent Powerbooks. To make it work we need to apply Ben’s patch to the most recent kernel. This took me forever to figure out, but here it is in eight easy steps.

1. Download and prepare the Linux 2.6.11 source
cd /usr/src
wget http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.11.tar.bz2
tar -jxf linux-2.6.11.tar.bz2
rm linux
ln -s linux-2.6.11 linux

2. Download and apply the Linux 2.6.12-rc2 patch
cd linux
wget http://kernel.org/pub/linux/kernel/v2.6/testing/patch-2.6.12-rc2.bz2
bunzip2 patch-2.6.12-rc2.bz2
patch -p1 <patch-2.6.12-rc2

3. Download and apply Ben’s powerbook sound patch
wget http://sharealike.net/debian/ppc/benssoundpatch
patch -p1 <benssoundpatch

4. Compile your patched kernel
make menuconfig # be sure to include ATA 100 support or your kernel won’t boot.
make-kpkg clean
make-kpkg –append-to-version=.050416 kernel_image # 050416 is the date in YYMMDD format

5. Prepare to install the compiled and patched kernel
Take a look at your /boot directory. There is a vmlinuz and an initrd.img file for the standard Debian kernel, but your new kernel will not need an initrd.img file, and will just have a vmlinuz file. If you want to keep several kernels available for use then note the names of their vmlinuz files for when we edit yaboot.conf in the next step. Now to install the kernel:

cd /usr/src
dpkg -i kernel-image-2.6.12-rc2.050416_10.00.Custom_powerpc.deb # Note again that your YYMMDD version will likely differ.

6. Edit your yaboot.conf file
vi /etc/yaboot.conf

You’ll want something like mine:

boot=/dev/hda3
device=/pci@f4000000/ata-6@d/disk@0:
partition=5
root=/dev/hda5
timeout=100
install=/usr/lib/yaboot/yaboot
magicboot=/usr/lib/yaboot/ofboot
enablecdboot
macosx=/dev/hda6

image=/boot/vmlinux
label=Linux-2.6.12
read-only

image=/boot/vmlinux-2.6.8-powerpc
label=Linux-2.6.8
read-only
initrd=/boot/initrd.img-2.6.8-powerpc

ybin -v # If you don’t do this your Powerbook may not boot!

7. Prepare for reboot
Before rebooting make sure you’ve got ALSA installed:
apt-get install alsa-base alsa-oss alsa-source alsa-utils alsamixergui gnome-alsamixer

I also needed the zd1211 driver for use with my wireless USB key. I got the CVS version:
cvs -z3 -d: pserver:anonymous@cvs.sourceforge.net:/cvsroot/zd1211 co -P zd1211 # There’s not supposed to be a space between ‘-d:’ and ‘pserver’ but if I don’t include the space here it prints a stupid smiley graphic. p

Cross your fingers and reboot.
On reboot, after pressing L for Linux you then can press TAB at the next prompt to see your two kernels. Type in the one probably called Linux-2.6.12 and press enter.

Sound should now be working. If, like me, you can just barely hear the internal speaker but the headphone jack output sounds fine, then start gnome-alsamixer and crank up the DRC Range setting. Then you can hear the internal speaker fine too.

8. Get wireless USB key working again
To get the zydas driver working again:
cd zd1211

make clean
make
make install # The version as of 04-15-2005 installs to the wrong directory. Do this:
mkdir /lib/modules/2.6.12.-rc2.050416/net
mv /lib/modules/2.6.12-rc2/net/zd1211.ko /lib/modules/2.6.12.-rc2.050416/net
depmod -a
modprobe zd1211
lsmod # Just to confirm that it’s there.
ifconfig wlan0 up
iwconfig wlan0 essid default # ‘default’ is the name of my no-WEP wireless router.
ifup wlan0

Ta-Dah! You’ve got sound on your wireless-enabled Debian-running Powerbook!

Creative Commons License
This work, unless otherwise expressly stated, is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.

Leave a Reply