Apple MacBook Pro 5.2 audio output not working

Bug #462098 reported by cloudboy
22
This bug affects 3 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
Low
Unassigned

Bug Description

upgrade to karmic and no longer have sound.

There is a guide here: https://help.ubuntu.com/community/MacBookPro5-1_5-2/Karmic

But what guide recommends seems like somewhat of a hack.

ProblemType: Bug
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/pcmC0D0c: cloudboy 3212 F...m pulseaudio
 /dev/snd/controlC0: cloudboy 3212 F.... pulseaudio
Card0.Amixer.info:
 Card hw:0 'NVidia'/'HDA NVidia at 0xdf480000 irq 21'
   Mixer name : 'Realtek ALC889A'
   Components : 'HDA:10ec0885,106b4600,00100103'
   Controls : 29
   Simple ctrls : 14
CheckboxCommand: alsa_record_playback
CheckboxTest: alsa_record_playback_alternates
Date: Tue Oct 27 12:25:00 2009
DistroRelease: Ubuntu 9.10
NonfreeKernelModules: nvidia wl
Package: alsa-base 1.0.20+dfsg-1ubuntu5
PackageArchitecture: all
ProcEnviron:
 SHELL=/bin/bash
 LANG=en_US.UTF-8
ProcVersionSignature: Ubuntu 2.6.31-14.48-generic
SourcePackage: alsa-driver
Tags: checkbox-bug
Uname: Linux 2.6.31-14-generic x86_64

Revision history for this message
cloudboy (whitecloudboy00) wrote :
Revision history for this message
Luke Yelavich (themuso) wrote : Re: [Bug 462098] Re: Apple MacBook Pro 5.2 audio output not working

Check that you have the correct output profile, and output device selected in the hardware and output tabs respectively, in the volume control preferences. If you also have a karmic live CD handy, please test that as well, to see if you get sound when you boot into the live CD.

Thanks.

Revision history for this message
cloudboy (whitecloudboy00) wrote :

I'm not entirely sure what the correct output profile is. There are several listed. I've tried all of them while running the System Testing sound test. The default selected profile is: "Analog Stereo Duplex" and the there is only one output device: "Internal Audio Analog Stereo".

When the Karmic release drops at the end of the week I'll burn a live CD and test. I'll update this ticket with the same test run using the live CD at that time.

I appreciate the help and quick response. If there is additional information that would be of interest please let me know.

