netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH iwl-net] idpf: avoid compiler padding in virtchnl2_ptype struct
@ 2023-12-27 17:37 Pavan Kumar Linga
  2023-12-27 21:45 ` [Intel-wired-lan] " Paul Menzel
  0 siblings, 1 reply; 4+ messages in thread
From: Pavan Kumar Linga @ 2023-12-27 17:37 UTC (permalink / raw)
  To: intel-wired-lan
  Cc: netdev, przemyslaw.kitszel, Pavan Kumar Linga, kernel test robot

Config option in arm random config file is causing the compiler
to add padding. Avoid it by using "__packed" structure attribute
for virtchnl2_ptype struct.

Fixes: 0d7502a9b4a7 ("virtchnl: add virtchnl version 2 ops")
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202312220250.ufEm8doQ-lkp@intel.com
Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Signed-off-by: Pavan Kumar Linga <pavan.kumar.linga@intel.com>
---
 drivers/net/ethernet/intel/idpf/virtchnl2.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/intel/idpf/virtchnl2.h b/drivers/net/ethernet/intel/idpf/virtchnl2.h
index 8dc83788972..dd750e6dcd0 100644
--- a/drivers/net/ethernet/intel/idpf/virtchnl2.h
+++ b/drivers/net/ethernet/intel/idpf/virtchnl2.h
@@ -978,7 +978,7 @@ struct virtchnl2_ptype {
 	u8 proto_id_count;
 	__le16 pad;
 	__le16 proto_id[];
-};
+} __packed;
 VIRTCHNL2_CHECK_STRUCT_LEN(6, virtchnl2_ptype);
 
 /**
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-01-04 22:15 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-12-27 17:37 [PATCH iwl-net] idpf: avoid compiler padding in virtchnl2_ptype struct Pavan Kumar Linga
2023-12-27 21:45 ` [Intel-wired-lan] " Paul Menzel
2023-12-28 17:39   ` Linga, Pavan Kumar
2024-01-04 22:15     ` Linga, Pavan Kumar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).