Re: [PATCH for-next v2] RDMA/efa: CQ notifications

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

 



On Mon, Sep 13, 2021 at 03:04:04PM +0300, Gal Pressman wrote:

> @@ -993,15 +1002,24 @@ int efa_destroy_cq(struct ib_cq *ibcq, struct ib_udata *udata)
>  		  "Destroy cq[%d] virt[0x%p] freed: size[%lu], dma[%pad]\n",
>  		  cq->cq_idx, cq->cpu_addr, cq->size, &cq->dma_addr);
>  
> -	rdma_user_mmap_entry_remove(cq->mmap_entry);
> +	efa_cq_user_mmap_entries_remove(cq);
>  	efa_destroy_cq_idx(dev, cq->cq_idx);
> +	xa_erase(&dev->cqs_xa, cq->cq_idx);
> +	if (cq->eq)
> +		synchronize_irq(cq->eq->irq.irqn);

Why is this conditional? The whole thing should be conditional,
including putting it in the XA in the first place if that is the
intention

A comment on the xa_load would also be good to explain that it is safe
because this must be a irq and snychronize_irq() manages lifetime

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