summaryrefslogtreecommitdiffstats
path: root/src/plugins/dns/dns.h
diff options
context:
space:
mode:
authorBenoît Ganne <bganne@cisco.com>2020-11-25 16:43:13 +0100
committerDamjan Marion <dmarion@me.com>2020-11-25 18:59:22 +0000
commit7483a7272d15354486371be7a20c4bf35ab2eb38 (patch)
tree6d76582674897441bc7d3aa30c5bc8f7a779f3a9 /src/plugins/dns/dns.h
parent0a2fde105a5a0c996333d67d2901b4eaedf7cbe1 (diff)
dns: use correct per-thread vlib_main
Using vlib_main of another thread is prohibited. Type: fix Change-Id: I7ae294dfaf2526738e91408c9b4865ef9f801b8a Signed-off-by: Benoît Ganne <bganne@cisco.com>
Diffstat (limited to 'src/plugins/dns/dns.h')
-rw-r--r--src/plugins/dns/dns.h28
1 files changed, 15 insertions, 13 deletions
diff --git a/src/plugins/dns/dns.h b/src/plugins/dns/dns.h
index 2351ab25f97..e6ca440b48a 100644
--- a/src/plugins/dns/dns.h
+++ b/src/plugins/dns/dns.h
@@ -123,7 +123,6 @@ typedef struct
u16 msg_id_base;
/* convenience */
- vlib_main_t *vlib_main;
vnet_main_t *vnet_main;
api_main_t *api_main;
} dns_main_t;
@@ -168,33 +167,36 @@ typedef enum
DNS46_REPLY_N_ERROR,
} dns46_reply_error_t;
-void vnet_send_dns_request (dns_main_t * dm, dns_cache_entry_t * ep);
-int
-vnet_dns_cname_indirection_nolock (dns_main_t * dm, u32 ep_index, u8 * reply);
+void vnet_send_dns_request (vlib_main_t * vm, dns_main_t * dm,
+ dns_cache_entry_t * ep);
+int vnet_dns_cname_indirection_nolock (vlib_main_t * vm, dns_main_t * dm,
+ u32 ep_index, u8 * reply);
int vnet_dns_delete_entry_by_index_nolock (dns_main_t * dm, u32 index);
int
-vnet_dns_resolve_name (dns_main_t * dm, u8 * name, dns_pending_request_t * t,
- dns_cache_entry_t ** retp);
+vnet_dns_resolve_name (vlib_main_t * vm, dns_main_t * dm, u8 * name,
+ dns_pending_request_t * t, dns_cache_entry_t ** retp);
void
-vnet_dns_send_dns6_request (dns_main_t * dm,
+vnet_dns_send_dns6_request (vlib_main_t * vm, dns_main_t * dm,
dns_cache_entry_t * ep, ip6_address_t * server);
void
-vnet_dns_send_dns4_request (dns_main_t * dm,
+vnet_dns_send_dns4_request (vlib_main_t * vm, dns_main_t * dm,
dns_cache_entry_t * ep, ip4_address_t * server);
-void vnet_send_dns4_reply (dns_main_t * dm, dns_pending_request_t * t,
- dns_cache_entry_t * ep, vlib_buffer_t * b0);
+void vnet_send_dns4_reply (vlib_main_t * vm, dns_main_t * dm,
+ dns_pending_request_t * t, dns_cache_entry_t * ep,
+ vlib_buffer_t * b0);
-void vnet_send_dns6_reply (dns_main_t * dm, dns_pending_request_t * t,
- dns_cache_entry_t * ep, vlib_buffer_t * b0);
+void vnet_send_dns6_reply (vlib_main_t * vm, dns_main_t * dm,
+ dns_pending_request_t * t, dns_cache_entry_t * ep,
+ vlib_buffer_t * b0);
u8 *vnet_dns_labels_to_name (u8 * label, u8 * full_text,
u8 ** parse_from_here);
-void vnet_dns_create_resolver_process (dns_main_t * dm);
+void vnet_dns_create_resolver_process (vlib_main_t * vm, dns_main_t * dm);
format_function_t format_dns_reply;