diff options
Diffstat (limited to 'drivers/base/module.c')
-rw-r--r-- | drivers/base/module.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/base/module.c b/drivers/base/module.c index a1b55da071..b0b79b9c18 100644 --- a/drivers/base/module.c +++ b/drivers/base/module.c @@ -7,6 +7,7 @@ #include <linux/errno.h> #include <linux/slab.h> #include <linux/string.h> +#include <linux/rcupdate.h> #include "base.h" static char *make_driver_name(struct device_driver *drv) @@ -97,6 +98,9 @@ void module_remove_driver(struct device_driver *drv) if (!drv) return; + /* Synchronize with dev_uevent() */ + synchronize_rcu(); + sysfs_remove_link(&drv->p->kobj, "module"); if (drv->owner) |