dmaengine: edma: Make reading the position of active channels work
authorThomas Gleixner <tglx@linutronix.de>
Mon, 28 Apr 2014 10:49:43 +0000 (10:49 +0000)
committerVinod Koul <vinod.koul@intel.com>
Wed, 30 Apr 2014 05:04:39 +0000 (10:34 +0530)
commitcdae05a0f0f7d15837dfd6f4200e8caea03c9cbf
tree9513241fb0020ad9cbd0b2e2fa36f707e09b864b
parentc2da2340e5818aa72b2e847f1f24b036742ea5c7
dmaengine: edma: Make reading the position of active channels work

As Joel pointed out, edma_read_position() uses memcpy_fromio() to read
the parameter ram. That's not synchronized with the internal update as
it does a byte by byte copy. We need to do a 32bit read to get a
consistent value.

Further reading destination and source is pointless. In DEV_TO_MEM
transfers we are only interested in the destination, in MEM_TO_DEV we
care about the source. In MEM_TO_MEM it really does not matter which
one you read.

Simple solution: Remove the pointers, select dest/source via a bool
and return the read value.

Remove the export of this function while at it. The only potential
user is the dmaengine and that's always builtin.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Sekhar Nori <nsekhar@ti.com>
Signed-off-by: Joel Fernandes <joelf@ti.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
arch/arm/common/edma.c
include/linux/platform_data/edma.h
This page took 0.02615 seconds and 5 git commands to generate.