Thread (95 messages) 95 messages, 32 authors, 2014-06-25

[PATCH 2/2] mtd: orion-nand: fix build error with ARMv4

From: Ezequiel Garcia <hidden>
Date: 2014-05-09 22:09:51
Also in: lkml

On 09 May 03:28 PM, Jason Gunthorpe wrote:
quoted
I gave this a try in order to answer Arnd's performance
question. First of all, the patch seems wrong. I guess it's because
readsl reads 4-bytes pieces, instead of 8-bytes.

This patch below is tested (but not completely, see below) and works:
Compilers are better now, I think you can just ditch the weirdness:
[..]
The below gives:

  c8:   ea000002        b       d8 <orion_nand_read_buf+0x84>
  cc:   e5dc0000        ldrb    r0, [ip]
  d0:   e7c30001        strb    r0, [r3, r1]
  d4:   e2811001        add     r1, r1, #1
  d8:   e1510002        cmp     r1, r2

Which looks the same as the asm version to me.
Nice! It wasn't really needed but since I have the board here:

# time nanddump /dev/mtd5 -f /dev/null -q
real	0m 5.82s
user	0m 0.20s
sys	0m 5.60s

Jason: Care to submit a proper patch?

On 08 May 04:56 PM, Arnd Bergmann wrote:
Ok, that is a noticeable difference. For scale, what is the size of that partition?
The board is Openblocks A6, running mainline.

# cat /proc/mtd 
dev:    size   erasesize  name
mtd0: 00090000 00004000 "uboot"
mtd1: 00044000 00004000 "env"
mtd2: 00024000 00004000 "test"
mtd3: 00400000 00004000 "conf"
mtd4: 01d20000 00004000 "linux"
mtd5: 01dec000 00004000 "user"

-- 
Ezequiel Garc?a, Free Electrons
Embedded Linux, Kernel and Android Engineering
http://free-electrons.com
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help