Re: [PATCH net] net/mlx5: fix calling mlx5_cmd_init() before DMA mask is set

From: Jason Gunthorpe
Date: Wed Oct 11 2023 - 19:10:28 EST


On Wed, Oct 11, 2023 at 11:45:04AM -0700, Saeed Mahameed wrote:
> > > The above works too. Maybe for consistency within probe_one() it would
> > > then make sense to also rename set_dma_caps() to mlx5_dma_init()?
> >
> > Sounds great, thanks
> >
> > BTW, I was informed offlist that Saeed also has fix to this issue,
> > but I don't know if he wants to progress with that fix as it has wrong
> > RCA in commit message and as an outcome of that much complex solution,
> > which is not necessary.
> >
> > So I would be happy to see your patch with mlx5_dma_init().
> >
> > Thanks
> >
>
> Actually I prefer the internal patch, it moves the dma parts out of
> mlx5_cmd_init() into mlx5_cmd_enable() which happens after dma caps are
> set. since it is using the current mlx5 function structure and breakdown, I
> prefer it over adding new function to the driver.
>
> I will share the patch, I will let Niklas test it and approve it before
> submission.

Let's hurry please, mlx5 will be broken on S390 in rc1 if this is not
fixed soon.

Jason