Small cleanup for z2ram.c
PATCH 1/1 Small cleanup for z2ram.c
We should use Z2MINOR_COUNT as range argument in blk_unregister_region()
Signed-off-by Zhao Lei <[email protected]>
---drivers/block/z2ram.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
drivers/block/z2ram.c +0 -0
@@ -374,7 +374,7 @@ err:
static void __exit z2_exit(void)
{
int i, j;
- blk_unregister_region(MKDEV(Z2RAM_MAJOR, 0), 256);
+ blk_unregister_region(MKDEV(Z2RAM_MAJOR, 0), Z2MINOR_COUNT);
unregister_blkdev(Z2RAM_MAJOR, DEVICE_NAME);
del_gendisk(z2ram_gendisk);
put_disk(z2ram_gendisk);Signature · 1 line
1.5.5.3
Quoted 3 lines · Zhaolei
We should use
Z2MINOR_COUNTas range argument inblk_unregister_region()Signed-off-by Zhao Lei <[email protected]>
Committed to #tj-block-for-linus (temp branch to collect block layer patches while Jens is gone).
git://git.kernel.org/pub/scm/linux/kernel/git/tj/misc.git tj-block-for-linus
Thanks.
Signature · 1 line
tejun