On 5/9/2024 11:50 PM, Anil Samal wrote:
> Current driver implementation for Sideband Queue supports a
> fixed flag (ICE_AQ_FLAG_RD). To retrieve FEC statistics from
> firmware, Sideband Queue command is used with a different flag.
> 
> Extend API for Sideband Queue command to use 'flag' as input
> argument.
> 
> Reviewed-by: Anthony L Nguyen <[email protected]>
> Reviewed-by: Jesse Brandeburg <[email protected]>
> Signed-off-by: Anil Samal <[email protected]>
> ---
>  drivers/net/ethernet/intel/ice/ice_common.c |  5 +++--
>  drivers/net/ethernet/intel/ice/ice_common.h |  2 +-
>  drivers/net/ethernet/intel/ice/ice_ptp_hw.c | 16 ++++++++--------
>  3 files changed, 12 insertions(+), 11 deletions(-)
> 
> diff --git a/drivers/net/ethernet/intel/ice/ice_common.c 
> b/drivers/net/ethernet/intel/ice/ice_common.c
> index 5649b257e631..9a0a533613ff 100644
> --- a/drivers/net/ethernet/intel/ice/ice_common.c
> +++ b/drivers/net/ethernet/intel/ice/ice_common.c
> @@ -1473,8 +1473,9 @@ ice_sbq_send_cmd(struct ice_hw *hw, struct 
> ice_sbq_cmd_desc *desc,
>   * ice_sbq_rw_reg - Fill Sideband Queue command
>   * @hw: pointer to the HW struct
>   * @in: message info to be filled in descriptor
> + * @flag: flag to fill desc structure

I would say:

@flags: control queue descriptor flags

>   */
> -int ice_sbq_rw_reg(struct ice_hw *hw, struct ice_sbq_msg_input *in)
> +int ice_sbq_rw_reg(struct ice_hw *hw, struct ice_sbq_msg_input *in, u16 flag)
>  {
>       struct ice_sbq_cmd_desc desc = {0};
>       struct ice_sbq_msg_req msg = {0};
> @@ -1498,7 +1499,7 @@ int ice_sbq_rw_reg(struct ice_hw *hw, struct 
> ice_sbq_msg_input *in)
>                */
>               msg_len -= sizeof(msg.data);
>  
> -     desc.flags = cpu_to_le16(ICE_AQ_FLAG_RD);
> +     desc.flags = cpu_to_le16(flag);

IMHO it makes more sense to call this "flags" instead of flag, since you
could pass arbitrary flags not just one flag.

Additionally, this patch did not apply cleanly to next-queue, due to
conflicts with other work on the tree.

Would you mind renaming this field and rebasing this series?

Thanks,
Jake

Reply via email to