Skip to content

Commit

Permalink
ACPI video: Still use ACPI backlight control if _DOS doesn't exist
Browse files Browse the repository at this point in the history
This fixes a regression in 3.4-rc1 caused by commit
ea9f885
(ACPI video: Harden video bus adding.)

Some platforms don't have _DOS control method, but the ACPI
backlight still works.
We should not invoke _DOS for these platforms.

https://bugzilla.kernel.org/show_bug.cgi?id=43168

Cc: Igor Murzov <intergalactic.anonymous@gmail.com>
Cc: stable@vger.kernel.org
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
  • Loading branch information
Zhang Rui authored and Len Brown committed Jun 30, 2012
1 parent 76e10d1 commit b037384
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/acpi/video.c
Original file line number Diff line number Diff line change
Expand Up @@ -558,6 +558,8 @@ acpi_video_bus_DOS(struct acpi_video_bus *video, int bios_flag, int lcd_flag)
union acpi_object arg0 = { ACPI_TYPE_INTEGER };
struct acpi_object_list args = { 1, &arg0 };

if (!video->cap._DOS)
return 0;

if (bios_flag < 0 || bios_flag > 3 || lcd_flag < 0 || lcd_flag > 1)
return -EINVAL;
Expand Down

0 comments on commit b037384

Please sign in to comment.