Platform: OLPC: Require CONFIG_POWER_SUPPLY for XO-1.75 EC
authorLubomir Rintel <lkundrak@v3.sk>
Wed, 29 May 2019 08:34:04 +0000 (10:34 +0200)
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Wed, 12 Jun 2019 08:53:17 +0000 (11:53 +0300)
ERROR: "power_supply_put" [drivers/platform/olpc/olpc-xo175-ec.ko] undefined!
  ERROR: "power_supply_changed" [drivers/platform/olpc/olpc-xo175-ec.ko] undefined!
  ERROR: "power_supply_get_by_name" [drivers/platform/olpc/olpc-xo175-ec.ko] undefined!

Adding the dependency seems like a more reasonable thing compared to
ifdef-ing the bits, as if one has an XO-1.75 they almost certainly want
a baterry and AC adapter support.

Reported-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Lubomir Rintel <lkundrak@v3.sk>
Acked-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
drivers/platform/olpc/Kconfig

index 1fa676c5e7faf5f033772e845f4e067ec19bd1fc..6f35c01254e507a47669fbd047f279e8a7671cf9 100644 (file)
@@ -7,6 +7,7 @@ config OLPC_XO175_EC
        depends on ARCH_MMP || COMPILE_TEST
        depends on SPI_SLAVE
        depends on INPUT
+       depends on POWER_SUPPLY
        select OLPC_EC
        help
          Include support for the OLPC XO Embedded Controller (EC). The EC