提交 20d3a518 编写于 作者: B Bart Van Assche 提交者: Jens Axboe

bcache: Reduce the number of sparse complaints about lock imbalances

Add more annotations for sparse to inform it about which functions do
not have the same number of spin_lock() and spin_unlock() calls.
Signed-off-by: NBart Van Assche <bart.vanassche@wdc.com>
Reviewed-by: NMichael Lyle <mlyle@lyle.org>
Signed-off-by: NJens Axboe <axboe@kernel.dk>
上级 42361469
...@@ -594,6 +594,7 @@ static void journal_write_done(struct closure *cl) ...@@ -594,6 +594,7 @@ static void journal_write_done(struct closure *cl)
} }
static void journal_write_unlock(struct closure *cl) static void journal_write_unlock(struct closure *cl)
__releases(&c->journal.lock)
{ {
struct cache_set *c = container_of(cl, struct cache_set, journal.io); struct cache_set *c = container_of(cl, struct cache_set, journal.io);
...@@ -705,6 +706,7 @@ static void journal_try_write(struct cache_set *c) ...@@ -705,6 +706,7 @@ static void journal_try_write(struct cache_set *c)
static struct journal_write *journal_wait_for_write(struct cache_set *c, static struct journal_write *journal_wait_for_write(struct cache_set *c,
unsigned nkeys) unsigned nkeys)
__acquires(&c->journal.lock)
{ {
size_t sectors; size_t sectors;
struct closure cl; struct closure cl;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册