Re: [PATCH for-next v11 01/11] RDMA/rxe: Move mcg_lock to rxe

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

 



On 2/11/22 13:00, Jason Gunthorpe wrote:
> On Tue, Feb 08, 2022 at 03:16:35PM -0600, Bob Pearson wrote:
> 
>> @@ -62,7 +61,7 @@ static int rxe_mcast_get_grp(struct rxe_dev *rxe, union ib_gid *mgid,
>>  	if (rxe->attr.max_mcast_qp_attach == 0)
>>  		return -EINVAL;
>>  
>> -	write_lock_bh(&pool->pool_lock);
>> +	spin_lock_bh(&rxe->mcg_lock);
> 
>>  	grp = rxe_pool_get_key_locked(pool, mgid);
> 
> Now this calls rxe_pool_get_key_locked() without the lock :\
> 
> This is all fixed up a few patches later, so it only hurts
> bisect-ability, do you want to fix it?
> 
> I looked up to 'Remove mcg from rxe pools' and it seems fine to me
> otherwise
> 
> Thanks,
> Jason
It is locked. Just a different lock. All uses of the red-black tree in rxe_pool for this object pool will be using the same lock. And as you say we are heading towards replacing it all. Just leave it.

Bob



[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