Re: [PATCH -next] mtd: Add WARN_ON_ONCE() to mtd_read() to check the return value

From: Miquel Raynal
Date: Mon Oct 16 2023 - 05:28:55 EST


On Tue, 2023-09-26 at 06:57:33 UTC, ZhaoLong Wang wrote:
> If the driver cannot read all the requested data, -EBADMSG or
> -EUCLEAN should never be returned.
>
> Add a WARN_ON_ONCE() to help driver developers detect this error.
>
> Signed-off-by: ZhaoLong Wang <wangzhaolong1@xxxxxxxxxx>

Applied to https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git mtd/next, thanks.

Miquel