Skip to content
Commit bad49c21 authored by Javier Martinez Canillas's avatar Javier Martinez Canillas
Browse files

ALSA: bcm2835: add memory-mapped I/O mode for audio stream



ALSA supports two transfers methods for PCM playback: Read/Write
transfer where samples are writtern to the device using standard
read and write functions and Direct Read/Write transfers where
samples can be written directly to a mapped memory area and the
driver is signaled once this has been done.

The bcm2835 driver only supported Read/Write transfer method so
this patch adds mmap support to the driver.

The ARM CPU is not able to directly address the audio device
hardware buffer so audio samples are sent to the device using
a message passing interface (vchiq).

Since hardware buffers can't be directly mapped to user-space
memory, an intermediate buffer (using the PCM indirect API) is
needed to store the audio samples and push them to the device
through videocore.

Signed-off-by: default avatarJavier Martinez Canillas <javier.martinez@collabora.co.uk>
parent 24f64ad5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment