Zephyr API Documentation
2.7.0-rc2
A Scalable Open Source RTOS
|
#include <dns_resolve.h>
Data Fields | |
struct k_work_delayable | timer |
struct dns_resolve_context * | ctx |
dns_resolve_cb_t | cb |
void * | user_data |
k_timeout_t | timeout |
const char * | query |
enum dns_query_type | query_type |
uint16_t | id |
uint16_t | query_hash |
Result callbacks. We have multiple callbacks here so that it is possible to do multiple queries at the same time.
Contents of this structure can be inspected and changed only when the lock is held.
dns_resolve_cb_t dns_resolve_context::dns_pending_query::cb |
Result callback.
A null value indicates the slot is not in use.
struct dns_resolve_context* dns_resolve_context::dns_pending_query::ctx |
Back pointer to ctx, needed in timeout handler
uint16_t dns_resolve_context::dns_pending_query::id |
DNS id of this query
const char* dns_resolve_context::dns_pending_query::query |
String containing the thing to resolve like www.example.com
This is set to a non-null value when the query is started, and is not used thereafter.
If the query completed at a point where the work item was still pending the pointer is cleared to indicate that the query is complete, but release of the query slot will be deferred until a request for a slot determines that the work item has been released.
uint16_t dns_resolve_context::dns_pending_query::query_hash |
Hash of the DNS name + query type we are querying. This hash is calculated so we can match the response that we are receiving. This is needed mainly for mDNS which is setting the DNS id to 0, which means that the id alone cannot be used to find correct pending query.
enum dns_query_type dns_resolve_context::dns_pending_query::query_type |
Query type
k_timeout_t dns_resolve_context::dns_pending_query::timeout |
TX timeout
struct k_work_delayable dns_resolve_context::dns_pending_query::timer |
Timeout timer
void* dns_resolve_context::dns_pending_query::user_data |
User data