aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdrian Bunk <bunk@stusta.de>2007-04-06 06:21:45 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2007-04-27 13:57:31 -0400
commit3106d46f51a1a72fdbf071ebc0800a9bcfcbc544 (patch)
treebd2045da6a476e942b1bbb004c3065124e856464
parent2753133eb3321feb81dcb9c88141dd2aa5973ee1 (diff)
the overdue removal of the mount/umount uevents
This patch contains the overdue removal of the mount/umount uevents. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--Documentation/feature-removal-schedule.txt9
-rw-r--r--fs/super.c12
-rw-r--r--include/linux/kobject.h8
-rw-r--r--lib/kobject_uevent.c4
4 files changed, 3 insertions, 30 deletions
diff --git a/Documentation/feature-removal-schedule.txt b/Documentation/feature-removal-schedule.txt
index 6da663607f7b..ec0b4843b1cb 100644
--- a/Documentation/feature-removal-schedule.txt
+++ b/Documentation/feature-removal-schedule.txt
@@ -134,15 +134,6 @@ Who: Arjan van de Ven <arjan@linux.intel.com>
134 134
135--------------------------- 135---------------------------
136 136
137What: mount/umount uevents
138When: February 2007
139Why: These events are not correct, and do not properly let userspace know
140 when a file system has been mounted or unmounted. Userspace should
141 poll the /proc/mounts file instead to detect this properly.
142Who: Greg Kroah-Hartman <gregkh@suse.de>
143
144---------------------------
145
146What: USB driver API moves to EXPORT_SYMBOL_GPL 137What: USB driver API moves to EXPORT_SYMBOL_GPL
147When: February 2008 138When: February 2008
148Files: include/linux/usb.h, drivers/usb/core/driver.c 139Files: include/linux/usb.h, drivers/usb/core/driver.c
diff --git a/fs/super.c b/fs/super.c
index 60b1e50cbf53..8341e4e1d738 100644
--- a/fs/super.c
+++ b/fs/super.c
@@ -725,16 +725,6 @@ static int test_bdev_super(struct super_block *s, void *data)
725 return (void *)s->s_bdev == data; 725 return (void *)s->s_bdev == data;
726} 726}
727 727
728static void bdev_uevent(struct block_device *bdev, enum kobject_action action)
729{
730 if (bdev->bd_disk) {
731 if (bdev->bd_part)
732 kobject_uevent(&bdev->bd_part->kobj, action);
733 else
734 kobject_uevent(&bdev->bd_disk->kobj, action);
735 }
736}
737
738int get_sb_bdev(struct file_system_type *fs_type, 728int get_sb_bdev(struct file_system_type *fs_type,
739 int flags, const char *dev_name, void *data, 729 int flags, const char *dev_name, void *data,
740 int (*fill_super)(struct super_block *, void *, int), 730 int (*fill_super)(struct super_block *, void *, int),
@@ -782,7 +772,6 @@ int get_sb_bdev(struct file_system_type *fs_type,
782 } 772 }
783 773
784 s->s_flags |= MS_ACTIVE; 774 s->s_flags |= MS_ACTIVE;
785 bdev_uevent(bdev, KOBJ_MOUNT);
786 } 775 }
787 776
788 return simple_set_mnt(mnt, s); 777 return simple_set_mnt(mnt, s);
@@ -801,7 +790,6 @@ void kill_block_super(struct super_block *sb)
801{ 790{
802 struct block_device *bdev = sb->s_bdev; 791 struct block_device *bdev = sb->s_bdev;
803 792
804 bdev_uevent(bdev, KOBJ_UMOUNT);
805 generic_shutdown_super(sb); 793 generic_shutdown_super(sb);
806 sync_blockdev(bdev); 794 sync_blockdev(bdev);
807 close_bdev_excl(bdev); 795 close_bdev_excl(bdev);
diff --git a/include/linux/kobject.h b/include/linux/kobject.h
index a659a97eccf1..eb0e63ef297f 100644
--- a/include/linux/kobject.h
+++ b/include/linux/kobject.h
@@ -42,11 +42,9 @@ enum kobject_action {
42 KOBJ_ADD = (__force kobject_action_t) 0x01, /* exclusive to core */ 42 KOBJ_ADD = (__force kobject_action_t) 0x01, /* exclusive to core */
43 KOBJ_REMOVE = (__force kobject_action_t) 0x02, /* exclusive to core */ 43 KOBJ_REMOVE = (__force kobject_action_t) 0x02, /* exclusive to core */
44 KOBJ_CHANGE = (__force kobject_action_t) 0x03, /* device state change */ 44 KOBJ_CHANGE = (__force kobject_action_t) 0x03, /* device state change */
45 KOBJ_MOUNT = (__force kobject_action_t) 0x04, /* mount event for block devices (broken) */ 45 KOBJ_OFFLINE = (__force kobject_action_t) 0x04, /* device offline */
46 KOBJ_UMOUNT = (__force kobject_action_t) 0x05, /* umount event for block devices (broken) */ 46 KOBJ_ONLINE = (__force kobject_action_t) 0x05, /* device online */
47 KOBJ_OFFLINE = (__force kobject_action_t) 0x06, /* device offline */ 47 KOBJ_MOVE = (__force kobject_action_t) 0x06, /* device move */
48 KOBJ_ONLINE = (__force kobject_action_t) 0x07, /* device online */
49 KOBJ_MOVE = (__force kobject_action_t) 0x08, /* device move */
50}; 48};
51 49
52struct kobject { 50struct kobject {
diff --git a/lib/kobject_uevent.c b/lib/kobject_uevent.c
index d9a3510ed2e2..12e311dc664c 100644
--- a/lib/kobject_uevent.c
+++ b/lib/kobject_uevent.c
@@ -42,10 +42,6 @@ static char *action_to_string(enum kobject_action action)
42 return "remove"; 42 return "remove";
43 case KOBJ_CHANGE: 43 case KOBJ_CHANGE:
44 return "change"; 44 return "change";
45 case KOBJ_MOUNT:
46 return "mount";
47 case KOBJ_UMOUNT:
48 return "umount";
49 case KOBJ_OFFLINE: 45 case KOBJ_OFFLINE:
50 return "offline"; 46 return "offline";
51 case KOBJ_ONLINE: 47 case KOBJ_ONLINE: