ACPI / video: get rid of magic numbers and use enum instead
authorDmitry Frank <mail@dmitryfrank.com>
Wed, 19 Apr 2017 09:48:07 +0000 (12:48 +0300)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 19 Apr 2017 10:32:26 +0000 (12:32 +0200)
commitd485ef43072e543e81c08276999987039dfa2755
tree26f2696e68e658dc9a6039dc0c56ee36c9a47fb8
parent4f7d029b9bf009fbee76bb10c0c4351a1870d2f3
ACPI / video: get rid of magic numbers and use enum instead

The first two items in the _BCL method response are special:

  - Level when machine has full power
  - Level when machine is on batteries
  - .... actual supported levels go there ....

So this commits adds an enum and uses its descriptive elements
throughout the code, instead of magic numbers.

Signed-off-by: Dmitry Frank <mail@dmitryfrank.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/acpi_video.c