Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1445715

[PATCH v1] ESIA : Dummy eisa_driver_register should return error code

From Arvind Yadav <arvind.yadav.cs@gmail.com>
Newsgroups linux.kernel
Subject [PATCH v1] ESIA : Dummy eisa_driver_register should return error code
Date 2016-07-18 20:50 +0200
Message-ID <rWlM6-1sH-33@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


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@gmail.com>
---
 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

Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread


Thread

[PATCH v1] ESIA : Dummy eisa_driver_register should return error code Arvind Yadav <arvind.yadav.cs@gmail.com> - 2016-07-18 20:50 +0200
  Re: [PATCH v1] ESIA : Dummy eisa_driver_register should return error  code Christoph Hellwig <hch@infradead.org> - 2016-07-19 06:40 +0200
    Re: [PATCH v1] ESIA : Dummy eisa_driver_register should return error  code arvind Yadav <arvind.yadav.cs@gmail.com> - 2016-07-19 18:00 +0200

csiph-web