/external/libnl/lib/genl/ |
H A D | genl.c | 75 * struct nlmsghdr *nlh = nlmsg_hdr(msg); 79 * genlmsg_parse(nlh, 0, attrs, ATTR_MAX, policy); 146 int genlmsg_valid_hdr(struct nlmsghdr *nlh, int hdrlen) argument 150 if (!nlmsg_valid_hdr(nlh, GENL_HDRLEN)) 153 ghdr = nlmsg_data(nlh); 160 int genlmsg_validate(struct nlmsghdr *nlh, int hdrlen, int maxtype, argument 165 if (!genlmsg_valid_hdr(nlh, hdrlen)) 168 ghdr = nlmsg_data(nlh); 173 int genlmsg_parse(struct nlmsghdr *nlh, int hdrlen, struct nlattr *tb[], argument 178 if (!genlmsg_valid_hdr(nlh, hdrle 201 struct nlmsghdr *nlh = (struct nlmsghdr *)((unsigned char *)gnlh - local 249 struct nlmsghdr *nlh; local [all...] |
H A D | mngt.c | 94 struct nlmsghdr *nlh, struct nl_parser_param *pp) 100 ghdr = nlmsg_data(nlh); 121 .nlh = nlh, 127 err = nlmsg_parse(nlh, ops->co_hdrsize, tb, cmd->c_maxattr, 93 genl_msg_parser(struct nl_cache_ops *ops, struct sockaddr_nl *who, struct nlmsghdr *nlh, struct nl_parser_param *pp) argument
|
/external/libnl/include/linux/ |
H A D | netlink.h | 80 #define NLMSG_DATA(nlh) ((void*)(((char*)nlh) + NLMSG_LENGTH(0))) 81 #define NLMSG_NEXT(nlh,len) ((len) -= NLMSG_ALIGN((nlh)->nlmsg_len), \ 82 (struct nlmsghdr*)(((char*)(nlh)) + NLMSG_ALIGN((nlh)->nlmsg_len))) 83 #define NLMSG_OK(nlh,len) ((len) >= (int)sizeof(struct nlmsghdr) && \ 84 (nlh)->nlmsg_len >= sizeof(struct nlmsghdr) && \ 85 (nlh)->nlmsg_len <= (len)) 86 #define NLMSG_PAYLOAD(nlh,le [all...] |
/external/wpa_supplicant_8/hostapd/src/drivers/ |
H A D | priv_netlink.h | 53 #define NLMSG_DATA(nlh) ((void*) (((char*) nlh) + NLMSG_LENGTH(0))) 54 #define NLMSG_NEXT(nlh,len) ((len) -= NLMSG_ALIGN((nlh)->nlmsg_len), \ 56 (((char *)(nlh)) + NLMSG_ALIGN((nlh)->nlmsg_len))) 57 #define NLMSG_OK(nlh,len) ((len) >= (int) sizeof(struct nlmsghdr) && \ 58 (nlh)->nlmsg_len >= sizeof(struct nlmsghdr) && \ 59 (int) (nlh)->nlmsg_len <= (len)) 60 #define NLMSG_PAYLOAD(nlh,le [all...] |
/external/wpa_supplicant_8/src/drivers/ |
H A D | priv_netlink.h | 53 #define NLMSG_DATA(nlh) ((void*) (((char*) nlh) + NLMSG_LENGTH(0))) 54 #define NLMSG_NEXT(nlh,len) ((len) -= NLMSG_ALIGN((nlh)->nlmsg_len), \ 56 (((char *)(nlh)) + NLMSG_ALIGN((nlh)->nlmsg_len))) 57 #define NLMSG_OK(nlh,len) ((len) >= (int) sizeof(struct nlmsghdr) && \ 58 (nlh)->nlmsg_len >= sizeof(struct nlmsghdr) && \ 59 (int) (nlh)->nlmsg_len <= (len)) 60 #define NLMSG_PAYLOAD(nlh,le [all...] |
/external/wpa_supplicant_8/wpa_supplicant/src/drivers/ |
H A D | priv_netlink.h | 53 #define NLMSG_DATA(nlh) ((void*) (((char*) nlh) + NLMSG_LENGTH(0))) 54 #define NLMSG_NEXT(nlh,len) ((len) -= NLMSG_ALIGN((nlh)->nlmsg_len), \ 56 (((char *)(nlh)) + NLMSG_ALIGN((nlh)->nlmsg_len))) 57 #define NLMSG_OK(nlh,len) ((len) >= (int) sizeof(struct nlmsghdr) && \ 58 (nlh)->nlmsg_len >= sizeof(struct nlmsghdr) && \ 59 (int) (nlh)->nlmsg_len <= (len)) 60 #define NLMSG_PAYLOAD(nlh,le [all...] |
/external/iproute2/include/linux/ |
H A D | netlink.h | 83 #define NLMSG_DATA(nlh) ((void*)(((char*)nlh) + NLMSG_LENGTH(0))) 84 #define NLMSG_NEXT(nlh,len) ((len) -= NLMSG_ALIGN((nlh)->nlmsg_len), \ 85 (struct nlmsghdr*)(((char*)(nlh)) + NLMSG_ALIGN((nlh)->nlmsg_len))) 86 #define NLMSG_OK(nlh,len) ((len) >= (int)sizeof(struct nlmsghdr) && \ 87 (nlh)->nlmsg_len >= sizeof(struct nlmsghdr) && \ 88 (nlh)->nlmsg_len <= (len)) 89 #define NLMSG_PAYLOAD(nlh,le [all...] |
/external/kernel-headers/original/uapi/linux/ |
H A D | netlink.h | 84 #define NLMSG_DATA(nlh) ((void*)(((char*)nlh) + NLMSG_LENGTH(0))) 85 #define NLMSG_NEXT(nlh,len) ((len) -= NLMSG_ALIGN((nlh)->nlmsg_len), \ 86 (struct nlmsghdr*)(((char*)(nlh)) + NLMSG_ALIGN((nlh)->nlmsg_len))) 87 #define NLMSG_OK(nlh,len) ((len) >= (int)sizeof(struct nlmsghdr) && \ 88 (nlh)->nlmsg_len >= sizeof(struct nlmsghdr) && \ 89 (nlh)->nlmsg_len <= (len)) 90 #define NLMSG_PAYLOAD(nlh,le [all...] |
/external/libnl/lib/netfilter/ |
H A D | nfnl.c | 129 * @arg nlh netlink messsage header 131 uint8_t nfnlmsg_subsys(struct nlmsghdr *nlh) argument 133 return NFNL_SUBSYS_ID(nlh->nlmsg_type); 138 * @arg nlh netlink messsage header 140 uint8_t nfnlmsg_subtype(struct nlmsghdr *nlh) argument 142 return NFNL_MSG_TYPE(nlh->nlmsg_type); 147 * @arg nlh netlink messsage header 149 uint8_t nfnlmsg_family(struct nlmsghdr *nlh) argument 151 struct nfgenmsg *nfg = nlmsg_data(nlh); 158 * @arg nlh netlin 160 nfnlmsg_res_id(struct nlmsghdr *nlh) argument 234 struct nlmsghdr *nlh; local [all...] |
H A D | log.c | 74 int nfnl_log_pf_bind(struct nl_sock *nlh, uint8_t pf) argument 82 return send_log_request(nlh, msg); 90 int nfnl_log_pf_unbind(struct nl_sock *nlh, uint8_t pf) argument 98 return send_log_request(nlh, msg); 182 int nfnl_log_create(struct nl_sock *nlh, const struct nfnl_log *log) argument 190 return send_log_request(nlh, msg); 199 int nfnl_log_change(struct nl_sock *nlh, const struct nfnl_log *log) argument 207 return send_log_request(nlh, msg); 220 int nfnl_log_delete(struct nl_sock *nlh, const struct nfnl_log *log) argument 228 return send_log_request(nlh, ms [all...] |
H A D | queue.c | 84 int nfnl_queue_pf_bind(struct nl_sock *nlh, uint8_t pf) argument 92 return send_queue_request(nlh, msg); 100 int nfnl_queue_pf_unbind(struct nl_sock *nlh, uint8_t pf) argument 108 return send_queue_request(nlh, msg); 182 int nfnl_queue_create(struct nl_sock *nlh, const struct nfnl_queue *queue) argument 190 return send_queue_request(nlh, msg); 199 int nfnl_queue_change(struct nl_sock *nlh, const struct nfnl_queue *queue) argument 207 return send_queue_request(nlh, msg); 220 int nfnl_queue_delete(struct nl_sock *nlh, const struct nfnl_queue *queue) argument 228 return send_queue_request(nlh, ms [all...] |
H A D | queue_msg.c | 62 int nfnlmsg_queue_msg_parse(struct nlmsghdr *nlh, argument 74 msg->ce_msgtype = nlh->nlmsg_type; 76 err = nlmsg_parse(nlh, sizeof(struct nfgenmsg), tb, NFQA_MAX, 81 nfnl_queue_msg_set_group(msg, nfnlmsg_res_id(nlh)); 82 nfnl_queue_msg_set_family(msg, nfnlmsg_family(nlh)); 149 struct nlmsghdr *nlh, struct nl_parser_param *pp) 154 if ((err = nfnlmsg_queue_msg_parse(nlh, &msg)) < 0) 195 * @arg nlh netlink messsage header 199 int nfnl_queue_msg_send_verdict(struct nl_sock *nlh, argument 209 err = nl_send_auto_complete(nlh, nlms 148 queue_msg_parser(struct nl_cache_ops *ops, struct sockaddr_nl *who, struct nlmsghdr *nlh, struct nl_parser_param *pp) argument 224 nfnl_queue_msg_send_verdict_payload(struct nl_sock *nlh, const struct nfnl_queue_msg *msg, const void *payload_data, unsigned payload_len) argument [all...] |
/external/iproute2/genl/ |
H A D | ctrl.c | 45 struct nlmsghdr *nlh; local 55 nlh = &req.n; 56 nlh->nlmsg_len = NLMSG_LENGTH(GENL_HDRLEN); 57 nlh->nlmsg_flags = NLM_F_REQUEST | NLM_F_ACK; 58 nlh->nlmsg_type = GENL_ID_CTRL; 68 addattr_l(nlh, 128, CTRL_ATTR_FAMILY_NAME, family, strlen(family) + 1); 70 if (rtnl_talk(&rth, nlh, 0, 0, nlh) < 0) { 77 struct genlmsghdr *ghdr = NLMSG_DATA(nlh); 78 int len = nlh 287 struct nlmsghdr *nlh; local [all...] |
/external/libnl/lib/ |
H A D | msg.c | 62 * nlmsg_data(nlh)---^ ^ 63 * nlmsg_next(nlh)-----------------------+ 71 * <---------------------- nlmsg_len(nlh) ---------------------> 72 * <------ hdrlen ------> <- nlmsg_attrlen(nlh, hdrlen) -> 76 * nlmsg_attrdata(nlh, hdrlen)---^ 216 * @arg nlh netlink messsage header 218 void *nlmsg_data(const struct nlmsghdr *nlh) argument 220 return (unsigned char *) nlh + NLMSG_HDRLEN; 223 void *nlmsg_tail(const struct nlmsghdr *nlh) argument 225 return (unsigned char *) nlh 232 nlmsg_len(const struct nlmsghdr *nlh) argument 249 nlmsg_attrdata(const struct nlmsghdr *nlh, int hdrlen) argument 260 nlmsg_attrlen(const struct nlmsghdr *nlh, int hdrlen) argument 272 nlmsg_valid_hdr(const struct nlmsghdr *nlh, int hdrlen) argument 285 nlmsg_ok(const struct nlmsghdr *nlh, int remaining) argument 300 nlmsg_next(struct nlmsghdr *nlh, int *remaining) argument 319 nlmsg_parse(struct nlmsghdr *nlh, int hdrlen, struct nlattr *tb[], int maxtype, struct nla_policy *policy) argument 337 nlmsg_find_attr(struct nlmsghdr *nlh, int hdrlen, int attrtype) argument 350 nlmsg_validate(struct nlmsghdr *nlh, int hdrlen, int maxtype, struct nla_policy *policy) argument 454 struct nlmsghdr nlh = { local 614 struct nlmsghdr *nlh; local 900 struct nlmsghdr *nlh = nlmsg_hdr(msg); local [all...] |
/external/libnl/src/ |
H A D | nl-fib-lookup.c | 28 struct nl_sock *nlh; local 76 nlh = nl_cli_alloc_socket(); 100 nl_cli_connect(nlh, NETLINK_FIB_LOOKUP); 102 err = flnl_lookup(nlh, request, result);
|
H A D | disabled-nl-qdisc-add.c | 128 struct nl_sock *nlh; local 139 nlh = nltool_alloc_handle(); 140 if (!nlh) 179 if (nltool_connect(nlh, NETLINK_ROUTE) < 0) 182 if (rtnl_qdisc_add(nlh, qdisc, NLM_F_REPLACE) < 0) { 189 nl_close(nlh); 193 nl_handle_destroy(nlh);
|
/external/iptables/libipq/ |
H A D | libipq.c | 129 struct nlmsghdr *nlh; local 185 nlh = (struct nlmsghdr *)buf; 186 if (nlh->nlmsg_flags & MSG_TRUNC || nlh->nlmsg_len > status) { 272 struct nlmsghdr nlh; member in struct:__anon22635 277 req.nlh.nlmsg_len = NLMSG_LENGTH(sizeof(req)); 278 req.nlh.nlmsg_flags = NLM_F_REQUEST; 279 req.nlh.nlmsg_type = IPQM_MODE; 280 req.nlh.nlmsg_pid = h->local.nl_pid; 283 return ipq_netlink_sendto(h, (void *)&req, req.nlh 321 struct nlmsghdr nlh; local [all...] |
/external/libpcap/ |
H A D | pcap-netfilter-linux.c | 110 const struct nlmsghdr *nlh = (const struct nlmsghdr *) buf; local 114 if (nlh->nlmsg_len < sizeof(struct nlmsghdr) || len < nlh->nlmsg_len) { 115 snprintf(handle->errbuf, PCAP_ERRBUF_SIZE, "Message truncated: (got: %d) (nlmsg_len: %u)", len, nlh->nlmsg_len); 119 if (NFNL_SUBSYS_ID(nlh->nlmsg_type) == NFNL_SUBSYS_ULOG && 120 NFNL_MSG_TYPE(nlh->nlmsg_type) == NFULNL_MSG_PACKET) 123 if (NFNL_SUBSYS_ID(nlh->nlmsg_type) == NFNL_SUBSYS_QUEUE && 124 NFNL_MSG_TYPE(nlh->nlmsg_type) == NFQNL_MSG_PACKET) 137 if (nlh->nlmsg_len < HDR_LENGTH) { 138 snprintf(handle->errbuf, PCAP_ERRBUF_SIZE, "Malformed message: (nlmsg_len: %u)", nlh 248 struct nlmsghdr *nlh = (struct nlmsghdr *) buf; local [all...] |
/external/iputils/ninfod/ |
H A D | ni_ifaddrs.c | 96 struct nlmsghdr *nlh; member in struct:nlmsg_list 220 struct nlmsghdr *nlh = NULL; local 230 status = nl_getmsg(sd, request, seq, &nlh, &done); 233 if (nlh) { 237 free(nlh); 242 nlm_next->nlh = (struct nlmsghdr *) nlh; 268 if(nlm->nlh) 269 free(nlm->nlh); 353 struct nlmsghdr *nlh, *nlh local [all...] |
/external/libnl/include/netlink/ |
H A D | msg.h | 118 * @arg nlh netlink message header 122 #define nlmsg_for_each_attr(pos, nlh, hdrlen, rem) \ 123 nla_for_each_attr(pos, nlmsg_attrdata(nlh, hdrlen), \ 124 nlmsg_attrlen(nlh, hdrlen), rem)
|
/external/libnl/include/netlink/genl/ |
H A D | mngt.h | 28 struct nlmsghdr * nlh; member in struct:genl_info
|
/external/libselinux/src/ |
H A D | avc_internal.c | 106 struct nlmsghdr *nlh = (struct nlmsghdr *)buf; local 149 if (nlh->nlmsg_flags & MSG_TRUNC || nlh->nlmsg_len > (unsigned)rc) { 162 struct nlmsghdr *nlh = (struct nlmsghdr *)buf; local 164 switch (nlh->nlmsg_type) { 166 struct nlmsgerr *err = NLMSG_DATA(nlh); 179 struct selnl_msg_setenforce *msg = NLMSG_DATA(nlh); 199 struct selnl_msg_policyload *msg = NLMSG_DATA(nlh); 219 avc_prefix, nlh->nlmsg_type);
|
/external/qemu/distrib/libselinux/src/ |
H A D | avc_internal.c | 106 struct nlmsghdr *nlh = (struct nlmsghdr *)buf; local 149 if (nlh->nlmsg_flags & MSG_TRUNC || nlh->nlmsg_len > (unsigned)rc) { 162 struct nlmsghdr *nlh = (struct nlmsghdr *)buf; local 164 switch (nlh->nlmsg_type) { 166 struct nlmsgerr *err = NLMSG_DATA(nlh); 179 struct selnl_msg_setenforce *msg = NLMSG_DATA(nlh); 199 struct selnl_msg_policyload *msg = NLMSG_DATA(nlh); 219 avc_prefix, nlh->nlmsg_type);
|
/external/dnsmasq/contrib/wrt/ |
H A D | dhcp_release.c | 188 struct nlmsghdr nlh; member in struct:__anon20424 197 req.nlh.nlmsg_len = sizeof(req); 198 req.nlh.nlmsg_type = RTM_GETADDR; 199 req.nlh.nlmsg_flags = NLM_F_ROOT | NLM_F_MATCH | NLM_F_REQUEST | NLM_F_ACK; 200 req.nlh.nlmsg_pid = 0; 201 req.nlh.nlmsg_seq = 1;
|
/external/dnsmasq/src/ |
H A D | netlink.c | 134 struct nlmsghdr nlh; member in struct:__anon20436 144 req.nlh.nlmsg_len = sizeof(req); 145 req.nlh.nlmsg_type = RTM_GETADDR; 146 req.nlh.nlmsg_flags = NLM_F_ROOT | NLM_F_MATCH | NLM_F_REQUEST | NLM_F_ACK; 147 req.nlh.nlmsg_pid = 0; 148 req.nlh.nlmsg_seq = ++seq;
|