/net/ax25/ |
D | ax25_iface.c | 57 struct ax25_protocol *protocol; in ax25_protocol_release() local 60 protocol = protocol_list; in ax25_protocol_release() 61 if (protocol == NULL) in ax25_protocol_release() 64 if (protocol->pid == pid) { in ax25_protocol_release() 65 protocol_list = protocol->next; in ax25_protocol_release() 69 while (protocol != NULL && protocol->next != NULL) { in ax25_protocol_release() 70 if (protocol->next->pid == pid) { in ax25_protocol_release() 71 protocol->next = protocol->next->next; in ax25_protocol_release() 75 protocol = protocol->next; in ax25_protocol_release() 161 struct ax25_protocol *protocol; in ax25_protocol_function() local [all …]
|
/net/ipv4/netfilter/ |
D | nf_socket_ipv4.c | 20 extract_icmp4_fields(const struct sk_buff *skb, u8 *protocol, in extract_icmp4_fields() argument 43 if (inside_iph->protocol != IPPROTO_TCP && in extract_icmp4_fields() 44 inside_iph->protocol != IPPROTO_UDP) in extract_icmp4_fields() 56 *protocol = inside_iph->protocol; in extract_icmp4_fields() 67 const u8 protocol, in nf_socket_get_sock_v4() argument 72 switch (protocol) { in nf_socket_get_sock_v4() 91 u8 protocol; in nf_sk_lookup_slow_v4() local 98 if (iph->protocol == IPPROTO_UDP || iph->protocol == IPPROTO_TCP) { in nf_sk_lookup_slow_v4() 103 iph->protocol == IPPROTO_UDP ? in nf_sk_lookup_slow_v4() 108 protocol = iph->protocol; in nf_sk_lookup_slow_v4() [all …]
|
/net/netfilter/ |
D | utils.c | 11 unsigned int dataoff, u8 protocol) in nf_ip_checksum() argument 20 if ((protocol != IPPROTO_TCP && protocol != IPPROTO_UDP && in nf_ip_checksum() 23 skb->len - dataoff, protocol, in nf_ip_checksum() 30 if (protocol != IPPROTO_TCP && protocol != IPPROTO_UDP) in nf_ip_checksum() 35 protocol, 0); in nf_ip_checksum() 45 u8 protocol) in nf_ip_checksum_partial() argument 53 return nf_ip_checksum(skb, hook, dataoff, protocol); in nf_ip_checksum_partial() 56 skb->csum = csum_tcpudp_nofold(iph->saddr, iph->daddr, protocol, in nf_ip_checksum_partial() 65 unsigned int dataoff, u8 protocol) in nf_ip6_checksum() argument 75 skb->len - dataoff, protocol, in nf_ip6_checksum() [all …]
|
/net/ipv4/ |
D | xfrm4_protocol.c | 26 static inline struct xfrm4_protocol __rcu **proto_handlers(u8 protocol) in proto_handlers() argument 28 switch (protocol) { in proto_handlers() 45 static int xfrm4_rcv_cb(struct sk_buff *skb, u8 protocol, int err) in xfrm4_rcv_cb() argument 49 struct xfrm4_protocol __rcu **head = proto_handlers(protocol); in xfrm4_rcv_cb() 203 static inline const struct net_protocol *netproto(unsigned char protocol) in netproto() argument 205 switch (protocol) { in netproto() 218 unsigned char protocol) in xfrm4_protocol_register() argument 226 if (!proto_handlers(protocol) || !netproto(protocol)) in xfrm4_protocol_register() 231 if (!rcu_dereference_protected(*proto_handlers(protocol), in xfrm4_protocol_register() 235 for (pprev = proto_handlers(protocol); in xfrm4_protocol_register() [all …]
|
D | protocol.c | 32 int inet_add_protocol(const struct net_protocol *prot, unsigned char protocol) in inet_add_protocol() argument 34 return !cmpxchg((const struct net_protocol **)&inet_protos[protocol], in inet_add_protocol() 39 int inet_add_offload(const struct net_offload *prot, unsigned char protocol) in inet_add_offload() argument 41 return !cmpxchg((const struct net_offload **)&inet_offloads[protocol], in inet_add_offload() 46 int inet_del_protocol(const struct net_protocol *prot, unsigned char protocol) in inet_del_protocol() argument 50 ret = (cmpxchg((const struct net_protocol **)&inet_protos[protocol], in inet_del_protocol() 59 int inet_del_offload(const struct net_offload *prot, unsigned char protocol) in inet_del_offload() argument 63 ret = (cmpxchg((const struct net_offload **)&inet_offloads[protocol], in inet_del_offload()
|
D | gre_offload.c | 21 __be16 protocol = skb->protocol; in gre_gso_segment() local 41 skb->protocol = skb->inner_protocol; in gre_gso_segment() 58 skb_gso_error_unwind(skb, protocol, tnl_hlen, mac_offset, in gre_gso_segment() 79 skb->protocol = protocol; in gre_gso_segment() 163 type = greh->protocol; in gre_gro_receive() 211 greh2->protocol != greh->protocol) { in gre_gro_receive() 251 type = greh->protocol; in gre_gro_complete()
|
D | af_inet.c | 248 static int inet_create(struct net *net, struct socket *sock, int protocol, in inet_create() argument 259 if (protocol < 0 || protocol >= IPPROTO_MAX) in inet_create() 272 if (protocol == answer->protocol) { in inet_create() 273 if (protocol != IPPROTO_IP) in inet_create() 277 if (IPPROTO_IP == protocol) { in inet_create() 278 protocol = answer->protocol; in inet_create() 281 if (IPPROTO_IP == answer->protocol) in inet_create() 296 PF_INET, protocol, sock->type); in inet_create() 303 PF_INET, protocol); in inet_create() 339 inet->inet_num = protocol; in inet_create() [all …]
|
/net/ipv6/ |
D | xfrm6_protocol.c | 27 static inline struct xfrm6_protocol __rcu **proto_handlers(u8 protocol) in proto_handlers() argument 29 switch (protocol) { in proto_handlers() 46 static int xfrm6_rcv_cb(struct sk_buff *skb, u8 protocol, int err) in xfrm6_rcv_cb() argument 50 struct xfrm6_protocol __rcu **head = proto_handlers(protocol); in xfrm6_rcv_cb() 55 for_each_protocol_rcu(*proto_handlers(protocol), handler) in xfrm6_rcv_cb() 219 static inline const struct inet6_protocol *netproto(unsigned char protocol) in netproto() argument 221 switch (protocol) { in netproto() 234 unsigned char protocol) in xfrm6_protocol_register() argument 242 if (!proto_handlers(protocol) || !netproto(protocol)) in xfrm6_protocol_register() 247 if (!rcu_dereference_protected(*proto_handlers(protocol), in xfrm6_protocol_register() [all …]
|
D | protocol.c | 28 int inet6_add_protocol(const struct inet6_protocol *prot, unsigned char protocol) in inet6_add_protocol() argument 30 return !cmpxchg((const struct inet6_protocol **)&inet6_protos[protocol], in inet6_add_protocol() 35 int inet6_del_protocol(const struct inet6_protocol *prot, unsigned char protocol) in inet6_del_protocol() argument 39 ret = (cmpxchg((const struct inet6_protocol **)&inet6_protos[protocol], in inet6_del_protocol() 52 int inet6_add_offload(const struct net_offload *prot, unsigned char protocol) in inet6_add_offload() argument 54 return !cmpxchg((const struct net_offload **)&inet6_offloads[protocol], in inet6_add_offload() 59 int inet6_del_offload(const struct net_offload *prot, unsigned char protocol) in inet6_del_offload() argument 63 ret = (cmpxchg((const struct net_offload **)&inet6_offloads[protocol], in inet6_del_offload()
|
D | fou6.c | 22 struct flowi6 *fl6, u8 *protocol, __be16 sport) in fou6_build_udp() argument 37 *protocol = IPPROTO_UDP; in fou6_build_udp() 41 u8 *protocol, struct flowi6 *fl6) in fou6_build_header() argument 48 err = __fou_build_header(skb, e, protocol, &sport, type); in fou6_build_header() 52 fou6_build_udp(skb, e, fl6, protocol, sport); in fou6_build_header() 58 u8 *protocol, struct flowi6 *fl6) in gue6_build_header() argument 65 err = __gue_build_header(skb, e, protocol, &sport, type); in gue6_build_header() 69 fou6_build_udp(skb, e, fl6, protocol, sport); in gue6_build_header()
|
/net/ceph/ |
D | auth.c | 177 ceph_encode_32_safe(&p, end, ac->protocol, e_range); in build_request() 184 ceph_auth_proto_name(ac->protocol), ret); in build_request() 204 int protocol; in ceph_handle_auth_reply() local 216 protocol = ceph_decode_32(&p); in ceph_handle_auth_reply() 236 if (!protocol && result < 0) { in ceph_handle_auth_reply() 241 if (ac->protocol && ac->protocol != protocol) { in ceph_handle_auth_reply() 243 ac->protocol = 0; in ceph_handle_auth_reply() 246 if (ac->protocol != protocol) { in ceph_handle_auth_reply() 247 ret = init_protocol(ac, protocol); in ceph_handle_auth_reply() 250 ceph_auth_proto_name(protocol), ret); in ceph_handle_auth_reply() [all …]
|
/net/phonet/ |
D | af_phonet.c | 27 static const struct phonet_protocol *phonet_proto_get(unsigned int protocol) in phonet_proto_get() argument 31 if (protocol >= PHONET_NPROTO) in phonet_proto_get() 35 pp = rcu_dereference(proto_tab[protocol]); in phonet_proto_get() 50 static int pn_socket_create(struct net *net, struct socket *sock, int protocol, in pn_socket_create() argument 61 if (protocol == 0) { in pn_socket_create() 65 protocol = PN_PROTO_PHONET; in pn_socket_create() 68 protocol = PN_PROTO_PIPE; in pn_socket_create() 75 pnp = phonet_proto_get(protocol); in pn_socket_create() 77 request_module("net-pf-%d-proto-%d", PF_PHONET, protocol) == 0) in pn_socket_create() 78 pnp = phonet_proto_get(protocol); in pn_socket_create() [all …]
|
/net/netfilter/ipset/ |
D | ip_set_getport.c | 25 get_port(const struct sk_buff *skb, int protocol, unsigned int protooff, in get_port() argument 28 switch (protocol) { in get_port() 92 *proto = protocol; in get_port() 103 int protocol = iph->protocol; in ip_set_get_ip4_port() local 106 if (protocol <= 0) in ip_set_get_ip4_port() 110 switch (protocol) { in ip_set_get_ip4_port() 122 *proto = protocol; in ip_set_get_ip4_port() 126 return get_port(skb, protocol, protooff, src, port, proto); in ip_set_get_ip4_port()
|
/net/netfilter/ipvs/ |
D | ip_vs_core.c | 231 struct sk_buff *skb, int protocol, in ip_vs_conn_fill_param_persist() argument 236 ip_vs_conn_fill_param(svc->ipvs, svc->af, protocol, caddr, cport, vaddr, in ip_vs_conn_fill_param_persist() 306 int protocol = iph->protocol; in ip_vs_sched_persist() local 327 protocol = IPPROTO_IP; in ip_vs_sched_persist() 332 if (ip_vs_conn_fill_param_persist(svc, skb, protocol, &snet, 0, in ip_vs_sched_persist() 391 && iph->protocol == IPPROTO_UDP) ? in ip_vs_sched_persist() 397 ip_vs_conn_fill_param(svc->ipvs, svc->af, iph->protocol, src_addr, in ip_vs_sched_persist() 538 && iph->protocol == IPPROTO_UDP) ? in ip_vs_schedule() 547 ip_vs_conn_fill_param(svc->ipvs, svc->af, iph->protocol, in ip_vs_schedule() 606 iph->protocol == IPPROTO_UDP) ? in ip_vs_leave() [all …]
|
D | ip_vs_conn.c | 140 return ip_vs_conn_hashkey(p->ipvs, p->af, p->protocol, addr, port); in ip_vs_conn_hashkey_param() 147 ip_vs_conn_fill_param(cp->ipvs, cp->af, cp->protocol, in ip_vs_conn_hashkey_conn() 278 p->protocol == cp->protocol && in __ip_vs_conn_in_get() 305 ip_vs_proto_name(p->protocol), in ip_vs_conn_in_get() 326 ip_vs_conn_fill_param(ipvs, af, iph->protocol, &iph->saddr, in ip_vs_conn_fill_param_proto() 329 ip_vs_conn_fill_param(ipvs, af, iph->protocol, &iph->daddr, in ip_vs_conn_fill_param_proto() 373 ip_vs_addr_equal(p->protocol == IPPROTO_IP ? AF_UNSPEC : in ip_vs_ct_in_get() 377 p->protocol == cp->protocol && in ip_vs_ct_in_get() 389 ip_vs_proto_name(p->protocol), in ip_vs_ct_in_get() 430 p->protocol == cp->protocol && in ip_vs_conn_out_get() [all …]
|
D | ip_vs_pe_sip.c | 77 if (!retc || iph.protocol != IPPROTO_UDP) in ip_vs_sip_fill_param() 117 ip_vs_addr_equal(p->protocol == IPPROTO_IP ? AF_UNSPEC : p->af, in ip_vs_sip_ct_match() 121 ct->protocol == p->protocol && in ip_vs_sip_ct_match() 127 ip_vs_proto_name(p->protocol), in ip_vs_sip_ct_match() 155 if (likely(iph->protocol == IPPROTO_UDP)) in ip_vs_sip_conn_out()
|
/net/bridge/netfilter/ |
D | ebt_ip.c | 61 if (NF_INVF(info, EBT_IP_PROTO, info->protocol != ih->protocol)) in ebt_ip_mt() 117 if (info->protocol != IPPROTO_TCP && in ebt_ip_mt_check() 118 info->protocol != IPPROTO_UDP && in ebt_ip_mt_check() 119 info->protocol != IPPROTO_UDPLITE && in ebt_ip_mt_check() 120 info->protocol != IPPROTO_SCTP && in ebt_ip_mt_check() 121 info->protocol != IPPROTO_DCCP) in ebt_ip_mt_check() 130 info->protocol != IPPROTO_ICMP) in ebt_ip_mt_check() 138 info->protocol != IPPROTO_IGMP) in ebt_ip_mt_check()
|
D | ebt_log.c | 53 print_ports(const struct sk_buff *skb, uint8_t protocol, int offset) in print_ports() argument 55 if (protocol == IPPROTO_TCP || in print_ports() 56 protocol == IPPROTO_UDP || in print_ports() 57 protocol == IPPROTO_UDPLITE || in print_ports() 58 protocol == IPPROTO_SCTP || in print_ports() 59 protocol == IPPROTO_DCCP) { in print_ports() 108 &ih->saddr, &ih->daddr, ih->tos, ih->protocol); in ebt_log_packet() 109 print_ports(skb, ih->protocol, ih->ihl*4); in ebt_log_packet()
|
D | ebt_ip6.c | 70 if (NF_INVF(info, EBT_IP6_PROTO, info->protocol != nexthdr)) in ebt_ip6_mt() 118 if (info->protocol != IPPROTO_TCP && in ebt_ip6_mt_check() 119 info->protocol != IPPROTO_UDP && in ebt_ip6_mt_check() 120 info->protocol != IPPROTO_UDPLITE && in ebt_ip6_mt_check() 121 info->protocol != IPPROTO_SCTP && in ebt_ip6_mt_check() 122 info->protocol != IPPROTO_DCCP) in ebt_ip6_mt_check() 131 info->protocol != IPPROTO_ICMPV6) in ebt_ip6_mt_check()
|
/net/hsr/ |
D | hsr_slave.c | 19 bool hsr_invalid_dan_ingress_frame(__be16 protocol) in hsr_invalid_dan_ingress_frame() argument 21 return (protocol != htons(ETH_P_PRP) && protocol != htons(ETH_P_HSR)); in hsr_invalid_dan_ingress_frame() 29 __be16 protocol; in hsr_handle_frame() local 55 protocol = eth_hdr(skb)->h_proto; in hsr_handle_frame() 59 hsr->proto_ops->invalid_dan_ingress_frame(protocol)) in hsr_handle_frame() 64 if ((!hsr->prot_version && protocol == htons(ETH_P_PRP)) || in hsr_handle_frame() 65 protocol == htons(ETH_P_HSR)) in hsr_handle_frame()
|
/net/can/ |
D | Kconfig | 10 communications protocol. Development of the CAN bus started in 11 1983 at Robert Bosch GmbH, and the protocol was officially 14 applications. More information on the CAN network protocol family 26 The raw CAN protocol option offers access to the CAN bus via 28 most cases where no higher level protocol is being used. The raw 30 To receive/send raw CAN messages, use AF_CAN with protocol CAN_RAW. 42 To use the Broadcast Manager, use AF_CAN with protocol CAN_BCM. 58 tristate "ISO 15765-2:2016 CAN transport protocol" 67 This protocol driver implements data transfers according to
|
/net/core/ |
D | lwt_bpf.c | 89 if (skb->protocol == htons(ETH_P_IP)) { in bpf_lwt_input_reroute() 98 } else if (skb->protocol == htons(ETH_P_IPV6)) { in bpf_lwt_input_reroute() 182 if (skb->protocol == htons(ETH_P_IP)) in bpf_lwt_xmit_reroute() 184 else if (skb->protocol == htons(ETH_P_IPV6)) in bpf_lwt_xmit_reroute() 208 fl4.flowi4_proto = iph->protocol; in bpf_lwt_xmit_reroute() 274 __be16 proto = skb->protocol; in bpf_xmit() 284 if (skb->protocol != proto) { in bpf_xmit() 538 __u8 protocol; in handle_gso_encap() local 548 protocol = ip_hdr(skb)->protocol; in handle_gso_encap() 552 protocol = ipv6_hdr(skb)->nexthdr; in handle_gso_encap() [all …]
|
/net/nfc/nci/ |
D | Kconfig | 4 tristate "NCI protocol support" 7 NCI (NFC Controller Interface) is a communication protocol between 16 tristate "NCI over SPI protocol support" 19 NCI (NFC Controller Interface) is a communication protocol between 26 tristate "NCI over UART protocol support"
|
/net/xfrm/ |
D | xfrm_output.c | 73 offsetof(struct iphdr, protocol); in xfrm4_transport_output() 241 offsetof(struct iphdr, protocol); in xfrm4_beet_encap_add() 256 ph->nexthdr = top_iph->protocol; in xfrm4_beet_encap_add() 260 top_iph->protocol = IPPROTO_BEETPH; in xfrm4_beet_encap_add() 276 bool small_ipv6 = (skb->protocol == htons(ETH_P_IPV6)) && (skb->len <= IPV6_MIN_MTU); in xfrm4_tunnel_encap_add() 286 offsetof(struct iphdr, protocol); in xfrm4_tunnel_encap_add() 293 top_iph->protocol = xfrm_af2proto(skb_dst(skb)->ops->family); in xfrm4_tunnel_encap_add() 415 skb->protocol = htons(ETH_P_IP); in xfrm4_prepare_output() 438 skb->protocol = htons(ETH_P_IPV6); in xfrm6_prepare_output() 665 xo->inner_ipproto = ip_hdr(skb)->protocol; in xfrm_get_inner_ipproto() [all …]
|
/net/bridge/ |
D | br_netfilter_hooks.c | 67 (!skb_vlan_tag_present(skb) && skb->protocol == htons(ETH_P_IP)) 70 (!skb_vlan_tag_present(skb) && skb->protocol == htons(ETH_P_IPV6)) 73 (!skb_vlan_tag_present(skb) && skb->protocol == htons(ETH_P_ARP)) 78 return skb->protocol; in vlan_proto() 79 else if (skb->protocol == htons(ETH_P_8021Q)) in vlan_proto() 118 return skb->protocol == htons(ETH_P_PPP_SES) && in is_pppoe_ip() 127 return skb->protocol == htons(ETH_P_PPP_SES) && in is_pppoe_ipv6() 165 switch (skb->protocol) { in nf_bridge_encap_header_len() 251 skb->protocol = htons(ETH_P_8021Q); in nf_bridge_update_protocol() 254 skb->protocol = htons(ETH_P_PPP_SES); in nf_bridge_update_protocol() [all …]
|