lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Fri,  4 Dec 2020 17:52:22 +0100
From:   Arnd Bergmann <arnd@...nel.org>
To:     Support Opensource <support.opensource@...semi.com>,
        Liam Girdwood <lgirdwood@...il.com>,
        Mark Brown <broonie@...nel.org>,
        Adam Ward <Adam.Ward.opensource@...semi.com>
Cc:     Arnd Bergmann <arnd@...db.de>,
        Vincent Whitchurch <vincent.whitchurch@...s.com>,
        linux-kernel@...r.kernel.org
Subject: [PATCH] regulator: da9121: include linux/gpio/consumer.h

From: Arnd Bergmann <arnd@...db.de>

When CONFIG_GPIOLIB is disabled, the declarations from linux/gpio/consumer.h
are not visible:

drivers/regulator/da9121-regulator.c:371:14: error: implicit declaration of function 'fwnode_gpiod_get_index' [-Werror,-Wimplicit-function-declaration]
        ena_gpiod = fwnode_gpiod_get_index(of_fwnode_handle(np), "enable", 0,
                    ^
drivers/regulator/da9121-regulator.c:372:7: error: use of undeclared identifier 'GPIOD_OUT_HIGH'
                                                GPIOD_OUT_HIGH |
                                                ^
drivers/regulator/da9121-regulator.c:373:7: error: use of undeclared identifier 'GPIOD_FLAGS_BIT_NONEXCLUSIVE'
                                                GPIOD_FLAGS_BIT_NONEXCLUSIVE,

Include this explicitly to help compile testing.

Fixes: 46c413d5bb23 ("regulator: da9121: Add support for device variants via devicetree")
Signed-off-by: Arnd Bergmann <arnd@...db.de>
---
 drivers/regulator/da9121-regulator.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/regulator/da9121-regulator.c b/drivers/regulator/da9121-regulator.c
index 3ead6a171d95..22630eb0b167 100644
--- a/drivers/regulator/da9121-regulator.c
+++ b/drivers/regulator/da9121-regulator.c
@@ -15,6 +15,7 @@
 
 #include <linux/of_device.h>
 #include <linux/of_gpio.h>
+#include <linux/gpio/consumer.h>
 #include <linux/regulator/of_regulator.h>
 #include <linux/regulator/machine.h>
 #include <linux/regulator/driver.h>
-- 
2.27.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