reset: add stub for device_reset when CONFIG_RESET_CONTROLLER=n
PATCH 1/1 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 ]
--- include/linux/reset.h | 6 ++++++ 1 file changed, 6 insertions(+)
include/linux/reset.h +6 -0
@@ -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
Signature · 7 lines
2.20.1 _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
Sascha Hauer
AppliedQuoted 11 lines · Ahmad Fatoum
Users of an optional
device_resetthat haveCONFIG_RESET_CONTROLLER=nwill trigger compilation errors. Add a static inline stub to fix it.[ Note:
device_resetis 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 <[email protected]>--- include/linux/reset.h | 6 ++++++ 1 file changed, 6 insertions(+)
Applied, thanks
Sascha
Signature · 9 lines
Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox