[PATCH v1] ESIA : Dummy eisa_driver_register should return error code
From: Arvind Yadav
Date: Mon Jul 18 2016 - 14:45:16 EST
The inline eisa_driver_register stub simply allows compilation on
systems with CONFIG_EISA disabled. the dummy eisa_driver_register
does not register an *_eisa_driver at all. The inline
eisa_driver_register should return to indicate lack of support
when attempting to register an *_eisa_driver on such a system with
CONFIG_EISA disabled.
Signed-off-by: Arvind Yadav <arvind.yadav.cs@xxxxxxxxx>
---
include/linux/eisa.h | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/include/linux/eisa.h b/include/linux/eisa.h
index 6925249..cbfc684 100644
--- a/include/linux/eisa.h
+++ b/include/linux/eisa.h
@@ -70,7 +70,10 @@ void eisa_driver_unregister (struct eisa_driver *edrv);
#else /* !CONFIG_EISA */
-static inline int eisa_driver_register (struct eisa_driver *edrv) { return 0; }
+static inline int eisa_driver_register(struct eisa_driver *edrv)
+{
+ return -ENODEV;
+}
static inline void eisa_driver_unregister (struct eisa_driver *edrv) { }
#endif /* !CONFIG_EISA */
--
1.9.1