@@ -331,13 +331,6 @@ read_pri_intelext(struct map_info *map, __u16 adr)
331331 return extp ;
332332}
333333
334- /* This routine is made available to other mtd code via
335- * inter_module_register. It must only be accessed through
336- * inter_module_get which will bump the use count of this module. The
337- * addresses passed back in cfi are valid as long as the use count of
338- * this module is non-zero, i.e. between inter_module_get and
339- * inter_module_put. Keith Owens <kaos@ocs.com.au> 29 Oct 2000.
340- */
341334struct mtd_info * cfi_cmdset_0001 (struct map_info * map , int primary )
342335{
343336 struct cfi_private * cfi = map -> fldrv_priv ;
@@ -415,6 +408,11 @@ struct mtd_info *cfi_cmdset_0001(struct map_info *map, int primary)
415408
416409 return cfi_intelext_setup (mtd );
417410}
411+ struct mtd_info * cfi_cmdset_0003 (struct map_info * map , int primary ) __attribute__((alias ("cfi_cmdset_0001" )));
412+ struct mtd_info * cfi_cmdset_0200 (struct map_info * map , int primary ) __attribute__((alias ("cfi_cmdset_0001" )));
413+ EXPORT_SYMBOL_GPL (cfi_cmdset_0001 );
414+ EXPORT_SYMBOL_GPL (cfi_cmdset_0003 );
415+ EXPORT_SYMBOL_GPL (cfi_cmdset_0200 );
418416
419417static struct mtd_info * cfi_intelext_setup (struct mtd_info * mtd )
420418{
@@ -2445,28 +2443,8 @@ static void cfi_intelext_destroy(struct mtd_info *mtd)
24452443 kfree (mtd -> eraseregions );
24462444}
24472445
2448- static char im_name_0001 [] = "cfi_cmdset_0001" ;
2449- static char im_name_0003 [] = "cfi_cmdset_0003" ;
2450- static char im_name_0200 [] = "cfi_cmdset_0200" ;
2451-
2452- static int __init cfi_intelext_init (void )
2453- {
2454- inter_module_register (im_name_0001 , THIS_MODULE , & cfi_cmdset_0001 );
2455- inter_module_register (im_name_0003 , THIS_MODULE , & cfi_cmdset_0001 );
2456- inter_module_register (im_name_0200 , THIS_MODULE , & cfi_cmdset_0001 );
2457- return 0 ;
2458- }
2459-
2460- static void __exit cfi_intelext_exit (void )
2461- {
2462- inter_module_unregister (im_name_0001 );
2463- inter_module_unregister (im_name_0003 );
2464- inter_module_unregister (im_name_0200 );
2465- }
2466-
2467- module_init (cfi_intelext_init );
2468- module_exit (cfi_intelext_exit );
2469-
24702446MODULE_LICENSE ("GPL" );
24712447MODULE_AUTHOR ("David Woodhouse <dwmw2@infradead.org> et al." );
24722448MODULE_DESCRIPTION ("MTD chip driver for Intel/Sharp flash chips" );
2449+ MODULE_ALIAS ("cfi_cmdset_0003" );
2450+ MODULE_ALIAS ("cfi_cmdset_0200" );
0 commit comments