Tagged with t430

FIXED: No sound from Thinkpad T430 when docked

Update (31/Jan/2013)

As of kernel 3.6.9 in Debian (experimental), the patch is included by default so this procedure is now obsolete. Save yourself a lot of trouble and simply install linux-image-3.7-trunk. ;)

</update>

My T430's speaker got muted as soon as I docked it in its Mini Dock Plus Series 3. Luckily a patch has been posted to the Linux' mailing list.

Here's a quick guide to get sound from the dock by patching the Linux kernel and building Debian packages for the patched kernel and for the proprietary nVidia module.

Get the latest kernel from kernel.org. I used version 3.6.4, released on 28 October 2012. Download it to /usr/src.

Extract the kernel's tarball in /usr/src, it will create a directory linux-3.6.4:

tar xf linux-3.6.4.tar.bz2

Create a symbolic link to /usr/src/linux for linux-3.6.4:

ln -sv /usr/src/linux-3.6.4 /usr/src/linux

chown the /usr/src directory to your normal user. This way you can build packages without having to be root.

chown -R youruser /usr/src

Install the nVidia kernel source. I installed version 304.60 from the unstable repo.

aptitude -t unstable install nvidia-kernel-source

Extract the nVidia kernel tarball, it was installed under /usr/src.

tar xf /usr/src/nvidia-kernel-source.tar.bz2

Configure your kernel manually (make menuconfig) or copy a config you already have (e.g. /boot/config-3.2.0-3-amd64) and run make oldconfig to set all the new options that have been introduced since v3.2.0.

Get the patch to get sound from the docking station: : https://lkml.org/lkml/2012/10/19/320. I just added the missing line manually to sound/pci/hda/patch_realtek.c: change the file from

SND_PCI_QUIRK(0x17aa, 0x21f6, "Thinkpad T530", ALC269_FIXUP_LENOVO_DOCK),
SND_PCI_QUIRK(0x17aa, 0x21fa, "Thinkpad X230", ALC269_FIXUP_LENOVO_DOCK),
SND_PCI_QUIRK(0x17aa, 0x21fb, "Thinkpad T430s", ALC269_FIXUP_LENOVO_DOCK),
SND_PCI_QUIRK(0x17aa, 0x2203, "Thinkpad X230 Tablet", ALC269_FIXUP_LENOVO_DOCK),

to

SND_PCI_QUIRK(0x17aa, 0x21f6, "Thinkpad T530", ALC269_FIXUP_LENOVO_DOCK),
SND_PCI_QUIRK(0x17aa, 0x21fa, "Thinkpad X230", ALC269_FIXUP_LENOVO_DOCK),
SND_PCI_QUIRK(0x17aa, 0x21f3, "Thinkpad T430", ALC269_FIXUP_LENOVO_DOCK),
SND_PCI_QUIRK(0x17aa, 0x21fb, "Thinkpad T430s", ALC269_FIXUP_LENOVO_DOCK),
SND_PCI_QUIRK(0x17aa, 0x2203, "Thinkpad X230 Tablet", ALC269_FIXUP_LENOVO_DOCK),

Now use make-kpkg to build the kernel, the modules, an initial ramdisk, the kernel header files and the nVidia kernel module in one swift command:

make-kpkg --revision 3.6.4 --append-to-version -2-bgd -j4 --initrd kernel_image kernel_headers modules_image

See make-kpkg's manpage for more info on the parameters and switches to the above command.

Find your new packages in /usr/src:

  • linux-headers-3.6.4-2-bgd_3.6.4_amd64.deb
  • linux-image-3.6.4-2-bgd_3.6.4_amd64.deb
  • nvidia-kernel-3.6.4-2-bgd_304.60-1+3.6.4_amd64.deb

Install your patched kernel, headers and nVidia module:

dpkg -i linux-headers-3.6.4-2-bgd_3.6.4_amd64.deb linux-image-3.6.4-2-bgd_3.6.4_amd64.deb nvidia-kernel-3.6.4-2-bgd_304.60-1+3.6.4_amd64.deb

Reboot and enjoy sound from the dock!

Update

When I installed the 3 .deb files above, I still had the nVidia packages from Debian unstable installed as well. This was not a good idea: after a few weeks a new nVidia driver was available (v304.64), and it got installed with aptitude safe-upgrade. It clashed with my custom package to the extent where X would not show an image anymore. I ended up with hundreds of Xorg.[0-999].log files in /var/log too.

I fixed this by removing all official Debian packages for nVidia, and reinstalling my own custom package.

Source: Debian Wiki - NvidiaGraphicsDrivers

Tagged , , , , ,