1 /******************************************************************************
2 * Copyright (c) 2004, 2008 IBM Corporation
4 * This program and the accompanying materials
5 * are made available under the terms of the BSD License
6 * which accompanies this distribution, and is available at
7 * http://www.opensource.org/licenses/bsd-license.php
10 * IBM Corporation - initial implementation
11 *****************************************************************************/
18 #include <netlib/ipv6.h>
29 ip6_addr_t server_ip6;
33 } __attribute__ ((packed)) filename_ip_t ;
36 uint32_t bad_tftp_packets;
38 uint32_t blocks_missed;
39 uint32_t blocks_received;
42 int tftp(filename_ip_t *, unsigned char *, int, unsigned int,
43 tftp_err_t *, int32_t mode, int32_t blocksize, int ip_version);
44 int tftp_netsave(filename_ip_t *, uint8_t * buffer, int len,
45 int use_ci, unsigned int retries, tftp_err_t * tftp_err);
47 int32_t handle_tftp(int fd, uint8_t *, int32_t);
48 void handle_tftp_dun(uint8_t err_code);
49 int parse_tftp_args(char buffer[], char *server_ip, char filename[], int fd, int len);