summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Agner <stefan.agner@toradex.com>2017-08-23 09:37:56 -0700
committerStefan Agner <stefan.agner@toradex.com>2017-08-31 19:57:39 -0700
commit16d2bc5503aab2d087c1e48c888a1307a7a86270 (patch)
treeef92d28d0a9993261aff57590869246ffe0b8a90
parent8215b596c0b27598a8a36b82bc70b5e0202c3a90 (diff)
disk: part: align buffer so it can be used with DMA enabled drivers
When using ISO partitions with a DMA enabled block device driver reading the ISO partition leads to unaligned DMA operations: CACHE: Misaligned operation at range [bffb7da8, bffb85a8] Align the buffer to make sure we pass a buffer which works for DMA operations. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
-rw-r--r--disk/part_iso.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/disk/part_iso.c b/disk/part_iso.c
index bb8ed658f2..8aef251f4e 100644
--- a/disk/part_iso.c
+++ b/disk/part_iso.c
@@ -24,7 +24,7 @@
#undef CHECK_FOR_POWERPC_PLATTFORM
#define CD_SECTSIZE 2048
-static unsigned char tmpbuf[CD_SECTSIZE];
+static unsigned char tmpbuf[CD_SECTSIZE] __aligned(ARCH_DMA_MINALIGN);
unsigned long iso_dread(struct blk_desc *block_dev, lbaint_t start,
lbaint_t blkcnt, void *buffer)