Lines Matching refs:tlv
36 static void i40e_parse_ieee_etscfg_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_parse_ieee_etscfg_tlv() argument
40 u8 *buf = tlv->tlvinfo; in i40e_parse_ieee_etscfg_tlv()
107 static void i40e_parse_ieee_etsrec_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_parse_ieee_etsrec_tlv() argument
110 u8 *buf = tlv->tlvinfo; in i40e_parse_ieee_etsrec_tlv()
162 static void i40e_parse_ieee_pfccfg_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_parse_ieee_pfccfg_tlv() argument
165 u8 *buf = tlv->tlvinfo; in i40e_parse_ieee_pfccfg_tlv()
189 static void i40e_parse_ieee_app_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_parse_ieee_app_tlv() argument
198 typelength = ntohs(tlv->typelength); in i40e_parse_ieee_app_tlv()
201 buf = tlv->tlvinfo; in i40e_parse_ieee_app_tlv()
204 length -= (sizeof(tlv->ouisubtype) + 1); in i40e_parse_ieee_app_tlv()
244 static void i40e_parse_ieee_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_parse_ieee_tlv() argument
250 ouisubtype = ntohl(tlv->ouisubtype); in i40e_parse_ieee_tlv()
255 i40e_parse_ieee_etscfg_tlv(tlv, dcbcfg); in i40e_parse_ieee_tlv()
258 i40e_parse_ieee_etsrec_tlv(tlv, dcbcfg); in i40e_parse_ieee_tlv()
261 i40e_parse_ieee_pfccfg_tlv(tlv, dcbcfg); in i40e_parse_ieee_tlv()
264 i40e_parse_ieee_app_tlv(tlv, dcbcfg); in i40e_parse_ieee_tlv()
278 static void i40e_parse_cee_pgcfg_tlv(struct i40e_cee_feat_tlv *tlv, in i40e_parse_cee_pgcfg_tlv() argument
282 u8 *buf = tlv->tlvinfo; in i40e_parse_cee_pgcfg_tlv()
289 if (tlv->en_will_err & I40E_CEE_FEAT_TLV_WILLING_MASK) in i40e_parse_cee_pgcfg_tlv()
331 static void i40e_parse_cee_pfccfg_tlv(struct i40e_cee_feat_tlv *tlv, in i40e_parse_cee_pfccfg_tlv() argument
334 u8 *buf = tlv->tlvinfo; in i40e_parse_cee_pfccfg_tlv()
336 if (tlv->en_will_err & I40E_CEE_FEAT_TLV_WILLING_MASK) in i40e_parse_cee_pfccfg_tlv()
355 static void i40e_parse_cee_app_tlv(struct i40e_cee_feat_tlv *tlv, in i40e_parse_cee_app_tlv() argument
362 typelength = ntohs(tlv->hdr.typelen); in i40e_parse_cee_app_tlv()
376 app = (struct i40e_cee_app_prio *)(tlv->tlvinfo + offset); in i40e_parse_cee_app_tlv()
411 static void i40e_parse_cee_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_parse_cee_tlv() argument
419 ouisubtype = ntohl(tlv->ouisubtype); in i40e_parse_cee_tlv()
426 typelength = ntohs(tlv->typelength); in i40e_parse_cee_tlv()
429 len = sizeof(tlv->typelength) + sizeof(ouisubtype) + in i40e_parse_cee_tlv()
435 sub_tlv = (struct i40e_cee_feat_tlv *)((char *)tlv + len); in i40e_parse_cee_tlv()
472 static void i40e_parse_org_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_parse_org_tlv() argument
478 ouisubtype = ntohl(tlv->ouisubtype); in i40e_parse_org_tlv()
483 i40e_parse_ieee_tlv(tlv, dcbcfg); in i40e_parse_org_tlv()
486 i40e_parse_cee_tlv(tlv, dcbcfg); in i40e_parse_org_tlv()
503 struct i40e_lldp_org_tlv *tlv; in i40e_lldp_to_dcb_config() local
515 tlv = (struct i40e_lldp_org_tlv *)lldpmib; in i40e_lldp_to_dcb_config()
517 typelength = ntohs(tlv->typelength); in i40e_lldp_to_dcb_config()
530 i40e_parse_org_tlv(tlv, dcbcfg); in i40e_lldp_to_dcb_config()
537 tlv = (struct i40e_lldp_org_tlv *)((char *)tlv + in i40e_lldp_to_dcb_config()
538 sizeof(tlv->typelength) + in i40e_lldp_to_dcb_config()
985 static void i40e_add_ieee_ets_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_add_ieee_ets_tlv() argument
991 u8 *buf = tlv->tlvinfo; in i40e_add_ieee_ets_tlv()
996 tlv->typelength = htons(typelength); in i40e_add_ieee_ets_tlv()
1000 tlv->ouisubtype = htonl(ouisubtype); in i40e_add_ieee_ets_tlv()
1060 static void i40e_add_ieee_etsrec_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_add_ieee_etsrec_tlv() argument
1066 u8 *buf = tlv->tlvinfo; in i40e_add_ieee_etsrec_tlv()
1071 tlv->typelength = htons(typelength); in i40e_add_ieee_etsrec_tlv()
1075 tlv->ouisubtype = htonl(ouisubtype); in i40e_add_ieee_etsrec_tlv()
1124 static void i40e_add_ieee_pfc_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_add_ieee_pfc_tlv() argument
1127 u8 *buf = tlv->tlvinfo; in i40e_add_ieee_pfc_tlv()
1133 tlv->typelength = htons(typelength); in i40e_add_ieee_pfc_tlv()
1137 tlv->ouisubtype = htonl(ouisubtype); in i40e_add_ieee_pfc_tlv()
1162 static void i40e_add_ieee_app_pri_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_add_ieee_app_pri_tlv() argument
1167 u8 *buf = tlv->tlvinfo; in i40e_add_ieee_app_pri_tlv()
1175 tlv->ouisubtype = htonl(ouisubtype); in i40e_add_ieee_app_pri_tlv()
1200 length = sizeof(tlv->ouisubtype) + 1 + (i * 3); in i40e_add_ieee_app_pri_tlv()
1203 tlv->typelength = htons(typelength); in i40e_add_ieee_app_pri_tlv()
1213 static void i40e_add_dcb_tlv(struct i40e_lldp_org_tlv *tlv, in i40e_add_dcb_tlv() argument
1219 i40e_add_ieee_ets_tlv(tlv, dcbcfg); in i40e_add_dcb_tlv()
1222 i40e_add_ieee_etsrec_tlv(tlv, dcbcfg); in i40e_add_dcb_tlv()
1225 i40e_add_ieee_pfc_tlv(tlv, dcbcfg); in i40e_add_dcb_tlv()
1228 i40e_add_ieee_app_pri_tlv(tlv, dcbcfg); in i40e_add_dcb_tlv()
1281 struct i40e_lldp_org_tlv *tlv; in i40e_dcb_config_to_lldp() local
1283 tlv = (struct i40e_lldp_org_tlv *)lldpmib; in i40e_dcb_config_to_lldp()
1286 i40e_add_dcb_tlv(tlv, dcbcfg, tlvid++); in i40e_dcb_config_to_lldp()
1287 typelength = ntohs(tlv->typelength); in i40e_dcb_config_to_lldp()
1298 tlv = (struct i40e_lldp_org_tlv *)((char *)tlv + in i40e_dcb_config_to_lldp()
1299 sizeof(tlv->typelength) + length); in i40e_dcb_config_to_lldp()