Lines Matching refs:phy_data
136 struct ice_phy_data *phy_data);
3190 struct ice_phy_data *phy_data) in ice_intersect_phy_types_and_speeds() argument
3205 switch (phy_data->report_mode) { in ice_intersect_phy_types_and_speeds()
3210 report_type = phy_data->report_mode >> 1; in ice_intersect_phy_types_and_speeds()
3215 __func__, phy_data->report_mode); in ice_intersect_phy_types_and_speeds()
3223 if (phy_data->user_speeds_orig == 0) in ice_intersect_phy_types_and_speeds()
3224 phy_data->user_speeds_orig = USHRT_MAX; in ice_intersect_phy_types_and_speeds()
3228 status = ice_aq_get_phy_caps(pi, false, phy_data->report_mode, &pcaps, NULL); in ice_intersect_phy_types_and_speeds()
3238 phy_data->phy_low_orig = le64toh(pcaps.phy_type_low); in ice_intersect_phy_types_and_speeds()
3239 phy_data->phy_high_orig = le64toh(pcaps.phy_type_high); in ice_intersect_phy_types_and_speeds()
3240 report_speeds = ice_aq_phy_types_to_link_speeds(phy_data->phy_low_orig, in ice_intersect_phy_types_and_speeds()
3241 phy_data->phy_high_orig); in ice_intersect_phy_types_and_speeds()
3245 if ((phy_data->user_speeds_orig & temp_speeds) == 0) { in ice_intersect_phy_types_and_speeds()
3248 phy_data->user_speeds_orig); in ice_intersect_phy_types_and_speeds()
3253 ice_sysctl_speeds_to_aq_phy_types(phy_data->user_speeds_orig, in ice_intersect_phy_types_and_speeds()
3254 &phy_data->phy_low_intr, &phy_data->phy_high_intr); in ice_intersect_phy_types_and_speeds()
3255 phy_data->user_speeds_intr = phy_data->user_speeds_orig & report_speeds; in ice_intersect_phy_types_and_speeds()
3256 phy_data->phy_low_intr &= phy_data->phy_low_orig; in ice_intersect_phy_types_and_speeds()
3257 phy_data->phy_high_intr &= phy_data->phy_high_orig; in ice_intersect_phy_types_and_speeds()
3278 struct ice_phy_data phy_data = { 0 }; in ice_sysctl_advertise_speed() local
3289 phy_data.report_mode = ICE_AQC_REPORT_ACTIVE_CFG; in ice_sysctl_advertise_speed()
3290 ret = ice_intersect_phy_types_and_speeds(sc, &phy_data); in ice_sysctl_advertise_speed()
3296 sysctl_speeds = phy_data.user_speeds_intr; in ice_sysctl_advertise_speed()
9559 struct ice_phy_data phy_data = { 0 }; in ice_apply_saved_phy_req_to_cfg() local
9568 memset(&phy_data, 0, sizeof(phy_data)); in ice_apply_saved_phy_req_to_cfg()
9569 phy_data.report_mode = ICE_AQC_REPORT_DFLT_CFG; in ice_apply_saved_phy_req_to_cfg()
9570 phy_data.user_speeds_orig = link_speeds; in ice_apply_saved_phy_req_to_cfg()
9571 ret = ice_intersect_phy_types_and_speeds(sc, &phy_data); in ice_apply_saved_phy_req_to_cfg()
9576 phy_low = phy_data.phy_low_intr; in ice_apply_saved_phy_req_to_cfg()
9577 phy_high = phy_data.phy_high_intr; in ice_apply_saved_phy_req_to_cfg()
9579 if (link_speeds == 0 || phy_data.user_speeds_intr) in ice_apply_saved_phy_req_to_cfg()
9582 memset(&phy_data, 0, sizeof(phy_data)); in ice_apply_saved_phy_req_to_cfg()
9583 phy_data.report_mode = ICE_AQC_REPORT_TOPO_CAP_NO_MEDIA; in ice_apply_saved_phy_req_to_cfg()
9584 phy_data.user_speeds_orig = link_speeds; in ice_apply_saved_phy_req_to_cfg()
9585 ret = ice_intersect_phy_types_and_speeds(sc, &phy_data); in ice_apply_saved_phy_req_to_cfg()
9590 phy_low = phy_data.phy_low_intr; in ice_apply_saved_phy_req_to_cfg()
9591 phy_high = phy_data.phy_high_intr; in ice_apply_saved_phy_req_to_cfg()
9593 if (!phy_data.user_speeds_intr) { in ice_apply_saved_phy_req_to_cfg()
9594 phy_low = phy_data.phy_low_orig; in ice_apply_saved_phy_req_to_cfg()
9595 phy_high = phy_data.phy_high_orig; in ice_apply_saved_phy_req_to_cfg()
9606 memset(&phy_data, 0, sizeof(phy_data)); in ice_apply_saved_phy_req_to_cfg()
9609 phy_data.report_mode = ICE_AQC_REPORT_TOPO_CAP_NO_MEDIA; in ice_apply_saved_phy_req_to_cfg()
9611 phy_data.report_mode = ICE_AQC_REPORT_TOPO_CAP_MEDIA; in ice_apply_saved_phy_req_to_cfg()
9612 phy_data.user_speeds_orig = link_speeds; in ice_apply_saved_phy_req_to_cfg()
9613 ret = ice_intersect_phy_types_and_speeds(sc, &phy_data); in ice_apply_saved_phy_req_to_cfg()
9618 phy_low = phy_data.phy_low_intr; in ice_apply_saved_phy_req_to_cfg()
9619 phy_high = phy_data.phy_high_intr; in ice_apply_saved_phy_req_to_cfg()
9635 memset(&phy_data, 0, sizeof(phy_data)); in ice_apply_saved_phy_req_to_cfg()
9636 phy_data.report_mode = ICE_AQC_REPORT_TOPO_CAP_NO_MEDIA; in ice_apply_saved_phy_req_to_cfg()
9637 phy_data.user_speeds_orig = link_speeds; in ice_apply_saved_phy_req_to_cfg()
9638 ret = ice_intersect_phy_types_and_speeds(sc, &phy_data); in ice_apply_saved_phy_req_to_cfg()
9643 phy_low = phy_data.phy_low_intr; in ice_apply_saved_phy_req_to_cfg()
9644 phy_high = phy_data.phy_high_intr; in ice_apply_saved_phy_req_to_cfg()
9646 if (!phy_data.user_speeds_intr) { in ice_apply_saved_phy_req_to_cfg()
9647 phy_low = phy_data.phy_low_orig; in ice_apply_saved_phy_req_to_cfg()
9648 phy_high = phy_data.phy_high_orig; in ice_apply_saved_phy_req_to_cfg()
9656 pi->phy.curr_user_speed_req = phy_data.user_speeds_intr; in ice_apply_saved_phy_req_to_cfg()