[PATCH] Fix sound on PowerPC

Bug #1296373 reported by Adam Smith
84
This bug affects 13 people
Affects Status Importance Assigned to Milestone
hw-detect (Debian)
Fix Released
Unknown
hw-detect (Ubuntu)
Invalid
Medium
Unassigned

Bug Description

This patch is one of several needed to fix sound on PowerPC. The wrong modules are loaded/blacklisted on many machines, causing sound not to work or worse the fatal "Fixing recursive fault rebooted is needed!" bug - https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1066435

The attached patch incorporates the suggestions in this debian bug report https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=650588 , and additionally splits off the 'i2s-a' machines which nolonger use snd_powermac (at least that is what I understand from this linuxppc-dev message - http://comments.gmane.org/gmane.linux.ports.ppc.embedded/51204 ).

It would be excellent if this could make it into Trusty. I'm going to submit another bug on the casper package.

Revision history for this message
Adam Smith (adamsmith) wrote :
tags: added: patch
Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "diff.txt" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

Revision history for this message
Adam Smith (adamsmith) wrote :

See also casper bug 1296386

Revision history for this message
Adam Smith (adamsmith) wrote :

The kernel patch I used for the machine I had can be found in bug 1066435. Until the patch(s) make there way into the kernel, I suggest people use DKMS to compile the snd-aoa modules, rather than recompiling the whole kernel. Of course you may have to adapt it for your machine. Submit your patch to the linuxppc/alsa devel lists and then raise an SRU on the ubuntu kernel.

Revision history for this message
Adam Conrad (adconrad) wrote :

Is the second hunk of this patch really necessary? It seems the one-liner avoids the blacklisting, which should be enough?

Revision history for this message
Adam Smith (adamsmith) wrote :

For the machines that have recently migrated to snd-aoa from snd-powermac it seems you need to modprobe snd-aoa-i2sbus . Well that is the experience of myself and Stefan - https://lists.debian.org/debian-powerpc/2013/09/msg00031.html .

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in hw-detect (Ubuntu):
status: New → Confirmed
Revision history for this message
Israel Dahl (israeldahl) wrote :

I thought I had messed something up when I was pulling out the hard drive in my iBook, until I realised I still heard the annoying startup chime.

So how do I test this appropriately?
I would like sound to work on my iBook G3/800
I am not entirely sure I understand your directions.

I did have sound previously in my Debian install... but wanted to install Lubuntu, as I just really like Lubuntu a whole lot!

Revision history for this message
Leo Lam (bearforeverfriends) wrote :

I am running Lubuntu 14.04 on my PowerBookG4 (PowerBook 3.5) and I am having this problem too.

I have already followed the advices in PowerPCFAQ (https://wiki.ubuntu.com/PowerPCFAQ#Why_do_I_have_no_sound.3F) to configure the /etc/modules and /etc/modprobe.d but it cannot solve the sound problem.

I am going to give up 14.04 and install 12.04 to have a try!!

Revision history for this message
Adam Smith (adamsmith) wrote :

To clarify for those joining/looking at this bug:

The attached patch mainly fixes an old problem that has been present since at least 12.04 (modules incorrectly blacklisted).

In 12.10 there were changes to the sound modules and this broke snd-powermac on a number of machines (the fixing recursive fault error). I think these users should be migrating to snd-aoa, and I did my best guest to adjust the hw-detect patch to account for this. I made the assumption (because they sound alike) that the i2s-a machines were the ones that used the deprectated i2c calls.

The advice in the FAQ describes how to remove the blacklist file, but for those users who still have broken sound (the snd-powermac users who should be now using snd-aoa) then they will have to patch the kernel modules themselves. I attached the kernel patch I used to the "fixing recursive fault" bug, but this is device-id dependant and is not a generic patch (i.e. you will have to make adjustments if your machine is different to mine).

The hw-detect bug cannot be fixed for 14.04 because the isos have been released, but the kernel bug can still be fixed. You just need to work out your device-id, adjust the patch, test it, submit it upstream, get the commit reference, and then raise an ubuntu SRU with it!

Revision history for this message
Israel Dahl (israeldahl) wrote :

@Adam
Is there a way to do this on the fly? Can I simply modprobe the module and edit something to workaround this issue?
Also, can you explain in detail how to get the correct device id, and edit the patch accordingly, as I have been sending a lot of Lubuntu users here that would appreciate this information.

Revision history for this message
Fritz Hudnut (este-el-paz) wrote :

This issue is affecting a livedvd session on my G4 iBook of 14.04 . . . same situation in the install of 12.04 on the same machine. And, just for humor, 14.04 Xu 64 bit on '10 MBPro . . . also has sound issues . . . which is not so humorous for a machine closer to the wave of technology. If someone posts details on a fix I might try it out.

F/e.e.p.

Revision history for this message
Adam Smith (adamsmith) wrote :

@IsraelDahl
This hw-detect bug can be overcome by just removing the blacklist file

sudo rm /etc/modprobe.d/blacklist.local.conf

Reboot.

Some users will also have to add snd-aoa-i2sbus to /etc/modules (this is like modprobing the module on startup) AND also remove the snd-powermac line.

If you still have no sound (or more precisely alsamixer doesn't load) then it is likely you are suffering from bug 1066435 . The only way to overcome this is to patch and re-compile the snd-aoa modules.

To get your device-id:

On a working install (e.g. 12.04) open alsamixer (type alsamixer from a terminal), hit F2, select /proc/asound/cards. Mine is listed as

PowerMac Snapper (Dev 38) Sub-frame 0

38 is the device id.

Revision history for this message
EdwardClay (eclay) wrote :

@Adam Smith,

I'm in the boat of needing to patch and recompile the snd-aoa module. Where can I find the patch code and what file do I apply it to?

Revision history for this message
Adam Smith (adamsmith) wrote :

@Edward - see posts 4 and 10

If you need help compiling then you are probably better asking questions on a forum where you can pick the brains of many people. I re-complied the whole kernel, but there are better ways (such as DKMS). It would be cool if somebody could work out DKMS and provide instructions for others....

tags: added: driver sound utopic
Revision history for this message
Boris Reinhard (reinhard-boris) wrote :

Same problem for me on my ibook G4

Id: PowerBook6,5

Sound Hardware: via hex dump: 0x26 = so converted device id: 38

Under OSX 10.5.8 it's detected as "Texas Instruments, TAS 3004, 1x Input (internal mic), 2xoutputs (1xspeakers, 1x headphone jack)"

-------------------
dmesg:
 3.773496] i2c i2c-3: i2c-powermac: modalias failure on /uni-n@f8000000/i2c@f8001000/cereal@1c0
-------------------

So is this simply a case of device id's missing and thus not all being listed/ detected or is it something else?

If it is, why is it not yet fixed if patches do already exist? No offence really just trying to understand this situation.

I've read they (community maintainers) would like to continue supporting PPC (eg. blog post about looking for more ppc testers) but if something like that is supposedly an easy fix even for non ppc users, why isn't it in yet?

What would it take to get this in, I believe the correct expression would be "upstream"!?

thx in advance

tags: added: alsa aoa snd snd-aoa
description: updated
description: updated
tags: added: detection device
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in alsa-dkms (Ubuntu):
status: New → Confirmed
Changed in alsa-dkms (Ubuntu):
importance: Undecided → Medium
Changed in hw-detect (Ubuntu):
importance: Undecided → Medium
Adam Smith (adamsmith)
description: updated
Revision history for this message
Adam Smith (adamsmith) wrote :

@borris, sorry for un-doing your changes!

affects: alsa-dkms (Ubuntu) → ubuntu
Revision history for this message
Boris Reinhard (reinhard-boris) wrote :

@Adam no need to be condescending!

Revision history for this message
Ubuntu QA Website (ubuntuqa) wrote :

This bug has been reported on the Ubuntu ISO testing tracker.

A list of all reports related to this bug can be found here:
http://iso.qa.ubuntu.com/qatracker/reports/bugs/1296373

tags: added: iso-testing
Revision history for this message
Adam Smith (adamsmith) wrote :

Condescending? - "having or showing an attitude of patronizing superiority". Really? There's me thinking I was just being friendly!

Anyway, if it isn't too condescending, I've attached a DKMS deb file here http://ubuntuforums.org/showthread.php?t=2209340&page=7&p=13173354#post13173354 which should make fixing sound easier for those users with a PowerBook 6,5

Revision history for this message
Adam Smith (adamsmith) wrote :

I see that the debian bug linked in the opening description is marked as fixed, so that should filter down to future versions of Ubuntu. That will just leave the i2s machines that won't work out of the box.

Revision history for this message
Fritz Hudnut (este-el-paz) wrote : Re: [Bug 1296373] Re: [PATCH] Fix sound on PowerPC

That's great . . . haven't had time to fiddle with getting sound going on
the iBook 14.04 yet . . . . No "alsamixer" opens in terminal . . . . How
long do you figure it will take to filter down to update/upgrade? Or, I'll
still have to "modprobe" something? : - 0

On Mon, Nov 24, 2014 at 1:27 PM, Adam Smith <email address hidden>
wrote:

> I see that the debian bug linked in the opening description is marked as
> fixed, so that should filter down to future versions of Ubuntu. That
> will just leave the i2s machines that won't work out of the box.
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1296373
>
> Title:
> [PATCH] Fix sound on PowerPC
>
> Status in Ubuntu:
> Confirmed
> Status in “hw-detect” package in Ubuntu:
> Confirmed
>
> Bug description:
> This patch is one of several needed to fix sound on PowerPC. The
> wrong modules are loaded/blacklisted on many machines, causing sound
> not to work or worse the fatal "Fixing recursive fault rebooted is
> needed!" bug -
> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1066435
>
> The attached patch incorporates the suggestions in this debian bug
> report https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=650588 , and
> additionally splits off the 'i2s-a' machines which nolonger use
> snd_powermac (at least that is what I understand from this linuxppc-
> dev message -
> http://comments.gmane.org/gmane.linux.ports.ppc.embedded/51204 ).
>
> It would be excellent if this could make it into Trusty. I'm going to
> submit another bug on the casper package.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/ubuntu/+bug/1296373/+subscriptions
>

Revision history for this message
Adam Smith (adamsmith) wrote :

@Fritz, you are an i2s machine, so unless they've incorporated the changes in the attached patch, then you'll still be modprobing!

Revision history for this message
McDonnell (mcdonn) wrote :

I had the no "sound card found" issue on an IBook G4 and tried multiple combinations of changes to /etc/modules, blacklists, and modprobes to no avail. All resulted in alsamixer not finding a sound card. Then I located the proposed patch in:

http://ubuntuforums.org/showthread.php?t=2209340&page=7

I verified that my white IBook G4 soundcard was Device 38, and applied the patch. It was an immediate success. On reboot, I had a sound card, alsamixer and alsaplayer were happy, Gmerlinmixer worked with both headphones and speakers (auto-detect), etc. The proposed patch worked for my PPC.

Changed in hw-detect (Ubuntu):
status: Confirmed → Fix Committed
Changed in hw-detect (Ubuntu):
status: Fix Committed → Triaged
Mathew Hodson (mhodson)
affects: ubuntu → dkms (Ubuntu)
Mathew Hodson (mhodson)
tags: removed: detection device quantal raring saucy snd
Mathew Hodson (mhodson)
tags: added: powerpc
removed: alsa aoa snd-aoa
Revision history for this message
Adam Smith (adamsmith) wrote :

This is not a bug with dkms. This bug relates to - and only to - hw-detect.

Dkms can be used to fix another bug with sound on Powerpc but that is filed against the Linux package and should not be confused with this bug.

affects: dkms (Ubuntu) → ubuntu
Changed in ubuntu:
status: Confirmed → Invalid
Changed in hw-detect (Debian):
status: Unknown → Fix Released
Revision history for this message
Adam Smith (adamsmith) wrote :

Just an FYI, today I was able to play around with one of the last iBook models. This has always used snd_aoa. However, in 14.04 it still need sns_aoa_i2sbus modprobing. Therefore, the attached patch needs expanding....does every aoa machine need i2sbus manually modprobing?

Revision history for this message
Fritz Hudnut (este-el-paz) wrote :

@Adam:

I've more or less got the basic functions straightened out in 14.04 Lu on
my iBook, so sometime in the next couple weeks I'll probably be finding
time to mess around with sound . . . it has been the least of my worries.
But, might have mentioned before that in the pre or post splash error list
is something about "i2sbus" . . . .

I'll have to read through this material and/or the forum posts to figure
out what I need to do, I'll post back when something is more clear or not .
. . . If there are some commands that you need me to run on my iBook . . .
happy to do that . . . you would just have to spell them out for me . . .
. : - )))) Machine is at home, I'm at work, but easy enough to do, etc.

