diff mbox series

[05/10] mtd: rawnand: qcom: Use EOPNOTSUPP instead of ENOTSUPP

Message ID 20230805174146.57006-6-manivannan.sadhasivam@linaro.org (mailing list archive)
State Not Applicable
Headers show
Series mtd: rawnand: qcom: Bunch of fixes and cleanups | expand

Commit Message

Manivannan Sadhasivam Aug. 5, 2023, 5:41 p.m. UTC
Checkpatch complains over the usage of ENOTSUPP for new patches as below:

WARNING: ENOTSUPP is not a SUSV4 error code, prefer EOPNOTSUPP

So let's fix the error code which is already present in qcom_check_op().

Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
---
 drivers/mtd/nand/raw/qcom_nandc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Miquel Raynal Aug. 18, 2023, 2:41 p.m. UTC | #1
On Sat, 2023-08-05 at 17:41:41 UTC, Manivannan Sadhasivam wrote:
> Checkpatch complains over the usage of ENOTSUPP for new patches as below:
> 
> WARNING: ENOTSUPP is not a SUSV4 error code, prefer EOPNOTSUPP
> 
> So let's fix the error code which is already present in qcom_check_op().
> 
> Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>

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

Miquel
diff mbox series

Patch

diff --git a/drivers/mtd/nand/raw/qcom_nandc.c b/drivers/mtd/nand/raw/qcom_nandc.c
index 29fcdac932f1..a7a9421ef003 100644
--- a/drivers/mtd/nand/raw/qcom_nandc.c
+++ b/drivers/mtd/nand/raw/qcom_nandc.c
@@ -3040,7 +3040,7 @@  static int qcom_check_op(struct nand_chip *chip,
 			    instr->ctx.cmd.opcode != NAND_CMD_ERASE2 &&
 			    instr->ctx.cmd.opcode != NAND_CMD_STATUS &&
 			    instr->ctx.cmd.opcode != NAND_CMD_PAGEPROG)
-				return -ENOTSUPP;
+				return -EOPNOTSUPP;
 			break;
 		default:
 			break;