Just to make it clear I have not tried the above mentioned guide (https://help.ubuntu.com/community/MacBookPro5-1_5-2/Karmic) for fixing sound issues, which seems to suggest though that others are having similar issues.

Revision history for this message
cloudboy (whitecloudboy00) wrote :

Given that there were updates to the guide I linked in the previous comment and I had some free time here, I went ahead and burned the Karmic RC to test.

Sound did not work out of the box as described in my previous comments. I couldn't easily add the bug report attachments from System Testing for that audio test to the ticket (because it sees it as duplicate of my reporting of the bug), but can rerun tests and supply information as needed (I may need minor assistance to location needed information). I've also gone ahead and linked the aforementioned guide to this ticket.

Running the command "uname -a" verifies that the live CD I burned was running the appropriate kernel mentioned in the updated guide. The output of uname was: "Linux ubuntu 2.6.31-14-generic #48-Ubuntu SMP Fri Oct 16 14:05:01 UTC 2009 x86_64 GNU/Linux"

Just also to briefly outline what I did to test using both an upgrade form Jaunty and using the Karmic RC Live CD:
1. Booted the live CD, installed the broadcom driver for wireless support, and obtained an internet connection
2. Pulled down beep-test.wav from http://www.defence.gov.au/army/hq8bde/jobs/beep-test.wav
3. Right-clicked on the sound preferences, verified all volume controls were at max and unmuted.
4. Ran the beep-test.wav in totem (default player). Noted that an Application appeared in Sound Preferences while the totem player was open and visibly playing the wav file. Noted that no sound played.
5. Ran the first audio test under System -> Administration -> System Testing by selecting Audio tests and on the first test clicking "Test". Noted no sound played.

And just a minor correction: I've titled this ticket with "MacBook Pro 5.2"; it should be "MacBook Pro 5-2". I wanted to note that in case someone started searching for MacBook Pro 5-2.

Again I appreciate any help.

Revision history for this message
Jon Ramvi (ramvi) wrote :
Revision history for this message
cloudboy (whitecloudboy00) wrote :

This not a duplicate of the above mentioned bug: 437150. Sound does not work, which is distinct from the problem of detecting when the headphone jack is inserted.

Sound worked in Jaunty by following the above mentioned guide (for Jaunty as opposed to for Karmic).

As far as I can tell headphone jack sense has never worked appropriately for either Jaunty or Karmic. Previously with Jaunty I had written my own script + keyboard shortcut to manually switch between muting the onboard speakers and muting the headphone jack.

My problem here is that I can not get sound (headphones or the speakers on the body of the MacBook Pro) to function at all with Karmic out of the box (which was also true for Jaunty but following the guide fixed that problem).

This weekend I'll probably try the directions mentioned in the guide and update the ticket with the results. I don't want to do it now, I need to block out some time in case I need to triage a problem with the removal of pulseaudio.

Revision history for this message
cloudboy (whitecloudboy00) wrote :

What's interesting to me is that up till now it seems the 5-1 and 5-2 MacBook Pro's have acted very similarly but I'm getting the distinct impression that this is no longer the case. Particularly noting that others seem to have no trouble with 5-1 and sound.

Revision history for this message
cloudboy (whitecloudboy00) wrote :

So following the instructions in guide to purge pulseaudio were successful.

Here were the steps I took:

 * aptitude purge pulseaudio
  - Note this removes ubuntu-desktop
 * follow the Jaunty guide for getting sound to work on the MacBook Pro 5-1, 5-2 (https://help.ubuntu.com/community/MacBookPro5-1_5-2/Jaunty)
 * restart as the Jaunty guide recommends
 * apt-get install ubuntu-desktop

Revision history for this message
cloudboy (whitecloudboy00) wrote :

... my comment got cut off here...

so from above:

* apt-get instal ubuntu-desktop
   - This will reinstall support for sound controls, etc
* I restarted after this, but it didn't seem necessary

I'll update the guide for MacBook Pro 5-2 specifically when I get a minute. I haven't tested headphone support either; I'll update the ticket if I can't use headphone sound and/or I'll update ticket 437150 if I run into problems setting up a script to switch between speakers and headphones (or it just works).

Revision history for this message
白い熊 (6-launchpad-net-sumou-com) wrote :

I wrote these hack steps to the wiki, however even purging pulseaudio, then applying the hack etc. sound is not working satisfactorily.

The volume fluctuates, there is scratching and hissing, sometimes the sound disappears, there's no way to use SIP telephony, won't get voice from mic...

So this hack doesn't solve it.

Revision history for this message
白い熊 (6-launchpad-net-sumou-com) wrote :

This seems to only affect 5,2 as there are many users of 5,1 reporting fine sound OOTB.

Revision history for this message
bit (bit) wrote :

I downloaded version 1.0.21 of Alsa (ftp://ftp.alsa-project.org/pub/driver/alsa-driver-1.0.21.tar.bz2) and it seems to be working without any issues after compiling with the following options:

./configure --enable-dynamic-minors --without-oss --with-cards="hda-intel"

I removed pulseaudio before and installed ubuntu-desktop after, then rebooted. Then in Sound Preferences selected the Analog Stereo Duplex Profile. With alsa-mixer also selected 6channels, but I do not remember if that had any influence.

Revision history for this message
Daniel T Chen (crimsun) wrote :

@bit Installing linux-backports-modules-alsa-karmic-generic and
rebooting should have accomplished similar.

Revision history for this message
till (till-straumann) wrote :

To #12 and #13: I doubt this works for MBP 5.2 (it didn't for me and I have a 5.2)

If we look at the 1.0.21 sources:

alsa-driver-1.0.21/alsa-kernel/pci/hda/patch_realtek.c

we find no mentioning of MBP 5.2 (lines 8804-8821)

/* codec SSID table for Intel Mac */
static struct snd_pci_quirk alc882_ssid_cfg_tbl[] = {
    SND_PCI_QUIRK(0x106b, 0x00a0, "MacBookPro 3,1", ALC885_MBP3),
    SND_PCI_QUIRK(0x106b, 0x00a1, "Macbook", ALC885_MBP3),
    SND_PCI_QUIRK(0x106b, 0x00a4, "MacbookPro 4,1", ALC885_MBP3),
    SND_PCI_QUIRK(0x106b, 0x0c00, "Mac Pro", ALC885_MACPRO),
    SND_PCI_QUIRK(0x106b, 0x1000, "iMac 24", ALC885_IMAC24),
    SND_PCI_QUIRK(0x106b, 0x2800, "AppleTV", ALC885_IMAC24),
    SND_PCI_QUIRK(0x106b, 0x2c00, "MacbookPro rev3", ALC885_MBP3),
    SND_PCI_QUIRK(0x106b, 0x3600, "Macbook 3,1", ALC889A_MB31),
    SND_PCI_QUIRK(0x106b, 0x3800, "MacbookPro 4,1", ALC885_MBP3),
    SND_PCI_QUIRK(0x106b, 0x3e00, "iMac 24 Aluminum", ALC885_IMAC24),
    SND_PCI_QUIRK(0x106b, 0x3f00, "Macbook 5,1", ALC885_MB5),
    /* FIXME: HP jack sense seems not working for MBP 5,1, so apparently
     * no perfect solution yet
     */
    SND_PCI_QUIRK(0x106b, 0x4000, "MacbookPro 5,1", ALC885_MB5),
    {} /* terminator */
};

I suspect adding a line

    SND_PCI_QUIRK(0x106b, 0x4600, "MacbookPro 5,2", ALC885_MB5),

would do the trick.

(I simply applied the well-known patch [see https://help.ubuntu.com/community/MacBookPro5-1_5-2/Jaunty]
to alsa-driver-1.0.20, built, installed and now have sound working as it did under Jaunty.)

Revision history for this message
Yesudeep J Mangalapilly (yesudeep) wrote :

#14 (till)

Can you please document your entire installation procedure for those who do have a MacBook Pro 5.2?

alsa-driver-1.0.21 seems to have the patch you mentioned applied already.

Revision history for this message
Daniel T Chen (crimsun) wrote :

@yesudeep Just install linux-backports-modules-alsa-karmic-generic and reboot.

Revision history for this message
Yesudeep J Mangalapilly (yesudeep) wrote :

@Daniel

I tried that. It didn't work.

Revision history for this message
Daniel T Chen (crimsun) wrote :

@Yesudeep Did you add the correct model quirk? The package I refer to
is *newer* than 1.0.21 and 1.0.21a.

Revision history for this message
till (till-straumann) wrote :

@Yesudeep.

I didn't have the time to search for or create a correct ubuntu/debian package.
Therefore, I
1) downloaded vanilla 1.0.20
2) applied the 'well-known' patch that already worked for 1.0.19
3) configure --with-cards=hda-intel
4) make
5) sudo make install
This is ugly but works.

