Skip to content

Commit

Permalink
md: remove unnecessary memset from multipath.
Browse files Browse the repository at this point in the history
Recent commit bbba809
replaced mempool_create_kzalloc_pool with mempool_create_kmalloc_pool
plus a memset.
This memset is not needed (and we didn't need kzalloc in the first
place).
Ever field of the allocated structure (struct multipath_bh) is
initialised immediately except retry_list, and memset does not
initial a list_head anyway.

To remove the memset.

Signed-off-by: NeilBrown <neilb@suse.de>
  • Loading branch information
NeilBrown committed Sep 23, 2009
1 parent 3fa841d commit f28f4e2
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion drivers/md/multipath.c
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,6 @@ static int multipath_make_request (struct request_queue *q, struct bio * bio)
}

mp_bh = mempool_alloc(conf->pool, GFP_NOIO);
memset(mp_bh, 0, sizeof(*mp_bh));

mp_bh->master_bio = bio;
mp_bh->mddev = mddev;
Expand Down

0 comments on commit f28f4e2

Please sign in to comment.