lkml.org 
[lkml]   [2018]   [Dec]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] mtip32xx: avoid using semaphores
From
Date
On 12/10/18 2:34 PM, Arnd Bergmann wrote:
> The "cmd_slot_unal" semaphore is never used in a blocking way
> but only as an atomic counter. Change the code to using
> atomic_dec_if_positive() as a better API.

Looks good to me. We should also convert the return to blk-mq
when we hit failure here to BLK_STS_DEV_RESOURCE, but that's
a separate patch.

--
Jens Axboe

\
 
 \ /
  Last update: 2018-12-10 22:45    [W:0.032 / U:0.340 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site