From: David Scidmore Date: Tue, 11 Dec 2007 23:44:30 +0000 (-0600) Subject: [MTD] mtdchar.c: ioctl always returns 0 as size written for ppc64 X-Git-Tag: v2.6.25-rc1~296^2~35 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e9d8d48253c50106d85b288939e5227083360863;p=pandora-kernel.git [MTD] mtdchar.c: ioctl always returns 0 as size written for ppc64 "include/linux/mtd/mtd.h" declares "mtd_oob_ops.retlen" as size_t, which is 64 bits on targets with a 64 bit addressing. The MEMWRITEOOB ioctl calls copy_to_user() to write it back to "mtd_oob_buf.length", which is declared in "include/linux/mtd-abi.h" as uint32_t. Since powerpc is a big endian architecture, this only copies the upper 32 bits of the address, which is always 0. Signed-off-by: David Scidmore Signed-off-by: David Woodhouse --- Reading git-diff-tree failed