Subject: Re: [PATCH net-next 4/5] net/mlx5e: Add PSP stats support for Rx/Tx flows

From: Jakub Kicinski <[email-masked]>
Date: Wed, 22 Oct 2025 17:56:02 -0700

On Wed, 22 Oct 2025 12:37:36 -0700 Daniel Zahka wrote:
> 		mlx5_core_warn(mdev,
> +			       "fail to create psp rx flow counter err(%ld)\n",
> +			       PTR_ERR(flow_counter));
> +		err = PTR_ERR(flow_counter);
> +		goto out_err;
> +	}
> +	accel_psp->rx_counter = flow_counter;
> +
> +	flow_counter = mlx5_fc_create(mdev, false);
> +	if (IS_ERR(flow_counter)) {
> +		mlx5_core_warn(mdev,
> +			       "fail to create psp rx auth fail flow counter err(%ld)\n",
> +			       PTR_ERR(flow_counter));
> +		err = PTR_ERR(flow_counter);
> +		goto out_counter_err;
> +	}
> +	accel_psp->rx_auth_fail_counter = flow_counter;
> +
> +	flow_counter = mlx5_fc_create(mdev, false);
> +	if (IS_ERR(flow_counter)) {
> +		mlx5_core_warn(mdev,
> +			       "fail to create psp rx error flow counter err(%ld)\n",
> +			       PTR_ERR(flow_counter));
> +		err = PTR_ERR(flow_counter);
> +		goto out_auth_fail_counter_err;
> +	}
> +	accel_psp->rx_err_counter = flow_counter;
> +
> +	flow_counter = mlx5_fc_create(mdev, false);
> +	if (IS_ERR(flow_counter)) {
> +		mlx5_core_warn(mdev,
> +			       "fail to create psp rx auth fail flow counter err(%ld)\n",
> +			       PTR_ERR(flow_counter));

Coccicheck sayeth (5x):

drivers/net/ethernet/mellanox/mlx5/core/en_accel/psp.c:
WARNING: Consider using %pe to print PTR_ERR()

That's %pe, flow_counter instead of %d, PTR_ERR(flow_counter)
-- 
pw-bot: cr