From 95dc112a5770dc670a1b45a3d9ee346fdd2b2697 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Mon, 20 Jun 2005 21:15:16 -0700 Subject: [PATCH] devfs: Remove devfs_mk_dir() function from the kernel tree Removes the devfs_mk_dir() function and all callers of it. Signed-off-by: Greg Kroah-Hartman --- drivers/media/dvb/dvb-core/dvbdev.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'drivers/media') diff --git a/drivers/media/dvb/dvb-core/dvbdev.c b/drivers/media/dvb/dvb-core/dvbdev.c index 134c2bbbeeb..cf78a72320e 100644 --- a/drivers/media/dvb/dvb-core/dvbdev.c +++ b/drivers/media/dvb/dvb-core/dvbdev.c @@ -302,7 +302,6 @@ int dvb_register_adapter(struct dvb_adapter *adap, const char *name, struct modu printk ("DVB: registering new adapter (%s).\n", name); - devfs_mk_dir("dvb/adapter%d", num); adap->num = num; adap->name = name; adap->module = module; @@ -410,8 +409,6 @@ static int __init init_dvbdev(void) goto error; } - devfs_mk_dir("dvb"); - dvb_class = class_create(THIS_MODULE, "dvb"); if (IS_ERR(dvb_class)) { retval = PTR_ERR(dvb_class); -- cgit v1.2.3 From 7c69ef79741910883d5543caafa06aca3ebadbd1 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Mon, 20 Jun 2005 21:15:16 -0700 Subject: [PATCH] devfs: Remove devfs_mk_cdev() function from the kernel tree Removes the devfs_mk_cdev() function and all callers of it. Signed-off-by: Greg Kroah-Hartman --- drivers/media/dvb/dvb-core/dvbdev.c | 4 ---- drivers/media/video/videodev.c | 7 ++----- 2 files changed, 2 insertions(+), 9 deletions(-) (limited to 'drivers/media') diff --git a/drivers/media/dvb/dvb-core/dvbdev.c b/drivers/media/dvb/dvb-core/dvbdev.c index cf78a72320e..8e926d98bd9 100644 --- a/drivers/media/dvb/dvb-core/dvbdev.c +++ b/drivers/media/dvb/dvb-core/dvbdev.c @@ -231,10 +231,6 @@ int dvb_register_device(struct dvb_adapter *adap, struct dvb_device **pdvbdev, mutex_unlock(&dvbdev_register_lock); - devfs_mk_cdev(MKDEV(DVB_MAJOR, nums2minor(adap->num, type, id)), - S_IFCHR | S_IRUSR | S_IWUSR, - "dvb/adapter%d/%s%d", adap->num, dnames[type], id); - class_device_create(dvb_class, NULL, MKDEV(DVB_MAJOR, nums2minor(adap->num, type, id)), adap->device, "dvb%d.%s%d", adap->num, dnames[type], id); diff --git a/drivers/media/video/videodev.c b/drivers/media/video/videodev.c index 2dfa7f23d0c..cc67ee95283 100644 --- a/drivers/media/video/videodev.c +++ b/drivers/media/video/videodev.c @@ -1563,10 +1563,6 @@ int video_register_device(struct video_device *vfd, int type, int nr) video_device[i]=vfd; vfd->minor=i; mutex_unlock(&videodev_lock); - - sprintf(vfd->devfs_name, "v4l/%s%d", name_base, i - base); - devfs_mk_cdev(MKDEV(VIDEO_MAJOR, vfd->minor), - S_IFCHR | S_IRUSR | S_IWUSR, vfd->devfs_name); mutex_init(&vfd->lock); /* sysfs class */ @@ -1575,7 +1571,8 @@ int video_register_device(struct video_device *vfd, int type, int nr) vfd->class_dev.dev = vfd->dev; vfd->class_dev.class = &video_class; vfd->class_dev.devt = MKDEV(VIDEO_MAJOR, vfd->minor); - strlcpy(vfd->class_dev.class_id, vfd->devfs_name + 4, BUS_ID_SIZE); + sprintf(vfd->devfs_name, "%s%d", name_base, i - base); + strlcpy(vfd->class_dev.class_id, vfd->devfs_name, BUS_ID_SIZE); class_device_register(&vfd->class_dev); class_device_create_file(&vfd->class_dev, &class_device_attr_name); -- cgit v1.2.3 From 8ab5e4c15b53e147c08031a959d9f776823dbe73 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Mon, 20 Jun 2005 21:15:16 -0700 Subject: [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 --- drivers/media/dvb/dvb-core/dvbdev.c | 6 ------ drivers/media/video/videodev.c | 1 - 2 files changed, 7 deletions(-) (limited to 'drivers/media') diff --git a/drivers/media/dvb/dvb-core/dvbdev.c b/drivers/media/dvb/dvb-core/dvbdev.c index 8e926d98bd9..40774feb895 100644 --- a/drivers/media/dvb/dvb-core/dvbdev.c +++ b/drivers/media/dvb/dvb-core/dvbdev.c @@ -248,9 +248,6 @@ void dvb_unregister_device(struct dvb_device *dvbdev) if (!dvbdev) return; - devfs_remove("dvb/adapter%d/%s%d", dvbdev->adapter->num, - dnames[dvbdev->type], dvbdev->id); - class_device_destroy(dvb_class, MKDEV(DVB_MAJOR, nums2minor(dvbdev->adapter->num, dvbdev->type, dvbdev->id))); @@ -314,8 +311,6 @@ EXPORT_SYMBOL(dvb_register_adapter); int dvb_unregister_adapter(struct dvb_adapter *adap) { - devfs_remove("dvb/adapter%d", adap->num); - if (mutex_lock_interruptible(&dvbdev_register_lock)) return -ERESTARTSYS; list_del (&adap->list_head); @@ -421,7 +416,6 @@ error: static void __exit exit_dvbdev(void) { - devfs_remove("dvb"); class_destroy(dvb_class); cdev_del(&dvb_device_cdev); unregister_chrdev_region(MKDEV(DVB_MAJOR, 0), MAX_DVB_MINORS); diff --git a/drivers/media/video/videodev.c b/drivers/media/video/videodev.c index cc67ee95283..3178353787d 100644 --- a/drivers/media/video/videodev.c +++ b/drivers/media/video/videodev.c @@ -1601,7 +1601,6 @@ void video_unregister_device(struct video_device *vfd) if(video_device[vfd->minor]!=vfd) panic("videodev: bad unregister"); - devfs_remove(vfd->devfs_name); video_device[vfd->minor]=NULL; class_device_unregister(&vfd->class_dev); mutex_unlock(&videodev_lock); -- cgit v1.2.3 From ff23eca3e8f613034e0d20ff86f6a89b62f5a14e Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Mon, 20 Jun 2005 21:15:16 -0700 Subject: [PATCH] devfs: Remove the devfs_fs_kernel.h file from the tree Also fixes up all files that #include it. Signed-off-by: Greg Kroah-Hartman --- drivers/media/dvb/dvb-core/dvbdev.h | 1 - drivers/media/dvb/ttpci/av7110.h | 4 ---- drivers/media/video/arv.c | 1 - drivers/media/video/videodev.c | 1 - 4 files changed, 7 deletions(-) (limited to 'drivers/media') diff --git a/drivers/media/dvb/dvb-core/dvbdev.h b/drivers/media/dvb/dvb-core/dvbdev.h index d7a976d040d..7a7f75fd168 100644 --- a/drivers/media/dvb/dvb-core/dvbdev.h +++ b/drivers/media/dvb/dvb-core/dvbdev.h @@ -27,7 +27,6 @@ #include #include #include -#include #include #define DVB_MAJOR 212 diff --git a/drivers/media/dvb/ttpci/av7110.h b/drivers/media/dvb/ttpci/av7110.h index 3e2e12124ba..9c79696da08 100644 --- a/drivers/media/dvb/ttpci/av7110.h +++ b/drivers/media/dvb/ttpci/av7110.h @@ -6,10 +6,6 @@ #include #include -#ifdef CONFIG_DEVFS_FS -#include -#endif - #include #include #include diff --git a/drivers/media/video/arv.c b/drivers/media/video/arv.c index 6e08e32346e..ae14f5f3203 100644 --- a/drivers/media/video/arv.c +++ b/drivers/media/video/arv.c @@ -20,7 +20,6 @@ #include #include -#include #include #include #include diff --git a/drivers/media/video/videodev.c b/drivers/media/video/videodev.c index 3178353787d..a802a7e0df7 100644 --- a/drivers/media/video/videodev.c +++ b/drivers/media/video/videodev.c @@ -37,7 +37,6 @@ #include #include #include -#include #include #include -- cgit v1.2.3 From 96192ff1a9d0c6ef365d21667080259d83ea2f5b Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Mon, 20 Jun 2005 21:15:16 -0700 Subject: [PATCH] devfs: Remove the miscdevice devfs_name field as it's no longer needed Also fixes all drivers that set this field. Signed-off-by: Greg Kroah-Hartman --- drivers/media/radio/miropcm20-rds.c | 1 - 1 file changed, 1 deletion(-) (limited to 'drivers/media') diff --git a/drivers/media/radio/miropcm20-rds.c b/drivers/media/radio/miropcm20-rds.c index 87b37b7691d..c1b1db65e66 100644 --- a/drivers/media/radio/miropcm20-rds.c +++ b/drivers/media/radio/miropcm20-rds.c @@ -115,7 +115,6 @@ static struct file_operations rds_fops = { static struct miscdevice rds_miscdev = { .minor = MISC_DYNAMIC_MINOR, .name = "radiotext", - .devfs_name = "v4l/rds/radiotext", .fops = &rds_fops, }; -- cgit v1.2.3 From 5e483075a1f9862a65af648d1d939499969c7b5d Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Mon, 20 Jun 2005 21:15:16 -0700 Subject: [PATCH] devfs: Remove the videodevice devfs_name field as it's no longer needed Also fixes all drivers that set this field. Signed-off-by: Greg Kroah-Hartman --- drivers/media/video/videodev.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'drivers/media') diff --git a/drivers/media/video/videodev.c b/drivers/media/video/videodev.c index a802a7e0df7..b26ebaff226 100644 --- a/drivers/media/video/videodev.c +++ b/drivers/media/video/videodev.c @@ -1570,8 +1570,7 @@ int video_register_device(struct video_device *vfd, int type, int nr) vfd->class_dev.dev = vfd->dev; vfd->class_dev.class = &video_class; vfd->class_dev.devt = MKDEV(VIDEO_MAJOR, vfd->minor); - sprintf(vfd->devfs_name, "%s%d", name_base, i - base); - strlcpy(vfd->class_dev.class_id, vfd->devfs_name, BUS_ID_SIZE); + sprintf(vfd->class_dev.class_id, "%s%d", name_base, i - base); class_device_register(&vfd->class_dev); class_device_create_file(&vfd->class_dev, &class_device_attr_name); -- cgit v1.2.3 From 890fbae2818a045350b8d1e3bda61ceb88ff1d17 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Mon, 20 Jun 2005 21:15:16 -0700 Subject: [PATCH] devfs: Last little devfs cleanups throughout the kernel tree. Just removes a few unused #defines and fixes some comments due to devfs now being gone. Signed-off-by: Greg Kroah-Hartman --- drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'drivers/media') diff --git a/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c b/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c index 14559ef6153..336b2fe1a5f 100644 --- a/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c +++ b/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c @@ -126,10 +126,6 @@ struct ttusb { int revision; -#if 0 - devfs_handle_t stc_devfs_handle; -#endif - struct dvb_frontend* fe; }; @@ -1746,13 +1742,6 @@ static int ttusb_probe(struct usb_interface *intf, const struct usb_device_id *i return -ENODEV; } -#if 0 - ttusb->stc_devfs_handle = - devfs_register(ttusb->adapter->devfs_handle, TTUSB_BUDGET_NAME, - DEVFS_FL_DEFAULT, 0, 192, - S_IFCHR | S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP - | S_IROTH | S_IWOTH, &stc_fops, ttusb); -#endif usb_set_intfdata(intf, (void *) ttusb); frontend_init(ttusb); -- cgit v1.2.3