Suggested patch: reset errno after isatty()

Mike Frysinger vapier.adi at
Wed Nov 24 02:50:42 EST 2010

On Thu, Nov 18, 2010 at 06:13, Ketil Froyn wrote:
> On Wed, Nov 17, 2010 at 4:50 PM, Ketil Froyn wrote:
>> I've done some digging around in the new code, but I haven't worked
>> out exactly why the OOB size is set to 0. I haven't figured out
>> exactly what it does yet... Or could it have anything to do with my
>> build environment?
> I rebuilt nanddump from v1.4.1 with my patches using the CodeSourcery
> toolchain (I'd been using the AOSP toolchain before). It works fine,
> so I guess that rules out problems in my build environment. Here's
> what the run looks like:
> / # nanddump-old -f /sdcard/mtd5.dump /dev/mtd/mtd5
> ECC failed: 0
> ECC corrected: 0
> Number of bad blocks: 0
> Number of bbt blocks: 0
> Block size 131072, page size 2048, OOB size 56
> Dumping data starting at 0x00000000 and ending at 0x0a5c0000...
> / #

so you'll want to dive into the ioctls to see what isnt working right.
 strace is your friend.

> This particular system appears to use MTD partitioning, maybe
> redboot(?) or something like that. I haven't had the opportunity to
> delve into how that works yet - could it be that the partitioning
> takes 8 bytes of the OOB?


More information about the linux-mtd mailing list