Skip to content

Commit

Permalink
ACPI: video - fit input device into sysfs tree
Browse files Browse the repository at this point in the history
Properly set up parent on input device registered by the video driver.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Acked-by: Zhang Rui <rui.zhang@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
  • Loading branch information
Dmitry Torokhov authored and Len Brown committed Nov 14, 2007
1 parent 9418d5d commit 91c05c6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/acpi/video.c
Original file line number Diff line number Diff line change
Expand Up @@ -1961,6 +1961,7 @@ static int acpi_video_bus_add(struct acpi_device *device)
input->phys = video->phys;
input->id.bustype = BUS_HOST;
input->id.product = 0x06;
input->dev.parent = &device->dev;
input->evbit[0] = BIT(EV_KEY);
set_bit(KEY_SWITCHVIDEOMODE, input->keybit);
set_bit(KEY_VIDEO_NEXT, input->keybit);
Expand Down Expand Up @@ -1990,7 +1991,7 @@ static int acpi_video_bus_add(struct acpi_device *device)
video->flags.rom ? "yes" : "no",
video->flags.post ? "yes" : "no");

end:
end:
if (result)
kfree(video);

Expand Down

0 comments on commit 91c05c6

Please sign in to comment.