[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cdi-devel] [PATCH v2 2/5] cdi.h: Add cdi_driver.initialised



Every complete implementation will need to store the information whether
a driver is already initialised somewhere, so just put it into struct
cdi_driver.

Signed-off-by: Kevin Wolf <kevin@xxxxxxxxxx>
---
 include/cdi.h |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/include/cdi.h b/include/cdi.h
index 851bb6a..cb87786 100644
--- a/include/cdi.h
+++ b/include/cdi.h
@@ -101,6 +101,7 @@
 #define _CDI_H_
 
 #include <stdint.h>
+#include <stdbool.h>
 
 #include <cdi-osdep.h>
 #include <cdi/lists.h>
@@ -196,6 +197,17 @@ struct cdi_driver {
 
     /**
      * \german
+     * Wird von der CDI-Implementierung auf true gesetzt, sobald .init()
+     * aufgerufen wurde.
+     * \endgerman
+     * \english
+     * Set by the CDI implementation to true as soon as .init() was called.
+     * \endenglish
+     */
+    bool                initialised;
+
+    /**
+     * \german
      * Enthält alle Geräte (cdi_device), die den Treiber benutzen
      * \endgerman
      * \english
-- 
1.7.7