Skip to contentSkip to conversation

staging: r8188eu: fix sparse warnings

PATCH Superseded Aakash Hemadri 6 participants 15 messages Aug 21, 2021 – Aug 25, 2021 Staging

v3 of 5 Superseded Latest is v5 →

lore
Share & tools
lore
#0 lore raw

v3 cover staging: r8188eu: fix sparse warnings

Hi,
This patch series fixes some sparse warnings in rtw_br_ext.c

Thanks,
Aakash Hemadri

Aakash Hemadri (5):
staging: r8188eu: restricted __be16 degrades to int
staging: r8188eu: cast to restricted __be32
staging: r8188eu: incorrect type in csum_ipv6_magic
staging: r8188eu: restricted __be16 degrades to int
staging: r8188eu: incorrect type in assignment

 drivers/staging/r8188eu/core/rtw_br_ext.c | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

base-commit: 093991aaadf0fbb34184fa37a46e7a157da3f386

Signature · 1 line
2.32.0
#1 lore raw

PATCH v3 1/5 staging: r8188eu: restricted __be16 degrades to int

Fix sparse warning:

Quoted 1 line

rtw_br_ext.c:73:23: warning: restricted __be16 degrades to integer

Here tag->tag_len is be16, use be16_to_cpu()

---
 drivers/staging/r8188eu/core/rtw_br_ext.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/r8188eu/core/rtw_br_ext.c +1 -1
index ee52f28a1e56..f6d1f6029ec3 100644
@@ -70,7 +70,7 @@ static int __nat25_add_pppoe_tag(struct sk_buff *skb, struct pppoe_tag *tag)
 	struct pppoe_hdr *ph = (struct pppoe_hdr *)(skb->data + ETH_HLEN);
 	int data_len;
 
