]> xenbits.xensource.com Git - people/pauldu/mini-os.git/commitdiff
mini-os: don't get xenbus parameters if xenbus is disabled
authorJuergen Gross <jgross@suse.com>
Mon, 29 Aug 2016 14:18:27 +0000 (16:18 +0200)
committerWei Liu <wei.liu2@citrix.com>
Tue, 30 Aug 2016 08:14:32 +0000 (09:14 +0100)
get_xenbus() should be called only if CONFIG_XENBUS is set.

Signed-off-by: Juergen Gross <jgross@suse.com>
Reviewed-by: Wei Liu <wei.liu2@citrix.com>
Acked-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
include/xenbus.h

index 5646a25eed28178b47c32af90df1b91db9b94c6e..c254652067f2c1920d2099c41e1348205c36232d 100644 (file)
@@ -9,10 +9,14 @@ typedef unsigned long xenbus_transaction_t;
 #ifdef CONFIG_XENBUS
 /* Initialize the XenBus system. */
 void init_xenbus(void);
+void get_xenbus(void *p);
 #else
 static inline void init_xenbus(void)
 {
 }
+static inline void get_xenbus(void *p)
+{
+}
 #endif
 
 /* Read the value associated with a path.  Returns a malloc'd error
@@ -31,7 +35,6 @@ typedef struct xenbus_event *xenbus_event_queue;
 
 extern uint32_t xenbus_evtchn;
 
-void get_xenbus(void *p);
 char *xenbus_watch_path_token(xenbus_transaction_t xbt, const char *path, const char *token, xenbus_event_queue *events);
 char *xenbus_unwatch_path_token(xenbus_transaction_t xbt, const char *path, const char *token);
 extern struct wait_queue_head xenbus_watch_queue;