Note that alsa-driver-1.0.21 does indeed have the patch *BUT* lacks the line I mentioned in #14 and thus only
works for MBP 5.1, and *not* for 5.2. You can install 1.0.21 using the procedure given above. Instead of step 2)
you would have to just add this one line to patch_realtek.c.

@ #16: I had tried this, too. Seems this is a backport of 1.0.21 which still would require the line that adds the quirk for MBP 5.2.

Revision history for this message
Daniel T Chen (crimsun) wrote :
affects: alsa-driver (Ubuntu) → linux (Ubuntu)
Changed in linux (Ubuntu):
assignee: nobody → Daniel T Chen (crimsun)
importance: Undecided → Low
status: New → Fix Committed
Revision history for this message
Yvo Swillens (yvoswillens) wrote :

I can confirm that applying the patch (#20) on alsa-driver-1.0.21 works for MBP 5.2.

Revision history for this message
Yesudeep J Mangalapilly (yesudeep) wrote :

I second Yvo. Sound works neatly with the patch (#20) applied to alsa-driver 1.0.21 on MBP 5.2

Revision history for this message
Daniel T Chen (crimsun) wrote :

Current alsa-driver snapshots already contain a similar patch.

Revision history for this message
Yesudeep J Mangalapilly (yesudeep) wrote :

Also to be added, as mentioned in the comments in the code, the hp jack does not produce any
output which means I can't listen to music without disturbing others. :(

Revision history for this message
Andrew C. Oliver (acoliver) wrote :

I have a MBP 5,2....

I did:
sudo apt-get purge pulse-audio
wget http://ftp.kernel.org/pub/linux/kernel/people/tiwai/alsa/alsa-driver/alsa-driver-20091116.tar.bz2 (a snapshot after the patch was added)
tar -xzf alsa-driver-20091116.tar.bz2
cd alsa-driver
./configure --enable-dynamic-minors --without-oss --with-cards="hda-intel"
make
sudo make install
sudo apt-get install ubuntu-desktop
reboot
upon reboot I had to right click on the little sound applet, preferences, and unmute all of the various channels (go to each tab and unmute)

Now sound works. I occasionally get "jack noises" when sound starts playing (the kind of noise you would customarily get when you jack-in or jack out a mic or something).

use the gnome-alsa-mixer (per: https://help.ubuntu.com/community/MacBookPro5-5/Karmic) to enable the headphone jack (IEC958/IEC958 Default PCM). I'm not sure what combination of dinking with the controls on that caused it to finally stop broadcasting on both headphone and speakers when I have the headphones plugged in)

Revision history for this message
Christopher "cv" (vchristopher) wrote :

Only thing I can say is that #20 patch applied to 1.0.21 does NOT work. sound is still not working and I'm very frustated. Does anyone know a real solution or is there a ubuntu ppa with the new alsa snapshot which includes this patch?

Revision history for this message
Andrew C. Oliver (acoliver) wrote :

after the recent kernel upgrade Linux 2.6.31-15-generic #50-Ubuntu SMP Tue Nov 10 14:53:52 UTC 2009 x86_64 GNU/Linux even after recompiling/installing that alsa it no longer works for me

Revision history for this message
Andrew C. Oliver (acoliver) wrote :

I got it working again. Apparently EACH time the kernel upgrades you have to run through EACH step above including purging pulse-audio and reinstalling it (via ubuntu-desktop). BTW I typo'd it: "sudo apt-get purge pulseaudio" without the "-"

Revision history for this message
Mmmm (ken-monks) wrote :

I just tried exactly the procedure listed in #25 on a fresh install of Karmic 64-bit (with all updates and with backports repos enabled) on a MBP 5,2, and it does not enable sound for me.

Revision history for this message
Gambit- (g-launchpad) wrote :

I can confirm that #25 does not work on a fresh Karmic 64-bit install for me. I hear clicks ('jack noise' as described) but no actual audio.

Revision history for this message
Daniel T Chen (crimsun) wrote :

A fresh Karmic install lacks the linux-backports-modules-alsa-karmic-generic
package...

On Dec 8, 2009 11:05 PM, "Gambit-" <email address hidden> wrote:

I can confirm that #25 does not work on a fresh Karmic 64-bit install
for me. I hear clicks ('jack noise' as described) but no actual audio.

-- Apple MacBook Pro 5.2 audio output not working
https://bugs.launchpad.net/bugs/462098

You received this bug notification because you are a bug assignee. Status in
“linux” package in Ubu...

Bug description: upgrade to karmic and no longer have sound. There is a
guide here: https://help....

Revision history for this message
Mmmm (ken-monks) wrote :

I should have been more precise in my description in message #29. What I meant by the parenthetical remark was that I had no sound (and still do not) after each of the following steps in order:

* Installed Karmic 64-bit to an empty formatted partition (ext4).
* Enabled the karmic-backports repository (System->Administration->Software Sources->Updates (tab)->Unsupported updates (checkbox)) and updated all packages (System->Administration->Update Manager->Install Updates).
* Installed linux-backports-modules-alsa-karmic from synaptic.
* Followed the exact procedure listed in #25 above, with the exceptions of (a) fixing the typo mentioned in #28 and (b) using nautilus to uncompress the archive since the tar command listed gave an error.
* Reinstalled linux-backports-modules-alsa-karmic again just now.

After each of these * starred items I rebooted, and tried to play a .wav file in Totem after checking the volume level and mute status in the System->Preferences->Sound Preferences application. None of them resulted in any sound, even jack noises.

Revision history for this message
Mmmm (ken-monks) wrote :

Update to #32: I was able to get sound working by installing the newest (not yet in the repos) linux kernel 2.6.32 following these instructions:

http://www.ramoonus.nl/2009/12/03/linux-kernel-2-6-32-installation-guide-for-ubuntu-linux/

Sound worked immediately after the installation, but as a side effect my iSIght camera no longer worked. Also sound clips have a "jack noise" at the start and end of a clip. If playing something continuously like a song it functions fine, but for short sound effects and the login audio there is a lot of popping and crackling.

Revision history for this message
Christopher "cv" (vchristopher) wrote :

@Mmmm post #33

Thank you.
Sound is working with the new kernel and I can finally use ubuntu, thanks.

#33 is definitely working with no problems.

Revision history for this message
markt (nospam-launchpad-net-titorenko) wrote :

Felt I should report that I have just managed to get audio output working under Karmic with the 2.6.31-20-generic on my MacBook Pro 5.2:

markt@wiggum:~$ uname -a
Linux wiggum 2.6.31-20-generic #57-Ubuntu SMP Mon Feb 8 09:02:26 UTC 2010 x86_64 GNU/Linux
markt@wiggum:~$ sudo dmidecode -s system-product-name
MacBookPro5,2

I have installed the linux-backports-modules-alsa-karmic-generic package and am installing snd-hda-intel with the following options in my /etc/modprobe.d/alsa-base.conf.

options snd-hda-intel model=mb5 power_save=10 power_save_controller=N

Revision history for this message
markt (nospam-launchpad-net-titorenko) wrote :

As an aside:

I forgot to mention that I was unable to get a 2.6.32.9 or 2.6.33 kernel to boot correctly on my MBP. GRUB bootstrapped the kernel but it appeared to crash somewhere just after initramfs extraction with the screen being set to full brightness and a hanging cursor.

@Mmmm, what 2.6.32.x are you using?

At some point I may iterate back over the 2.6.32.x series to see if I can pinpoint where that started happening.

However, with sound now working under 2.6.31-20, I'm more likely to leave it alone. :-)

Changed in linux (Ubuntu):
assignee: Daniel T Chen (crimsun) → nobody
status: Fix Committed → Fix Released
Mathew Hodson (mhodson)
tags: added: karmic
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.