Re: [PATCH] RDMA/mlx4: Do not fail the registration on port stats

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Nov 15, 2021 at 11:15:19AM +0100, Jack Wang wrote:
> If the FW doesn't support MLX4_DEV_CAP_FLAG2_DIAG_PER_PORT,
> mlx4 driver will fail the ib_setup_port_attrs, which is called
> from ib_register_device/enable_device_and_get, in the end leads
> to device not detected[1][2]
> 
> To fix it, add a new mlx4_ib_hw_stats_ops1, w/o alloc_hw_port_stats
> if FW does not support MLX4_DEV_CAP_FLAG2_DIAG_PER_PORT.
> 
> [1] https://bugzilla.redhat.com/show_bug.cgi?id=2014094
> [2] https://lore.kernel.org/linux-rdma/CAMGffEn2wvEnmzc0xe=xYiCLqpphiHDBxCxqAELrBofbUAMQxw@xxxxxxxxxxxxxx/T/#t
> 
> Fixes: 4b5f4d3fb408 ("RDMA: Split the alloc_hw_stats() ops to port and device variants")
> 
> Signed-off-by: Jack Wang <jinpu.wang@xxxxxxxxx>
> Reviewed-by: Leon Romanovsky <leonro@xxxxxxxxxx>
> ---
>  drivers/infiniband/hw/mlx4/main.c | 18 +++++++++++++++---
>  1 file changed, 15 insertions(+), 3 deletions(-)

Applied to for-rc, thanks

Jason



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux