diff options
Diffstat (limited to 'drivers/md')
-rw-r--r-- | drivers/md/dm.c | 4 | ||||
-rw-r--r-- | drivers/md/md.c | 4 | ||||
-rw-r--r-- | drivers/md/md.h | 2 | ||||
-rw-r--r-- | drivers/md/multipath.c | 3 |
4 files changed, 7 insertions, 6 deletions
diff --git a/drivers/md/dm.c b/drivers/md/dm.c index eee28fac210c..376f1ab48a24 100644 --- a/drivers/md/dm.c +++ b/drivers/md/dm.c | |||
@@ -1716,7 +1716,7 @@ out: | |||
1716 | return r; | 1716 | return r; |
1717 | } | 1717 | } |
1718 | 1718 | ||
1719 | static struct block_device_operations dm_blk_dops; | 1719 | static const struct block_device_operations dm_blk_dops; |
1720 | 1720 | ||
1721 | static void dm_wq_work(struct work_struct *work); | 1721 | static void dm_wq_work(struct work_struct *work); |
1722 | 1722 | ||
@@ -2663,7 +2663,7 @@ void dm_free_md_mempools(struct dm_md_mempools *pools) | |||
2663 | kfree(pools); | 2663 | kfree(pools); |
2664 | } | 2664 | } |
2665 | 2665 | ||
2666 | static struct block_device_operations dm_blk_dops = { | 2666 | static const struct block_device_operations dm_blk_dops = { |
2667 | .open = dm_blk_open, | 2667 | .open = dm_blk_open, |
2668 | .release = dm_blk_close, | 2668 | .release = dm_blk_close, |
2669 | .ioctl = dm_blk_ioctl, | 2669 | .ioctl = dm_blk_ioctl, |
diff --git a/drivers/md/md.c b/drivers/md/md.c index 9dd872000cec..6aa497e4baf8 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c | |||
@@ -138,7 +138,7 @@ static ctl_table raid_root_table[] = { | |||
138 | { .ctl_name = 0 } | 138 | { .ctl_name = 0 } |
139 | }; | 139 | }; |
140 | 140 | ||
141 | static struct block_device_operations md_fops; | 141 | static const struct block_device_operations md_fops; |
142 | 142 | ||
143 | static int start_readonly; | 143 | static int start_readonly; |
144 | 144 | ||
@@ -5556,7 +5556,7 @@ static int md_revalidate(struct gendisk *disk) | |||
5556 | mddev->changed = 0; | 5556 | mddev->changed = 0; |
5557 | return 0; | 5557 | return 0; |
5558 | } | 5558 | } |
5559 | static struct block_device_operations md_fops = | 5559 | static const struct block_device_operations md_fops = |
5560 | { | 5560 | { |
5561 | .owner = THIS_MODULE, | 5561 | .owner = THIS_MODULE, |
5562 | .open = md_open, | 5562 | .open = md_open, |
diff --git a/drivers/md/md.h b/drivers/md/md.h index f8fc188bc762..f55d2ff95133 100644 --- a/drivers/md/md.h +++ b/drivers/md/md.h | |||
@@ -201,7 +201,7 @@ struct mddev_s | |||
201 | * INTR: resync needs to be aborted for some reason | 201 | * INTR: resync needs to be aborted for some reason |
202 | * DONE: thread is done and is waiting to be reaped | 202 | * DONE: thread is done and is waiting to be reaped |
203 | * REQUEST: user-space has requested a sync (used with SYNC) | 203 | * REQUEST: user-space has requested a sync (used with SYNC) |
204 | * CHECK: user-space request for for check-only, no repair | 204 | * CHECK: user-space request for check-only, no repair |
205 | * RESHAPE: A reshape is happening | 205 | * RESHAPE: A reshape is happening |
206 | * | 206 | * |
207 | * If neither SYNC or RESHAPE are set, then it is a recovery. | 207 | * If neither SYNC or RESHAPE are set, then it is a recovery. |
diff --git a/drivers/md/multipath.c b/drivers/md/multipath.c index 89e76819f61f..d2d3fd54cc68 100644 --- a/drivers/md/multipath.c +++ b/drivers/md/multipath.c | |||
@@ -150,6 +150,7 @@ static int multipath_make_request (struct request_queue *q, struct bio * bio) | |||
150 | } | 150 | } |
151 | 151 | ||
152 | mp_bh = mempool_alloc(conf->pool, GFP_NOIO); | 152 | mp_bh = mempool_alloc(conf->pool, GFP_NOIO); |
153 | memset(mp_bh, 0, sizeof(*mp_bh)); | ||
153 | 154 | ||
154 | mp_bh->master_bio = bio; | 155 | mp_bh->master_bio = bio; |
155 | mp_bh->mddev = mddev; | 156 | mp_bh->mddev = mddev; |
@@ -493,7 +494,7 @@ static int multipath_run (mddev_t *mddev) | |||
493 | } | 494 | } |
494 | mddev->degraded = conf->raid_disks - conf->working_disks; | 495 | mddev->degraded = conf->raid_disks - conf->working_disks; |
495 | 496 | ||
496 | conf->pool = mempool_create_kzalloc_pool(NR_RESERVED_BUFS, | 497 | conf->pool = mempool_create_kmalloc_pool(NR_RESERVED_BUFS, |
497 | sizeof(struct multipath_bh)); | 498 | sizeof(struct multipath_bh)); |
498 | if (conf->pool == NULL) { | 499 | if (conf->pool == NULL) { |
499 | printk(KERN_ERR | 500 | printk(KERN_ERR |