lkml.org 
[lkml]   [2003]   [Feb]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
Subject[PATCH 4/8] dm: deregister the misc device before removing /dev/mapper
From
Fix problem with devfs when unloading the dm module.

dm-ioctl.c: deregister the misc device, and its associated symlink
*before* removing the /dev/mapper dir. [Alasdair Kergon]

--- diff/drivers/md/dm-ioctl.c 2003-02-26 16:09:52.000000000 +0000
+++ source/drivers/md/dm-ioctl.c 2003-02-26 16:09:57.000000000 +0000
@@ -1123,17 +1123,17 @@
return 0;

failed:
+ devfs_remove(DM_DIR "/control");
+ if (misc_deregister(&_dm_misc) < 0)
+ DMERR("misc_deregister failed for control device");
dm_hash_exit();
- misc_deregister(&_dm_misc);
return r;
}

void dm_interface_exit(void)
{
- dm_hash_exit();
-
devfs_remove(DM_DIR "/control");
-
if (misc_deregister(&_dm_misc) < 0)
DMERR("misc_deregister failed for control device");
+ dm_hash_exit();
}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 13:33    [W:0.082 / U:0.460 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site