From: Tony Nguyen <anthony.l.nguyen@intel.com>
To: Mikael Barsehyan <mikael.barsehyan@intel.com>,
<intel-wired-lan@lists.osuosl.org>
Cc: Chinh T Cao <chinh.t.cao@intel.com>
Subject: Re: [Intel-wired-lan] [PATCH net-next v2] ice: Allow 100M speeds for some devices
Date: Fri, 29 Jul 2022 10:51:24 -0700 [thread overview]
Message-ID: <2744b8f1-a669-cb2e-73c5-1402605cc616@intel.com> (raw)
In-Reply-To: <20220728192332.159990-1-mikael.barsehyan@intel.com>
On 7/28/2022 12:23 PM, Mikael Barsehyan wrote:
<snip>
> @@ -1503,20 +1503,22 @@ ice_get_ethtool_stats(struct net_device *netdev,
>
> /**
> * ice_mask_min_supported_speeds
> + * @hw: pointer to the HW structure
> * @phy_types_high: PHY type high
> * @phy_types_low: PHY type low to apply minimum supported speeds mask
> *
> * Apply minimum supported speeds mask to PHY type low. These are the speeds
> * for ethtool supported link mode.
> */
> -static
> -void ice_mask_min_supported_speeds(u64 phy_types_high, u64 *phy_types_low)
> +static void
> +ice_mask_min_supported_speeds(struct ice_hw *hw,
> + u64 phy_types_high, u64 *phy_types_low)
Alignment needs to be adjusted:
Warning - CHECK: Alignment should match open parenthesis
> {
> /* if QSFP connection with 100G speed, minimum supported speed is 25G */
> if (*phy_types_low & ICE_PHY_TYPE_LOW_MASK_100G ||
> phy_types_high & ICE_PHY_TYPE_HIGH_MASK_100G)
> *phy_types_low &= ~ICE_PHY_TYPE_LOW_MASK_MIN_25G;
> - else
> + else if (!ice_is_100m_speed_supported(hw))
> *phy_types_low &= ~ICE_PHY_TYPE_LOW_MASK_MIN_1G;
> }
>
> @@ -1566,7 +1568,8 @@ ice_phy_type_to_ethtool(struct net_device *netdev,
> phy_types_low = le64_to_cpu(pf->nvm_phy_type_lo);
> phy_types_high = le64_to_cpu(pf->nvm_phy_type_hi);
>
> - ice_mask_min_supported_speeds(phy_types_high, &phy_types_low);
> + ice_mask_min_supported_speeds(&pf->hw, phy_types_high,
> + &phy_types_low);
> /* determine advertised modes based on link override only
> * if it's supported and if the FW doesn't abstract the
> * driver from having to account for link overrides
_______________________________________________
Intel-wired-lan mailing list
Intel-wired-lan@osuosl.org
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
next prev parent reply other threads:[~2022-07-29 17:51 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-28 19:23 [Intel-wired-lan] [PATCH net-next v2] ice: Allow 100M speeds for some devices Mikael Barsehyan
2022-07-29 17:51 ` Tony Nguyen [this message]
2022-08-02 6:48 ` Paul Menzel
2022-08-08 17:44 ` Anirudh Venkataramanan
2022-08-11 0:10 ` Rustad, Mark D
2022-08-12 8:12 ` Paul Menzel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2744b8f1-a669-cb2e-73c5-1402605cc616@intel.com \
--to=anthony.l.nguyen@intel.com \
--cc=chinh.t.cao@intel.com \
--cc=intel-wired-lan@lists.osuosl.org \
--cc=mikael.barsehyan@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox