diff options
author | Christian Gromm <christian.gromm@microchip.com> | 2019-11-08 17:21:08 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-11-11 16:41:00 +0100 |
commit | 08283d30744434d8f30d386622372e8f5b03bcf2 (patch) | |
tree | c34f2411b0de27f49975720fd9e066ec08c6ee13 /drivers/staging/most/core.h | |
parent | 4845b3c8c8d221441605a1eff8aab7f1622dce93 (diff) |
staging: most: block module removal while having active configfs items
This patch avoids that core component modules are being unloaded
while the related configfs interface has active items in its directories.
It is needed to prevent the situation where the core module cannot
be unloaded anymore, because the reference count 'used by' indicates that
the module is still being used and the usage count cannot be decreased by
calling rmdir, as the configfs directory has already been removed.
Signed-off-by: Christian Gromm <christian.gromm@microchip.com>
Link: https://lore.kernel.org/r/1573230068-27658-3-git-send-email-christian.gromm@microchip.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/most/core.h')
-rw-r--r-- | drivers/staging/most/core.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/staging/most/core.h b/drivers/staging/most/core.h index 652aaa771029..49859aef98df 100644 --- a/drivers/staging/most/core.h +++ b/drivers/staging/most/core.h @@ -265,6 +265,7 @@ struct most_interface { struct core_component { struct list_head list; const char *name; + struct module *mod; int (*probe_channel)(struct most_interface *iface, int channel_idx, struct most_channel_config *cfg, char *name, char *param); |