Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

isdn: replace ->proc_fops with ->proc_show

And switch to proc_create_single_data.

Signed-off-by: Christoph Hellwig <hch@lst.de>

+20 -110
+2 -1
drivers/isdn/capi/kcapi.c
··· 534 534 init_waitqueue_head(&ctr->state_wait_queue); 535 535 536 536 sprintf(ctr->procfn, "capi/controllers/%d", ctr->cnr); 537 - ctr->procent = proc_create_data(ctr->procfn, 0, NULL, ctr->proc_fops, ctr); 537 + ctr->procent = proc_create_single_data(ctr->procfn, 0, NULL, 538 + ctr->proc_show, ctr); 538 539 539 540 ncontrollers++; 540 541
+1 -15
drivers/isdn/gigaset/capi.c
··· 2437 2437 return 0; 2438 2438 } 2439 2439 2440 - static int gigaset_proc_open(struct inode *inode, struct file *file) 2441 - { 2442 - return single_open(file, gigaset_proc_show, PDE_DATA(inode)); 2443 - } 2444 - 2445 - static const struct file_operations gigaset_proc_fops = { 2446 - .owner = THIS_MODULE, 2447 - .open = gigaset_proc_open, 2448 - .read = seq_read, 2449 - .llseek = seq_lseek, 2450 - .release = single_release, 2451 - }; 2452 - 2453 2440 /** 2454 2441 * gigaset_isdn_regdev() - register device to LL 2455 2442 * @cs: device descriptor structure. ··· 2465 2478 iif->ctr.register_appl = gigaset_register_appl; 2466 2479 iif->ctr.release_appl = gigaset_release_appl; 2467 2480 iif->ctr.send_message = gigaset_send_message; 2468 - iif->ctr.procinfo = gigaset_procinfo; 2469 - iif->ctr.proc_fops = &gigaset_proc_fops; 2481 + iif->ctr.proc_show = gigaset_proc_show, 2470 2482 INIT_LIST_HEAD(&iif->appls); 2471 2483 skb_queue_head_init(&iif->sendqueue); 2472 2484 atomic_set(&iif->sendqlen, 0);
+2 -2
drivers/isdn/hardware/avm/avmcard.h
··· 556 556 void b1_parse_version(avmctrl_info *card); 557 557 irqreturn_t b1_interrupt(int interrupt, void *devptr); 558 558 559 - extern const struct file_operations b1ctl_proc_fops; 559 + int b1_proc_show(struct seq_file *m, void *v); 560 560 561 561 avmcard_dmainfo *avmcard_dma_alloc(char *name, struct pci_dev *, 562 562 long rsize, long ssize); ··· 576 576 capi_register_params *rp); 577 577 void b1dma_release_appl(struct capi_ctr *ctrl, u16 appl); 578 578 u16 b1dma_send_message(struct capi_ctr *ctrl, struct sk_buff *skb); 579 - extern const struct file_operations b1dmactl_proc_fops; 579 + int b1dma_proc_show(struct seq_file *m, void *v); 580 580 581 581 #endif /* _AVMCARD_H_ */
+2 -15
drivers/isdn/hardware/avm/b1.c
··· 637 637 } 638 638 639 639 /* ------------------------------------------------------------- */ 640 - static int b1ctl_proc_show(struct seq_file *m, void *v) 640 + int b1_proc_show(struct seq_file *m, void *v) 641 641 { 642 642 struct capi_ctr *ctrl = m->private; 643 643 avmctrl_info *cinfo = (avmctrl_info *)(ctrl->driverdata); ··· 699 699 700 700 return 0; 701 701 } 702 - 703 - static int b1ctl_proc_open(struct inode *inode, struct file *file) 704 - { 705 - return single_open(file, b1ctl_proc_show, PDE_DATA(inode)); 706 - } 707 - 708 - const struct file_operations b1ctl_proc_fops = { 709 - .owner = THIS_MODULE, 710 - .open = b1ctl_proc_open, 711 - .read = seq_read, 712 - .llseek = seq_lseek, 713 - .release = single_release, 714 - }; 715 - EXPORT_SYMBOL(b1ctl_proc_fops); 702 + EXPORT_SYMBOL(b1_proc_show); 716 703 717 704 /* ------------------------------------------------------------- */ 718 705
+2 -15
drivers/isdn/hardware/avm/b1dma.c
··· 858 858 859 859 /* ------------------------------------------------------------- */ 860 860 861 - static int b1dmactl_proc_show(struct seq_file *m, void *v) 861 + int b1dma_proc_show(struct seq_file *m, void *v) 862 862 { 863 863 struct capi_ctr *ctrl = m->private; 864 864 avmctrl_info *cinfo = (avmctrl_info *)(ctrl->driverdata); ··· 941 941 942 942 return 0; 943 943 } 944 - 945 - static int b1dmactl_proc_open(struct inode *inode, struct file *file) 946 - { 947 - return single_open(file, b1dmactl_proc_show, PDE_DATA(inode)); 948 - } 949 - 950 - const struct file_operations b1dmactl_proc_fops = { 951 - .owner = THIS_MODULE, 952 - .open = b1dmactl_proc_open, 953 - .read = seq_read, 954 - .llseek = seq_lseek, 955 - .release = single_release, 956 - }; 957 - EXPORT_SYMBOL(b1dmactl_proc_fops); 944 + EXPORT_SYMBOL(b1dma_proc_show); 958 945 959 946 /* ------------------------------------------------------------- */ 960 947
+1 -1
drivers/isdn/hardware/avm/b1isa.c
··· 121 121 cinfo->capi_ctrl.load_firmware = b1_load_firmware; 122 122 cinfo->capi_ctrl.reset_ctr = b1_reset_ctr; 123 123 cinfo->capi_ctrl.procinfo = b1isa_procinfo; 124 - cinfo->capi_ctrl.proc_fops = &b1ctl_proc_fops; 124 + cinfo->capi_ctrl.proc_show = b1_proc_show; 125 125 strcpy(cinfo->capi_ctrl.name, card->name); 126 126 127 127 retval = attach_capi_ctr(&cinfo->capi_ctrl);
+2 -2
drivers/isdn/hardware/avm/b1pci.c
··· 112 112 cinfo->capi_ctrl.load_firmware = b1_load_firmware; 113 113 cinfo->capi_ctrl.reset_ctr = b1_reset_ctr; 114 114 cinfo->capi_ctrl.procinfo = b1pci_procinfo; 115 - cinfo->capi_ctrl.proc_fops = &b1ctl_proc_fops; 115 + cinfo->capi_ctrl.proc_show = b1_proc_show; 116 116 strcpy(cinfo->capi_ctrl.name, card->name); 117 117 cinfo->capi_ctrl.owner = THIS_MODULE; 118 118 ··· 251 251 cinfo->capi_ctrl.load_firmware = b1dma_load_firmware; 252 252 cinfo->capi_ctrl.reset_ctr = b1dma_reset_ctr; 253 253 cinfo->capi_ctrl.procinfo = b1pciv4_procinfo; 254 - cinfo->capi_ctrl.proc_fops = &b1dmactl_proc_fops; 254 + cinfo->capi_ctrl.proc_show = b1dma_proc_show; 255 255 strcpy(cinfo->capi_ctrl.name, card->name); 256 256 257 257 retval = attach_capi_ctr(&cinfo->capi_ctrl);
+1 -1
drivers/isdn/hardware/avm/b1pcmcia.c
··· 108 108 cinfo->capi_ctrl.load_firmware = b1_load_firmware; 109 109 cinfo->capi_ctrl.reset_ctr = b1_reset_ctr; 110 110 cinfo->capi_ctrl.procinfo = b1pcmcia_procinfo; 111 - cinfo->capi_ctrl.proc_fops = &b1ctl_proc_fops; 111 + cinfo->capi_ctrl.proc_show = b1_proc_show; 112 112 strcpy(cinfo->capi_ctrl.name, card->name); 113 113 114 114 retval = attach_capi_ctr(&cinfo->capi_ctrl);
+1 -14
drivers/isdn/hardware/avm/c4.c
··· 1127 1127 return 0; 1128 1128 } 1129 1129 1130 - static int c4_proc_open(struct inode *inode, struct file *file) 1131 - { 1132 - return single_open(file, c4_proc_show, PDE_DATA(inode)); 1133 - } 1134 - 1135 - static const struct file_operations c4_proc_fops = { 1136 - .owner = THIS_MODULE, 1137 - .open = c4_proc_open, 1138 - .read = seq_read, 1139 - .llseek = seq_lseek, 1140 - .release = single_release, 1141 - }; 1142 - 1143 1130 /* ------------------------------------------------------------- */ 1144 1131 1145 1132 static int c4_add_card(struct capicardparams *p, struct pci_dev *dev, ··· 1198 1211 cinfo->capi_ctrl.load_firmware = c4_load_firmware; 1199 1212 cinfo->capi_ctrl.reset_ctr = c4_reset_ctr; 1200 1213 cinfo->capi_ctrl.procinfo = c4_procinfo; 1201 - cinfo->capi_ctrl.proc_fops = &c4_proc_fops; 1214 + cinfo->capi_ctrl.proc_show = c4_proc_show; 1202 1215 strcpy(cinfo->capi_ctrl.name, card->name); 1203 1216 1204 1217 retval = attach_capi_ctr(&cinfo->capi_ctrl);
+1 -1
drivers/isdn/hardware/avm/t1isa.c
··· 430 430 cinfo->capi_ctrl.load_firmware = t1isa_load_firmware; 431 431 cinfo->capi_ctrl.reset_ctr = t1isa_reset_ctr; 432 432 cinfo->capi_ctrl.procinfo = t1isa_procinfo; 433 - cinfo->capi_ctrl.proc_fops = &b1ctl_proc_fops; 433 + cinfo->capi_ctrl.proc_show = b1_proc_show; 434 434 strcpy(cinfo->capi_ctrl.name, card->name); 435 435 436 436 retval = attach_capi_ctr(&cinfo->capi_ctrl);
+1 -1
drivers/isdn/hardware/avm/t1pci.c
··· 119 119 cinfo->capi_ctrl.load_firmware = b1dma_load_firmware; 120 120 cinfo->capi_ctrl.reset_ctr = b1dma_reset_ctr; 121 121 cinfo->capi_ctrl.procinfo = t1pci_procinfo; 122 - cinfo->capi_ctrl.proc_fops = &b1dmactl_proc_fops; 122 + cinfo->capi_ctrl.proc_show = b1dma_proc_show; 123 123 strcpy(cinfo->capi_ctrl.name, card->name); 124 124 125 125 retval = attach_capi_ctr(&cinfo->capi_ctrl);
+1 -14
drivers/isdn/hardware/eicon/capimain.c
··· 90 90 return 0; 91 91 } 92 92 93 - static int diva_ctl_proc_open(struct inode *inode, struct file *file) 94 - { 95 - return single_open(file, diva_ctl_proc_show, NULL); 96 - } 97 - 98 - static const struct file_operations diva_ctl_proc_fops = { 99 - .owner = THIS_MODULE, 100 - .open = diva_ctl_proc_open, 101 - .read = seq_read, 102 - .llseek = seq_lseek, 103 - .release = single_release, 104 - }; 105 - 106 93 /* 107 94 * set additional os settings in capi_ctr struct 108 95 */ ··· 98 111 ctrl->driver_name = DRIVERLNAME; 99 112 ctrl->load_firmware = NULL; 100 113 ctrl->reset_ctr = NULL; 101 - ctrl->proc_fops = &diva_ctl_proc_fops; 114 + ctrl->proc_show = diva_ctl_proc_show; 102 115 ctrl->owner = THIS_MODULE; 103 116 } 104 117
+1 -14
drivers/isdn/hysdn/hycapi.c
··· 467 467 return 0; 468 468 } 469 469 470 - static int hycapi_proc_open(struct inode *inode, struct file *file) 471 - { 472 - return single_open(file, hycapi_proc_show, PDE_DATA(inode)); 473 - } 474 - 475 - static const struct file_operations hycapi_proc_fops = { 476 - .owner = THIS_MODULE, 477 - .open = hycapi_proc_open, 478 - .read = seq_read, 479 - .llseek = seq_lseek, 480 - .release = single_release, 481 - }; 482 - 483 470 /************************************************************** 484 471 hycapi_load_firmware 485 472 ··· 761 774 ctrl->load_firmware = hycapi_load_firmware; 762 775 ctrl->reset_ctr = hycapi_reset_ctr; 763 776 ctrl->procinfo = hycapi_procinfo; 764 - ctrl->proc_fops = &hycapi_proc_fops; 777 + ctrl->proc_show = hycapi_proc_show; 765 778 strcpy(ctrl->name, cinfo->cardname); 766 779 ctrl->owner = THIS_MODULE; 767 780
+1 -1
include/linux/isdn/capilli.h
··· 50 50 u16 (*send_message)(struct capi_ctr *, struct sk_buff *skb); 51 51 52 52 char *(*procinfo)(struct capi_ctr *); 53 - const struct file_operations *proc_fops; 53 + int (*proc_show)(struct seq_file *, void *); 54 54 55 55 /* filled in before calling ready callback */ 56 56 u8 manu[CAPI_MANUFACTURER_LEN]; /* CAPI_GET_MANUFACTURER */
+1 -13
net/bluetooth/cmtp/capi.c
··· 521 521 return 0; 522 522 } 523 523 524 - static int cmtp_proc_open(struct inode *inode, struct file *file) 525 - { 526 - return single_open(file, cmtp_proc_show, PDE_DATA(inode)); 527 - } 528 - 529 - static const struct file_operations cmtp_proc_fops = { 530 - .open = cmtp_proc_open, 531 - .read = seq_read, 532 - .llseek = seq_lseek, 533 - .release = single_release, 534 - }; 535 - 536 524 int cmtp_attach_device(struct cmtp_session *session) 537 525 { 538 526 unsigned char buf[4]; ··· 559 571 session->ctrl.send_message = cmtp_send_message; 560 572 561 573 session->ctrl.procinfo = cmtp_procinfo; 562 - session->ctrl.proc_fops = &cmtp_proc_fops; 574 + session->ctrl.proc_show = cmtp_proc_show; 563 575 564 576 if (attach_capi_ctr(&session->ctrl) < 0) { 565 577 BT_ERR("Can't attach new controller");