/linux-4.1.27/net/ipv4/ |
H A D | udp_impl.h | 11 int udp_v4_get_port(struct sock *sk, unsigned short snum);
|
H A D | inet_hashtables.c | 58 * The bindhash mutex for snum's hash chain must be held here. 63 const unsigned short snum) inet_bind_bucket_create() 69 tb->port = snum; inet_bind_bucket_create() 91 const unsigned short snum) inet_bind_hash() 97 inet_sk(sk)->inet_num = snum; inet_bind_hash() 494 const unsigned short snum = inet_sk(sk)->inet_num; __inet_hash_connect() local 501 if (!snum) { __inet_hash_connect() 579 head = &hinfo->bhash[inet_bhashfn(net, snum, hinfo->bhash_size)]; __inet_hash_connect() 589 ret = check_established(death_row, sk, snum, NULL); __inet_hash_connect() 60 inet_bind_bucket_create(struct kmem_cache *cachep, struct net *net, struct inet_bind_hashbucket *head, const unsigned short snum) inet_bind_bucket_create() argument 90 inet_bind_hash(struct sock *sk, struct inet_bind_bucket *tb, const unsigned short snum) inet_bind_hash() argument
|
H A D | inet_connection_sock.c | 91 * if snum is zero it means select any available local port. 93 int inet_csk_get_port(struct sock *sk, unsigned short snum) inet_csk_get_port() argument 104 if (!snum) { inet_csk_get_port() 132 snum = smallest_rover; inet_csk_get_port() 137 snum = rover; inet_csk_get_port() 159 snum = smallest_rover; inet_csk_get_port() 167 snum = rover; inet_csk_get_port() 170 head = &hashinfo->bhash[inet_bhashfn(net, snum, inet_csk_get_port() 174 if (net_eq(ib_net(tb), net) && tb->port == snum) inet_csk_get_port() 208 net, head, snum)) == NULL) inet_csk_get_port() 230 inet_bind_hash(sk, tb, snum); inet_csk_get_port()
|
H A D | udp.c | 204 * @snum: port number to look up 209 int udp_lib_get_port(struct sock *sk, unsigned short snum, udp_lib_get_port() argument 219 if (!snum) { udp_lib_get_port() 239 udp_lib_lport_inuse(net, snum, hslot, bitmap, sk, udp_lib_get_port() 242 snum = first; udp_lib_get_port() 244 * Iterate on all possible values of snum for this hash. udp_lib_get_port() 249 if (low <= snum && snum <= high && udp_lib_get_port() 250 !test_bit(snum >> udptable->log, bitmap) && udp_lib_get_port() 251 !inet_is_local_reserved_port(net, snum)) udp_lib_get_port() 253 snum += rand; udp_lib_get_port() 254 } while (snum != first); udp_lib_get_port() 259 hslot = udp_hashslot(udptable, net, snum); udp_lib_get_port() 263 unsigned int slot2 = udp_sk(sk)->udp_portaddr_hash ^ snum; udp_lib_get_port() 272 exist = udp_lib_lport_inuse2(net, snum, hslot2, udp_lib_get_port() 276 exist = udp_lib_lport_inuse2(net, snum, hslot2, udp_lib_get_port() 285 if (udp_lib_lport_inuse(net, snum, hslot, NULL, sk, udp_lib_get_port() 290 inet_sk(sk)->inet_num = snum; udp_lib_get_port() 291 udp_sk(sk)->udp_port_hash = snum; udp_lib_get_port() 292 udp_sk(sk)->udp_portaddr_hash ^= snum; udp_lib_get_port() 328 int udp_v4_get_port(struct sock *sk, unsigned short snum) udp_v4_get_port() argument 331 udp4_portaddr_hash(sock_net(sk), htonl(INADDR_ANY), snum); udp_v4_get_port() 337 return udp_lib_get_port(sk, snum, ipv4_rcv_saddr_equal, hash2_nulladdr); udp_v4_get_port()
|
H A D | af_inet.c | 430 unsigned short snum; inet_bind() local 471 snum = ntohs(addr->sin_port); inet_bind() 473 if (snum && snum < PROT_SOCK && inet_bind() 496 if (sk->sk_prot->get_port(sk, snum)) { inet_bind() 504 if (snum) inet_bind()
|
H A D | ping.c | 416 unsigned short snum; ping_bind() local 432 snum = ntohs(((struct sockaddr_in *)uaddr)->sin_port); ping_bind() 433 if (ping_get_port(sk, snum) != 0) { ping_bind() 450 if (snum) ping_bind()
|
/linux-4.1.27/net/ipv6/ |
H A D | udp_impl.h | 14 int udp_v6_get_port(struct sock *sk, unsigned short snum);
|
H A D | af_inet6.c | 263 unsigned short snum; inet6_bind() local 281 snum = ntohs(addr->sin6_port); inet6_bind() 282 if (snum && snum < PROT_SOCK && !ns_capable(net->user_ns, CAP_NET_BIND_SERVICE)) inet6_bind() 368 if (sk->sk_prot->get_port(sk, snum)) { inet6_bind() 379 if (snum) inet6_bind()
|
H A D | udp.c | 123 int udp_v6_get_port(struct sock *sk, unsigned short snum) udp_v6_get_port() argument 126 udp6_portaddr_hash(sock_net(sk), &in6addr_any, snum); udp_v6_get_port() 132 return udp_lib_get_port(sk, snum, ipv6_rcv_saddr_equal, hash2_nulladdr); udp_v6_get_port()
|
/linux-4.1.27/arch/powerpc/sysdev/qe_lib/ |
H A D | qe.c | 46 /* QE snum state */ 52 /* QE snum */ 306 int snum = -EBUSY; qe_get_snum() local 313 snum = snums[i].num; qe_get_snum() 319 return snum; qe_get_snum() 323 void qe_put_snum(u8 snum) qe_put_snum() argument 328 if (snums[i].num == snum) { qe_put_snum() 645 num_of_snums = 28; /* The default number of snum for threads is 28 */ qe_get_num_of_snums() 662 pr_err("QE: number of snum is invalid\n"); qe_get_num_of_snums()
|
/linux-4.1.27/fs/reiserfs/ |
H A D | do_balan.c | 941 if (n - tb->snum[i] >= tb->item_pos) { balance_leaf_new_nodes_insert() 943 tb->snum[i], tb->sbytes[i], tb->S_new[i]); balance_leaf_new_nodes_insert() 950 if (tb->item_pos == n - tb->snum[i] + 1 && tb->sbytes[i] != -1) { balance_leaf_new_nodes_insert() 955 /* Move snum[i]-1 items from S[0] to S_new[i] */ balance_leaf_new_nodes_insert() 956 leaf_move_items(LEAF_FROM_S_TO_SNEW, tb, tb->snum[i] - 1, -1, balance_leaf_new_nodes_insert() 1004 * Shift snum[0] - 1 items to S_new[i] balance_leaf_new_nodes_insert() 1008 tb->snum[i] - 1, tb->sbytes[i], tb->S_new[i]); balance_leaf_new_nodes_insert() 1012 leaf_insert_into_buf(&bi, tb->item_pos - n + tb->snum[i] - 1, balance_leaf_new_nodes_insert() 1043 * Shift snum[i]-1 items in whole. balance_leaf_new_nodes_paste_dirent() 1045 * from directory item number snum[i] balance_leaf_new_nodes_paste_dirent() 1047 leaf_move_items(LEAF_FROM_S_TO_SNEW, tb, tb->snum[i], balance_leaf_new_nodes_paste_dirent() 1069 leaf_move_items(LEAF_FROM_S_TO_SNEW, tb, tb->snum[i], balance_leaf_new_nodes_paste_dirent() 1110 leaf_move_items(LEAF_FROM_S_TO_SNEW, tb, tb->snum[i], n_shift, balance_leaf_new_nodes_paste_shift() 1173 leaf_mi = leaf_move_items(LEAF_FROM_S_TO_SNEW, tb, tb->snum[i], balance_leaf_new_nodes_paste_whole() 1182 leaf_paste_in_buffer(&bi, tb->item_pos - n + tb->snum[i], balance_leaf_new_nodes_paste_whole() 1187 tb->snum[i]); balance_leaf_new_nodes_paste_whole() 1189 leaf_paste_entries(&bi, tb->item_pos - n + tb->snum[i], balance_leaf_new_nodes_paste_whole() 1212 if (n - tb->snum[i] > tb->item_pos) { balance_leaf_new_nodes_paste() 1214 tb->snum[i], tb->sbytes[i], tb->S_new[i]); balance_leaf_new_nodes_paste() 1220 if (tb->item_pos == n - tb->snum[i] && tb->sbytes[i] != -1) balance_leaf_new_nodes_paste() 1242 RFALSE(!tb->snum[i], balance_leaf_new_nodes() 1243 "PAP-12200: snum[%d] == %d. Must be > 0", i, balance_leaf_new_nodes() 1244 tb->snum[i]); balance_leaf_new_nodes()
|
H A D | ibalance.c | 1042 int snum; balance_internal() local 1060 snum = (insert_num + n + 1) / 2; balance_internal() 1061 if (n - snum >= child_pos) { balance_internal() 1064 /* new_insert_key = (n - snum)'th key in S[h] */ balance_internal() 1065 memcpy(&new_insert_key, internal_key(tbSh, n - snum), balance_internal() 1069 LAST_TO_FIRST, snum, 0); balance_internal() 1070 } else if (n + insert_num - snum < child_pos) { balance_internal() 1074 * new_insert_key = (n + insert_item - snum)'th balance_internal() 1078 internal_key(tbSh, n + insert_num - snum), balance_internal() 1083 snum - insert_num, 0); balance_internal() 1092 snum - 1, balance_internal() 1106 k = snum - n + child_pos - 1; balance_internal()
|
H A D | prints.c | 676 tb->rbytes, tb->blknum[0], tb->s0num, tb->snum[0], store_print_tb() 677 tb->sbytes[0], tb->snum[1], tb->sbytes[1], store_print_tb()
|
H A D | fix_node.c | 635 tb->snum[0] = *s012++; set_parameters() 636 tb->snum[1] = *s012++; set_parameters()
|
H A D | reiserfs.h | 2508 int snum[2]; member in struct:tree_balance
|
/linux-4.1.27/drivers/isdn/pcbit/ |
H A D | pcbit.h | 30 unsigned char snum; /* used in TData */ member in struct:pcbit_chan
|
H A D | callbacks.c | 71 chan->snum = 0; cb_out_1()
|
/linux-4.1.27/include/net/ |
H A D | udplite.h | 131 int udplite_get_port(struct sock *sk, unsigned short snum,
|
H A D | udp.h | 193 int udp_lib_get_port(struct sock *sk, unsigned short snum, 237 int udp_get_port(struct sock *sk, unsigned short snum,
|
H A D | inet_hashtables.h | 220 const unsigned short snum); 231 const unsigned short snum);
|
H A D | inet_connection_sock.h | 267 int inet_csk_get_port(struct sock *sk, unsigned short snum);
|
H A D | sock.h | 992 int (*get_port)(struct sock *sk, unsigned short snum);
|
/linux-4.1.27/fs/udf/ |
H A D | misc.c | 278 void udf_new_tag(char *data, uint16_t ident, uint16_t version, uint16_t snum, udf_new_tag() argument 284 tptr->tagSerialNum = cpu_to_le16(snum); udf_new_tag()
|
/linux-4.1.27/tools/perf/scripts/python/ |
H A D | event_analyzing_sample.py | 117 snum = '#' * (int)(math.log(num, 2) + 1) 118 return snum
|
/linux-4.1.27/drivers/net/ethernet/freescale/ |
H A D | ucc_geth.c | 278 int snum; fill_init_enet_entries() local 281 if ((snum = qe_get_snum()) < 0) { fill_init_enet_entries() 284 return snum; fill_init_enet_entries() 295 qe_put_snum((u8) snum); fill_init_enet_entries() 300 ((u8) snum << ENET_INIT_PARAM_SNUM_SHIFT) | init_enet_offset fill_init_enet_entries() 315 int snum; return_init_enet_entries() local 323 snum = return_init_enet_entries() 326 qe_put_snum((u8) snum); return_init_enet_entries() 350 int snum; dump_init_enet_entries() local 358 snum = dump_init_enet_entries() 361 qe_put_snum((u8) snum); dump_init_enet_entries() 3846 /* If QE's snum number is 46/76 which means we need to support ucc_geth_probe()
|
/linux-4.1.27/net/sctp/ |
H A D | socket.c | 329 unsigned short snum; sctp_do_bind() local 340 snum = ntohs(addr->v4.sin_port); sctp_do_bind() 343 __func__, sk, &addr->sa, bp->port, snum, len); sctp_do_bind() 354 if (!snum) sctp_do_bind() 355 snum = bp->port; sctp_do_bind() 356 else if (snum != bp->port) { sctp_do_bind() 358 "%d\n", __func__, snum, bp->port); sctp_do_bind() 363 if (snum && snum < PROT_SOCK && sctp_do_bind() 377 addr->v4.sin_port = htons(snum); sctp_do_bind() 6149 struct sctp_bind_hashbucket *head, struct net *, unsigned short snum); 6155 unsigned short snum; sctp_get_port_local() local 6158 snum = ntohs(addr->v4.sin_port); sctp_get_port_local() 6160 pr_debug("%s: begins, snum:%d\n", __func__, snum); sctp_get_port_local() 6164 if (snum == 0) { sctp_get_port_local() 6201 snum = rover; sctp_get_port_local() 6206 * to the port number (snum) - we detect that with the sctp_get_port_local() 6209 head = &sctp_port_hashtable[sctp_phashfn(sock_net(sk), snum)]; sctp_get_port_local() 6212 if ((pp->port == snum) && net_eq(pp->net, sock_net(sk))) sctp_get_port_local() 6265 if (!pp && !(pp = sctp_bucket_create(head, sock_net(sk), snum))) sctp_get_port_local() 6287 inet_sk(sk)->inet_num = snum; sctp_get_port_local() 6301 /* Assign a 'snum' port to the socket. If snum == 0, an ephemeral 6304 static int sctp_get_port(struct sock *sk, unsigned short snum) sctp_get_port() argument 6311 addr.v4.sin_port = htons(snum); sctp_get_port() 6497 struct sctp_bind_hashbucket *head, struct net *net, unsigned short snum) sctp_bucket_create() 6504 pp->port = snum; sctp_bucket_create() 6496 sctp_bucket_create( struct sctp_bind_hashbucket *head, struct net *net, unsigned short snum) sctp_bucket_create() argument
|
/linux-4.1.27/drivers/infiniband/core/ |
H A D | cma.c | 2321 unsigned short snum) cma_alloc_port() 2330 ret = idr_alloc(ps, bind_list, snum, snum + 1, GFP_KERNEL); cma_alloc_port() 2412 unsigned short snum; cma_use_port() local 2415 snum = ntohs(cma_port(cma_src_addr(id_priv))); cma_use_port() 2416 if (snum < PROT_SOCK && !capable(CAP_NET_BIND_SERVICE)) cma_use_port() 2419 bind_list = idr_find(ps, snum); cma_use_port() 2421 ret = cma_alloc_port(ps, id_priv, snum); cma_use_port() 2320 cma_alloc_port(struct idr *ps, struct rdma_id_private *id_priv, unsigned short snum) cma_alloc_port() argument
|
/linux-4.1.27/drivers/bluetooth/ |
H A D | bpa10x.c | 63 __le16 snum; member in struct:hci_vendor_hdr
|
/linux-4.1.27/security/selinux/ |
H A D | hooks.c | 4105 unsigned short snum; selinux_socket_bind() local 4110 snum = ntohs(addr4->sin_port); selinux_socket_bind() 4114 snum = ntohs(addr6->sin6_port); selinux_socket_bind() 4118 if (snum) { selinux_socket_bind() 4123 if (snum < max(PROT_SOCK, low) || snum > high) { selinux_socket_bind() 4125 snum, &sid); selinux_socket_bind() 4130 ad.u.net->sport = htons(snum); selinux_socket_bind() 4164 ad.u.net->sport = htons(snum); selinux_socket_bind() 4200 unsigned short snum; selinux_socket_connect() local 4207 snum = ntohs(addr4->sin_port); selinux_socket_connect() 4212 snum = ntohs(addr6->sin6_port); selinux_socket_connect() 4215 err = sel_netport_sid(sk->sk_protocol, snum, &sid); selinux_socket_connect() 4224 ad.u.net->dport = htons(snum); selinux_socket_connect()
|
/linux-4.1.27/drivers/crypto/ |
H A D | hifn_795x.c | 448 u8 snum; member in struct:hifn_device 1103 unsigned dlen, unsigned slen, u16 mask, u8 snum) hifn_setup_base_command() 1117 base_cmd->session_num = __cpu_to_le16(snum | hifn_setup_base_command() 1193 nbytes, mask, dev->snum); hifn_setup_cmd_desc() 1624 dev->snum++; hifn_setup_session() 1645 static int hifn_test(struct hifn_device *dev, int encdec, u8 snum) hifn_test() argument 1102 hifn_setup_base_command(struct hifn_device *dev, u8 *buf, unsigned dlen, unsigned slen, u16 mask, u8 snum) hifn_setup_base_command() argument
|
/linux-4.1.27/drivers/staging/wlan-ng/ |
H A D | prism2sta.c | 584 u8 snum[HFA384x_RID_NICSERIALNUMBER_LEN]; prism2sta_getcardinfo() local 837 snum, HFA384x_RID_NICSERIALNUMBER_LEN); prism2sta_getcardinfo() 840 HFA384x_RID_NICSERIALNUMBER_LEN, snum); prism2sta_getcardinfo()
|
/linux-4.1.27/arch/powerpc/include/asm/ |
H A D | qe.h | 163 void qe_put_snum(u8 snum);
|
/linux-4.1.27/arch/mips/include/asm/sn/ |
H A D | klconfig.h | 645 } snum; member in struct:klmod_serial_num_s
|