diff options
author | David Woodhouse <dwmw2@infradead.org> | 2006-05-08 09:05:05 -0400 |
---|---|---|
committer | David Woodhouse <dwmw2@infradead.org> | 2006-05-08 09:05:05 -0400 |
commit | 5e535429a9117b8b6219da0e0cb087f52c0c9597 (patch) | |
tree | b20a402b5696e2b5aabdc7a4720eaf33e306bd71 /drivers/mtd/devices/doc2001plus.c | |
parent | 73566edf9b91dd085ddb12033d0ea7288979dd10 (diff) |
Remove inter_module_xxx() from DiskOnChip drivers.
Finally putting it back how it was before Keith got at it -- yay :)
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Diffstat (limited to 'drivers/mtd/devices/doc2001plus.c')
-rw-r--r-- | drivers/mtd/devices/doc2001plus.c | 22 |
1 files changed, 4 insertions, 18 deletions
diff --git a/drivers/mtd/devices/doc2001plus.c b/drivers/mtd/devices/doc2001plus.c index 5f57f29efee4..c80a0efa3f35 100644 --- a/drivers/mtd/devices/doc2001plus.c +++ b/drivers/mtd/devices/doc2001plus.c | |||
@@ -447,16 +447,9 @@ static int DoCMilPlus_is_alias(struct DiskOnChip *doc1, struct DiskOnChip *doc2) | |||
447 | return retval; | 447 | return retval; |
448 | } | 448 | } |
449 | 449 | ||
450 | static const char im_name[] = "DoCMilPlus_init"; | 450 | /* This routine is found from the docprobe code by symbol_get(), |
451 | 451 | * which will bump the use count of this module. */ | |
452 | /* This routine is made available to other mtd code via | 452 | void DoCMilPlus_init(struct mtd_info *mtd) |
453 | * inter_module_register. It must only be accessed through | ||
454 | * inter_module_get which will bump the use count of this module. The | ||
455 | * addresses passed back in mtd are valid as long as the use count of | ||
456 | * this module is non-zero, i.e. between inter_module_get and | ||
457 | * inter_module_put. Keith Owens <kaos@ocs.com.au> 29 Oct 2000. | ||
458 | */ | ||
459 | static void DoCMilPlus_init(struct mtd_info *mtd) | ||
460 | { | 453 | { |
461 | struct DiskOnChip *this = mtd->priv; | 454 | struct DiskOnChip *this = mtd->priv; |
462 | struct DiskOnChip *old = NULL; | 455 | struct DiskOnChip *old = NULL; |
@@ -524,6 +517,7 @@ static void DoCMilPlus_init(struct mtd_info *mtd) | |||
524 | return; | 517 | return; |
525 | } | 518 | } |
526 | } | 519 | } |
520 | EXPORT_SYMBOL_GPL(DocMilPlus_init); | ||
527 | 521 | ||
528 | #if 0 | 522 | #if 0 |
529 | static int doc_dumpblk(struct mtd_info *mtd, loff_t from) | 523 | static int doc_dumpblk(struct mtd_info *mtd, loff_t from) |
@@ -1122,12 +1116,6 @@ int doc_erase(struct mtd_info *mtd, struct erase_info *instr) | |||
1122 | * | 1116 | * |
1123 | ****************************************************************************/ | 1117 | ****************************************************************************/ |
1124 | 1118 | ||
1125 | static int __init init_doc2001plus(void) | ||
1126 | { | ||
1127 | inter_module_register(im_name, THIS_MODULE, &DoCMilPlus_init); | ||
1128 | return 0; | ||
1129 | } | ||
1130 | |||
1131 | static void __exit cleanup_doc2001plus(void) | 1119 | static void __exit cleanup_doc2001plus(void) |
1132 | { | 1120 | { |
1133 | struct mtd_info *mtd; | 1121 | struct mtd_info *mtd; |
@@ -1143,11 +1131,9 @@ static void __exit cleanup_doc2001plus(void) | |||
1143 | kfree(this->chips); | 1131 | kfree(this->chips); |
1144 | kfree(mtd); | 1132 | kfree(mtd); |
1145 | } | 1133 | } |
1146 | inter_module_unregister(im_name); | ||
1147 | } | 1134 | } |
1148 | 1135 | ||
1149 | module_exit(cleanup_doc2001plus); | 1136 | module_exit(cleanup_doc2001plus); |
1150 | module_init(init_doc2001plus); | ||
1151 | 1137 | ||
1152 | MODULE_LICENSE("GPL"); | 1138 | MODULE_LICENSE("GPL"); |
1153 | MODULE_AUTHOR("Greg Ungerer <gerg@snapgear.com> et al."); | 1139 | MODULE_AUTHOR("Greg Ungerer <gerg@snapgear.com> et al."); |