-	data_len = tag->tag_len + TAG_HDR_LEN;
+	data_len = be16_to_cpu(tag->tag_len) + TAG_HDR_LEN;
 	if (skb_tailroom(skb) < data_len) {
 		_DEBUG_ERR("skb_tailroom() failed in add SID tag!\n");
 		return -1;
Signature · 1 line
2.32.0
Acked-by on v3 1/5
#2 lore raw

Re: [PATCH v3 1/5] staging: r8188eu: restricted __be16 degrades to int

Quoted 25 lines · Aakash Hemadri

Fix sparse warning:

Quoted 1 line

rtw_br_ext.c:73:23: warning: restricted __be16 degrades to integer

Here tag->tag_len is be16, use be16_to_cpu()

---
 drivers/staging/r8188eu/core/rtw_br_ext.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/r8188eu/core/rtw_br_ext.c +1 -2
index ee52f28a1e56..f6d1f6029ec3 100644
@@ -70,7 +70,7 @@ static int __nat25_add_pppoe_tag(struct sk_buff *skb, struct pppoe_tag *tag)
        struct pppoe_hdr *ph = (struct pppoe_hdr *)(skb->data + ETH_HLEN);
        int data_len;
 
-       data_len = tag->tag_len + TAG_HDR_LEN;
+       data_len = be16_to_cpu(tag->tag_len) + TAG_HDR_LEN;
        if (skb_tailroom(skb) < data_len) {
                _DEBUG_ERR("skb_tailroom() failed in add SID tag!\n");
                return -1;
--
Quoted 2 lines

2.32.0

Thanks for this - looks good from what I can see.

Regards,
Phil

#3 lore raw

PATCH v3 2/5 staging: r8188eu: cast to restricted __be32

In reply to Aakash Hemadri

Fix sparse warning:

Quoted 1 line

rtw_br_ext.c:836:54: warning: cast to restricted __be32

dhpch->cookie is be32, change it's type.

---
 drivers/staging/r8188eu/core/rtw_br_ext.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/r8188eu/core/rtw_br_ext.c +2 -2
index f6d1f6029ec3..f65d94bfa286 100644
@@ -649,7 +649,7 @@ struct dhcpMessage {
 	u_int8_t chaddr[16];
 	u_int8_t sname[64];
 	u_int8_t file[128];
-	u_int32_t cookie;
+	__be32 cookie;
 	u_int8_t options[308]; /* 312 - cookie */
 };
 
@@ -671,7 +671,7 @@ void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb)
 				    (udph->dest == __constant_htons(SERVER_PORT))) { /*  DHCP request */
 					struct dhcpMessage *dhcph =
 						(struct dhcpMessage *)((size_t)udph + sizeof(struct udphdr));
-					u32 cookie = be32_to_cpu((__be32)dhcph->cookie);
+					u32 cookie = be32_to_cpu(dhcph->cookie);
 
 					if (cookie == DHCP_MAGIC) { /*  match magic word */
 						if (!(dhcph->flags & htons(BROADCAST_FLAG))) {
Signature · 1 line
2.32.0
#4 lore raw

Re: [PATCH v3 2/5] staging: r8188eu: cast to restricted __be32

Quoted 36 lines · Aakash Hemadri

Fix sparse warning:

Quoted 1 line

rtw_br_ext.c:836:54: warning: cast to restricted __be32

dhpch->cookie is be32, change it's type.

---
 drivers/staging/r8188eu/core/rtw_br_ext.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/r8188eu/core/rtw_br_ext.c +2 -2
index f6d1f6029ec3..f65d94bfa286 100644
@@ -649,7 +649,7 @@ struct dhcpMessage {
 	u_int8_t chaddr[16];
 	u_int8_t sname[64];
 	u_int8_t file[128];
-	u_int32_t cookie;
+	__be32 cookie;
 	u_int8_t options[308]; /* 312 - cookie */
 };
 
@@ -671,7 +671,7 @@ void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb)
 				    (udph->dest == __constant_htons(SERVER_PORT))) { /*  DHCP request */
 					struct dhcpMessage *dhcph =
 						(struct dhcpMessage *)((size_t)udph + sizeof(struct udphdr));
-					u32 cookie = be32_to_cpu((__be32)dhcph->cookie);
+					u32 cookie = be32_to_cpu(dhcph->cookie);
 
 					if (cookie == DHCP_MAGIC) { /*  match magic word */
 						if (!(dhcph->flags & htons(BROADCAST_FLAG))) {
Signature · 1 line
2.32.0

David Laight suggested to use get_unaligned_be32, I am not sure if it's the right thing to do because as far as I understand get_unaligned_be32 byteshifts the argument.

Can someone please confirm if this change is okay?

Thanks,
Aakash Hemadri.

#5 lore raw

Re: [PATCH v3 2/5] staging: r8188eu: cast to restricted __be32

Quoted 42 lines · Aakash Hemadri
Quoted 36 lines · Aakash Hemadri

Fix sparse warning:

Quoted 1 line

rtw_br_ext.c:836:54: warning: cast to restricted __be32

dhpch->cookie is be32, change it's type.

---
  drivers/staging/r8188eu/core/rtw_br_ext.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/r8188eu/core/rtw_br_ext.c +2 -2
index f6d1f6029ec3..f65d94bfa286 100644
@@ -649,7 +649,7 @@ struct dhcpMessage {
  	u_int8_t chaddr[16];
  	u_int8_t sname[64];
  	u_int8_t file[128];
-	u_int32_t cookie;
+	__be32 cookie;
  	u_int8_t options[308]; /* 312 - cookie */
  };
 
@@ -671,7 +671,7 @@ void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb)
  				    (udph->dest == __constant_htons(SERVER_PORT))) { /*  DHCP request */
  					struct dhcpMessage *dhcph =
  						(struct dhcpMessage *)((size_t)udph + sizeof(struct udphdr));
-					u32 cookie = be32_to_cpu((__be32)dhcph->cookie);
+					u32 cookie = be32_to_cpu(dhcph->cookie);
 
  					if (cookie == DHCP_MAGIC) { /*  match magic word */
  						if (!(dhcph->flags & htons(BROADCAST_FLAG))) {
Signature · 1 line
2.32.0

David Laight suggested to use get_unaligned_be32, I am not sure if it's the right thing to do because as far as I understand get_unaligned_be32 byteshifts the argument.

Quoted 2 lines

Can someone please confirm if this change is okay?

It is not needed. variable dhcph->cookie is 4-byte aligned. Usind the unaligned version would just add cpu cycles and arrivw at the same point!

Larry

#6 lore raw

RE: [PATCH v3 2/5] staging: r8188eu: cast to restricted __be32

From: Larry Finger

Quoted 8 lines

Sent: 23 August 2021 15:24

Quoted 5 lines · Aakash Hemadri
Quoted 4 lines · Aakash Hemadri

Fix sparse warning:

Quoted 1 line

rtw_br_ext.c:836:54: warning: cast to restricted __be32

dhpch->cookie is be32, change it's type.

...

Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
drivers/staging/r8188eu/core/rtw_br_ext.c +0 -0
index f6d1f6029ec3..f65d94bfa286 100644

...

Quoted 4 lines
Quoted 4 lines

drivers/staging/r8188eu/core/rtw_br_ext.c void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb) · line 673

Quoted 4 lines
drivers/staging/r8188eu/core/rtw_br_ext.c +0 -0
@@ -671,7 +671,7 @@ void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb)
  				    (udph->dest == __constant_htons(SERVER_PORT))) { /*  DHCP request */
  					struct dhcpMessage *dhcph =
  						(struct dhcpMessage *)((size_t)udph + sizeof(struct udphdr));

This assignment looks dubious at best - WTF is (size_t) for?
I don't seem to have a source tree with this driver in it (probably only in 'next'?). I suspect it should be:

	struct dhcp_message *dhcph = (void *)(udph + 1);
Quoted 13 lines
Quoted 13 lines
Quoted 8 lines
drivers/staging/r8188eu/core/rtw_br_ext.c +1 -2
-					u32 cookie = be32_to_cpu((__be32)dhcph->cookie);
+					u32 cookie = be32_to_cpu(dhcph->cookie);
 
  					if (cookie == DHCP_MAGIC) { /*  match magic word */
  						if (!(dhcph->flags & htons(BROADCAST_FLAG))) {
--

2.32.0

David Laight suggested to use get_unaligned_be32, I am not sure if it's the right thing to do because as far as I understand get_unaligned_be32 byteshifts the argument.

Quoted 5 lines
Quoted 2 lines

Can someone please confirm if this change is okay?

It is not needed. variable dhcph->cookie is 4-byte aligned. Usind the unaligned version would just add cpu cycles and arrivw at the same point!

It rather depends on whether the input buffer is aligned. Although if it might not be then then the structure(s) that map it need to be marked 'packed'.
Which would also mean the get_unaligned_be32() isn't the correct way to handle a misaligned buffer.

David

-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK Registration No: 1397386 (Wales)

#7 lore raw

Re: [PATCH v3 2/5] staging: r8188eu: cast to restricted __be32

Quoted 23 lines · David Laight

From: Larry Finger

Quoted 8 lines

Sent: 23 August 2021 15:24

Quoted 5 lines · Aakash Hemadri
Quoted 4 lines · Aakash Hemadri

Fix sparse warning:

Quoted 1 line

rtw_br_ext.c:836:54: warning: cast to restricted __be32

dhpch->cookie is be32, change it's type.

...

Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
drivers/staging/r8188eu/core/rtw_br_ext.c +0 -0
index f6d1f6029ec3..f65d94bfa286 100644

...

Quoted 4 lines
Quoted 4 lines

drivers/staging/r8188eu/core/rtw_br_ext.c void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb) · line 673

Quoted 4 lines
drivers/staging/r8188eu/core/rtw_br_ext.c +0 -0
@@ -671,7 +671,7 @@ void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb)
  				    (udph->dest == __constant_htons(SERVER_PORT))) { /*  DHCP request */
  					struct dhcpMessage *dhcph =
  						(struct dhcpMessage *)((size_t)udph + sizeof(struct udphdr));

This assignment looks dubious at best - WTF is (size_t) for?
I don't seem to have a source tree with this driver in it (probably only in 'next'?). I suspect it should be:

Quoted 1 line
	struct dhcp_message *dhcph = (void *)(udph + 1);

Those are equivalent. Either way works.

regards,
dan carpenter

#8 lore raw

RE: [PATCH v3 2/5] staging: r8188eu: cast to restricted __be32

From: Dan Carpenter

Quoted 25 lines

Sent: 25 August 2021 10:19

Quoted 11 lines · David Laight

From: Larry Finger

Quoted 8 lines

Sent: 23 August 2021 15:24

Quoted 5 lines · Aakash Hemadri
Quoted 4 lines · Aakash Hemadri

Fix sparse warning:

Quoted 1 line

rtw_br_ext.c:836:54: warning: cast to restricted __be32

dhpch->cookie is be32, change it's type.

...

Quoted 1 line
Quoted 1 line

Review

Quoted 1 line
(quoted diff) +0 -0

b/drivers/staging/r8188eu/core/rtw_br_ext.c

Quoted 8 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

index f6d1f6029ec3..f65d94bfa286 100644

drivers/staging/r8188eu/core/rtw_br_ext.c +0 -0

...

Quoted 4 lines
Quoted 4 lines

drivers/staging/r8188eu/core/rtw_br_ext.c void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb) · line 673

Quoted 4 lines
drivers/staging/r8188eu/core/rtw_br_ext.c +0 -0
@@ -671,7 +671,7 @@ void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb)
  				    (udph->dest == __constant_htons(SERVER_PORT))) { /*  DHCP request */
  					struct dhcpMessage *dhcph =
  						(struct dhcpMessage *)((size_t)udph + sizeof(struct

udphdr));

Quoted 1 line
Quoted 6 lines
Quoted 4 lines

This assignment looks dubious at best - WTF is (size_t) for?
I don't seem to have a source tree with this driver in it (probably only in 'next'?). I suspect it should be:

	struct dhcp_message *dhcph = (void *)(udph + 1);

Those are equivalent. Either way works.

size_t isn't guaranteed to be large enough to hold a pointer.

David

-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK Registration No: 1397386 (Wales)

#9 lore raw

Re: [PATCH v3 2/5] staging: r8188eu: cast to restricted __be32

Quoted 26 lines · David Laight

From: Dan Carpenter

Quoted 25 lines

Sent: 25 August 2021 10:19

Quoted 11 lines · David Laight

From: Larry Finger

Quoted 8 lines

Sent: 23 August 2021 15:24

Quoted 5 lines · Aakash Hemadri
Quoted 4 lines · Aakash Hemadri

Fix sparse warning:

Quoted 1 line

rtw_br_ext.c:836:54: warning: cast to restricted __be32

dhpch->cookie is be32, change it's type.

...

Quoted 1 line
Quoted 1 line

Review

Quoted 1 line
(quoted diff) +0 -0

b/drivers/staging/r8188eu/core/rtw_br_ext.c

Quoted 8 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

index f6d1f6029ec3..f65d94bfa286 100644

drivers/staging/r8188eu/core/rtw_br_ext.c +0 -0

...

Quoted 4 lines
Quoted 4 lines

drivers/staging/r8188eu/core/rtw_br_ext.c void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb) · line 673

