Lines Matching refs:fc
1258 struct xgbe_fc_info fc = pdata->fc; in axgbe_flow_ctrl_get() local
1263 fc.low_water[0] = AXGMAC_MTL_IOREAD_BITS(pdata, 0, MTL_Q_RQFCR, RFA); in axgbe_flow_ctrl_get()
1264 fc.high_water[0] = AXGMAC_MTL_IOREAD_BITS(pdata, 0, MTL_Q_RQFCR, RFD); in axgbe_flow_ctrl_get()
1265 fc.pause_time[0] = AXGMAC_GET_BITS(reg_val, MAC_Q0TFCR, PT); in axgbe_flow_ctrl_get()
1266 fc.autoneg = pdata->pause_autoneg; in axgbe_flow_ctrl_get()
1269 fc.mode = RTE_ETH_FC_FULL; in axgbe_flow_ctrl_get()
1271 fc.mode = RTE_ETH_FC_RX_PAUSE; in axgbe_flow_ctrl_get()
1273 fc.mode = RTE_ETH_FC_TX_PAUSE; in axgbe_flow_ctrl_get()
1275 fc.mode = RTE_ETH_FC_NONE; in axgbe_flow_ctrl_get()
1277 fc_conf->high_water = (1024 + (fc.low_water[0] << 9)) / 1024; in axgbe_flow_ctrl_get()
1278 fc_conf->low_water = (1024 + (fc.high_water[0] << 9)) / 1024; in axgbe_flow_ctrl_get()
1279 fc_conf->pause_time = fc.pause_time[0]; in axgbe_flow_ctrl_get()
1280 fc_conf->send_xon = fc.send_xon; in axgbe_flow_ctrl_get()
1281 fc_conf->mode = fc.mode; in axgbe_flow_ctrl_get()
1290 struct xgbe_fc_info fc = pdata->fc; in axgbe_flow_ctrl_set() local
1296 fc.send_xon = fc_conf->send_xon; in axgbe_flow_ctrl_set()
1303 fc.mode = fc_conf->mode; in axgbe_flow_ctrl_set()
1305 if (fc.mode == RTE_ETH_FC_FULL) { in axgbe_flow_ctrl_set()
1308 } else if (fc.mode == RTE_ETH_FC_RX_PAUSE) { in axgbe_flow_ctrl_set()
1311 } else if (fc.mode == RTE_ETH_FC_TX_PAUSE) { in axgbe_flow_ctrl_set()
1337 struct xgbe_fc_info fc = pdata->fc; in axgbe_priority_flow_ctrl_set() local
1348 pdata->pause_autoneg = pfc_conf->fc.autoneg; in axgbe_priority_flow_ctrl_set()
1350 fc.send_xon = pfc_conf->fc.send_xon; in axgbe_priority_flow_ctrl_set()
1352 AXGMAC_FLOW_CONTROL_VALUE(1024 * pfc_conf->fc.high_water)); in axgbe_priority_flow_ctrl_set()
1354 AXGMAC_FLOW_CONTROL_VALUE(1024 * pfc_conf->fc.low_water)); in axgbe_priority_flow_ctrl_set()
1359 PSTC0, pfc_conf->fc.pause_time); in axgbe_priority_flow_ctrl_set()
1363 PSTC1, pfc_conf->fc.pause_time); in axgbe_priority_flow_ctrl_set()
1367 PSTC2, pfc_conf->fc.pause_time); in axgbe_priority_flow_ctrl_set()
1371 PSTC3, pfc_conf->fc.pause_time); in axgbe_priority_flow_ctrl_set()
1375 PSTC4, pfc_conf->fc.pause_time); in axgbe_priority_flow_ctrl_set()
1379 PSTC5, pfc_conf->fc.pause_time); in axgbe_priority_flow_ctrl_set()
1383 PSTC6, pfc_conf->fc.pause_time); in axgbe_priority_flow_ctrl_set()
1387 PSTC7, pfc_conf->fc.pause_time); in axgbe_priority_flow_ctrl_set()
1391 fc.mode = pfc_conf->fc.mode; in axgbe_priority_flow_ctrl_set()
1393 if (fc.mode == RTE_ETH_FC_FULL) { in axgbe_priority_flow_ctrl_set()
1397 } else if (fc.mode == RTE_ETH_FC_RX_PAUSE) { in axgbe_priority_flow_ctrl_set()
1401 } else if (fc.mode == RTE_ETH_FC_TX_PAUSE) { in axgbe_priority_flow_ctrl_set()