diff options
| author | Christoph Hellwig <hch@lst.de> | 2002-12-29 19:52:11 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@home.transmeta.com> | 2002-12-29 19:52:11 -0800 |
| commit | 2cea9523ee55d8bda0b14287d5761c956868572c (patch) | |
| tree | e87ee6049e318e98c42af0a458502404aa94918b /include/linux/mtd | |
| parent | 32cce74ba349764f1bda932748500232604e960d (diff) | |
[PATCH] more obsolete module API fixes
completly remove the old try_inc_mod_count()
Diffstat (limited to 'include/linux/mtd')
| -rw-r--r-- | include/linux/mtd/mtd.h | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h index 52d38241e91e..503a715fe014 100644 --- a/include/linux/mtd/mtd.h +++ b/include/linux/mtd/mtd.h @@ -215,10 +215,8 @@ static inline struct mtd_info *get_mtd_device(struct mtd_info *mtd, int num) struct mtd_info *ret; ret = __get_mtd_device(mtd, num); - - if (ret && ret->module && !try_inc_mod_count(ret->module)) + if (ret && !try_module_get(ret->module)) return NULL; - return ret; } @@ -227,7 +225,6 @@ static inline void put_mtd_device(struct mtd_info *mtd) module_put(mtd->module); } - struct mtd_notifier { void (*add)(struct mtd_info *mtd); void (*remove)(struct mtd_info *mtd); |
