RE: [PATCH net 1/3] qed: Release CQ resource under lock on failure

2017-02-16 Thread Amrani, Ram
> The bitmap functions are being used by various bitmaps one of which is the > cid. > The cid code must allocate two consecutive cids. So here the lock is over two > calls > to the bit allocating call. > > I am planning to recode the cid to use one bit instead of two, this is further > down the

RE: [PATCH net 1/3] qed: Release CQ resource under lock on failure

2017-01-26 Thread Amrani, Ram
> Minor suggestion. > Can you consider embedding the lock and unlock inside qed_bmap_release_id? > There are two places where this is bad idea as driver needs to release two > IDs but still one is in error flow and second is when destroying QP so for > most cases code may look a bit better. > The

Re: [PATCH net 1/3] qed: Release CQ resource under lock on failure

2017-01-24 Thread Yuval Shaia
On Tue, Jan 24, 2017 at 11:15:21PM +0200, Yuval Mintz wrote: > From: Ram Amrani > > The CQ resource pool is protected by a spin lock. When a CQ creation > fails it now deallocates under that lock as well. > > Signed-off-by: Ram Amrani > Signed-off-by: Yuval Mintz > --- > drivers/net/ethernet/