Commit 8ab5e4c15b53e147c08031a959d9f776823dbe73
1 parent
7c69ef7974
[PATCH] devfs: Remove devfs_remove() function from the kernel tree
Removes the devfs_remove() function and all callers of it. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Showing 47 changed files with 9 additions and 161 deletions Side-by-side Diff
- arch/sparc64/solaris/socksys.c
- drivers/block/acsi_slm.c
- drivers/block/cpqarray.c
- drivers/block/floppy.c
- drivers/block/loop.c
- drivers/block/nbd.c
- drivers/block/paride/pg.c
- drivers/block/paride/pt.c
- drivers/block/rd.c
- drivers/block/sx8.c
- drivers/block/ub.c
- drivers/cdrom/sbpcd.c
- drivers/char/dsp56k.c
- drivers/char/dtlk.c
- drivers/char/ftape/zftape/zftape-init.c
- drivers/char/ip2/ip2main.c
- drivers/char/ipmi/ipmi_devintf.c
- drivers/char/istallion.c
- drivers/char/lp.c
- drivers/char/misc.c
- drivers/char/ppdev.c
- drivers/char/raw.c
- drivers/char/stallion.c
- drivers/char/tipar.c
- drivers/char/tty_io.c
- drivers/char/vc_screen.c
- drivers/char/viotape.c
- drivers/isdn/capi/capi.c
- drivers/isdn/hardware/eicon/divamnt.c
- drivers/isdn/hardware/eicon/divasi.c
- drivers/isdn/hardware/eicon/divasmain.c
- drivers/md/dm-ioctl.c
- drivers/md/md.c
- drivers/media/dvb/dvb-core/dvbdev.c
- drivers/media/video/videodev.c
- drivers/mmc/mmc_block.c
- drivers/net/ppp_generic.c
- drivers/net/wan/cosa.c
- drivers/s390/block/dasd.c
- drivers/s390/block/xpram.c
- drivers/sbus/char/bpp.c
- drivers/sbus/char/vfc_dev.c
- drivers/telephony/phonedev.c
- drivers/video/fbmem.c
- fs/coda/psdev.c
- fs/partitions/check.c
- include/linux/devfs_fs_kernel.h
arch/sparc64/solaris/socksys.c
drivers/block/acsi_slm.c
... | ... | @@ -1027,10 +1027,6 @@ |
1027 | 1027 | |
1028 | 1028 | void cleanup_module(void) |
1029 | 1029 | { |
1030 | - int i; | |
1031 | - for (i = 0; i < MAX_SLM; i++) | |
1032 | - devfs_remove("slm/%d", i); | |
1033 | - devfs_remove("slm"); | |
1034 | 1030 | if (unregister_chrdev( ACSI_MAJOR, "slm" ) != 0) |
1035 | 1031 | printk( KERN_ERR "acsi_slm: cleanup_module failed\n"); |
1036 | 1032 | atari_stram_free( SLMBuffer ); |
drivers/block/cpqarray.c
... | ... | @@ -348,7 +348,6 @@ |
348 | 348 | for(j = 0; j < NWD; j++) { |
349 | 349 | if (ida_gendisk[i][j]->flags & GENHD_FL_UP) |
350 | 350 | del_gendisk(ida_gendisk[i][j]); |
351 | - devfs_remove("ida/c%dd%d",i,j); | |
352 | 351 | put_disk(ida_gendisk[i][j]); |
353 | 352 | } |
354 | 353 | blk_cleanup_queue(hba[i]->queue); |
... | ... | @@ -1844,7 +1843,6 @@ |
1844 | 1843 | } |
1845 | 1844 | } |
1846 | 1845 | |
1847 | - devfs_remove("ida"); | |
1848 | 1846 | remove_proc_entry("cpqarray", proc_root_driver); |
1849 | 1847 | } |
1850 | 1848 |
drivers/block/floppy.c
... | ... | @@ -3952,20 +3952,6 @@ |
3952 | 3952 | .media_changed = check_floppy_change, |
3953 | 3953 | .revalidate_disk = floppy_revalidate, |
3954 | 3954 | }; |
3955 | -static char *table[] = { | |
3956 | - "", "d360", "h1200", "u360", "u720", "h360", "h720", | |
3957 | - "u1440", "u2880", "CompaQ", "h1440", "u1680", "h410", | |
3958 | - "u820", "h1476", "u1722", "h420", "u830", "h1494", "u1743", | |
3959 | - "h880", "u1040", "u1120", "h1600", "u1760", "u1920", | |
3960 | - "u3200", "u3520", "u3840", "u1840", "u800", "u1600", | |
3961 | - NULL | |
3962 | -}; | |
3963 | -static int t360[] = { 1, 0 }, | |
3964 | - t1200[] = { 2, 5, 6, 10, 12, 14, 16, 18, 20, 23, 0 }, | |
3965 | - t3in[] = { 8, 9, 26, 27, 28, 7, 11, 15, 19, 24, 25, 29, 31, 3, 4, 13, | |
3966 | - 17, 21, 22, 30, 0 }; | |
3967 | -static int *table_sup[] = | |
3968 | - { NULL, t360, t1200, t3in + 5 + 8, t3in + 5, t3in, t3in }; | |
3969 | 3955 | |
3970 | 3956 | /* |
3971 | 3957 | * Floppy Driver initialization |
... | ... | @@ -4244,7 +4230,7 @@ |
4244 | 4230 | |
4245 | 4231 | err = register_blkdev(FLOPPY_MAJOR, "fd"); |
4246 | 4232 | if (err) |
4247 | - goto out_devfs_remove; | |
4233 | + goto out_put_disk; | |
4248 | 4234 | |
4249 | 4235 | floppy_queue = blk_init_queue(do_fd_request, &floppy_lock); |
4250 | 4236 | if (!floppy_queue) { |
... | ... | @@ -4403,8 +4389,6 @@ |
4403 | 4389 | blk_cleanup_queue(floppy_queue); |
4404 | 4390 | out_unreg_blkdev: |
4405 | 4391 | unregister_blkdev(FLOPPY_MAJOR, "fd"); |
4406 | -out_devfs_remove: | |
4407 | - devfs_remove("floppy"); | |
4408 | 4392 | out_put_disk: |
4409 | 4393 | while (dr--) { |
4410 | 4394 | del_timer(&motor_off_timer[dr]); |
... | ... | @@ -4565,19 +4549,6 @@ |
4565 | 4549 | |
4566 | 4550 | static char *floppy; |
4567 | 4551 | |
4568 | -static void unregister_devfs_entries(int drive) | |
4569 | -{ | |
4570 | - int i; | |
4571 | - | |
4572 | - if (UDP->cmos < ARRAY_SIZE(default_drive_params)) { | |
4573 | - i = 0; | |
4574 | - do { | |
4575 | - devfs_remove("floppy/%d%s", drive, | |
4576 | - table[table_sup[UDP->cmos][i]]); | |
4577 | - } while (table_sup[UDP->cmos][i++]); | |
4578 | - } | |
4579 | -} | |
4580 | - | |
4581 | 4552 | static void __init parse_floppy_cfg_string(char *cfg) |
4582 | 4553 | { |
4583 | 4554 | char *ptr; |
4584 | 4555 | |
... | ... | @@ -4614,13 +4585,11 @@ |
4614 | 4585 | if ((allowed_drive_mask & (1 << drive)) && |
4615 | 4586 | fdc_state[FDC(drive)].version != FDC_NONE) { |
4616 | 4587 | del_gendisk(disks[drive]); |
4617 | - unregister_devfs_entries(drive); | |
4618 | 4588 | device_remove_file(&floppy_device[drive].dev, &dev_attr_cmos); |
4619 | 4589 | platform_device_unregister(&floppy_device[drive]); |
4620 | 4590 | } |
4621 | 4591 | put_disk(disks[drive]); |
4622 | 4592 | } |
4623 | - devfs_remove("floppy"); | |
4624 | 4593 | |
4625 | 4594 | del_timer_sync(&fd_timeout); |
4626 | 4595 | del_timer_sync(&fd_timer); |
drivers/block/loop.c
... | ... | @@ -1308,7 +1308,6 @@ |
1308 | 1308 | out_mem4: |
1309 | 1309 | while (i--) |
1310 | 1310 | blk_cleanup_queue(loop_dev[i].lo_queue); |
1311 | - devfs_remove("loop"); | |
1312 | 1311 | i = max_loop; |
1313 | 1312 | out_mem3: |
1314 | 1313 | while (i--) |
... | ... | @@ -1331,7 +1330,6 @@ |
1331 | 1330 | blk_cleanup_queue(loop_dev[i].lo_queue); |
1332 | 1331 | put_disk(disks[i]); |
1333 | 1332 | } |
1334 | - devfs_remove("loop"); | |
1335 | 1333 | if (unregister_blkdev(LOOP_MAJOR, "loop")) |
1336 | 1334 | printk(KERN_WARNING "loop: cannot unregister blkdev\n"); |
1337 | 1335 |
drivers/block/nbd.c
drivers/block/paride/pg.c
... | ... | @@ -695,13 +695,10 @@ |
695 | 695 | |
696 | 696 | for (unit = 0; unit < PG_UNITS; unit++) { |
697 | 697 | struct pg *dev = &devices[unit]; |
698 | - if (dev->present) { | |
698 | + if (dev->present) | |
699 | 699 | class_device_destroy(pg_class, MKDEV(major, unit)); |
700 | - devfs_remove("pg/%u", unit); | |
701 | - } | |
702 | 700 | } |
703 | 701 | class_destroy(pg_class); |
704 | - devfs_remove("pg"); | |
705 | 702 | unregister_chrdev(major, name); |
706 | 703 | |
707 | 704 | for (unit = 0; unit < PG_UNITS; unit++) { |
drivers/block/paride/pt.c
... | ... | @@ -992,12 +992,9 @@ |
992 | 992 | for (unit = 0; unit < PT_UNITS; unit++) |
993 | 993 | if (pt[unit].present) { |
994 | 994 | class_device_destroy(pt_class, MKDEV(major, unit)); |
995 | - devfs_remove("pt/%d", unit); | |
996 | 995 | class_device_destroy(pt_class, MKDEV(major, unit + 128)); |
997 | - devfs_remove("pt/%dn", unit); | |
998 | 996 | } |
999 | 997 | class_destroy(pt_class); |
1000 | - devfs_remove("pt"); | |
1001 | 998 | unregister_chrdev(major, name); |
1002 | 999 | for (unit = 0; unit < PT_UNITS; unit++) |
1003 | 1000 | if (pt[unit].present) |
drivers/block/rd.c
drivers/block/sx8.c
drivers/block/ub.c
... | ... | @@ -2453,7 +2453,6 @@ |
2453 | 2453 | return 0; |
2454 | 2454 | |
2455 | 2455 | err_register: |
2456 | - devfs_remove(DEVFS_NAME); | |
2457 | 2456 | unregister_blkdev(UB_MAJOR, DRV_NAME); |
2458 | 2457 | err_regblkdev: |
2459 | 2458 | return rc; |
... | ... | @@ -2463,7 +2462,6 @@ |
2463 | 2462 | { |
2464 | 2463 | usb_deregister(&ub_driver); |
2465 | 2464 | |
2466 | - devfs_remove(DEVFS_NAME); | |
2467 | 2465 | unregister_blkdev(UB_MAJOR, DRV_NAME); |
2468 | 2466 | usb_usual_clear_present(USB_US_TYPE_UB); |
2469 | 2467 | } |
drivers/cdrom/sbpcd.c
... | ... | @@ -5904,7 +5904,6 @@ |
5904 | 5904 | if (D_S[j].drv_id==-1) continue; |
5905 | 5905 | del_gendisk(D_S[j].disk); |
5906 | 5906 | put_disk(D_S[j].disk); |
5907 | - devfs_remove("sbp/c0t%d", j); | |
5908 | 5907 | vfree(D_S[j].sbp_buf); |
5909 | 5908 | if (D_S[j].sbp_audsiz>0) |
5910 | 5909 | vfree(D_S[j].aud_buf); |
... | ... | @@ -5915,7 +5914,6 @@ |
5915 | 5914 | } |
5916 | 5915 | vfree(D_S[j].sbpcd_infop); |
5917 | 5916 | } |
5918 | - devfs_remove("sbp"); | |
5919 | 5917 | msg(DBG_INF, "%s module released.\n", major_name); |
5920 | 5918 | } |
5921 | 5919 |
drivers/char/dsp56k.c
drivers/char/dtlk.c
drivers/char/ftape/zftape/zftape-init.c
... | ... | @@ -362,17 +362,11 @@ |
362 | 362 | TRACE(ft_t_info, "successful"); |
363 | 363 | } |
364 | 364 | for (i = 0; i < 4; i++) { |
365 | - devfs_remove("qft%i", i); | |
366 | 365 | class_device_destroy(zft_class, MKDEV(QIC117_TAPE_MAJOR, i)); |
367 | - devfs_remove("nqft%i", i); | |
368 | 366 | class_device_destroy(zft_class, MKDEV(QIC117_TAPE_MAJOR, i + 4)); |
369 | - devfs_remove("zqft%i", i); | |
370 | 367 | class_device_destroy(zft_class, MKDEV(QIC117_TAPE_MAJOR, i + 16)); |
371 | - devfs_remove("nzqft%i", i); | |
372 | 368 | class_device_destroy(zft_class, MKDEV(QIC117_TAPE_MAJOR, i + 20)); |
373 | - devfs_remove("rawqft%i", i); | |
374 | 369 | class_device_destroy(zft_class, MKDEV(QIC117_TAPE_MAJOR, i + 32)); |
375 | - devfs_remove("nrawqft%i", i); | |
376 | 370 | class_device_destroy(zft_class, MKDEV(QIC117_TAPE_MAJOR, i + 36)); |
377 | 371 | } |
378 | 372 | class_destroy(zft_class); |
drivers/char/ip2/ip2main.c
... | ... | @@ -414,9 +414,7 @@ |
414 | 414 | /* free io addresses and Tibet */ |
415 | 415 | release_region( ip2config.addr[i], 8 ); |
416 | 416 | class_device_destroy(ip2_class, MKDEV(IP2_IPL_MAJOR, 4 * i)); |
417 | - devfs_remove("ip2/ipl%d", i); | |
418 | 417 | class_device_destroy(ip2_class, MKDEV(IP2_IPL_MAJOR, 4 * i + 1)); |
419 | - devfs_remove("ip2/stat%d", i); | |
420 | 418 | } |
421 | 419 | /* Disable and remove interrupt handler. */ |
422 | 420 | if ( (ip2config.irq[i] > 0) && have_requested_irq(ip2config.irq[i]) ) { |
... | ... | @@ -425,7 +423,6 @@ |
425 | 423 | } |
426 | 424 | } |
427 | 425 | class_destroy(ip2_class); |
428 | - devfs_remove("ip2"); | |
429 | 426 | if ( ( err = tty_unregister_driver ( ip2_tty_driver ) ) ) { |
430 | 427 | printk(KERN_ERR "IP2: failed to unregister tty driver (%d)\n", err); |
431 | 428 | } |
drivers/char/ipmi/ipmi_devintf.c
... | ... | @@ -833,7 +833,6 @@ |
833 | 833 | } |
834 | 834 | class_device_destroy(ipmi_class, dev); |
835 | 835 | mutex_unlock(®_list_mutex); |
836 | - devfs_remove("ipmidev/%d", if_num); | |
837 | 836 | } |
838 | 837 | |
839 | 838 | static struct ipmi_smi_watcher smi_watcher = |
... | ... | @@ -893,7 +892,6 @@ |
893 | 892 | mutex_unlock(®_list_mutex); |
894 | 893 | class_destroy(ipmi_class); |
895 | 894 | ipmi_smi_watcher_unregister(&smi_watcher); |
896 | - devfs_remove(DEVICE_NAME); | |
897 | 895 | unregister_chrdev(ipmi_major, DEVICE_NAME); |
898 | 896 | } |
899 | 897 | module_exit(cleanup_ipmi); |
drivers/char/istallion.c
... | ... | @@ -849,11 +849,8 @@ |
849 | 849 | return; |
850 | 850 | } |
851 | 851 | put_tty_driver(stli_serial); |
852 | - for (i = 0; i < 4; i++) { | |
853 | - devfs_remove("staliomem/%d", i); | |
852 | + for (i = 0; i < 4; i++) | |
854 | 853 | class_device_destroy(istallion_class, MKDEV(STL_SIOMEMMAJOR, i)); |
855 | - } | |
856 | - devfs_remove("staliomem"); | |
857 | 854 | class_destroy(istallion_class); |
858 | 855 | if ((i = unregister_chrdev(STL_SIOMEMMAJOR, "staliomem"))) |
859 | 856 | printk("STALLION: failed to un-register serial memory device, " |
drivers/char/lp.c
... | ... | @@ -930,7 +930,6 @@ |
930 | 930 | out_class: |
931 | 931 | class_destroy(lp_class); |
932 | 932 | out_devfs: |
933 | - devfs_remove("printers"); | |
934 | 933 | unregister_chrdev(LP_MAJOR, "lp"); |
935 | 934 | return err; |
936 | 935 | } |
937 | 936 | |
... | ... | @@ -978,10 +977,8 @@ |
978 | 977 | if (lp_table[offset].dev == NULL) |
979 | 978 | continue; |
980 | 979 | parport_unregister_device(lp_table[offset].dev); |
981 | - devfs_remove("printers/%d", offset); | |
982 | 980 | class_device_destroy(lp_class, MKDEV(LP_MAJOR, offset)); |
983 | 981 | } |
984 | - devfs_remove("printers"); | |
985 | 982 | class_destroy(lp_class); |
986 | 983 | } |
987 | 984 |
drivers/char/misc.c
... | ... | @@ -271,7 +271,6 @@ |
271 | 271 | down(&misc_sem); |
272 | 272 | list_del(&misc->list); |
273 | 273 | class_device_destroy(misc_class, MKDEV(MISC_MAJOR, misc->minor)); |
274 | - devfs_remove(misc->devfs_name); | |
275 | 274 | if (i < DYNAMIC_MINORS && i>0) { |
276 | 275 | misc_minors[i>>3] &= ~(1 << (misc->minor & 7)); |
277 | 276 | } |
drivers/char/ppdev.c
... | ... | @@ -770,7 +770,7 @@ |
770 | 770 | |
771 | 771 | static int __init ppdev_init (void) |
772 | 772 | { |
773 | - int i, err = 0; | |
773 | + int err = 0; | |
774 | 774 | |
775 | 775 | if (register_chrdev (PP_MAJOR, CHRDEV, &pp_fops)) { |
776 | 776 | printk (KERN_WARNING CHRDEV ": unable to get major %d\n", |
... | ... | @@ -791,9 +791,6 @@ |
791 | 791 | goto out; |
792 | 792 | |
793 | 793 | out_class: |
794 | - for (i = 0; i < PARPORT_MAX; i++) | |
795 | - devfs_remove("parports/%d", i); | |
796 | - devfs_remove("parports"); | |
797 | 794 | class_destroy(ppdev_class); |
798 | 795 | out_chrdev: |
799 | 796 | unregister_chrdev(PP_MAJOR, CHRDEV); |
800 | 797 | |
801 | 798 | |
... | ... | @@ -803,12 +800,8 @@ |
803 | 800 | |
804 | 801 | static void __exit ppdev_cleanup (void) |
805 | 802 | { |
806 | - int i; | |
807 | 803 | /* Clean up all parport stuff */ |
808 | - for (i = 0; i < PARPORT_MAX; i++) | |
809 | - devfs_remove("parports/%d", i); | |
810 | 804 | parport_unregister_driver(&pp_driver); |
811 | - devfs_remove("parports"); | |
812 | 805 | class_destroy(ppdev_class); |
813 | 806 | unregister_chrdev (PP_MAJOR, CHRDEV); |
814 | 807 | } |
drivers/char/raw.c
... | ... | @@ -318,12 +318,6 @@ |
318 | 318 | |
319 | 319 | static void __exit raw_exit(void) |
320 | 320 | { |
321 | - int i; | |
322 | - | |
323 | - for (i = 1; i < MAX_RAW_MINORS; i++) | |
324 | - devfs_remove("raw/raw%d", i); | |
325 | - devfs_remove("raw/rawctl"); | |
326 | - devfs_remove("raw"); | |
327 | 321 | class_device_destroy(raw_class, MKDEV(RAW_MAJOR, 0)); |
328 | 322 | class_destroy(raw_class); |
329 | 323 | cdev_del(&raw_cdev); |
drivers/char/stallion.c
... | ... | @@ -773,11 +773,8 @@ |
773 | 773 | restore_flags(flags); |
774 | 774 | return; |
775 | 775 | } |
776 | - for (i = 0; i < 4; i++) { | |
777 | - devfs_remove("staliomem/%d", i); | |
776 | + for (i = 0; i < 4; i++) | |
778 | 777 | class_device_destroy(stallion_class, MKDEV(STL_SIOMEMMAJOR, i)); |
779 | - } | |
780 | - devfs_remove("staliomem"); | |
781 | 778 | if ((i = unregister_chrdev(STL_SIOMEMMAJOR, "staliomem"))) |
782 | 779 | printk("STALLION: failed to un-register serial memory device, " |
783 | 780 | "errno=%d\n", -i); |
drivers/char/tipar.c
... | ... | @@ -515,7 +515,6 @@ |
515 | 515 | class_destroy(tipar_class); |
516 | 516 | |
517 | 517 | out_chrdev: |
518 | - devfs_remove("ticables/par"); | |
519 | 518 | unregister_chrdev(TIPAR_MAJOR, "tipar"); |
520 | 519 | out: |
521 | 520 | return err; |
522 | 521 | |
... | ... | @@ -536,10 +535,8 @@ |
536 | 535 | continue; |
537 | 536 | parport_unregister_device(table[i].dev); |
538 | 537 | class_device_destroy(tipar_class, MKDEV(TIPAR_MAJOR, i)); |
539 | - devfs_remove("ticables/par/%d", i); | |
540 | 538 | } |
541 | 539 | class_destroy(tipar_class); |
542 | - devfs_remove("ticables/par"); | |
543 | 540 | |
544 | 541 | pr_info("tipar: module unloaded\n"); |
545 | 542 | } |
drivers/char/tty_io.c
... | ... | @@ -2997,7 +2997,6 @@ |
2997 | 2997 | */ |
2998 | 2998 | void tty_unregister_device(struct tty_driver *driver, unsigned index) |
2999 | 2999 | { |
3000 | - devfs_remove("%s%d", driver->devfs_name, index + driver->name_base); | |
3001 | 3000 | class_device_destroy(tty_class, MKDEV(driver->major, driver->minor_start) + index); |
3002 | 3001 | } |
3003 | 3002 |
drivers/char/vc_screen.c
... | ... | @@ -485,8 +485,6 @@ |
485 | 485 | } |
486 | 486 | void vcs_remove_devfs(struct tty_struct *tty) |
487 | 487 | { |
488 | - devfs_remove("vcc/%u", tty->index + 1); | |
489 | - devfs_remove("vcc/a%u", tty->index + 1); | |
490 | 488 | class_device_destroy(vc_class, MKDEV(VCS_MAJOR, tty->index + 1)); |
491 | 489 | class_device_destroy(vc_class, MKDEV(VCS_MAJOR, tty->index + 129)); |
492 | 490 | } |
drivers/char/viotape.c
... | ... | @@ -970,8 +970,6 @@ |
970 | 970 | { |
971 | 971 | int i = vdev->unit_address; |
972 | 972 | |
973 | - devfs_remove("iseries/nvt%d", i); | |
974 | - devfs_remove("iseries/vt%d", i); | |
975 | 973 | class_device_destroy(tape_class, MKDEV(VIOTAPE_MAJOR, i | 0x80)); |
976 | 974 | class_device_destroy(tape_class, MKDEV(VIOTAPE_MAJOR, i)); |
977 | 975 | return 0; |
drivers/isdn/capi/capi.c
... | ... | @@ -1550,7 +1550,6 @@ |
1550 | 1550 | class_device_destroy(capi_class, MKDEV(capi_major, 0)); |
1551 | 1551 | class_destroy(capi_class); |
1552 | 1552 | unregister_chrdev(capi_major, "capi20"); |
1553 | - devfs_remove("isdn/capi20"); | |
1554 | 1553 | |
1555 | 1554 | #ifdef CONFIG_ISDN_CAPI_MIDDLEWARE |
1556 | 1555 | capinc_tty_exit(); |
drivers/isdn/hardware/eicon/divamnt.c
drivers/isdn/hardware/eicon/divasi.c
drivers/isdn/hardware/eicon/divasmain.c
drivers/md/dm-ioctl.c
... | ... | @@ -74,7 +74,6 @@ |
74 | 74 | static void dm_hash_exit(void) |
75 | 75 | { |
76 | 76 | dm_hash_remove_all(0); |
77 | - devfs_remove(DM_DIR); | |
78 | 77 | } |
79 | 78 | |
80 | 79 | /*----------------------------------------------------------------- |
... | ... | @@ -171,15 +170,6 @@ |
171 | 170 | } |
172 | 171 | |
173 | 172 | /* |
174 | - * devfs stuff. | |
175 | - */ | |
176 | -static int unregister_with_devfs(struct hash_cell *hc) | |
177 | -{ | |
178 | - devfs_remove(DM_DIR"/%s", hc->name); | |
179 | - return 0; | |
180 | -} | |
181 | - | |
182 | -/* | |
183 | 173 | * The kdev_t and uuid of a device can never change once it is |
184 | 174 | * initially inserted. |
185 | 175 | */ |
... | ... | @@ -234,7 +224,6 @@ |
234 | 224 | /* remove from the dev hash */ |
235 | 225 | list_del(&hc->uuid_list); |
236 | 226 | list_del(&hc->name_list); |
237 | - unregister_with_devfs(hc); | |
238 | 227 | dm_set_mdptr(hc->md, NULL); |
239 | 228 | |
240 | 229 | table = dm_get_table(hc->md); |
... | ... | @@ -330,8 +319,6 @@ |
330 | 319 | /* |
331 | 320 | * rename and move the name cell. |
332 | 321 | */ |
333 | - unregister_with_devfs(hc); | |
334 | - | |
335 | 322 | list_del(&hc->name_list); |
336 | 323 | old_name = hc->name; |
337 | 324 | hc->name = new_name; |
drivers/md/md.c
... | ... | @@ -5611,15 +5611,9 @@ |
5611 | 5611 | { |
5612 | 5612 | mddev_t *mddev; |
5613 | 5613 | struct list_head *tmp; |
5614 | - int i; | |
5614 | + | |
5615 | 5615 | blk_unregister_region(MKDEV(MAJOR_NR,0), MAX_MD_DEVS); |
5616 | 5616 | blk_unregister_region(MKDEV(mdp_major,0), MAX_MD_DEVS << MdpMinorShift); |
5617 | - for (i=0; i < MAX_MD_DEVS; i++) | |
5618 | - devfs_remove("md/%d", i); | |
5619 | - for (i=0; i < MAX_MD_DEVS; i++) | |
5620 | - devfs_remove("md/d%d", i); | |
5621 | - | |
5622 | - devfs_remove("md"); | |
5623 | 5617 | |
5624 | 5618 | unregister_blkdev(MAJOR_NR,"md"); |
5625 | 5619 | unregister_blkdev(mdp_major, "mdp"); |
drivers/media/dvb/dvb-core/dvbdev.c
... | ... | @@ -248,9 +248,6 @@ |
248 | 248 | if (!dvbdev) |
249 | 249 | return; |
250 | 250 | |
251 | - devfs_remove("dvb/adapter%d/%s%d", dvbdev->adapter->num, | |
252 | - dnames[dvbdev->type], dvbdev->id); | |
253 | - | |
254 | 251 | class_device_destroy(dvb_class, MKDEV(DVB_MAJOR, nums2minor(dvbdev->adapter->num, |
255 | 252 | dvbdev->type, dvbdev->id))); |
256 | 253 | |
... | ... | @@ -314,8 +311,6 @@ |
314 | 311 | |
315 | 312 | int dvb_unregister_adapter(struct dvb_adapter *adap) |
316 | 313 | { |
317 | - devfs_remove("dvb/adapter%d", adap->num); | |
318 | - | |
319 | 314 | if (mutex_lock_interruptible(&dvbdev_register_lock)) |
320 | 315 | return -ERESTARTSYS; |
321 | 316 | list_del (&adap->list_head); |
... | ... | @@ -421,7 +416,6 @@ |
421 | 416 | |
422 | 417 | static void __exit exit_dvbdev(void) |
423 | 418 | { |
424 | - devfs_remove("dvb"); | |
425 | 419 | class_destroy(dvb_class); |
426 | 420 | cdev_del(&dvb_device_cdev); |
427 | 421 | unregister_chrdev_region(MKDEV(DVB_MAJOR, 0), MAX_DVB_MINORS); |
drivers/media/video/videodev.c
drivers/mmc/mmc_block.c
drivers/net/ppp_generic.c
... | ... | @@ -2674,7 +2674,6 @@ |
2674 | 2674 | cardmap_destroy(&all_ppp_units); |
2675 | 2675 | if (unregister_chrdev(PPP_MAJOR, "ppp") != 0) |
2676 | 2676 | printk(KERN_ERR "PPP: failed to unregister PPP device\n"); |
2677 | - devfs_remove("ppp"); | |
2678 | 2677 | class_device_destroy(ppp_class, MKDEV(PPP_MAJOR, 0)); |
2679 | 2678 | class_destroy(ppp_class); |
2680 | 2679 | } |
drivers/net/wan/cosa.c
... | ... | @@ -418,12 +418,9 @@ |
418 | 418 | int i; |
419 | 419 | printk(KERN_INFO "Unloading the cosa module\n"); |
420 | 420 | |
421 | - for (i=0; i<nr_cards; i++) { | |
421 | + for (i=0; i<nr_cards; i++) | |
422 | 422 | class_device_destroy(cosa_class, MKDEV(cosa_major, i)); |
423 | - devfs_remove("cosa/%d", i); | |
424 | - } | |
425 | 423 | class_destroy(cosa_class); |
426 | - devfs_remove("cosa"); | |
427 | 424 | for (cosa=cosa_cards; nr_cards--; cosa++) { |
428 | 425 | /* Clean up the per-channel data */ |
429 | 426 | for (i=0; i<cosa->nchannels; i++) { |
drivers/s390/block/dasd.c
drivers/s390/block/xpram.c
... | ... | @@ -474,7 +474,6 @@ |
474 | 474 | |
475 | 475 | return 0; |
476 | 476 | out_unreg: |
477 | - devfs_remove("slram"); | |
478 | 477 | unregister_blkdev(XPRAM_MAJOR, XPRAM_NAME); |
479 | 478 | out: |
480 | 479 | while (i--) |
... | ... | @@ -493,7 +492,6 @@ |
493 | 492 | put_disk(xpram_disks[i]); |
494 | 493 | } |
495 | 494 | unregister_blkdev(XPRAM_MAJOR, XPRAM_NAME); |
496 | - devfs_remove("slram"); | |
497 | 495 | blk_cleanup_queue(xpram_queue); |
498 | 496 | sysdev_unregister(&xpram_sys_device); |
499 | 497 | sysdev_class_unregister(&xpram_sysclass); |
drivers/sbus/char/bpp.c
drivers/sbus/char/vfc_dev.c
... | ... | @@ -712,7 +712,6 @@ |
712 | 712 | { |
713 | 713 | if(dev == NULL) |
714 | 714 | return; |
715 | - devfs_remove("vfc/%d", dev->instance); | |
716 | 715 | sbus_iounmap(dev->regs, sizeof(struct vfc_regs)); |
717 | 716 | kfree(dev); |
718 | 717 | } |
... | ... | @@ -726,7 +725,6 @@ |
726 | 725 | for (devp = vfc_dev_lst; *devp; devp++) |
727 | 726 | deinit_vfc_device(*devp); |
728 | 727 | |
729 | - devfs_remove("vfc"); | |
730 | 728 | kfree(vfc_dev_lst); |
731 | 729 | return; |
732 | 730 | } |
drivers/telephony/phonedev.c
drivers/video/fbmem.c
fs/coda/psdev.c
... | ... | @@ -409,12 +409,9 @@ |
409 | 409 | } |
410 | 410 | return 0; |
411 | 411 | out: |
412 | - for (i = 0; i < MAX_CODADEVS; i++) { | |
412 | + for (i = 0; i < MAX_CODADEVS; i++) | |
413 | 413 | class_device_destroy(coda_psdev_class, MKDEV(CODA_PSDEV_MAJOR, i)); |
414 | - devfs_remove("coda/%d", i); | |
415 | - } | |
416 | 414 | class_destroy(coda_psdev_class); |
417 | - devfs_remove("coda"); | |
418 | 415 | unregister_chrdev(CODA_PSDEV_MAJOR, "coda"); |
419 | 416 | coda_sysctl_clean(); |
420 | 417 | out1: |
421 | 418 | |
422 | 419 | |
... | ... | @@ -431,12 +428,9 @@ |
431 | 428 | if ( err != 0 ) { |
432 | 429 | printk("coda: failed to unregister filesystem\n"); |
433 | 430 | } |
434 | - for (i = 0; i < MAX_CODADEVS; i++) { | |
431 | + for (i = 0; i < MAX_CODADEVS; i++) | |
435 | 432 | class_device_destroy(coda_psdev_class, MKDEV(CODA_PSDEV_MAJOR, i)); |
436 | - devfs_remove("coda/%d", i); | |
437 | - } | |
438 | 433 | class_destroy(coda_psdev_class); |
439 | - devfs_remove("coda"); | |
440 | 434 | unregister_chrdev(CODA_PSDEV_MAJOR, "coda"); |
441 | 435 | coda_sysctl_clean(); |
442 | 436 | coda_destroy_inodecache(); |
fs/partitions/check.c
... | ... | @@ -320,7 +320,6 @@ |
320 | 320 | p->nr_sects = 0; |
321 | 321 | p->ios[0] = p->ios[1] = 0; |
322 | 322 | p->sectors[0] = p->sectors[1] = 0; |
323 | - devfs_remove("%s/part%d", disk->devfs_name, part); | |
324 | 323 | sysfs_remove_link(&p->kobj, "subsystem"); |
325 | 324 | if (p->holder_dir) |
326 | 325 | kobject_unregister(p->holder_dir); |