From: Mikulas Patocka Date: Tue, 24 Nov 2015 00:11:32 +0000 (-0500) Subject: dm bufio: return NULL to improve code clarity X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=f98c8f797021e78ba27143ecd39c51995c47aa8b;p=linux-beck.git dm bufio: return NULL to improve code clarity A small code cleanup in new_read() - return NULL instead of b (although b is NULL at this point). This function is not returning pointer to the buffer, it is returning a pointer to the bufffer's data, thus it makes no sense to return the variable b. Signed-off-by: Mikulas Patocka Signed-off-by: Mike Snitzer --- diff --git a/drivers/md/dm-bufio.c b/drivers/md/dm-bufio.c index 2dd33085b331..7734298bff3c 100644 --- a/drivers/md/dm-bufio.c +++ b/drivers/md/dm-bufio.c @@ -1068,7 +1068,7 @@ static void *new_read(struct dm_bufio_client *c, sector_t block, __flush_write_list(&write_list); if (!b) - return b; + return NULL; if (need_submit) submit_io(b, READ, b->block, read_endio);