Skip to contentSkip to conversation

staging: octeon: remove typedef declaration for cvmx_fau_op_size

PATCH In review Dalvin-Ehinoma Noah Aiguobas 2 participants 3 messages Apr 5, 2023 – Apr 6, 2023 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: octeon: remove typedef declaration for cvmx_fau_op_size

Fix checkpatch.pl warning: do not add new typedefs in drivers/staging/octeon/octeon-stubs.h:216

---
 drivers/staging/octeon/octeon-stubs.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/staging/octeon/octeon-stubs.h +3 -3
index 3e7b92cd2e35..9f269626b862 100644
@@ -213,12 +213,12 @@ enum cvmx_fau_op_size {
 	CVMX_FAU_OP_SIZE_64 = 3
 };
 
-typedef enum {
+enum cvmx_spi_mode {
 	CVMX_SPI_MODE_UNKNOWN = 0,
 	CVMX_SPI_MODE_TX_HALFPLEX = 1,
 	CVMX_SPI_MODE_RX_HALFPLEX = 2,
 	CVMX_SPI_MODE_DUPLEX = 3
-} cvmx_spi_mode_t;
+};
 
 typedef enum {
 	CVMX_HELPER_INTERFACE_MODE_DISABLED,
@@ -1362,7 +1362,7 @@ static inline struct cvmx_wqe *cvmx_pow_work_request_sync(cvmx_pow_wait_t wait)
 }
 
 static inline int cvmx_spi_restart_interface(int interface,
-					cvmx_spi_mode_t mode, int timeout)
+					enum cvmx_spi_mode mode, int timeout)
 {
 	return 0;
 }
Signature · 1 line
2.25.1
#1 lore raw
Quoted 2 lines · Dalvin-Ehinoma Noah Aiguobas

Fix checkpatch.pl warning: do not add new typedefs in drivers/staging/octeon/octeon-stubs.h:216

There are a few more of these 'typedef enum' is this file. I believe it would be OK to bundle the changes together in one patch. Perhaps you are going to come back with additional patches.

There appears to be an inconsistent style with how the enums are actually enumerated in this file. cvmx_pow_wait_t is esp odd.

Alison

Quoted 37 lines
---
 drivers/staging/octeon/octeon-stubs.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/staging/octeon/octeon-stubs.h +3 -3
index 3e7b92cd2e35..9f269626b862 100644
@@ -213,12 +213,12 @@ enum cvmx_fau_op_size {
 	CVMX_FAU_OP_SIZE_64 = 3
 };
 
-typedef enum {
+enum cvmx_spi_mode {
 	CVMX_SPI_MODE_UNKNOWN = 0,
 	CVMX_SPI_MODE_TX_HALFPLEX = 1,
 	CVMX_SPI_MODE_RX_HALFPLEX = 2,
 	CVMX_SPI_MODE_DUPLEX = 3
-} cvmx_spi_mode_t;
+};
 
 typedef enum {
 	CVMX_HELPER_INTERFACE_MODE_DISABLED,
@@ -1362,7 +1362,7 @@ static inline struct cvmx_wqe *cvmx_pow_work_request_sync(cvmx_pow_wait_t wait)
 }
 
 static inline int cvmx_spi_restart_interface(int interface,
-					cvmx_spi_mode_t mode, int timeout)
+					enum cvmx_spi_mode mode, int timeout)
 {
 	return 0;
 }
Signature · 1 line
2.25.1
#2 lore raw
In reply to Dalvin-Ehinoma Noah Aiguobas
Quoted 14 lines · Dalvin-Ehinoma Noah Aiguobas

Fix checkpatch.pl warning: do not add new typedefs in drivers/staging/octeon/octeon-stubs.h:216

---
 drivers/staging/octeon/octeon-stubs.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/staging/octeon/octeon-stubs.h +0 -0
index 3e7b92cd2e35..9f269626b862 100644
@@ -213,12 +213,12 @@ enum cvmx_fau_op_size {
 	CVMX_FAU_OP_SIZE_64 = 3

drivers/staging/octeon/octeon-stubs.h enum cvmx_fau_op_size { · line 221

Quoted 10 lines
drivers/staging/octeon/octeon-stubs.h +2 -2
 };
 
-typedef enum {
+enum cvmx_spi_mode {
 	CVMX_SPI_MODE_UNKNOWN = 0,
 	CVMX_SPI_MODE_TX_HALFPLEX = 1,
 	CVMX_SPI_MODE_RX_HALFPLEX = 2,
 	CVMX_SPI_MODE_DUPLEX = 3
-} cvmx_spi_mode_t;
+};

Commit msg says typedef cvmx_fau_op_size was removed, not this one.

Quoted 15 lines
drivers/staging/octeon/octeon-stubs.h +1 -1
 typedef enum {
 	CVMX_HELPER_INTERFACE_MODE_DISABLED,
@@ -1362,7 +1362,7 @@ static inline struct cvmx_wqe *cvmx_pow_work_request_sync(cvmx_pow_wait_t wait)
 }
 
 static inline int cvmx_spi_restart_interface(int interface,
-					cvmx_spi_mode_t mode, int timeout)
+					enum cvmx_spi_mode mode, int timeout)
 {
 	return 0;
 }
Signature · 1 line
2.25.1