Quoted 4 lines
drivers/staging/r8188eu/core/rtw_br_ext.c +0 -0
@@ -671,7 +671,7 @@ void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb)
  				    (udph->dest == __constant_htons(SERVER_PORT))) { /*  DHCP request */
  					struct dhcpMessage *dhcph =
  						(struct dhcpMessage *)((size_t)udph + sizeof(struct

udphdr));

Quoted 1 line
Quoted 8 lines
Quoted 6 lines
Quoted 4 lines

This assignment looks dubious at best - WTF is (size_t) for?
I don't seem to have a source tree with this driver in it (probably only in 'next'?). I suspect it should be:

	struct dhcp_message *dhcph = (void *)(udph + 1);

Those are equivalent. Either way works.

size_t isn't guaranteed to be large enough to hold a pointer.

It is on every system that Linux is ever going to build on.

regards,
dan carpenter

#10 lore raw

PATCH v3 3/5 staging: r8188eu: incorrect type in csum_ipv6_magic

In reply to Aakash Hemadri

Fix sparse warning:

Quoted 2 lines

rtw_br_ext.c:771:84: got restricted __be16 [usertype] payload_len
rtw_br_ext.c:773:110: warning: incorrect type in argument 2

(different base types)

Quoted 2 lines

rtw_br_ext.c:773:110: expected int len
rtw_br_ext.c:773:110: got restricted __be16 [usertype] payload_len

csum_ipv6_magic and csum_partial expect int len not __be16, use be16_to_cpu()

---
 drivers/staging/r8188eu/core/rtw_br_ext.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/r8188eu/core/rtw_br_ext.c +2 -2
index f65d94bfa286..26606093a3c3 100644
@@ -615,9 +615,9 @@ int nat25_db_handle(struct adapter *priv, struct sk_buff *skb, int method)
 						struct icmp6hdr  *hdr = (struct icmp6hdr *)(skb->data + ETH_HLEN + sizeof(*iph));
 						hdr->icmp6_cksum = 0;
 						hdr->icmp6_cksum = csum_ipv6_magic(&iph->saddr, &iph->daddr,
-										iph->payload_len,
+										be16_to_cpu(iph->payload_len),
 										IPPROTO_ICMPV6,
-										csum_partial((__u8 *)hdr, iph->payload_len, 0));
+										csum_partial((__u8 *)hdr, be16_to_cpu(iph->payload_len), 0));
 					}
 				}
 			}
