Searched refs:nb (Results 1 - 25 of 55) sorted by relevance

123

/osnet-11/usr/src/grub/grub2/grub-core/net/
H A Dnetbuff.c25 grub_netbuff_put (struct grub_net_buff *nb, grub_size_t len) argument
27 nb->tail += len;
28 if (nb->tail > nb->end)
34 grub_netbuff_unput (struct grub_net_buff *nb, grub_size_t len) argument
36 nb->tail -= len;
37 if (nb->tail < nb->head)
44 grub_netbuff_push (struct grub_net_buff *nb, grub_size_t len) argument
46 nb
54 grub_netbuff_pull(struct grub_net_buff *nb, grub_size_t len) argument
64 grub_netbuff_reserve(struct grub_net_buff *nb, grub_size_t len) argument
77 struct grub_net_buff *nb; local
97 grub_netbuff_free(struct grub_net_buff *nb) argument
104 grub_netbuff_clear(struct grub_net_buff *nb) argument
[all...]
H A Dicmp.c43 grub_net_recv_icmp_packet (struct grub_net_buff *nb, argument
55 grub_netbuff_free (nb);
59 icmph = (struct icmp_header *) nb->data;
61 if (nb->tail - nb->data < (grub_ssize_t) sizeof (*icmph))
63 grub_netbuff_free (nb);
69 if (checksum != grub_net_ip_chksum (nb->data, nb->tail - nb->data))
76 err = grub_netbuff_pull (nb, sizeo
[all...]
H A Dicmp6.c104 grub_net_recv_icmp6_packet (struct grub_net_buff *nb, argument
116 icmph = (struct icmp_header *) nb->data;
118 if (nb->tail - nb->data < (grub_ssize_t) sizeof (*icmph))
120 grub_netbuff_free (nb);
126 if (checksum != grub_net_ip_transport_checksum (nb,
133 grub_net_ip_transport_checksum (nb,
138 grub_netbuff_free (nb);
143 err = grub_netbuff_pull (nb, sizeof (*icmph));
146 grub_netbuff_free (nb);
442 struct grub_net_buff *nb; local
[all...]
H A Dhttp.c60 ret += pack->nb->tail - pack->nb->data;
162 struct grub_net_buff *nb,
171 char *ptr = (char *) nb->data;
176 ptr = grub_memchr (nb->data, '\n', nb->tail - nb->data);
182 ptr = (char *) nb->tail;
185 data->current_line_len + (ptr - (char *) nb->data));
188 grub_netbuff_free (nb);
161 http_receive(grub_net_tcp_socket_t sock __attribute__ ((unused)), struct grub_net_buff *nb, void *f) argument
285 struct grub_net_buff *nb; local
[all...]
H A Dudp.c35 grub_err_t (*recv_hook) (grub_net_udp_socket_t sock, struct grub_net_buff *nb,
66 struct grub_net_buff *nb,
112 struct grub_net_buff *nb)
119 err = grub_netbuff_push (nb, sizeof (*udph));
123 udph = (struct udphdr *) nb->data;
128 udph->len = grub_cpu_to_be16 (nb->tail - nb->data);
130 udph->chksum = grub_net_ip_transport_checksum (nb, GRUB_NET_IP_UDP,
135 &(socket->ll_target_addr), nb,
140 grub_net_recv_udp_packet (struct grub_net_buff *nb, argument
63 grub_net_udp_open(grub_net_network_level_address_t addr, grub_uint16_t out_port, grub_err_t (*recv_hook) (grub_net_udp_socket_t sock, struct grub_net_buff *nb, void *data), void *recv_hook_data) argument
111 grub_net_send_udp_packet(const grub_net_udp_socket_t socket, struct grub_net_buff *nb) argument
[all...]
H A Dip.c126 struct grub_net_buff * nb,
137 while (nb->tail - nb->data)
143 if ((grub_ssize_t) len > nb->tail - nb->data)
144 len = nb->tail - nb->data;
162 == nb->tail - nb->data)
175 grub_memcpy (iph + 1, nb
124 send_fragmented(struct grub_net_network_level_interface * inf, const grub_net_network_level_address_t * target, struct grub_net_buff * nb, grub_net_ip_protocol_t proto, grub_net_link_level_address_t ll_target_addr) argument
188 grub_net_send_ip4_packet(struct grub_net_network_level_interface *inf, const grub_net_network_level_address_t *target, const grub_net_link_level_address_t *ll_target_addr, struct grub_net_buff *nb, grub_net_ip_protocol_t proto) argument
222 handle_dgram(struct grub_net_buff *nb, struct grub_net_card *card, const grub_net_link_level_address_t *source_hwaddress, const grub_net_link_level_address_t *hwaddress, grub_net_ip_protocol_t proto, const grub_net_network_level_address_t *source, const grub_net_network_level_address_t *dest, grub_uint8_t ttl) argument
340 struct grub_net_buff **nb; local
365 grub_net_recv_ip4_packets(struct grub_net_buff *nb, struct grub_net_card *card, const grub_net_link_level_address_t *hwaddress, const grub_net_link_level_address_t *src_hwaddress) argument
583 grub_net_send_ip6_packet(struct grub_net_network_level_interface *inf, const grub_net_network_level_address_t *target, const grub_net_link_level_address_t *ll_target_addr, struct grub_net_buff *nb, grub_net_ip_protocol_t proto) argument
611 grub_net_send_ip_packet(struct grub_net_network_level_interface *inf, const grub_net_network_level_address_t *target, const grub_net_link_level_address_t *ll_target_addr, struct grub_net_buff *nb, grub_net_ip_protocol_t proto) argument
629 grub_net_recv_ip6_packets(struct grub_net_buff *nb, struct grub_net_card *card, const grub_net_link_level_address_t *hwaddress, const grub_net_link_level_address_t *src_hwaddress) argument
687 grub_net_recv_ip_packets(struct grub_net_buff *nb, struct grub_net_card *card, const grub_net_link_level_address_t *hwaddress, const grub_net_link_level_address_t *src_hwaddress) argument
[all...]
H A Darp.c54 struct grub_net_buff nb; local
73 nb.head = arp_data;
74 nb.end = arp_data + sizeof (arp_data);
75 grub_netbuff_clear (&nb);
76 grub_netbuff_reserve (&nb, 128);
78 err = grub_netbuff_push (&nb, sizeof (*arp_header) + 2 * (6 + addrlen));
82 arp_header = (struct arphdr *) nb.data;
104 nbd = nb.data;
105 send_ethernet_packet (inf, &nb, target_hw_addr, GRUB_NET_ETHERTYPE_ARP);
113 nb
121 grub_net_arp_receive(struct grub_net_buff *nb, struct grub_net_card *card) argument
[all...]
H A Dethernet.c53 struct grub_net_buff *nb,
62 err = grub_netbuff_push (nb, sizeof (*eth));
65 eth = (struct etherhdr *) nb->data;
79 return inf->card->driver->send (inf->card, nb);
83 grub_net_recv_ethernet_packet (struct grub_net_buff *nb, argument
94 eth = (struct etherhdr *) nb->data;
96 err = grub_netbuff_pull (nb, sizeof (*eth));
102 llch = (struct llchdr *) nb->data;
107 err = grub_netbuff_pull (nb, sizeof (*llch));
110 snaph = (struct snaphdr *) nb
52 send_ethernet_packet(struct grub_net_network_level_interface *inf, struct grub_net_buff *nb, grub_net_link_level_address_t target_addr, grub_net_ethertype_t ethertype) argument
[all...]
H A Dtftp.c117 struct grub_net_buff *nb; member in struct:tftp_cmp
126 struct grub_net_buff *a_ = cmpa->nb;
127 struct grub_net_buff *b_ = cmpb->nb;
168 alloc_tftp_cmp(struct grub_net_buff *nb, grub_uint64_t wrapgen) argument
173 rv->nb = nb;
180 struct grub_net_buff *nb,
184 struct tftphdr *tftph = (void *) nb->data;
190 if (nb->tail - nb
179 tftp_receive(grub_net_udp_socket_t sock __attribute__ ((unused)), struct grub_net_buff *nb, void *f) argument
389 struct grub_net_buff nb; local
[all...]
H A Dtcp.c35 struct grub_net_buff *nb; member in struct:unacked
69 grub_err_t (*recv_hook) (grub_net_tcp_socket_t sock, struct grub_net_buff *nb,
175 grub_netbuff_free (unack->nb);
184 tcp_send (struct grub_net_buff *nb, grub_net_tcp_socket_t socket) argument
192 tcph = (struct tcphdr *) nb->data;
195 size = (nb->tail - nb->data - (grub_be_to_cpu16 (tcph->flags) >> 12) * 4);
202 tcph->checksum = grub_net_ip_transport_checksum (nb, GRUB_NET_IP_TCP,
205 nbd = nb->data;
213 unack->nb
411 grub_net_ip_transport_checksum(struct grub_net_buff *nb, grub_uint16_t proto, const grub_net_network_level_address_t *src, const grub_net_network_level_address_t *dst) argument
485 grub_net_tcp_accept(grub_net_tcp_socket_t sock, grub_err_t (*recv_hook) (grub_net_tcp_socket_t sock, struct grub_net_buff *nb, void *data), void (*error_hook) (grub_net_tcp_socket_t sock, void *data), void (*fin_hook) (grub_net_tcp_socket_t sock, void *data), void *hook_data) argument
537 grub_net_tcp_open(char *server, grub_uint16_t out_port, grub_err_t (*recv_hook) (grub_net_tcp_socket_t sock, struct grub_net_buff *nb, void *data), void (*error_hook) (grub_net_tcp_socket_t sock, void *data), void (*fin_hook) (grub_net_tcp_socket_t sock, void *data), void *hook_data) argument
554 struct grub_net_buff *nb; local
676 grub_net_send_tcp_packet(const grub_net_tcp_socket_t socket, struct grub_net_buff *nb, int push) argument
738 grub_net_recv_tcp_packet(struct grub_net_buff *nb, struct grub_net_network_level_interface *inf, const grub_net_network_level_address_t *source) argument
[all...]
H A Ddns.c224 struct grub_net_buff *nb,
235 head = (struct dns_header *) nb->data;
237 if (ptr >= nb->tail)
239 grub_netbuff_free (nb);
245 grub_netbuff_free (nb);
250 grub_netbuff_free (nb);
256 grub_netbuff_free (nb);
261 if (ptr >= nb->tail)
263 grub_netbuff_free (nb);
266 while (ptr < nb
223 recv_hook(grub_net_udp_socket_t sock __attribute__ ((unused)), struct grub_net_buff *nb, void *data_) argument
421 struct grub_net_buff *nb; local
[all...]
/osnet-11/usr/src/lib/libast/common/string/
H A Dstrvcmp.c35 register unsigned long nb; local
41 na = nb = 0;
45 nb = nb * 10 + *b++ - '0';
46 if (na < nb)
48 if (na > nb)
H A Dstrnvcmp.c37 register unsigned long nb; local
53 na = nb = 0;
57 nb = nb * 10 + *b++ - '0';
58 if (na < nb)
60 if (na > nb)
/osnet-11/usr/src/grub/grub2/include/grub/net/
H A Dethernet.h34 struct grub_net_buff *nb,
38 grub_net_recv_ethernet_packet (struct grub_net_buff *nb,
H A Darp.h24 extern grub_err_t grub_net_arp_receive (struct grub_net_buff *nb,
H A Dip.h48 grub_net_recv_ip_packets (struct grub_net_buff *nb,
57 struct grub_net_buff *nb,
61 grub_net_recv_icmp_packet (struct grub_net_buff *nb,
66 grub_net_recv_icmp6_packet (struct grub_net_buff *nb,
74 grub_net_recv_udp_packet (struct grub_net_buff *nb,
78 grub_net_recv_tcp_packet (struct grub_net_buff *nb,
83 grub_net_ip_transport_checksum (struct grub_net_buff *nb,
H A Dudp.h39 struct grub_net_buff *nb,
48 struct grub_net_buff *nb);
H A Dtcp.h34 struct grub_net_buff *nb,
55 struct grub_net_buff *nb,
71 struct grub_net_buff *nb,
/osnet-11/usr/src/grub/grub2/grub-core/net/drivers/emu/
H A Demunet.c65 struct grub_net_buff *nb; local
67 nb = grub_netbuff_alloc (1536);
68 if (!nb)
73 grub_netbuff_reserve (nb, 2);
74 if (!nb)
76 grub_netbuff_free (nb);
80 actual = read (fd, nb->data, 1536);
83 grub_netbuff_free (nb);
86 grub_netbuff_put (nb, actual);
88 return nb;
[all...]
/osnet-11/usr/src/lib/librdc/common/
H A Dnetaddrs.c342 struct netbuf *nb = NULL; local
389 struct netbuf *nb; local
394 nb = &(tbind->addr);
400 nb->len = nb->maxlen = sizeof (struct sockaddr_in6);
404 nb->len = nb->maxlen = sizeof (struct sockaddr_in);
413 nb->buf = (char *)calloc(1, nb->maxlen);
414 if (nb
521 struct netbuf *nb = NULL; local
[all...]
/osnet-11/usr/src/grub/grub-0.97/stage2/
H A Dfsys_ufs.c171 grub_daddr32_t nb, blkno; local
192 nb = INODE->ic_ib[level];
193 if (nb == 0) {
196 if (indirblk0 != nb) {
198 blkno = fsbtodb(SUPERBLOCK, nb);
202 indirblk0 = nb;
206 nb = INDIRBLK0[index];
210 if (indirblk1 != nb) {
211 blkno = fsbtodb(SUPERBLOCK, nb);
215 indirblk1 = nb;
[all...]
/osnet-11/usr/src/lib/libparted/common/libparted/fs/hfs/
H A Dfile_plus.c109 unsigned int nb)
184 ret.sector_count = (sect_size < nb) ? sect_size : nb;
190 unsigned int nb)
197 if (sector+nb < sector /* detect overflow */
198 || sector+nb > file->sect_nb) /* out of file */ {
207 while (nb) {
208 phy_area = hfsplus_file_find_extent(file, sector, nb);
223 nb -= phy_area.sector_count; /* < nb anywa
108 hfsplus_file_find_extent(HfsPPrivateFile* file, PedSector sector, unsigned int nb) argument
189 hfsplus_file_read(HfsPPrivateFile* file, void *buf, PedSector sector, unsigned int nb) argument
232 hfsplus_file_write(HfsPPrivateFile* file, void *buf, PedSector sector, unsigned int nb) argument
[all...]
H A Dfile_plus.h37 PedSector sector, unsigned int nb);
41 PedSector sector, unsigned int nb);
/osnet-11/usr/src/lib/krb5/plugins/kdb/db2/libdb2/btree/
H A Dbt_overflow.c89 size_t nb, plen; local
113 for (p = *buf;; p = (char *)p + nb, pg = h->nextpg) {
117 nb = MIN(sz, plen);
118 memmove(p, (char *)h + BTDATAOFF, nb); local
121 if ((sz -= nb) == 0)
147 size_t nb, plen; local
165 nb = MIN(sz, plen);
166 memmove((char *)h + BTDATAOFF, p, nb);
174 if ((sz -= nb) == 0) {
/osnet-11/usr/src/grub/grub2/grub-core/net/drivers/efi/
H A Definet.c79 struct grub_net_buff *nb; local
89 nb = grub_netbuff_alloc (bufsize);
90 if (!nb)
95 grub_netbuff_reserve (nb, 2);
96 if (!nb)
98 grub_netbuff_free (nb);
103 nb->data, NULL, NULL, NULL);
106 grub_netbuff_free (nb);
110 nb = grub_netbuff_alloc (bufsize);
111 if (!nb)
[all...]

Completed in 109 milliseconds

123