chrome ec: Add ACPI Device for ALS if enabled

Hardware / Coreboot - Duncan Laurie [chromium.org] - 9 January 2015 00:43 UTC

The EC can export ALS information if the sensor is attached to it directly rather than to the host. This adds a basic ACPI ALS device and implements the required information.

The kernel does not use the _ALR tuple set but it is required by the ACPI spec so this just adds the sample two point response curve defined in ACPI 5.0 section 9.2.5.

The EC does not currently send events for lux value changes so a polling interval of 1 second is defined.

BUG=chrome-os-partner:24208 BRANCH=None TEST=build and boot on samus, add acpi-als driver to the kernel and read /sys/bus/iio/devices/iio:device0/in_illuminance_raw

Original-Change-Id: Id29b72a68aa21c1a7c71d5f87223ac010cef0377

612163eb chrome ec: Add ACPI Device for ALS if enabled
src/ec/google/chromeec/acpi/als.asl | 70 +++++++++++++++++++++++++++++++++++
src/ec/google/chromeec/acpi/ec.asl | 4 ++
2 files changed, 74 insertions(+)

Upstream: review.coreboot.org


  • Share