[PATCH net 2/2] net: phylink: use USXGMII control-word format to parse Q-USGMII word

Simon Horman simon.horman at corigine.com
Thu Jun 8 10:45:16 PDT 2023


On Thu, Jun 08, 2023 at 06:34:15PM +0200, Maxime Chevallier wrote:

...

> diff --git a/drivers/net/phy/phylink.c b/drivers/net/phy/phylink.c
> index 809e6d5216dc..730f8860d2a6 100644
> --- a/drivers/net/phy/phylink.c
> +++ b/drivers/net/phy/phylink.c
> @@ -3298,6 +3298,41 @@ void phylink_decode_usxgmii_word(struct phylink_link_state *state,
>  }
>  EXPORT_SYMBOL_GPL(phylink_decode_usxgmii_word);
>  
> +/**
> + * phylink_decode_usgmii_word() - decode the USGMII word from a MAC PCS
> + * @state: a pointer to a struct phylink_link_state.
> + * @lpa: a 16 bit value which stores the USGMII auto-negotiation word
> + *
> + * Helper for MAC PCS supporting the USGMII protocol and the auto-negotiation
> + * code word.  Decode the USGMII code word and populate the corresponding fields
> + * (speed, duplex) into the phylink_link_state structure. The structure for this
> + * word is the same as the USXGMII word, expect it only supports speeds up to
> + * 1Gbps.
> + */
> +static void phylink_decode_usgmii_word(struct phylink_link_state *state,
> +				 uint16_t lpa)

Hi Maxime,

a minor nit from my side: the indentation of the line above should line up
with the inside of the opening parentheses on the previous line.

static void phylink_decode_usgmii_word(struct phylink_link_state *state,
				       uint16_t lpa)

...

As I see there is feedback from Russell, of a more substantial nature,
and it looks will be a v2, I'll mark this as changes requested in patchwork.

pw-bot: cr



More information about the linux-arm-kernel mailing list