Subject: [PATCH] [acpi video] Convert the "video" driver into the "video_bus" driver. - Change Makefile to create video-bus.o - Module will be video-bus.ko, and though it is a name change, it shouldn't change userspace much. It should be loaded automatically by the video.ko (video device) driver on modprobe. - Convert struct acpi_video to acpi_video_bus. - Convert names of driver and proc, sysfs, and event interfaces. Signed-off-by: Patrick Mochel --- drivers/acpi/drivers/video/Makefile | 8 ++++---- drivers/acpi/drivers/video/driver.c | 28 ++++++++++++++-------------- drivers/acpi/drivers/video/event.c | 2 +- drivers/acpi/drivers/video/proc.c | 2 +- drivers/acpi/drivers/video/sysfs.c | 2 +- drivers/acpi/drivers/video/video.h | 2 +- 6 files changed, 22 insertions(+), 22 deletions(-) applies-to: b5d1ff68951ccf91db858e54fb70b2ed92ab19b1 aa86ef3f504a677527b639ee075c6358f406b34b diff --git a/drivers/acpi/drivers/video/Makefile b/drivers/acpi/drivers/video/Makefile index 890475f..12c32af 100644 --- a/drivers/acpi/drivers/video/Makefile +++ b/drivers/acpi/drivers/video/Makefile @@ -1,7 +1,7 @@ -obj-$(CONFIG_ACPI_VIDEO) += video.o +obj-$(CONFIG_ACPI_VIDEO) += video-bus.o -video-y := driver.o device.o event.o +video-bus-y := driver.o device.o event.o -video-$(CONFIG_ACPI_DM_PROC) += proc.o -video-$(CONFIG_ACPI_DM_SYSFS) += sysfs.o +video-bus-$(CONFIG_ACPI_DM_PROC) += proc.o +video-bus-$(CONFIG_ACPI_DM_SYSFS) += sysfs.o diff --git a/drivers/acpi/drivers/video/driver.c b/drivers/acpi/drivers/video/driver.c index 10f2825..2e0202a 100644 --- a/drivers/acpi/drivers/video/driver.c +++ b/drivers/acpi/drivers/video/driver.c @@ -12,16 +12,16 @@ #include "video.h" -static int video_probe(struct acpi_dev * ad) +static int video_bus_probe(struct acpi_dev * ad) { return video_bus_test(ad); } -static int video_add(struct acpi_dev * ad) +static int video_bus_add(struct acpi_dev * ad) { - struct acpi_video * av; + struct acpi_video_bus * av; - av = kzalloc(sizeof(struct acpi_video), GFP_KERNEL); + av = kzalloc(sizeof(struct acpi_video_bus), GFP_KERNEL); if (!av) return -ENOMEM; @@ -29,14 +29,14 @@ static int video_add(struct acpi_dev * a dev_set_drvdata(&ad->dev, av); - printk(KERN_INFO PREFIX "video [%s]\n", + printk(KERN_INFO PREFIX "video bus [%s]\n", acpi_dev_bid(ad)); return 0; } -static int video_remove(struct acpi_dev * ad) +static int video_bus_remove(struct acpi_dev * ad) { - struct acpi_video * av = dev_get_drvdata(&ad->dev); + struct acpi_video_bus * av = dev_get_drvdata(&ad->dev); dev_set_drvdata(&ad->dev, NULL); kfree(av); @@ -44,14 +44,14 @@ static int video_remove(struct acpi_dev } -acpi_no_start(video); -acpi_no_stop(video); -acpi_no_shutdown(video); -acpi_no_suspend(video); -acpi_no_resume(video); +acpi_no_start(video_bus); +acpi_no_stop(video_bus); +acpi_no_shutdown(video_bus); +acpi_no_suspend(video_bus); +acpi_no_resume(video_bus); -declare_acpi_driver(video); +declare_acpi_driver(video_bus); MODULE_AUTHOR("Patrick Mochel"); -MODULE_DESCRIPTION("ACPI Video Driver"); +MODULE_DESCRIPTION("ACPI Video Bus Driver"); MODULE_LICENSE("GPL"); diff --git a/drivers/acpi/drivers/video/event.c b/drivers/acpi/drivers/video/event.c index f79efc3..84702b6 100644 --- a/drivers/acpi/drivers/video/event.c +++ b/drivers/acpi/drivers/video/event.c @@ -12,4 +12,4 @@ #include "video.h" -acpi_device_event_none(video); +acpi_device_event_none(video_bus); diff --git a/drivers/acpi/drivers/video/proc.c b/drivers/acpi/drivers/video/proc.c index c3043d6..8297c84 100644 --- a/drivers/acpi/drivers/video/proc.c +++ b/drivers/acpi/drivers/video/proc.c @@ -12,4 +12,4 @@ #include "video.h" -acpi_driver_proc_none(video); +acpi_driver_proc_none(video_bus); diff --git a/drivers/acpi/drivers/video/sysfs.c b/drivers/acpi/drivers/video/sysfs.c index 8aae719..b2d1eaf 100644 --- a/drivers/acpi/drivers/video/sysfs.c +++ b/drivers/acpi/drivers/video/sysfs.c @@ -8,4 +8,4 @@ #include "video.h" -acpi_driver_sysfs_none(video); +acpi_driver_sysfs_none(video_bus); diff --git a/drivers/acpi/drivers/video/video.h b/drivers/acpi/drivers/video/video.h index 1e1ea01..78f3a2a 100644 --- a/drivers/acpi/drivers/video/video.h +++ b/drivers/acpi/drivers/video/video.h @@ -12,7 +12,7 @@ ACPI_MODULE_NAME("acpi_video"); -struct acpi_video { +struct acpi_video_bus { struct acpi_dev * v_ad; }; --- 0.99.9.GIT