summaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorAhmad Fatoum <ahmad@a3f.at>2020-02-20 10:33:27 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2020-03-03 08:32:11 +0100
commitc14498420db89723049c494e6e89b414acd75f76 (patch)
tree643b0857e81a28b6ab647e0d72be6f1c1e5e766d /include/linux
parentccdd25a65393cbaf985ae6120a7d23897be325b3 (diff)
downloadbarebox-c14498420db89723049c494e6e89b414acd75f76.tar.gz
barebox-c14498420db89723049c494e6e89b414acd75f76.tar.xz
reset: add stub for device_reset when CONFIG_RESET_CONTROLLER=n
Users of an optional device_reset that have CONFIG_RESET_CONTROLLER=n will trigger compilation errors. Add a static inline stub to fix it. [ Note: device_reset is unused and unusable because we have no reset controller implementing .reset. It's available in Linux though and apparently useful for shared resets, so it's left in ] Signed-off-by: Ahmad Fatoum <ahmad@a3f.at> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/reset.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/reset.h b/include/linux/reset.h
index a22bcf9a5d..4a92a177bc 100644
--- a/include/linux/reset.h
+++ b/include/linux/reset.h
@@ -55,6 +55,12 @@ static inline int device_reset_us(struct device_d *dev, int us)
return 0;
}
+static inline int device_reset(struct device_d *dev)
+{
+ WARN_ON(1);
+ return 0;
+}
+
#endif /* CONFIG_RESET_CONTROLLER */
#endif