Lines Matching refs:npc
89 npf_socket_lookup_rid(npf_cache_t *npc, get_rid_t get_rid, uint32_t *rid, int dir)
93 KASSERT(npf_iscached(npc, NPC_IP46));
96 if (npf_iscached(npc, NPC_IP4)) {
97 so = npf_ip_socket(npc, dir);
99 } else if (npf_iscached(npc, NPC_IP6)) {
100 so = npf_ip6_socket(npc, dir);
114 npf_ip_socket(npf_cache_t *npc, int dir)
127 KASSERT(npf_iscached(npc, NPC_LAYER4));
128 KASSERT(npf_iscached(npc, NPC_IP4));
130 struct tcphdr *tcp = npc->npc_l4.tcp;
131 struct udphdr *udp = npc->npc_l4.udp;
132 struct ip *ip = npc->npc_ip.v4;
134 switch(npc->npc_proto) {
176 npf_ip6_socket(npf_cache_t *npc, int dir)
190 KASSERT(npf_iscached(npc, NPC_LAYER4));
191 KASSERT(npf_iscached(npc, NPC_IP6));
193 struct tcphdr *tcp = npc->npc_l4.tcp;
194 struct udphdr *udp = npc->npc_l4.udp;
195 struct ip6_hdr *ip6 = npc->npc_ip.v6;
197 switch(npc->npc_proto) {