Revision: | 1.1 |
Committed: | 2005-05-13T09:00:59Z (19 years, 6 months ago) by gbeauche |
Content type: | text/plain |
Branch: | MAIN |
CVS Tags: | nigel-build-17 |
Log Message: | slirp user mode network emulation code from qemu |
# | User | Rev | Content |
---|---|---|---|
1 | gbeauche | 1.1 | /* tftp defines */ |
2 | |||
3 | #define TFTP_SESSIONS_MAX 3 | ||
4 | |||
5 | #define TFTP_SERVER 69 | ||
6 | |||
7 | #define TFTP_RRQ 1 | ||
8 | #define TFTP_WRQ 2 | ||
9 | #define TFTP_DATA 3 | ||
10 | #define TFTP_ACK 4 | ||
11 | #define TFTP_ERROR 5 | ||
12 | |||
13 | #define TFTP_FILENAME_MAX 512 | ||
14 | |||
15 | struct tftp_t { | ||
16 | struct ip ip; | ||
17 | struct udphdr udp; | ||
18 | u_int16_t tp_op; | ||
19 | union { | ||
20 | struct { | ||
21 | u_int16_t tp_block_nr; | ||
22 | u_int8_t tp_buf[512]; | ||
23 | } tp_data; | ||
24 | struct { | ||
25 | u_int16_t tp_error_code; | ||
26 | u_int8_t tp_msg[512]; | ||
27 | } tp_error; | ||
28 | u_int8_t tp_buf[512 + 2]; | ||
29 | } x; | ||
30 | }; | ||
31 | |||
32 | void tftp_input(struct mbuf *m); |