Getting the sound to work on Alienware M17xR4 laptop with Ubuntu 12.10 and kernel 3.6.0-030600-generic.
I've installed kernel 3.6 from the kernel PPA
# wget -nd http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.6-quantal/linux-image-3.6.0-030600-generic_3.6.0-030600.201209302035_amd64.deb
# dpkg -i linux-image-3.6.0-030600-generic_3.6.0-030600.201209302035_amd64.deb
Edit the file /etc/modprobe.d/alsa-base.conf and add a snd-hda intel line at the end.
snd-hda-intel index=0 model=dell-m6-amic
Reboot
Enjoy both speakers, headphones and sound input works.