Lines Matching refs:mad
107 struct ib_mad *mad,
112 if ((mad->mad_hdr.mgmt_class == IB_MGMT_CLASS_SUBN_LID_ROUTED ||
113 mad->mad_hdr.mgmt_class == IB_MGMT_CLASS_SUBN_DIRECTED_ROUTE) &&
114 mad->mad_hdr.method == IB_MGMT_METHOD_SET) {
115 if (mad->mad_hdr.attr_id == IB_SMP_ATTR_PORT_INFO) {
117 (struct ib_port_info *) ((struct ib_smp *) mad)->data;
139 if (mad->mad_hdr.attr_id == IB_SMP_ATTR_PKEY_TABLE) {
149 struct ib_mad *mad)
151 if ((mad->mad_hdr.mgmt_class == IB_MGMT_CLASS_SUBN_LID_ROUTED ||
152 mad->mad_hdr.mgmt_class == IB_MGMT_CLASS_SUBN_DIRECTED_ROUTE) &&
153 mad->mad_hdr.method == IB_MGMT_METHOD_GET_RESP &&
154 mad->mad_hdr.attr_id == IB_SMP_ATTR_NODE_DESC) {
156 memcpy(((struct ib_smp *) mad)->data, dev->node_desc, 64);
163 struct ib_mad *mad)
165 int qpn = mad->mad_hdr.mgmt_class != IB_MGMT_CLASS_SUBN_LID_ROUTED;
181 memcpy(send_buf->mad, mad, sizeof *mad);