From 55c9ab6ba2f85c34fa64e06107762b1d65553208 Mon Sep 17 00:00:00 2001 From: Andy Green Date: Wed, 19 Nov 2008 17:11:07 +0000 Subject: change-glamo-mci-try-memcpy.patch Trial to see if (mainly 32-bit) memcpy is any better than u16 loop Signed-off-by: Andy Green --- drivers/mfd/glamo/glamo-mci.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'drivers/mfd/glamo/glamo-mci.c') diff --git a/drivers/mfd/glamo/glamo-mci.c b/drivers/mfd/glamo/glamo-mci.c index 10617cc84bd..0c8c1974f39 100644 --- a/drivers/mfd/glamo/glamo-mci.c +++ b/drivers/mfd/glamo/glamo-mci.c @@ -199,8 +199,16 @@ static void do_pio_read(struct glamo_mci_host *host) block = (u16 *)host->pio_ptr; res = host->pio_words << 1; #endif +#if 0 + /* u16-centric memcpy */ while (host->pio_words--) *host->pio_ptr++ = *from_ptr++; +#else + /* memcpy can be faster? */ + memcpy((void *)host->pio_ptr, from_ptr, host->pio_words << 1); + host->pio_ptr += host->pio_words; +#endif + #ifdef DEBUG print_hex_dump(KERN_DEBUG, "", DUMP_PREFIX_OFFSET, 16, 1, (void *)block, res, 1); -- cgit v1.2.3