mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-20 13:41:30 +00:00
lightnvm: prevent target type module removal when in use
If target type module e.g. pblk here is unloaded (rmmod) while module is in use (after creating target) system crashes. We fix this by using module API refcnt. Signed-off-by: Rakesh Pandit <rakesh@tuxera.com> Signed-off-by: Matias Bjørling <m@bjorling.me> Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
parent
47bc227dee
commit
900148296b
3 changed files with 6 additions and 0 deletions
|
@ -460,6 +460,7 @@ struct nvm_tgt_type {
|
|||
|
||||
/* For internal use */
|
||||
struct list_head list;
|
||||
struct module *owner;
|
||||
};
|
||||
|
||||
extern struct nvm_tgt_type *nvm_find_target_type(const char *, int);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue