aboutsummaryrefslogtreecommitdiff
path: root/sound/firewire/cmp.c
diff options
context:
space:
mode:
authorClemens Ladisch <clemens@ladisch.de>2011-03-15 07:55:50 +0100
committerTakashi Iwai <tiwai@suse.de>2011-03-15 08:42:28 +0100
commit5b2599a07eaee53d713fb68f5343eba88fa249c0 (patch)
tree43cd8d7bebd8b1d9f86ca8f2db69d985da82e94f /sound/firewire/cmp.c
parentbe454366324b31922a2460c63c65d5e3cebe9641 (diff)
ALSA: firewire-lib: allocate DMA buffer separately
For correct cache coherency on some architectures, DMA buffers must be allocated in a different cache line than data that is concurrently used by the CPU. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/firewire/cmp.c')
-rw-r--r--sound/firewire/cmp.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sound/firewire/cmp.c b/sound/firewire/cmp.c
index c992dab4bb9..4a37f3a6fab 100644
--- a/sound/firewire/cmp.c
+++ b/sound/firewire/cmp.c
@@ -117,9 +117,12 @@ int cmp_connection_init(struct cmp_connection *c,
if (ipcr_index >= (impr & IMPR_PLUGS_MASK))
return -EINVAL;
+ err = fw_iso_resources_init(&c->resources, unit);
+ if (err < 0)
+ return err;
+
c->connected = false;
mutex_init(&c->mutex);
- fw_iso_resources_init(&c->resources, unit);
c->last_pcr_value = cpu_to_be32(0x80000000);
c->pcr_index = ipcr_index;
c->max_speed = (impr & IMPR_SPEED_MASK) >> IMPR_SPEED_SHIFT;