Re: [RFC] mtd: Fix error code loss in mtdchar_read() function.
From: Richard Weinberger
Date: Mon Sep 25 2023 - 05:31:53 EST
----- Ursprüngliche Mail -----
> Von: "Miquel Raynal" <miquel.raynal@xxxxxxxxxxx>
>> As pointed out by Miquel, the comment makes it clean that this behavior is
>> on purpose. If we return now all of a sudden -EBADMSG for the described
>> scenario we might even break existing MTD userspace.
>
> The bugzilla link in the commit log [1] mentions:
Ups.
> * dd would just stop in the middle without showing errors
> -> we probably don't care, we expect the userspace to know this is
> NAND when dealing with mtd devices directly, dd is not mtd-aware
> anyway.
Yep. That's fine.
> * ubiformat would loop forever
> -> that one needs attention I guess :)
Hmm. Let me check the source.
Thanks,
//richard