Skip to content

Add onboard sound device to Device Tree #977

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 23, 2015
Merged

Add onboard sound device to Device Tree #977

merged 2 commits into from
May 23, 2015

Conversation

notro
Copy link
Contributor

@notro notro commented May 21, 2015

Tested on Pi1 and Pi2 regular kernel with and without DT + ARCH_BCM2835.

Tested from userspace:

$ speaker-test -c2 -t wav
$ omxplayer /usr/share/scratch/Media/Sounds/Vocals/Singer2.wav

omxplayer hangs with no sound on ARCH_BCM2835, reason unknown.

I will enable the driver on ARCH_BCM2835 later when I merge bcm2835_defconfig with bcmrpi_config.

notro added 2 commits May 21, 2015 13:24
Add Device Tree support to alsa driver.
Add device to Device Tree.
Don't add platform devices when booting in DT mode.

Signed-off-by: Noralf Trønnes <[email protected]>
Add onboard sound device to Device Tree.

Signed-off-by: Noralf Trønnes <[email protected]>
@pelwell
Copy link
Contributor

pelwell commented May 21, 2015

OK by me.

@popcornmix?

@popcornmix
Copy link
Collaborator

Not tested yet (I'm doing something on 3.18 tree).
Can you confirm no observable effect on mach-bcm2708/mach-bcm2709?

@notro
Copy link
Contributor Author

notro commented May 22, 2015

Can you confirm no observable effect on mach-bcm2708/mach-bcm2709?

I have only tested using the above mentioned commands, which worked fine.
But I have only tested that stereo left/right is working as expected, so I don't know how and probably don't have the equipment to test more channels.

@popcornmix
Copy link
Collaborator

I guess I'm more concerned about alsa devices having same names as before so they are detected as they used to be and any alsa config continues to work as before.

@notro
Copy link
Contributor Author

notro commented May 22, 2015

How do I check that?
These commands give the same output with this PR as with the latest 3.18:

$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: ALSA [bcm2835 ALSA], device 0: bcm2835 ALSA [bcm2835 ALSA]
  Subdevices: 8/8
  Subdevice #0: subdevice #0
  Subdevice #1: subdevice #1
  Subdevice #2: subdevice #2
  Subdevice #3: subdevice #3
  Subdevice #4: subdevice #4
  Subdevice #5: subdevice #5
  Subdevice #6: subdevice #6
  Subdevice #7: subdevice #7
card 0: ALSA [bcm2835 ALSA], device 1: bcm2835 ALSA [bcm2835 IEC958/HDMI]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

$ aplay -L
null
    Discard all samples (playback) or generate zero samples (capture)
default:CARD=ALSA
    bcm2835 ALSA, bcm2835 ALSA
    Default Audio Device
sysdefault:CARD=ALSA
    bcm2835 ALSA, bcm2835 ALSA
    Default Audio Device

@popcornmix
Copy link
Collaborator

Yes, that's what I was thinking of. If that reports the same then it seems unlikely to break other alsa apps.

popcornmix added a commit that referenced this pull request May 23, 2015
Add onboard sound device to Device Tree
@popcornmix popcornmix merged commit 4f54d3c into raspberrypi:rpi-4.0.y May 23, 2015
@notro notro deleted the audio branch June 1, 2015 22:00
@jpl888 jpl888 mentioned this pull request Mar 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants