/openbmc/linux/net/core/ |
H A D | secure_seq.c | 57 const __be32 *saddr, const __be32 *daddr) in secure_tcpv6_ts_off() argument 60 struct in6_addr saddr; in secure_tcpv6_ts_off() member 63 .saddr = *(struct in6_addr *)saddr, in secure_tcpv6_ts_off() 76 u32 secure_tcpv6_seq(const __be32 *saddr, const __be32 *daddr, in secure_tcpv6_seq() argument 80 struct in6_addr saddr; in secure_tcpv6_seq() member 85 .saddr = *(struct in6_addr *)saddr, in secure_tcpv6_seq() 99 u64 secure_ipv6_port_ephemeral(const __be32 *saddr, const __be32 *daddr, in secure_ipv6_port_ephemeral() argument 103 struct in6_addr saddr; in secure_ipv6_port_ephemeral() member 108 .saddr = *(struct in6_addr *)saddr, in secure_ipv6_port_ephemeral() 121 u32 secure_tcp_ts_off(const struct net *net, __be32 saddr, __be32 daddr) in secure_tcp_ts_off() argument [all …]
|
/openbmc/linux/net/xfrm/ |
H A D | xfrm_hash.h | 20 const xfrm_address_t *saddr) in __xfrm4_daddr_saddr_hash() argument 22 u32 sum = (__force u32)daddr->a4 + (__force u32)saddr->a4; in __xfrm4_daddr_saddr_hash() 27 const xfrm_address_t *saddr) in __xfrm6_daddr_saddr_hash() argument 29 return __xfrm6_addr_hash(daddr) ^ __xfrm6_addr_hash(saddr); in __xfrm6_daddr_saddr_hash() 45 const xfrm_address_t *saddr, in __xfrm4_dpref_spref_hash() argument 50 ntohl(saddr->a4) & __bits2mask32(sbits), in __xfrm4_dpref_spref_hash() 76 const xfrm_address_t *saddr, in __xfrm6_dpref_spref_hash() argument 81 __xfrm6_pref_hash(saddr, sbits); in __xfrm6_dpref_spref_hash() 85 const xfrm_address_t *saddr, in __xfrm_dst_hash() argument 92 h ^= __xfrm4_daddr_saddr_hash(daddr, saddr); in __xfrm_dst_hash() [all …]
|
/openbmc/qemu/util/ |
H A D | qemu-sockets.c | 170 static int try_bind(int socket, InetSocketAddress *saddr, struct addrinfo *e) in try_bind() argument 180 ((!saddr->has_ipv4 && !saddr->has_ipv6) || in try_bind() 181 (saddr->has_ipv4 && saddr->ipv4 && in try_bind() 182 saddr->has_ipv6 && saddr->ipv6)) ? 0 : 1; in try_bind() 208 static int inet_listen_saddr(InetSocketAddress *saddr, in inet_listen_saddr() argument 223 if (saddr->keep_alive) { in inet_listen_saddr() 231 if (saddr->has_numeric && saddr->numeric) { in inet_listen_saddr() 235 ai.ai_family = inet_ai_family_from_address(saddr, errp); in inet_listen_saddr() 240 if (saddr->host == NULL) { in inet_listen_saddr() 244 if (saddr->port != NULL) { in inet_listen_saddr() [all …]
|
/openbmc/qemu/migration/ |
H A D | socket.c | 35 SocketAddress *saddr; member 41 qio_channel_socket_connect_async(sioc, outgoing_args.saddr, in socket_send_channel_create() 85 SocketAddress *saddr, in socket_start_outgoing_migration() argument 90 SocketAddress *addr = QAPI_CLONE(SocketAddress, saddr); in socket_start_outgoing_migration() 95 qapi_free_SocketAddress(outgoing_args.saddr); in socket_start_outgoing_migration() 96 outgoing_args.saddr = addr; in socket_start_outgoing_migration() 98 if (saddr->type == SOCKET_ADDRESS_TYPE_INET) { in socket_start_outgoing_migration() 99 data->hostname = g_strdup(saddr->u.inet.host); in socket_start_outgoing_migration() 104 saddr, in socket_start_outgoing_migration() 113 if (outgoing_args.saddr) { in socket_cleanup_outgoing_migration() [all …]
|
/openbmc/linux/include/net/ |
H A D | ip6_checksum.h | 34 __sum16 csum_ipv6_magic(const struct in6_addr *saddr, 41 return ~csum_unfold(csum_ipv6_magic(&ipv6_hdr(skb)->saddr, in ip6_compute_pseudo() 47 const struct in6_addr *saddr, in tcp_v6_check() argument 51 return csum_ipv6_magic(saddr, daddr, len, IPPROTO_TCP, base); in tcp_v6_check() 55 const struct in6_addr *saddr, in __tcp_v6_send_check() argument 60 th->check = ~tcp_v6_check(skb->len, saddr, daddr, 0); in __tcp_v6_send_check() 71 th->check = ~tcp_v6_check(0, &ipv6h->saddr, &ipv6h->daddr, 0); in tcp_v6_gso_csum_prep() 75 const struct in6_addr *saddr, in udp_v6_check() argument 79 return csum_ipv6_magic(saddr, daddr, len, IPPROTO_UDP, base); in udp_v6_check() 83 const struct in6_addr *saddr,
|
H A D | secure_seq.h | 9 u64 secure_ipv4_port_ephemeral(__be32 saddr, __be32 daddr, __be16 dport); 10 u64 secure_ipv6_port_ephemeral(const __be32 *saddr, const __be32 *daddr, 12 u32 secure_tcp_seq(__be32 saddr, __be32 daddr, 14 u32 secure_tcp_ts_off(const struct net *net, __be32 saddr, __be32 daddr); 15 u32 secure_tcpv6_seq(const __be32 *saddr, const __be32 *daddr, 18 const __be32 *saddr, const __be32 *daddr); 19 u64 secure_dccp_sequence_number(__be32 saddr, __be32 daddr, 21 u64 secure_dccpv6_sequence_number(__be32 *saddr, __be32 *daddr,
|
H A D | inet6_hashtables.h | 45 const struct in6_addr *saddr, 61 const struct in6_addr *saddr, 70 const struct in6_addr *saddr, 79 const struct in6_addr *saddr, 88 const struct in6_addr *saddr, in __inet6_lookup() argument 95 struct sock *sk = __inet6_lookup_established(net, hashinfo, saddr, in __inet6_lookup() 102 return inet6_lookup_listener(net, hashinfo, skb, doff, saddr, sport, in __inet6_lookup() 108 const struct in6_addr *saddr, const __be16 sport, in inet6_steal_sock() argument 133 saddr, sport, daddr, ntohs(dport), in inet6_steal_sock() 157 sk = inet6_steal_sock(net, skb, doff, &ip6h->saddr, sport, &ip6h->daddr, dport, in __inet6_lookup_skb() [all …]
|
/openbmc/linux/include/trace/events/ |
H A D | tcp.h | 15 #define TP_STORE_V4MAPPED(__entry, saddr, daddr) \ argument 20 ipv6_addr_set_v4mapped(saddr, pin6); \ 26 #define TP_STORE_ADDRS(__entry, saddr, daddr, saddr6, daddr6) \ argument 36 TP_STORE_V4MAPPED(__entry, saddr, daddr); \ 40 #define TP_STORE_ADDRS(__entry, saddr, daddr, saddr6, daddr6) \ argument 41 TP_STORE_V4MAPPED(__entry, saddr, daddr) 63 __array(__u8, saddr, 4) 81 p32 = (__be32 *) __entry->saddr; 93 __entry->sport, __entry->dport, __entry->saddr, __entry->daddr, 132 __array(__u8, saddr, 4) [all …]
|
/openbmc/qemu/hw/sparc/ |
H A D | sun4m_iommu.c | 138 hwaddr saddr; in iommu_mem_read() local 141 saddr = addr >> 2; in iommu_mem_read() 142 switch (saddr) { in iommu_mem_read() 144 ret = s->regs[saddr]; in iommu_mem_read() 148 ret = s->regs[saddr]; in iommu_mem_read() 152 trace_sun4m_iommu_mem_readl(saddr, ret); in iommu_mem_read() 160 hwaddr saddr; in iommu_mem_write() local 162 saddr = addr >> 2; in iommu_mem_write() 163 trace_sun4m_iommu_mem_writel(saddr, val); in iommu_mem_write() 164 switch (saddr) { in iommu_mem_write() [all …]
|
/openbmc/qemu/hw/audio/ |
H A D | cs4231.c | 72 uint32_t saddr, ret; in cs_mem_read() local 74 saddr = addr >> 2; in cs_mem_read() 75 switch (saddr) { in cs_mem_read() 88 ret = s->regs[saddr]; in cs_mem_read() 89 trace_cs4231_mem_readl_reg(saddr, ret); in cs_mem_read() 99 uint32_t saddr; in cs_mem_write() local 101 saddr = addr >> 2; in cs_mem_write() 102 trace_cs4231_mem_writel_reg(saddr, s->regs[saddr], val); in cs_mem_write() 103 switch (saddr) { in cs_mem_write() 127 s->regs[saddr] = val; in cs_mem_write() [all …]
|
/openbmc/linux/net/ipv6/ |
H A D | ip6_checksum.c | 8 __sum16 csum_ipv6_magic(const struct in6_addr *saddr, in csum_ipv6_magic() argument 18 sum += (__force u32)saddr->s6_addr32[0]; in csum_ipv6_magic() 19 carry = (sum < (__force u32)saddr->s6_addr32[0]); in csum_ipv6_magic() 22 sum += (__force u32)saddr->s6_addr32[1]; in csum_ipv6_magic() 23 carry = (sum < (__force u32)saddr->s6_addr32[1]); in csum_ipv6_magic() 26 sum += (__force u32)saddr->s6_addr32[2]; in csum_ipv6_magic() 27 carry = (sum < (__force u32)saddr->s6_addr32[2]); in csum_ipv6_magic() 30 sum += (__force u32)saddr->s6_addr32[3]; in csum_ipv6_magic() 31 carry = (sum < (__force u32)saddr->s6_addr32[3]); in csum_ipv6_magic() 116 const struct in6_addr *saddr, in udp6_set_csum() argument [all …]
|
H A D | inet6_hashtables.c | 52 const struct in6_addr *saddr, in __inet6_lookup_established() argument 64 unsigned int hash = inet6_ehashfn(net, daddr, hnum, saddr, sport); in __inet6_lookup_established() 73 if (!inet6_match(net, sk, saddr, daddr, ports, dif, sdif)) in __inet6_lookup_established() 78 if (unlikely(!inet6_match(net, sk, saddr, daddr, ports, dif, sdif))) { in __inet6_lookup_established() 132 const struct in6_addr *saddr, in inet6_lookup_reuseport() argument 143 net, daddr, hnum, saddr, sport); in inet6_lookup_reuseport() 154 const struct in6_addr *saddr, in inet6_lhash2_lookup() argument 166 saddr, sport, daddr, hnum, inet6_ehashfn); in inet6_lhash2_lookup() 181 const struct in6_addr *saddr, in inet6_lookup_run_sk_lookup() argument 190 no_reuseport = bpf_sk_lookup_run_v6(net, protocol, saddr, sport, in inet6_lookup_run_sk_lookup() [all …]
|
H A D | xfrm6_tunnel.c | 74 …ic struct xfrm6_tunnel_spi *__xfrm6_tunnel_spi_lookup(struct net *net, const xfrm_address_t *saddr) in __xfrm6_tunnel_spi_lookup() argument 80 &xfrm6_tn->spi_byaddr[xfrm6_tunnel_spi_hash_byaddr(saddr)], in __xfrm6_tunnel_spi_lookup() 82 if (xfrm6_addr_equal(&x6spi->addr, saddr)) in __xfrm6_tunnel_spi_lookup() 89 __be32 xfrm6_tunnel_spi_lookup(struct net *net, const xfrm_address_t *saddr) in xfrm6_tunnel_spi_lookup() argument 95 x6spi = __xfrm6_tunnel_spi_lookup(net, saddr); in xfrm6_tunnel_spi_lookup() 117 static u32 __xfrm6_tunnel_alloc_spi(struct net *net, xfrm_address_t *saddr) in __xfrm6_tunnel_alloc_spi() argument 151 memcpy(&x6spi->addr, saddr, sizeof(x6spi->addr)); in __xfrm6_tunnel_alloc_spi() 157 index = xfrm6_tunnel_spi_hash_byaddr(saddr); in __xfrm6_tunnel_alloc_spi() 163 __be32 xfrm6_tunnel_alloc_spi(struct net *net, xfrm_address_t *saddr) in xfrm6_tunnel_alloc_spi() argument 169 x6spi = __xfrm6_tunnel_spi_lookup(net, saddr); in xfrm6_tunnel_alloc_spi() [all …]
|
/openbmc/qemu/net/ |
H A D | dgram.c | 288 struct sockaddr_in *saddr; in net_dgram_mcast_init() local 295 saddr = g_new(struct sockaddr_in, 1); in net_dgram_mcast_init() 296 if (convert_host_port(saddr, remote->u.inet.host, remote->u.inet.port, in net_dgram_mcast_init() 298 g_free(saddr); in net_dgram_mcast_init() 303 fd = net_dgram_mcast_create(saddr, NULL, errp); in net_dgram_mcast_init() 305 g_free(saddr); in net_dgram_mcast_init() 314 g_free(saddr); in net_dgram_mcast_init() 320 fd = net_dgram_mcast_create(saddr, &localaddr, errp); in net_dgram_mcast_init() 322 g_free(saddr); in net_dgram_mcast_init() 332 g_free(saddr); in net_dgram_mcast_init() [all …]
|
H A D | socket.c | 336 struct sockaddr_in saddr; in net_socket_fd_init_dgram() local 356 if (parse_host_port(&saddr, mcast, errp) < 0) { in net_socket_fd_init_dgram() 360 if (saddr.sin_addr.s_addr == 0) { in net_socket_fd_init_dgram() 365 newfd = net_socket_mcast_create(&saddr, NULL, errp); in net_socket_fd_init_dgram() 387 s->dgram_dst = saddr; in net_socket_fd_init_dgram() 389 inet_ntoa(saddr.sin_addr), ntohs(saddr.sin_port)); in net_socket_fd_init_dgram() 469 struct sockaddr_in saddr; in net_socket_accept() local 474 len = sizeof(saddr); in net_socket_accept() 475 fd = qemu_accept(s->listen_fd, (struct sockaddr *)&saddr, &len); in net_socket_accept() 488 inet_ntoa(saddr.sin_addr), ntohs(saddr.sin_port)); in net_socket_accept() [all …]
|
/openbmc/linux/drivers/net/wireguard/selftest/ |
H A D | ratelimiter.c | 56 hdr4->saddr = htonl(ntohl(hdr4->saddr) + i + 1); in timings_test() 64 hdr4->saddr = htonl(ntohl(hdr4->saddr) - i - 1); in timings_test() 67 hdr6->saddr.in6_u.u6_addr32[2] = htonl(i); in timings_test() 68 hdr6->saddr.in6_u.u6_addr32[3] = htonl(i); in timings_test() 77 hdr6->saddr.in6_u.u6_addr32[0] = in timings_test() 78 htonl(ntohl(hdr6->saddr.in6_u.u6_addr32[0]) + i + 1); in timings_test() 86 hdr6->saddr.in6_u.u6_addr32[0] = in timings_test() 87 htonl(ntohl(hdr6->saddr.in6_u.u6_addr32[0]) - i - 1); in timings_test() 110 hdr4->saddr = htonl(i); in capacity_test() 152 hdr4->saddr = htonl(8182); in wg_ratelimiter_selftest() [all …]
|
/openbmc/linux/net/netfilter/ |
H A D | nft_chain_route.c | 22 __be32 saddr, daddr; in nf_route_table_hook4() local 33 saddr = iph->saddr; in nf_route_table_hook4() 41 if (iph->saddr != saddr || in nf_route_table_hook4() 69 struct in6_addr saddr, daddr; in nf_route_table_hook6() local 80 memcpy(&saddr, &ipv6_hdr(skb)->saddr, sizeof(saddr)); in nf_route_table_hook6() 90 (memcmp(&ipv6_hdr(skb)->saddr, &saddr, sizeof(saddr)) || in nf_route_table_hook6()
|
/openbmc/qemu/hw/pci-host/ |
H A D | gt64120.c | 446 uint32_t saddr = addr >> 2; in gt64120_writel() local 453 switch (saddr) { in gt64120_writel() 494 s->regs[saddr] = val & 0x0000007f; in gt64120_writel() 500 s->regs[saddr] = val & 0x0000007f; in gt64120_writel() 503 s->regs[saddr] = val & 0x00007fff; in gt64120_writel() 513 s->regs[saddr] = val & 0x000007ff; in gt64120_writel() 526 saddr << 2, size, size << 1, val); in gt64120_writel() 536 saddr << 2, size, size << 1, val); in gt64120_writel() 565 s->regs[saddr] = val; in gt64120_writel() 578 saddr << 2, size, size << 1, val); in gt64120_writel() [all …]
|
/openbmc/u-boot/arch/arm/mach-rmobile/include/mach/ |
H A D | rcar-mstp.h | 12 #define mstp_setbits(type, addr, saddr, set) \ argument 13 out_##type((saddr), in_##type(addr) | (set)) 14 #define mstp_clrbits(type, addr, saddr, clear) \ argument 15 out_##type((saddr), in_##type(addr) & ~(clear)) 18 #define mstp_setbits_le32(addr, saddr, set) \ argument 19 mstp_setbits(le32, addr, saddr, set) 20 #define mstp_clrbits_le32(addr, saddr, clear) \ argument 21 mstp_clrbits(le32, addr, saddr, clear)
|
/openbmc/linux/arch/s390/include/asm/ |
H A D | checksum.h | 81 static inline __wsum csum_tcpudp_nofold(__be32 saddr, __be32 daddr, __u32 len, in csum_tcpudp_nofold() argument 86 csum += (__force __u32)saddr; in csum_tcpudp_nofold() 98 static inline __sum16 csum_tcpudp_magic(__be32 saddr, __be32 daddr, __u32 len, in csum_tcpudp_magic() argument 101 return csum_fold(csum_tcpudp_nofold(saddr, daddr, len, proto, sum)); in csum_tcpudp_magic() 113 static inline __sum16 csum_ipv6_magic(const struct in6_addr *saddr, in csum_ipv6_magic() argument 119 sum += (__force __u32)saddr->s6_addr32[0]; in csum_ipv6_magic() 120 sum += (__force __u32)saddr->s6_addr32[1]; in csum_ipv6_magic() 121 sum += (__force __u32)saddr->s6_addr32[2]; in csum_ipv6_magic() 122 sum += (__force __u32)saddr->s6_addr32[3]; in csum_ipv6_magic()
|
/openbmc/google-misc/subprojects/ncsid/src/ |
H A D | net_iface.cpp | 106 struct sockaddr_ll saddr; in bind_sock() local 107 std::memset(&saddr, 0, sizeof(saddr)); in bind_sock() 108 saddr.sll_family = AF_PACKET; in bind_sock() 109 saddr.sll_protocol = htons(ETH_P_ALL); in bind_sock() 110 saddr.sll_ifindex = get_index(); in bind_sock() 111 return bind(sockfd, reinterpret_cast<struct sockaddr*>(&saddr), in bind_sock() 112 sizeof(saddr)); in bind_sock()
|
/openbmc/linux/arch/arm/include/asm/ |
H A D | checksum.h | 100 csum_tcpudp_nofold(__be32 saddr, __be32 daddr, __u32 len, in csum_tcpudp_nofold() argument 114 : "r" (daddr), "r" (saddr), "r" (lenprot) in csum_tcpudp_nofold() 127 : "r" (sum), "r" (daddr), "r" (saddr), "r" (lenprot) in csum_tcpudp_nofold() 137 csum_tcpudp_magic(__be32 saddr, __be32 daddr, __u32 len, in csum_tcpudp_magic() argument 140 return csum_fold(csum_tcpudp_nofold(saddr, daddr, len, proto, sum)); in csum_tcpudp_magic() 156 __csum_ipv6_magic(const struct in6_addr *saddr, const struct in6_addr *daddr, __be32 len, 160 csum_ipv6_magic(const struct in6_addr *saddr, const struct in6_addr *daddr, in csum_ipv6_magic() argument 163 return csum_fold(__csum_ipv6_magic(saddr, daddr, htonl(len), in csum_ipv6_magic()
|
/openbmc/linux/tools/testing/selftests/net/ |
H A D | psock_lib.h | 79 struct sockaddr_in saddr, daddr; in pair_udp_open() local 88 memset(&saddr, 0, sizeof(saddr)); in pair_udp_open() 89 saddr.sin_family = AF_INET; in pair_udp_open() 90 saddr.sin_port = htons(port); in pair_udp_open() 91 saddr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); in pair_udp_open() 103 if (bind(fds[0], (void *) &saddr, sizeof(saddr))) { in pair_udp_open()
|
/openbmc/linux/arch/parisc/include/asm/ |
H A D | checksum.h | 74 static inline __wsum csum_tcpudp_nofold(__be32 saddr, __be32 daddr, in csum_tcpudp_nofold() argument 84 : "r" (daddr), "r"(saddr), "r"(proto+len), "0"(sum)); in csum_tcpudp_nofold() 92 static inline __sum16 csum_tcpudp_magic(__be32 saddr, __be32 daddr, in csum_tcpudp_magic() argument 96 return csum_fold(csum_tcpudp_nofold(saddr,daddr,len,proto,sum)); in csum_tcpudp_magic() 110 static __inline__ __sum16 csum_ipv6_magic(const struct in6_addr *saddr, in csum_ipv6_magic() argument 171 : "=r" (sum), "=r" (saddr), "=r" (daddr), "=r" (len), in csum_ipv6_magic() 173 : "0" (sum), "1" (saddr), "2" (daddr), "3" (len) in csum_ipv6_magic()
|
/openbmc/linux/arch/m68k/include/asm/ |
H A D | checksum.h | 82 csum_tcpudp_nofold(__be32 saddr, __be32 daddr, unsigned short len, in csum_tcpudp_nofold() argument 90 : "=&d" (sum), "=d" (saddr) in csum_tcpudp_nofold() 91 : "g" (daddr), "1" (saddr), "d" (len + proto), in csum_tcpudp_nofold() 102 csum_tcpudp_magic(__be32 saddr, __be32 daddr, unsigned short len, in csum_tcpudp_magic() argument 105 return csum_fold(csum_tcpudp_nofold(saddr,daddr,len,proto,sum)); in csum_tcpudp_magic() 120 csum_ipv6_magic(const struct in6_addr *saddr, const struct in6_addr *daddr, in csum_ipv6_magic() argument 143 : "a" (saddr), "a" (daddr), "d" (len + proto), in csum_ipv6_magic()
|