On Thu, Dec 15, 2016 at 06:59:47PM -0800, Vishwanathapura, Niranjana wrote:
> We have made the hfi_vnic driver dependent on CONFIG_X86_64.

Er, don't do that either?

> >>+struct __hfi_vesw_info {
> >>+   u16  fabric_id;
> >>+   u16  vesw_id;
> >>+
> >>+   u8   rsvd0[6];
> >>+   u16  def_port_mask;
> >>+
> >>+   u8   rsvd1[2];
> >>+   u16  pkey;
> >>+
> >>+   u8   rsvd2[4];
> >>+   u32  u_mcast_dlid;
> >>+   u32  u_ucast_dlid[HFI_VESW_MAX_NUM_DEF_PORT];
> >>+
> >>+   u8   rsvd3[44];
> >>+   u16  eth_mtu[HFI_VNIC_MAX_NUM_PCP];
> >>+   u16  eth_mtu_non_vlan;
> >>+   u8   rsvd4[2];
> >>+} __packed;
> >
> >This goes on the network too? Also looks like it has endian problems.
> >
> >Ditto for all the __packed structures.
> >
> 
> This is in CPU format. There is a separate big endian version of
> this

Why are CPU handled structures packed and full of reserved fields?
Don't pack them if they are not pushed out to the network..

There were lots of __packed structures, any that go on the network
need be/le annoations.

Jason

Reply via email to