__be64 port_vl_xmit_wait_data;
__be64 port_vl_rcv_bubble;
__be64 port_vl_mark_fecn;
- } vls[0];
+ } vls[];
/* array size defined by #bits set in vl_select_mask*/
- } port[1]; /* array size defined by #ports in attribute modifier */
+ } port;
};
struct opa_port_error_counters64_msg {
u8 reserved3[7];
struct _vls_ectrs {
__be64 port_vl_xmit_discards;
- } vls[0];
+ } vls[];
/* array size defined by #bits set in vl_select_mask */
- } port[1]; /* array size defined by #ports in attribute modifier */
+ } port;
};
struct opa_port_error_info_msg {
u8 error_info;
} __packed fm_config_ei;
__u32 reserved9;
- } port[1]; /* actual array size defined by #ports in attr modifier */
+ } port;
};
/* opa_port_error_info_msg error_info_select_mask bit definitions */
}
/* Sanity check */
- response_data_size = struct_size(req, port[0].vls, num_vls);
+ response_data_size = struct_size(req, port.vls, num_vls);
if (response_data_size > sizeof(pmp->data)) {
pmp->mad_hdr.status |= IB_SMP_INVALID_FIELD;
return reply((struct ib_mad_hdr *)pmp);
}
- rsp = &req->port[0];
+ rsp = &req->port;
memset(rsp, 0, sizeof(*rsp));
rsp->port_number = port;
return reply((struct ib_mad_hdr *)pmp);
}
- response_data_size = struct_size(req, port[0].vls, num_vls);
+ response_data_size = struct_size(req, port.vls, num_vls);
if (response_data_size > sizeof(pmp->data)) {
pmp->mad_hdr.status |= IB_SMP_INVALID_FIELD;
return reply((struct ib_mad_hdr *)pmp);
}
- rsp = &req->port[0];
+ rsp = &req->port;
ibp = to_iport(ibdev, port_num);
ppd = ppd_from_ibp(ibp);
u64 reg;
req = (struct opa_port_error_info_msg *)pmp->data;
- rsp = &req->port[0];
+ rsp = &req->port;
num_ports = OPA_AM_NPORT(be32_to_cpu(pmp->mad_hdr.attr_mod));
num_pslm = hweight64(be64_to_cpu(req->port_select_mask[3]));
u32 error_info_select;
req = (struct opa_port_error_info_msg *)pmp->data;
- rsp = &req->port[0];
+ rsp = &req->port;
num_ports = OPA_AM_NPORT(be32_to_cpu(pmp->mad_hdr.attr_mod));
num_pslm = hweight64(be64_to_cpu(req->port_select_mask[3]));