Signature · 1 line
2.32.0
#11 lore raw

PATCH v3 4/5 staging: r8188eu: restricted __be16 degrades to int

In reply to Aakash Hemadri

Fix sparse warning:

Quoted 4 lines

rtw_br_ext.c:839:70: warning: restricted __be16 degrades to integer rtw_br_ext.c:845:70: warning: invalid assignment: |=
rtw_br_ext.c:845:70: left side has type unsigned short
rtw_br_ext.c:845:70: right side has type restricted __be16

dhcp->flags is be16, so change its type to that.
Change htons() to cpu_to_be16() for clarity.

---
 drivers/staging/r8188eu/core/rtw_br_ext.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/staging/r8188eu/core/rtw_br_ext.c +3 -3
index 26606093a3c3..83a4594a4214 100644
@@ -641,7 +641,7 @@ struct dhcpMessage {
 	u_int8_t hops;
 	u_int32_t xid;
 	u_int16_t secs;
-	u_int16_t flags;
+	__be16 flags;
 	u_int32_t ciaddr;
 	u_int32_t yiaddr;
 	u_int32_t siaddr;
@@ -674,13 +674,13 @@ void dhcp_flag_bcast(struct adapter *priv, struct sk_buff *skb)
 					u32 cookie = be32_to_cpu(dhcph->cookie);
 
 					if (cookie == DHCP_MAGIC) { /*  match magic word */
-						if (!(dhcph->flags & htons(BROADCAST_FLAG))) {
+						if (!(dhcph->flags & cpu_to_be16(BROADCAST_FLAG))) {
 							/*  if not broadcast */
 							register int sum = 0;
 
 							DEBUG_INFO("DHCP: change flag of DHCP request to broadcast.\n");
 							/*  or BROADCAST flag */
-							dhcph->flags |= htons(BROADCAST_FLAG);
+							dhcph->flags |= cpu_to_be16(BROADCAST_FLAG);
 							/*  recalculate checksum */
 							sum = ~(udph->check) & 0xffff;
 							sum += be16_to_cpu(dhcph->flags);
Signature · 1 line
2.32.0
#12 lore raw

PATCH v3 5/5 staging: r8188eu: incorrect type in assignment

In reply to Aakash Hemadri

Fix sparse warning:

Quoted 1 line

rtw_br_ext.c:516:57: warning: incorrect type in assignment

(different base types)

Quoted 2 lines

rtw_br_ext.c:516:57: expected unsigned short
rtw_br_ext.c:516:57: got restricted __be16 [usertype]

*pMagic holds __be16 change it's type to __be16

---
 drivers/staging/r8188eu/core/rtw_br_ext.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/r8188eu/core/rtw_br_ext.c +2 -2
index 83a4594a4214..14cf13516d34 100644
@@ -474,7 +474,7 @@ int nat25_db_handle(struct adapter *priv, struct sk_buff *skb, int method)
 		/*                Handle PPPoE frame                 */
 		/*---------------------------------------------------*/
 		struct pppoe_hdr *ph = (struct pppoe_hdr *)(skb->data + ETH_HLEN);
-		unsigned short *pMagic;
+		__be16 *pMagic;
 
 		switch (method) {
 		case NAT25_CHECK:
@@ -512,7 +512,7 @@ int nat25_db_handle(struct adapter *priv, struct sk_buff *skb, int method)
 						tag->tag_len = htons(MAGIC_CODE_LEN+RTL_RELAY_TAG_LEN+old_tag_len);
 
 						/*  insert the magic_code+client mac in relay tag */
-						pMagic = (unsigned short *)tag->tag_data;
+						pMagic = (__be16 *)tag->tag_data;
 						*pMagic = htons(MAGIC_CODE);
 						memcpy(tag->tag_data+MAGIC_CODE_LEN, skb->data+ETH_ALEN, ETH_ALEN);
 
Signature · 1 line
2.32.0
#13 lore raw

Re: [PATCH v3 5/5] staging: r8188eu: incorrect type in assignment

Quoted 28 lines · Aakash Hemadri

Fix sparse warning:

Quoted 1 line

rtw_br_ext.c:516:57: warning: incorrect type in assignment

(different base types)

Quoted 2 lines

rtw_br_ext.c:516:57: expected unsigned short
rtw_br_ext.c:516:57: got restricted __be16 [usertype]

*pMagic holds __be16 change it's type to __be16

---
  drivers/staging/r8188eu/core/rtw_br_ext.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/r8188eu/core/rtw_br_ext.c +1 -1
index 83a4594a4214..14cf13516d34 100644
@@ -474,7 +474,7 @@ int nat25_db_handle(struct adapter *priv, struct sk_buff *skb, int method)
  		/*                Handle PPPoE frame                 */
  		/*---------------------------------------------------*/
  		struct pppoe_hdr *ph = (struct pppoe_hdr *)(skb->data + ETH_HLEN);
-		unsigned short *pMagic;
+		__be16 *pMagic;
 
  		switch (method) {
  		case NAT25_CHECK:

drivers/staging/r8188eu/core/rtw_br_ext.c int nat25_db_handle(struct adapter *priv, struct sk_buff *skb, int method) · line 518

Quoted 8 lines
drivers/staging/r8188eu/core/rtw_br_ext.c +1 -1
@@ -512,7 +512,7 @@ int nat25_db_handle(struct adapter *priv, struct sk_buff *skb, int method)
  						tag->tag_len = htons(MAGIC_CODE_LEN+RTL_RELAY_TAG_LEN+old_tag_len);
 
  						/*  insert the magic_code+client mac in relay tag */
-						pMagic = (unsigned short *)tag->tag_data;
+						pMagic = (__be16 *)tag->tag_data;
  						*pMagic = htons(MAGIC_CODE);
  						memcpy(tag->tag_data+MAGIC_CODE_LEN, skb->data+ETH_ALEN, ETH_ALEN);
 

For all 5 patches,

Ack by Larry Finger <Larry.finger#lwfinger.net>

Thanks,

Larry

#14 lore raw
In reply to Aakash Hemadri
Quoted 13 lines · Aakash Hemadri

Hi,
This patch series fixes some sparse warnings in rtw_br_ext.c

Thanks,
Aakash Hemadri

Aakash Hemadri (5):
staging: r8188eu: restricted __be16 degrades to int
staging: r8188eu: cast to restricted __be32
staging: r8188eu: incorrect type in csum_ipv6_magic
staging: r8188eu: restricted __be16 degrades to int
staging: r8188eu: incorrect type in assignment

Quoted 9 lines
 drivers/staging/r8188eu/core/rtw_br_ext.c | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

base-commit: 093991aaadf0fbb34184fa37a46e7a157da3f386

Signature · 1 line
2.32.0

Hi,

This is the friendly patch-bot of Greg Kroah-Hartman. You have sent him a patch that has triggered this response. He used to manually respond to these common problems, but in order to save his sanity (he kept writing the same thing over and over, yet to different people), I was created. Hopefully you will not take offence and will fix the problem in your patch and resubmit it so that it can be accepted into the Linux kernel tree.

You are receiving this message because of the following common error(s) as indicated below:

- This looks like a new version of a previously submitted patch, but you did not list below the --- line any changes from the previous version. Please read the section entitled "The canonical patch format" in the kernel file, Documentation/SubmittingPatches for what needs to be done here to properly describe this.

If you wish to discuss this problem further, or you have questions about how to resolve this issue, please feel free to respond to this email and Greg will reply once he has dug out from the pending patches received from other developers.

thanks,

greg k-h's patch email bot