aboutsummaryrefslogtreecommitdiffstats
path: root/net/netlabel/netlabel_domainhash.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/netlabel/netlabel_domainhash.c')
-rw-r--r--net/netlabel/netlabel_domainhash.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/net/netlabel/netlabel_domainhash.c b/net/netlabel/netlabel_domainhash.c
index 3f905e5370c2..38204112b9f4 100644
--- a/net/netlabel/netlabel_domainhash.c
+++ b/net/netlabel/netlabel_domainhash.c
@@ -78,7 +78,7 @@ static void netlbl_domhsh_free_entry(struct rcu_head *entry)
78 struct netlbl_dom_map *ptr; 78 struct netlbl_dom_map *ptr;
79 struct netlbl_af4list *iter4; 79 struct netlbl_af4list *iter4;
80 struct netlbl_af4list *tmp4; 80 struct netlbl_af4list *tmp4;
81#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) 81#if IS_ENABLED(CONFIG_IPV6)
82 struct netlbl_af6list *iter6; 82 struct netlbl_af6list *iter6;
83 struct netlbl_af6list *tmp6; 83 struct netlbl_af6list *tmp6;
84#endif /* IPv6 */ 84#endif /* IPv6 */
@@ -90,7 +90,7 @@ static void netlbl_domhsh_free_entry(struct rcu_head *entry)
90 netlbl_af4list_remove_entry(iter4); 90 netlbl_af4list_remove_entry(iter4);
91 kfree(netlbl_domhsh_addr4_entry(iter4)); 91 kfree(netlbl_domhsh_addr4_entry(iter4));
92 } 92 }
93#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) 93#if IS_ENABLED(CONFIG_IPV6)
94 netlbl_af6list_foreach_safe(iter6, tmp6, 94 netlbl_af6list_foreach_safe(iter6, tmp6,
95 &ptr->type_def.addrsel->list6) { 95 &ptr->type_def.addrsel->list6) {
96 netlbl_af6list_remove_entry(iter6); 96 netlbl_af6list_remove_entry(iter6);
@@ -217,7 +217,7 @@ static void netlbl_domhsh_audit_add(struct netlbl_dom_map *entry,
217 cipsov4 = map4->type_def.cipsov4; 217 cipsov4 = map4->type_def.cipsov4;
218 netlbl_af4list_audit_addr(audit_buf, 0, NULL, 218 netlbl_af4list_audit_addr(audit_buf, 0, NULL,
219 addr4->addr, addr4->mask); 219 addr4->addr, addr4->mask);
220#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) 220#if IS_ENABLED(CONFIG_IPV6)
221 } else if (addr6 != NULL) { 221 } else if (addr6 != NULL) {
222 struct netlbl_domaddr6_map *map6; 222 struct netlbl_domaddr6_map *map6;
223 map6 = netlbl_domhsh_addr6_entry(addr6); 223 map6 = netlbl_domhsh_addr6_entry(addr6);
@@ -306,7 +306,7 @@ int netlbl_domhsh_add(struct netlbl_dom_map *entry,
306 struct netlbl_dom_map *entry_old; 306 struct netlbl_dom_map *entry_old;
307 struct netlbl_af4list *iter4; 307 struct netlbl_af4list *iter4;
308 struct netlbl_af4list *tmp4; 308 struct netlbl_af4list *tmp4;
309#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) 309#if IS_ENABLED(CONFIG_IPV6)
310 struct netlbl_af6list *iter6; 310 struct netlbl_af6list *iter6;
311 struct netlbl_af6list *tmp6; 311 struct netlbl_af6list *tmp6;
312#endif /* IPv6 */ 312#endif /* IPv6 */
@@ -338,7 +338,7 @@ int netlbl_domhsh_add(struct netlbl_dom_map *entry,
338 &entry->type_def.addrsel->list4) 338 &entry->type_def.addrsel->list4)
339 netlbl_domhsh_audit_add(entry, iter4, NULL, 339 netlbl_domhsh_audit_add(entry, iter4, NULL,
340 ret_val, audit_info); 340 ret_val, audit_info);
341#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) 341#if IS_ENABLED(CONFIG_IPV6)
342 netlbl_af6list_foreach_rcu(iter6, 342 netlbl_af6list_foreach_rcu(iter6,
343 &entry->type_def.addrsel->list6) 343 &entry->type_def.addrsel->list6)
344 netlbl_domhsh_audit_add(entry, NULL, iter6, 344 netlbl_domhsh_audit_add(entry, NULL, iter6,
@@ -365,7 +365,7 @@ int netlbl_domhsh_add(struct netlbl_dom_map *entry,
365 ret_val = -EEXIST; 365 ret_val = -EEXIST;
366 goto add_return; 366 goto add_return;
367 } 367 }
368#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) 368#if IS_ENABLED(CONFIG_IPV6)
369 netlbl_af6list_foreach_rcu(iter6, 369 netlbl_af6list_foreach_rcu(iter6,
370 &entry->type_def.addrsel->list6) 370 &entry->type_def.addrsel->list6)
371 if (netlbl_af6list_search_exact(&iter6->addr, 371 if (netlbl_af6list_search_exact(&iter6->addr,
@@ -386,7 +386,7 @@ int netlbl_domhsh_add(struct netlbl_dom_map *entry,
386 if (ret_val != 0) 386 if (ret_val != 0)
387 goto add_return; 387 goto add_return;
388 } 388 }
389#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) 389#if IS_ENABLED(CONFIG_IPV6)
390 netlbl_af6list_foreach_safe(iter6, tmp6, 390 netlbl_af6list_foreach_safe(iter6, tmp6,
391 &entry->type_def.addrsel->list6) { 391 &entry->type_def.addrsel->list6) {
392 netlbl_af6list_remove_entry(iter6); 392 netlbl_af6list_remove_entry(iter6);
@@ -510,7 +510,7 @@ int netlbl_domhsh_remove_af4(const char *domain,
510 struct netlbl_dom_map *entry_map; 510 struct netlbl_dom_map *entry_map;
511 struct netlbl_af4list *entry_addr; 511 struct netlbl_af4list *entry_addr;
512 struct netlbl_af4list *iter4; 512 struct netlbl_af4list *iter4;
513#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) 513#if IS_ENABLED(CONFIG_IPV6)
514 struct netlbl_af6list *iter6; 514 struct netlbl_af6list *iter6;
515#endif /* IPv6 */ 515#endif /* IPv6 */
516 struct netlbl_domaddr4_map *entry; 516 struct netlbl_domaddr4_map *entry;
@@ -533,7 +533,7 @@ int netlbl_domhsh_remove_af4(const char *domain,
533 goto remove_af4_failure; 533 goto remove_af4_failure;
534 netlbl_af4list_foreach_rcu(iter4, &entry_map->type_def.addrsel->list4) 534 netlbl_af4list_foreach_rcu(iter4, &entry_map->type_def.addrsel->list4)
535 goto remove_af4_single_addr; 535 goto remove_af4_single_addr;
536#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) 536#if IS_ENABLED(CONFIG_IPV6)
537 netlbl_af6list_foreach_rcu(iter6, &entry_map->type_def.addrsel->list6) 537 netlbl_af6list_foreach_rcu(iter6, &entry_map->type_def.addrsel->list6)
538 goto remove_af4_single_addr; 538 goto remove_af4_single_addr;
539#endif /* IPv6 */ 539#endif /* IPv6 */
@@ -644,7 +644,7 @@ struct netlbl_domaddr4_map *netlbl_domhsh_getentry_af4(const char *domain,
644 return netlbl_domhsh_addr4_entry(addr_iter); 644 return netlbl_domhsh_addr4_entry(addr_iter);
645} 645}
646 646
647#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) 647#if IS_ENABLED(CONFIG_IPV6)
648/** 648/**
649 * netlbl_domhsh_getentry_af6 - Get an entry from the domain hash table 649 * netlbl_domhsh_getentry_af6 - Get an entry from the domain hash table
650 * @domain: the domain name to search for 650 * @domain: the domain name to search for