diff mbox series

[net] hv_netvsc: Fix the variable sizes in ipsecv2 and rsc offload

Message ID 20180615012909.13440-1-haiyangz@linuxonhyperv.com
State Accepted, archived
Delegated to: David Miller
Headers show
Series [net] hv_netvsc: Fix the variable sizes in ipsecv2 and rsc offload | expand

Commit Message

Haiyang Zhang June 15, 2018, 1:29 a.m. UTC
From: Haiyang Zhang <haiyangz@microsoft.com>

These fields in struct ndis_ipsecv2_offload and struct ndis_rsc_offload
are one byte according to the specs. This patch defines them with the
right size. These structs are not in use right now, but will be used soon.

Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
---
 drivers/net/hyperv/hyperv_net.h | 26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

Comments

David Miller June 15, 2018, 3:16 a.m. UTC | #1
From: Haiyang Zhang <haiyangz@linuxonhyperv.com>
Date: Thu, 14 Jun 2018 18:29:09 -0700

> From: Haiyang Zhang <haiyangz@microsoft.com>
> 
> These fields in struct ndis_ipsecv2_offload and struct ndis_rsc_offload
> are one byte according to the specs. This patch defines them with the
> right size. These structs are not in use right now, but will be used soon.
> 
> Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>

Applied, thank you.
Dan Carpenter June 15, 2018, 9:14 a.m. UTC | #2
On Thu, Jun 14, 2018 at 06:29:09PM -0700, Haiyang Zhang wrote:
> These structs are not in use right now, but will be used soon.

Btw, thank you for adding this information.  I was wondering about that
in the first version of this patch.  It's always useful to know what
the effect of a bugfix is even if the effect is nothing at this time.

regards,
dan carpenter
diff mbox series

Patch

diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
index d31c0cd329a1..1a924b867b07 100644
--- a/drivers/net/hyperv/hyperv_net.h
+++ b/drivers/net/hyperv/hyperv_net.h
@@ -1277,17 +1277,17 @@  struct ndis_lsov2_offload {
 
 struct ndis_ipsecv2_offload {
 	u32	encap;
-	u16	ip6;
-	u16	ip4opt;
-	u16	ip6ext;
-	u16	ah;
-	u16	esp;
-	u16	ah_esp;
-	u16	xport;
-	u16	tun;
-	u16	xport_tun;
-	u16	lso;
-	u16	extseq;
+	u8	ip6;
+	u8	ip4opt;
+	u8	ip6ext;
+	u8	ah;
+	u8	esp;
+	u8	ah_esp;
+	u8	xport;
+	u8	tun;
+	u8	xport_tun;
+	u8	lso;
+	u8	extseq;
 	u32	udp_esp;
 	u32	auth;
 	u32	crypto;
@@ -1295,8 +1295,8 @@  struct ndis_ipsecv2_offload {
 };
 
 struct ndis_rsc_offload {
-	u16	ip4;
-	u16	ip6;
+	u8	ip4;
+	u8	ip6;
 };
 
 struct ndis_encap_offload {