mfd: cros_ec_dev: Load lightbar module only present
authorGwendal Grignou <gwendal@chromium.org>
Wed, 26 May 2021 03:45:00 +0000 (20:45 -0700)
committerLee Jones <lee.jones@linaro.org>
Wed, 2 Jun 2021 09:51:18 +0000 (10:51 +0100)
commita75f4d1f468319d8db755d0ea2b771113356d494
treecb75adfd3c8daa3c37b810243f4399c0676ea349
parent39cdbe8d2bc61d70efa22b06b14b129ebd9d0bc5
mfd: cros_ec_dev: Load lightbar module only present

The pixel lightbar is only present on chromebook pixel (link), pixel 2
and pixel C. For the latter two, the EC reports its presence.
Instead of always loading the lightbar driver on all chromebook, only
load it when reported by the EC or Link device.

Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Acked-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Tested-by: Stephen Boyd <swboyd@chromium.org>
Reviewed-by: Stephen Boyd <swboyd@chromium.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
drivers/mfd/cros_ec_dev.c