Skip to contentSkip to conversation

staging: octeon: Remove typedef declaration

PATCH In review Wambui Karuga 2 participants 2 messages Oct 8, 2019 – Oct 23, 2019 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: octeon: Remove typedef declaration

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

---
 drivers/staging/octeon/octeon-stubs.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/staging/octeon/octeon-stubs.h +3 -3
index a4ac3bfb62a8..773591348ef4 100644
@@ -38,7 +38,7 @@
 #define CVMX_NPI_RSL_INT_BLOCKS		0
 #define CVMX_POW_WQ_INT_PC		0
 
-typedef union {
+union cvmx_pip_wqe_word2 {
 	uint64_t u64;
 	struct {
 		uint64_t bufs:8;
@@ -114,7 +114,7 @@ typedef union {
 		uint64_t err_code:8;
 	} snoip;
 
-} cvmx_pip_wqe_word2;
+};
 
 union cvmx_pip_wqe_word0 {
 	struct {
@@ -183,7 +183,7 @@ union cvmx_buf_ptr {
 typedef struct {
 	union cvmx_wqe_word0 word0;
 	union cvmx_wqe_word1 word1;
-	cvmx_pip_wqe_word2 word2;
+	union cvmx_pip_wqe_word2 word2;
 	union cvmx_buf_ptr packet_ptr;
 	uint8_t packet_data[96];
 } cvmx_wqe_t;
Signature · 1 line
2.23.0
#1 lore raw

Hi,

Quoted 13 lines · Wambui Karuga

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

---
 drivers/staging/octeon/octeon-stubs.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/staging/octeon/octeon-stubs.h +0 -0
index a4ac3bfb62a8..773591348ef4 100644

drivers/staging/octeon/octeon-stubs.h line 41

Quoted 5 lines
drivers/staging/octeon/octeon-stubs.h +1 -1
@@ -38,7 +38,7 @@
 #define CVMX_NPI_RSL_INT_BLOCKS		0
 #define CVMX_POW_WQ_INT_PC		0
 
-typedef union {
+union cvmx_pip_wqe_word2 {

The "real" definition is in arch/mips/include/asm/octeon/cvmx-wqe.h.

octeon-stubs.h is just a temporary hack to allow compile testing without MIPS cross-compiler. Changing only the stubs file is not really an improvement.

A.