summaryrefslogtreecommitdiffstats
path: root/net/netlabel/netlabel_addrlist.h
diff options
context:
space:
mode:
authorManish Katiyar <mkatiyar@gmail.com>2008-10-30 10:44:48 -0400
committerPaul Moore <paul.moore@hp.com>2008-10-30 10:44:48 -0400
commit47b676c0e03dcfd88de91f6f24a06653cfdf32af (patch)
tree30c7400d784109845af731891ff22fc10461c9bb /net/netlabel/netlabel_addrlist.h
parentf8a024796b2bbec3d1a4ad5aae6173cfb18226b4 (diff)
netlabel: Fix compilation warnings in net/netlabel/netlabel_addrlist.c
Enable netlabel auditing functions only when CONFIG_AUDIT is set Signed-off-by: Manish Katiyar <mkatiyar@gmail.com> Signed-off-by: Paul Moore <paul.moore@hp.com>
Diffstat (limited to 'net/netlabel/netlabel_addrlist.h')
-rw-r--r--net/netlabel/netlabel_addrlist.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/net/netlabel/netlabel_addrlist.h b/net/netlabel/netlabel_addrlist.h
index 0242bead405..07ae7fd82be 100644
--- a/net/netlabel/netlabel_addrlist.h
+++ b/net/netlabel/netlabel_addrlist.h
@@ -120,9 +120,19 @@ struct netlbl_af4list *netlbl_af4list_search(__be32 addr,
struct netlbl_af4list *netlbl_af4list_search_exact(__be32 addr,
__be32 mask,
struct list_head *head);
+
+#ifdef CONFIG_AUDIT
void netlbl_af4list_audit_addr(struct audit_buffer *audit_buf,
int src, const char *dev,
__be32 addr, __be32 mask);
+#else
+static inline void netlbl_af4list_audit_addr(struct audit_buffer *audit_buf,
+ int src, const char *dev,
+ __be32 addr, __be32 mask)
+{
+ return;
+}
+#endif
#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
@@ -179,11 +189,23 @@ struct netlbl_af6list *netlbl_af6list_search(const struct in6_addr *addr,
struct netlbl_af6list *netlbl_af6list_search_exact(const struct in6_addr *addr,
const struct in6_addr *mask,
struct list_head *head);
+
+#ifdef CONFIG_AUDIT
void netlbl_af6list_audit_addr(struct audit_buffer *audit_buf,
int src,
const char *dev,
const struct in6_addr *addr,
const struct in6_addr *mask);
+#else
+static inline void netlbl_af6list_audit_addr(struct audit_buffer *audit_buf,
+ int src,
+ const char *dev,
+ const struct in6_addr *addr,
+ const struct in6_addr *mask)
+{
+ return;
+}
+#endif
#endif /* IPV6 */
#endif