Content-Type: multipart/mixed; boundary="===============1079860578425738476==" MIME-Version: 1.0 From: Krzysztof Kozlowski To: kbuild-all@lists.01.org Subject: [PATCH] extcon: Add stubs for extcon_register_notifier_all() functions Date: Thu, 31 Dec 2020 09:52:52 +0100 Message-ID: <20201231085252.69831-1-krzk@kernel.org> List-Id: --===============1079860578425738476== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Add stubs for extcon_register_notifier_all() function for !CONFIG_EXTCON case. This is useful for compile testing and for drivers which use EXTCON but do not require it (therefore do not depend on CONFIG_EXTCON). Fixes: 815429b39d94 ("extcon: Add new extcon_register_notifier_all() to mon= itor all external connectors") Reported-by: kernel test robot Signed-off-by: Krzysztof Kozlowski --- include/linux/extcon.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/include/linux/extcon.h b/include/linux/extcon.h index fd183fb9c20f..0c19010da77f 100644 --- a/include/linux/extcon.h +++ b/include/linux/extcon.h @@ -271,6 +271,29 @@ static inline void devm_extcon_unregister_notifier(st= ruct device *dev, struct extcon_dev *edev, unsigned int id, struct notifier_block *nb) { } = +static inline int extcon_register_notifier_all(struct extcon_dev *edev, + struct notifier_block *nb) +{ + return 0; +} + +static inline int extcon_unregister_notifier_all(struct extcon_dev *edev, + struct notifier_block *nb) +{ + return 0; +} + +static inline int devm_extcon_register_notifier_all(struct device *dev, + struct extcon_dev *edev, + struct notifier_block *nb) +{ + return 0; +} + +static inline void devm_extcon_unregister_notifier_all(struct device *dev, + struct extcon_dev *edev, + struct notifier_block *nb) { } + static inline struct extcon_dev *extcon_get_extcon_dev(const char *extcon_= name) { return ERR_PTR(-ENODEV); -- = 2.25.1 --===============1079860578425738476==--