/freebsd-current/sys/netlink/ |
H A D | netlink_io.c | 54 static bool nl_process_nbuf(struct nl_buf *nb, struct nlpcb *nlp); 78 nl_schedule_taskqueue(struct nlpcb *nlp) argument 80 if (!nlp->nl_task_pending) { 81 nlp->nl_task_pending = true; 82 taskqueue_enqueue(nlp->nl_taskqueue, &nlp->nl_task); 90 nl_process_received_one(struct nlpcb *nlp) argument 92 struct socket *so = nlp->nl_socket; 97 NLP_LOCK(nlp); 98 nlp 138 nl_process_received(struct nlpcb *nlp) argument 157 nl_on_transmit(struct nlpcb *nlp) argument 183 struct nlpcb *nlp = (struct nlpcb *)_arg; local 197 nl_send(struct nl_writer *nw, struct nlpcb *nlp) argument 255 nl_receive_message(struct nlmsghdr *hdr, int remaining_length, struct nlpcb *nlp, struct nl_pstate *npt) argument 318 nl_process_nbuf(struct nl_buf *nb, struct nlpcb *nlp) argument [all...] |
H A D | netlink_domain.c | 112 nl_set_thread_nlp(struct thread *td, struct nlpcb *nlp) argument 114 NLP_LOG(LOG_DEBUG2, nlp, "Set thread %p nlp to %p (slot %u)", td, nlp, osd_slot_id); 115 if (osd_set(OSD_THREAD, &td->td_osd, osd_slot_id, nlp) == 0) 119 osd_set_reserved(OSD_THREAD, &td->td_osd, osd_slot_id, rsv, nlp); 129 struct nlpcb *nlp; local 131 CK_LIST_FOREACH(nlp, &V_nl_ctl->ctl_port_head, nl_port_next) { 132 if (nlp->nl_port == port_id) 133 return (nlp); 139 nl_add_group_locked(struct nlpcb *nlp, unsigned int group_id) argument 152 nl_del_group_locked(struct nlpcb *nlp, unsigned int group_id) argument 161 nl_isset_group_locked(struct nlpcb *nlp, unsigned int group_id) argument 170 nl_get_groups_compat(struct nlpcb *nlp) argument 203 struct nlpcb *nlp; local 285 nl_bind_locked(struct nlpcb *nlp, struct sockaddr_nl *snl) argument 317 struct nlpcb *nlp; local 380 struct nlpcb *nlp = sotonlpcb(so); local 404 nl_assign_port(struct nlpcb *nlp, uint32_t port_id) argument 429 nl_autobind_port(struct nlpcb *nlp, uint32_t candidate_id) argument 457 struct nlpcb *nlp; local 484 struct nlpcb *nlp; local 497 struct nlpcb *nlp; local 566 struct nlpcb *nlp = sotonlpcb(so); local 639 nl_createcontrol(struct nlpcb *nlp) argument 671 struct nlpcb *nlp = sotonlpcb(so); local 857 struct nlpcb *nlp = sotonlpcb(so); local [all...] |
H A D | netlink_route.c | 71 struct nlpcb *nlp = npt->nlp; local 85 NLP_LOG(LOG_DEBUG2, nlp, "received msg %s(%d) len %d", cmd->name, 88 if (cmd->priv != 0 && !nlp_has_priv(nlp, cmd->priv)) { 89 NLP_LOG(LOG_DEBUG2, nlp, "priv %d check failed for msg %s", cmd->priv, cmd->name); 92 NLP_LOG(LOG_DEBUG3, nlp, "priv %d check passed for msg %s", cmd->priv, cmd->name); 94 if (!nlp_unconstrained_vnet(nlp) && (cmd->flags & RTNL_F_ALLOW_NONVNET_JAIL) == 0) { 95 NLP_LOG(LOG_DEBUG2, nlp, "jail check failed for msg %s", cmd->name); 103 error = cmd->cb(hdr, nlp, npt); 107 NLP_LOG(LOG_DEBUG3, nlp, "messag [all...] |
H A D | netlink_linux.h | 40 typedef bool msgs_to_linux_cb_t(struct nl_writer *nw, struct nlpcb *nlp);
|
H A D | netlink_glue.c | 82 * nlp accessors. 86 nlp_has_priv(struct nlpcb *nlp, int priv) argument 88 return (priv_check_cred(nlp->nl_cred, priv) == 0); 92 nlp_get_cred(struct nlpcb *nlp) argument 94 return (nlp->nl_cred); 98 nlp_get_pid(const struct nlpcb *nlp) argument 100 return (nlp->nl_process_id); 104 nlp_unconstrained_vnet(const struct nlpcb *nlp) argument 106 return (nlp->nl_unconstrained_vnet); 122 nlmsg_get_unicast_writer_stub(struct nl_writer *nw, int size, struct nlpcb *nlp) argument 229 nlmsg_get_unicast_writer(struct nl_writer *nw, int size, struct nlpcb *nlp) argument [all...] |
H A D | netlink_var.h | 82 #define NLP_LOCK_INIT(_nlp) mtx_init(&((_nlp)->nl_lock), "nlp mtx", NULL, MTX_DEF) 130 void nl_set_thread_nlp(struct thread *td, struct nlpcb *nlp); 134 void nlmsg_ack(struct nlpcb *nlp, int error, struct nlmsghdr *nlmsg, 136 void nl_on_transmit(struct nlpcb *nlp); 139 void nl_schedule_taskqueue(struct nlpcb *nlp); 140 void nl_process_receive_locked(struct nlpcb *nlp); 186 bool (*nlmsg_get_unicast_writer)(struct nl_writer *nw, int size, struct nlpcb *nlp);
|
H A D | netlink_ctl.h | 83 bool nlp_has_priv(struct nlpcb *nlp, int priv); 84 struct ucred *nlp_get_cred(struct nlpcb *nlp); 85 uint32_t nlp_get_pid(const struct nlpcb *nlp); 86 bool nlp_unconstrained_vnet(const struct nlpcb *nlp);
|
H A D | netlink_message_writer.c | 72 return (nl_send(nw, nw->nlp)); 76 _nlmsg_get_unicast_writer(struct nl_writer *nw, int size, struct nlpcb *nlp) argument 78 nw->nlp = nlp; 260 nlmsg_ack(struct nlpcb *nlp, int error, struct nlmsghdr *hdr, argument 265 uint32_t flags = nlp->nl_flags; 282 if ((npt->err_msg || npt->err_off) && nlp->nl_flags & NLF_EXT_ACK) 288 if (!nlmsg_add(nw, nlp->nl_port, hdr->nlmsg_seq, NLMSG_ERROR, nl_flags, payload_len)) 296 if (npt->err_msg != NULL && nlp->nl_flags & NLF_EXT_ACK) 298 if (npt->err_off != 0 && nlp [all...] |
H A D | netlink_generic.c | 59 struct nlpcb *nlp = npt->nlp; local 66 NLP_LOG(LOG_DEBUG, nlp, "invalid message type: %d", hdr->nlmsg_type); 71 NLP_LOG(LOG_DEBUG, nlp, "invalid message size: %d", hdr->nlmsg_len); 78 NLP_LOG(LOG_DEBUG, nlp, "family %s: invalid cmd %d", 85 if (cmd->cmd_priv != 0 && !nlp_has_priv(nlp, cmd->cmd_priv)) { 86 NLP_LOG(LOG_DEBUG, nlp, "family %s: cmd %d priv_check() failed", 91 NLP_LOG(LOG_DEBUG2, nlp, "received family %s cmd %s(%d) len %d",
|
H A D | netlink_message_writer.h | 49 struct nlpcb *nlp; member in union:nl_writer::__anon58 69 bool _nlmsg_get_unicast_writer(struct nl_writer *nw, int expected_size, struct nlpcb *nlp); 84 nlmsg_get_unicast_writer(struct nl_writer *nw, int expected_size, struct nlpcb *nlp) argument 86 return (_nlmsg_get_unicast_writer(nw, expected_size, nlp)); 141 bool nlmsg_get_unicast_writer(struct nl_writer *nw, int expected_size, struct nlpcb *nlp);
|
/freebsd-current/share/examples/sunrpc/dir/ |
H A D | dir_proc.c | 19 namelist *nlp; local 39 nlp = &res.readdir_res_u.list; 41 nl = *nlp = (namenode *) malloc(sizeof(namenode)); 44 nlp = &nl->next; 46 *nlp = NULL;
|
/freebsd-current/contrib/libarchive/libarchive/test/ |
H A D | test_write_disk_mac_metadata.c | 67 char *nl, *nlp; local 88 for (nlp = nl; nlp < nl + r; nlp += strlen(nlp) + 1) { 89 if (strcmp(nlp, xattrname) == 0) {
|
H A D | test_write_disk_hfs_compression.c | 37 char *nl, *nlp; local 58 for (nlp = nl; nlp < nl + r; nlp += strlen(nlp) + 1) { 59 if (strcmp(nlp, xattrname) == 0) {
|
H A D | test_write_disk_no_hfs_compression.c | 37 char *nl, *nlp; local 58 for (nlp = nl; nlp < nl + r; nlp += strlen(nlp) + 1) { 59 if (strcmp(nlp, xattrname) == 0) {
|
H A D | test_write_disk_appledouble.c | 67 char *nl, *nlp; local 88 for (nlp = nl; nlp < nl + r; nlp += strlen(nlp) + 1) { 89 if (strcmp(nlp, xattrname) == 0) {
|
/freebsd-current/usr.bin/gprof/ |
H A D | gprof.c | 336 register nltype *nlp; local 356 for ( nlp = nl ; nlp < npe ; nlp++ ) { 357 for ( arcp = nlp -> children ; arcp ; arcp = arcp -> arc_childlist ) { 560 register struct nl *nlp; local 564 for (nlp = nl; nlp < npe; nlp++) { 565 nlp [all...] |
H A D | arcs.c | 350 register nltype *nlp; local 360 for ( nlp = nl ; nlp < npe ; nlp++ ) { 364 if ( nlp -> cyclehead == nlp && nlp -> cnext != 0 ) { 381 for ( nlp = nl ; nlp < npe ; nlp 448 nltype *nlp; local [all...] |
/freebsd-current/sys/compat/linux/ |
H A D | linux_netlink.c | 353 rtnl_newlink_to_linux(struct nlmsghdr *hdr, struct nlpcb *nlp, argument 388 rtnl_newaddr_to_linux(struct nlmsghdr *hdr, struct nlpcb *nlp, argument 410 rtnl_newneigh_to_linux(struct nlmsghdr *hdr, struct nlpcb *nlp, argument 431 rtnl_newroute_to_linux(struct nlmsghdr *hdr, struct nlpcb *nlp, argument 479 rtnl_to_linux(struct nlmsghdr *hdr, struct nlpcb *nlp, struct nl_writer *nw) argument 487 return (rtnl_newlink_to_linux(hdr, nlp, nw)); 490 return (rtnl_newaddr_to_linux(hdr, nlp, nw)); 493 return (rtnl_newroute_to_linux(hdr, nlp, nw)); 497 return (rtnl_newneigh_to_linux(hdr, nlp, nw)); 506 nlmsg_error_to_linux(struct nlmsghdr *hdr, struct nlpcb *nlp, struc argument 540 nlmsg_to_linux(struct nlmsghdr *hdr, struct nlpcb *nlp, struct nl_writer *nw) argument 566 nlmsgs_to_linux(struct nl_writer *nw, struct nlpcb *nlp) argument [all...] |
/freebsd-current/share/examples/ipfilter/samples/ |
H A D | proxy.c | 133 do_nat_out(in, out, fd, nlp, extif) 135 natlookup_t *nlp; 163 usin.sin_addr = nlp->nl_realip; 164 usin.sin_port = nlp->nl_realport; 182 nat->nat_outip = nlp->nl_outip; 183 nat->nat_oip = nlp->nl_realip; 186 sum2 = LONG_SUM(ntohl(nat->nat_outip.s_addr)) + ntohs(nlp->nl_outport); 197 nat->nat_outport = nlp->nl_outport; 198 nat->nat_oport = nlp->nl_realport; 217 usin.sin_addr = nlp [all...] |
/freebsd-current/sys/netlink/route/ |
H A D | route_var.h | 40 typedef int rtnl_msg_cb_f(struct nlmsghdr *hdr, struct nlpcb *nlp, 108 const struct nlattr_bmask *bm, struct nlpcb *nlp, struct nl_pstate *npt); 110 const struct nlattr_bmask *bm, struct nlpcb *nlp, struct nl_pstate *npt);
|
H A D | iface.c | 450 rtnl_handle_getlink(struct nlmsghdr *hdr, struct nlpcb *nlp, struct nl_pstate *npt) argument 462 .so = nlp, 473 NLP_LOG(LOG_DEBUG3, nlp, "fast track -> searching index %u", 479 NLP_LOG(LOG_DEBUG3, nlp, "fast track -> searching name %s", 531 rtnl_handle_dellink(struct nlmsghdr *hdr, struct nlpcb *nlp, struct nl_pstate *npt) argument 546 NLP_LOG(LOG_DEBUG, nlp, "unable to find interface %u", attrs.ifi_index); 549 NLP_LOG(LOG_DEBUG3, nlp, "mapped ifindex %u to %s", attrs.ifi_index, if_name(ifp)); 555 NLP_LOG(LOG_DEBUG2, nlp, "deleting interface %s returned %d", if_name(ifp), error); 587 struct nlattr_bmask *bm, struct nlpcb *nlp, struct nl_pstate *npt) 612 struct nlattr_bmask *bm, struct nlpcb *nlp, struc 586 create_link(struct nlmsghdr *hdr, struct nl_parsed_link *lattrs, struct nlattr_bmask *bm, struct nlpcb *nlp, struct nl_pstate *npt) argument 611 modify_link(struct nlmsghdr *hdr, struct nl_parsed_link *lattrs, struct nlattr_bmask *bm, struct nlpcb *nlp, struct nl_pstate *npt) argument 668 rtnl_handle_newlink(struct nlmsghdr *hdr, struct nlpcb *nlp, struct nl_pstate *npt) argument 1058 rtnl_handle_getaddr(struct nlmsghdr *hdr, struct nlpcb *nlp, struct nl_pstate *npt) argument 1110 handle_newaddr_inet(struct nlmsghdr *hdr, struct nl_parsed_ifa *attrs, if_t ifp, struct nlpcb *nlp, struct nl_pstate *npt) argument 1194 handle_deladdr_inet(struct nlmsghdr *hdr, struct nl_parsed_ifa *attrs, if_t ifp, struct nlpcb *nlp, struct nl_pstate *npt) argument 1215 handle_newaddr_inet6(struct nlmsghdr *hdr, struct nl_parsed_ifa *attrs, if_t ifp, struct nlpcb *nlp, struct nl_pstate *npt) argument 1278 handle_deladdr_inet6(struct nlmsghdr *hdr, struct nl_parsed_ifa *attrs, if_t ifp, struct nlpcb *nlp, struct nl_pstate *npt) argument 1299 rtnl_handle_addr(struct nlmsghdr *hdr, struct nlpcb *nlp, struct nl_pstate *npt) argument [all...] |
H A D | iface_drivers.c | 72 if (nlp_has_priv(npt->nlp, PRIV_NET_SETIFDESCR)) { 91 if (nlp_has_priv(npt->nlp, PRIV_NET_SETIFMTU)) {
|
H A D | rt.c | 351 struct nlpcb *nlp, struct nlmsghdr *hdr) 530 struct nlpcb *nlp; member in struct:netlink_walkargs 548 if (!rt_is_exportable(rt, nlp_get_cred(wa->nlp))) 607 handle_rtm_getroute(struct nlpcb *nlp, struct nl_parsed_route *attrs, argument 644 if (!rt_is_exportable(rt, nlp_get_cred(nlp))) 661 handle_rtm_dump(struct nlpcb *nlp, uint32_t fibnum, int family, argument 665 .nlp = nlp, 922 rtnl_handle_newroute(struct nlmsghdr *hdr, struct nlpcb *nlp, argument 968 report_operation(attrs.rta_table, &rc, nlp, hd 350 report_operation(uint32_t fibnum, struct rib_cmd_info *rc, struct nlpcb *nlp, struct nlmsghdr *hdr) argument 987 rtnl_handle_delroute(struct nlmsghdr *hdr, struct nlpcb *nlp, struct nl_pstate *npt) argument 1016 rtnl_handle_getroute(struct nlmsghdr *hdr, struct nlpcb *nlp, struct nl_pstate *npt) argument [all...] |
/freebsd-current/contrib/sendmail/src/ |
H A D | alias.c | 678 char *nlp; local 681 nlp = &p[strlen(p)]; 682 if (nlp > p && nlp[-1] == '\n') 683 *--nlp = '\0'; 684 return nlp; 857 register char *nlp; local 859 nlp = &p[strlen(p)]; 860 if (nlp > p && nlp[ [all...] |
/freebsd-current/contrib/libpcap/ |
H A D | pcap-snit.c | 122 register struct nit_iflen *nlp; local 185 nlp = (struct nit_iflen *)cp; 186 cp += sizeof(*nlp); 191 caplen = nlp->nh_pktlen; 195 if (pcap_filter(p->fcode.bf_insns, cp, nlp->nh_pktlen, caplen)) { 198 h.len = nlp->nh_pktlen;
|