Detect missing symbols used with kallsyms_lookup at compile time
[lttng-modules.git] / include / wrapper / writeback.h
index e5f36c258534a211ba76d8b3a316c2dc4bdb3ce1..74b5482ca3b6957bc9b8fb17e250bb519e4619dd 100644 (file)
@@ -37,6 +37,20 @@ unsigned long wrapper_global_dirty_limit(void)
                return 0;
        }
 }
+
+/*
+ * Canary function to check for 'global_wb_domain' at compile time.
+ *
+ * From 'include/linux/writeback.h':
+ *
+ *   extern struct wb_domain global_wb_domain;
+ */
+static inline
+unsigned long __canary__global_wb_domain(void)
+{
+       return global_wb_domain.dirty_limit;
+}
+
 #else
 
 static unsigned long *global_dirty_limit_sym;
@@ -54,6 +68,20 @@ unsigned long wrapper_global_dirty_limit(void)
                return 0;
        }
 }
+
+/*
+ * Canary function to check for 'global_dirty_limit' at compile time.
+ *
+ * From 'include/linux/writeback.h':
+ *
+ *   extern unsigned long global_dirty_limit;
+ */
+static inline
+unsigned long __canary__global_dirty_limit(void)
+{
+       return global_dirty_limit;
+}
+
 #endif
 
 #else /* CONFIG_KALLSYMS_ALL */
This page took 0.023906 seconds and 4 git commands to generate.