davinci: support for EDMA resource sharing
authorRajashekhara, Sudhakar <sudhakar.raj@ti.com>
Tue, 29 Jun 2010 06:05:13 +0000 (11:35 +0530)
committerKevin Hilman <khilman@deeprootsystems.com>
Thu, 5 Aug 2010 16:58:25 +0000 (09:58 -0700)
commit90bd4e6dd7f4b747477f2ad0125adb933cf3bcfa
tree081fdeffcd68ac2aebf9cfea60de94770b9bef64
parentbc3ac9f31642fb4697b313c2eb575c5286f35c2a
davinci: support for EDMA resource sharing

Current EDMA driver is not taking care of EDMA channels/slots
which are allocated from other processor, say DSP. If a
channel/slot is allocated from DSP, the existing EDMA driver
can still allocate the same resource on ARM.

This patch enables the user to pass the channel/slots reserved
for DSP as platform data. EDMA driver scans this list during
probe and prepares a bitmap of channel/slots which can be used
on ARM side.

Trying to reserve channels by doing a 'pre-allocate' using
edma_alloc_{slot|channel}() API does not work because

1) The reservation should be done in probe() to avoid race
   with other ARM side driver trying to use EDMA

2) The alloc channel API sets up the access through shadow region
   0 which will be incorrect for DSP usage. It also sets up the
   channel <-> queue number mapping which is not required as DSP
   will likely do its own mapping anyway.

3) (minor) There is no API to allocate channels in bulk.

Signed-off-by: Sudhakar Rajashekhara <sudhakar.raj@ti.com>
Cc: David Brownell <david-b@pacbell.net>
Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
arch/arm/mach-davinci/dma.c
arch/arm/mach-davinci/include/mach/edma.h
This page took 0.024871 seconds and 5 git commands to generate.