XINU
|
Go to the source code of this file.
Data Structures | |
struct | tftp_msg |
Macros | |
#define | TFTP_ACK 4 /* Acknowledgement */ |
#define | TFTP_DATA 3 /* Data Packet */ |
#define | TFTP_ERROR 5 /* Error */ |
#define | TFTP_ERROR_ACCESS_VIOLATION 2 /* Access violation. */ |
#define | TFTP_ERROR_DISK_FULL 3 /* Disk full or allocation exceeded. */ |
#define | TFTP_ERROR_FILE_EXISTS 6 /* File already exists. */ |
#define | TFTP_ERROR_FILE_NOT_FOUND 1 /* File not found. */ |
#define | TFTP_ERROR_ILLEGAL_OP 4 /* Illegal TFTP operation. */ |
#define | TFTP_ERROR_NO_SUCH_USER 7 /* No such user. */ |
#define | TFTP_ERROR_NOT_DEFINED 0 /* Not defined, see error message (if any). */ |
#define | TFTP_ERROR_UNKNOWN_TRANSFER_ID 5 /* Unknown transfer ID. */ |
#define | TFTP_MAXDATA 512 /* Max size of a data packet */ |
#define | TFTP_MAXNAM 64 /* Max length of a file name */ |
#define | TFTP_MAXRETRIES 3 /* Number of retranmissions */ |
#define | TFTP_NON_VERBOSE 0 /* Do not use verbose output */ |
#define | TFTP_PORT 69 /* UDP Port for TFTP */ |
#define | TFTP_RRQ 1 /* Read Request */ |
#define | TFTP_VERBOSE 1 /* Use verbose output */ |
#define | TFTP_WAIT 5000 /* Time to wait for reply (ms) */ |
#define | TFTP_WRQ 2 /* Write Request */ |
Functions | |
status | tftpget (uint32 serverip, const char *filename, char *rcv_buf, uint32 rcv_buf_size, byte verbose) |
status | tftpget_mb (uint32 serverip, const char *filename, char **rcv_bufs, uint32 *rcv_buf_sizes, uint32 rcv_buf_count, byte verbose) |
#define TFTP_ACK 4 /* Acknowledgement */ |
Definition at line 7 of file tftp.h.
Referenced by tftpget_mb().
#define TFTP_DATA 3 /* Data Packet */ |
Definition at line 6 of file tftp.h.
Referenced by tftp_send1().
#define TFTP_ERROR 5 /* Error */ |
Definition at line 8 of file tftp.h.
Referenced by tftp_send1().
#define TFTP_ERROR_DISK_FULL 3 /* Disk full or allocation exceeded. */ |
#define TFTP_ERROR_UNKNOWN_TRANSFER_ID 5 /* Unknown transfer ID. */ |
#define TFTP_MAXNAM 64 /* Max length of a file name */ |
Definition at line 21 of file tftp.h.
Referenced by tftpget_mb().
#define TFTP_MAXRETRIES 3 /* Number of retranmissions */ |
Definition at line 23 of file tftp.h.
Referenced by tftpget_mb().
#define TFTP_PORT 69 /* UDP Port for TFTP */ |
Definition at line 20 of file tftp.h.
Referenced by tftpget_mb().
#define TFTP_RRQ 1 /* Read Request */ |
Definition at line 4 of file tftp.h.
Referenced by tftpget_mb().
#define TFTP_VERBOSE 1 /* Use verbose output */ |
Definition at line 28 of file tftp.h.
Referenced by tftpget_mb().
#define TFTP_WAIT 5000 /* Time to wait for reply (ms) */ |
Definition at line 24 of file tftp.h.
Referenced by tftp_send1().
status tftpget | ( | uint32 | serverip, |
const char * | filename, | ||
char * | rcv_buf, | ||
uint32 | rcv_buf_size, | ||
byte | verbose | ||
) |
Definition at line 100 of file tftp.c.
References tftpget_mb().
status tftpget_mb | ( | uint32 | serverip, |
const char * | filename, | ||
char ** | rcv_bufs, | ||
uint32 * | rcv_buf_sizes, | ||
uint32 | rcv_buf_count, | ||
byte | verbose | ||
) |
Definition at line 118 of file tftp.c.
References getport(), htons, kprintf(), memset(), NULL, NULLCH, strncpy(), strnlen(), SYSERR, tftp_msg::tf_data, tftp_msg::tf_dblk, tftp_msg::tf_opcode, TFTP_ACK, TFTP_MAXNAM, TFTP_MAXRETRIES, TFTP_PORT, TFTP_RRQ, tftp_send1(), TFTP_VERBOSE, TIMEOUT, udp_register(), udp_release(), and udp_sendto().
Referenced by tftpget().