F

On Mon, Dec 22, 2014 at 6:43 AM, Adam Smith <email address hidden>
wrote:

> Just an FYI, today I was able to play around with one of the last iBook
> models. This has always used snd_aoa. However, in 14.04 it still need
> sns_aoa_i2sbus modprobing. Therefore, the attached patch needs
> expanding....does every aoa machine need i2sbus manually modprobing?
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1296373
>
> Title:
> [PATCH] Fix sound on PowerPC
>
> Status in Ubuntu:
> Invalid
> Status in hw-detect package in Ubuntu:
> Triaged
> Status in hw-detect package in Debian:
> Fix Released
>
> Bug description:
> This patch is one of several needed to fix sound on PowerPC. The
> wrong modules are loaded/blacklisted on many machines, causing sound
> not to work or worse the fatal "Fixing recursive fault rebooted is
> needed!" bug -
> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1066435
>
> The attached patch incorporates the suggestions in this debian bug
> report https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=650588 , and
> additionally splits off the 'i2s-a' machines which nolonger use
> snd_powermac (at least that is what I understand from this linuxppc-
> dev message -
> http://comments.gmane.org/gmane.linux.ports.ppc.embedded/51204 ).
>
> It would be excellent if this could make it into Trusty. I'm going to
> submit another bug on the casper package.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/ubuntu/+bug/1296373/+subscriptions
>

Revision history for this message
Boris Reinhard (reinhard-boris) wrote :

Sadly I can't do any further testing on this at the moment as my ibook recently checked out for good, but at some point I plan on getting another one off of ebay.

I'm also still in contact with Mr. Ellerman and although he made no promises and it of course is in no way any priority I'm still optimistic we eventually will at least land the id38 fix.

no longer affects: ubuntu
Revision history for this message
Adam Smith (adamsmith) wrote :
Revision history for this message
Adam Smith (adamsmith) wrote :
Revision history for this message
Adam Smith (adamsmith) wrote :

For anyone still having problems, see https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=714345

Revision history for this message
Adam Smith (adamsmith) wrote :
Revision history for this message
Ivan Cervantes (ivanc-g) wrote :

I know there has been a lot said about this bug. I need to fix sound on a Macintosh eMac. How do I get this bug fixed? please, I might be asking for something quite easy for you but since this bug is still going on recent releases.

-Computer-
Processor : PowerPC 7447/7457, altivec supported (1250.00MHz)
Memory : 764MB (322MB used)
Operating System : Ubuntu 14.04.3 LTS
Date/Time : Wed 30 Sep 2015 08:37:29 PM CDT
-Display-
Resolution : 1024x768 pixels
OpenGL Renderer : Unknown
X11 Vendor : The X.Org Foundation
-Multimedia-
Audio Adapter : (null) <--------------------------------------------------------------------
-Input Devices-
 PMU
 Logitech Apple Optical USB Mouse
 Mitsumi Electric Apple Extended USB Keyboard
 Mitsumi Electric Apple Extended USB Keyboard
 Macintosh mouse button emulation
 Mouseemu virtual keyboard
 Mouseemu virtual mouse
-Printers-
No printers found
-SCSI Disks-
ATA Maxtor 6Y080L0
HL-DT-ST DVD-RW GWA-4082B

Kiminori Ooe (ooecvs)
Changed in hw-detect (Ubuntu):
assignee: nobody → Kiminori Ooe (ooecvs)
Revision history for this message
Adam Smith (adamsmith) wrote :

This has now been fixed in the linux kernel. Even the autoloading of the snd-aoa-i2sbus module has been fixed. See https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=714345#161

Changed in hw-detect (Ubuntu):
status: Triaged → Invalid
assignee: Kiminori Ooe (ooecvs) → nobody
tags: added: xenial
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.