On 5/26/25 21:11, Jason Gunthorpe wrote:
On Mon, May 26, 2025 at 10:19:38AM -0300, Jason Gunthorpe wrote:
@@ -1454,11 +1466,15 @@ static int ionic_destroy_cq(struct ib_cq *ibcq, struct ib_udata *udata)
static bool pd_local_privileged(struct ib_pd *pd)
{
+ /* That isn't how it works, only the lkey get_dma_mr() returns is
+ special and must be used on any WRs that require it. WRs refering to any
+ other lkeys must behave normally. */
return !pd->uobject;
}
I was thinking about this some more, probably the call to get_dma_mr()
should set a flag in the pd struct (you need a pds_pd struct) which
indicates that the IONIC_DMA_LKEY is enabled on that PD. Then all
QPs/etc created against the PD should allow using it.
Checking a uobject here is just a little weird.
Jason
Sure. Will use a flag inside pd to indicate use of local key.
Thanks,
Abhijit