]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
i3c: master: cdns: replace ENOTSUPP with SUSV4-compliant EOPNOTSUPP
authorWolfram Sang <wsa+renesas@sang-engineering.com>
Sat, 28 Jun 2025 19:20:30 +0000 (21:20 +0200)
committerAlexandre Belloni <alexandre.belloni@bootlin.com>
Mon, 7 Jul 2025 21:14:46 +0000 (23:14 +0200)
Replace non-standard ENOTSUPP with the SUSV4-defined error code
EOPNOTSUPP to fix below checkpatch warning:
  "ENOTSUPP is not a SUSV4 error code, prefer EOPNOTSUPP"

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Frank Li <Frank.Li@nxp.com>
Link: https://lore.kernel.org/r/20250628192027.3932-8-wsa+renesas@sang-engineering.com
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
drivers/i3c/master/i3c-master-cdns.c

index 562e49e930b4599b98252434bd5309c3a2de1573..449e85d7ba87e3547617c041ec50c6ba829ea504 100644 (file)
@@ -742,7 +742,7 @@ static int cdns_i3c_master_priv_xfers(struct i3c_dev_desc *dev,
 
        for (i = 0; i < nxfers; i++) {
                if (xfers[i].len > CMD0_FIFO_PL_LEN_MAX)
-                       return -ENOTSUPP;
+                       return -EOPNOTSUPP;
        }
 
        if (!nxfers)
@@ -750,7 +750,7 @@ static int cdns_i3c_master_priv_xfers(struct i3c_dev_desc *dev,
 
        if (nxfers > master->caps.cmdfifodepth ||
            nxfers > master->caps.cmdrfifodepth)
-               return -ENOTSUPP;
+               return -EOPNOTSUPP;
 
        /*
         * First make sure that all transactions (block of transfers separated
@@ -765,7 +765,7 @@ static int cdns_i3c_master_priv_xfers(struct i3c_dev_desc *dev,
 
        if (rxslots > master->caps.rxfifodepth ||
            txslots > master->caps.txfifodepth)
-               return -ENOTSUPP;
+               return -EOPNOTSUPP;
 
        cdns_xfer = cdns_i3c_master_alloc_xfer(master, nxfers);
        if (!cdns_xfer)
@@ -822,11 +822,11 @@ static int cdns_i3c_master_i2c_xfers(struct i2c_dev_desc *dev,
        int i, ret = 0;
 
        if (nxfers > master->caps.cmdfifodepth)
-               return -ENOTSUPP;
+               return -EOPNOTSUPP;
 
        for (i = 0; i < nxfers; i++) {
                if (xfers[i].len > CMD0_FIFO_PL_LEN_MAX)
-                       return -ENOTSUPP;
+                       return -EOPNOTSUPP;
 
                if (xfers[i].flags & I2C_M_RD)
                        nrxwords += DIV_ROUND_UP(xfers[i].len, 4);
@@ -836,7 +836,7 @@ static int cdns_i3c_master_i2c_xfers(struct i2c_dev_desc *dev,
 
        if (ntxwords > master->caps.txfifodepth ||
            nrxwords > master->caps.rxfifodepth)
-               return -ENOTSUPP;
+               return -EOPNOTSUPP;
 
        xfer = cdns_i3c_master_alloc_xfer(master, nxfers);
        if (!xfer)