[PATCH 3/5] UBI: Expose the bitrot interface

Artem Bityutskiy dedekind1 at gmail.com
Fri Nov 6 04:30:06 PST 2015


On Fri, 2015-11-06 at 13:14 +0100, Richard Weinberger wrote:
> Am 06.11.2015 um 12:59 schrieb Artem Bityutskiy:
> > On Thu, 2015-11-05 at 23:56 +0100, Richard Weinberger wrote:
> > > +#define UBI_IOCRPEB _IOW(UBI_IOC_MAGIC, 4, __s32)
> > > +#define UBI_IOCSPEB _IOW(UBI_IOC_MAGIC, 5, __s32)
> > 
> > Could you please, add short comments telling what are these ioctls
> > about.
> 
> Sure.
> 
> Something like:
> 
> +/* Trigger re-read of a given PEB */

Something more end-user oriented. Trigger re-read does not tell the end
user anything, but "check if a PEB has bitflips" does tell exactly why
the ioctl exists.

> +#define UBI_IOCRPEB _IOW(UBI_IOC_MAGIC, 4, __s32)
> +/* Trigger scrubbing of a given PEB */

Sounds good to me, although if you could also tell at the same time
whether this is unconditional or only if the PEB has bit-flips.

> +#define UBI_IOCSPEB _IOW(UBI_IOC_MAGIC, 5, __s32)

> While we're here, would it make sense to do a manpage for UBI's
> ioctl()s?

Well, more documentation is always a great thing, I invested a lot of
time into mtd web site at some point, and I think it payed off at the
end. Investing time into a man page would pay off too I believe.

Thanks!



More information about the linux-mtd mailing list