david/ipxe
david
/
ipxe
Archived
1
0
Fork 0
This repository has been archived on 2020-12-06. You can view files and clone it, but cannot push or open issues or pull requests.
ipxe/src/include/ipxe/udp.h

46 lines
694 B
C
Raw Normal View History

#ifndef _IPXE_UDP_H
#define _IPXE_UDP_H
2006-06-18 01:34:48 +02:00
/** @file
*
* UDP protocol
*
* This file defines the iPXE UDP API.
2006-06-18 01:34:48 +02:00
*
*/
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
2006-06-18 01:34:48 +02:00
#include <stddef.h>
#include <ipxe/iobuf.h>
#include <ipxe/tcpip.h>
#include <ipxe/if_ether.h>
2006-06-25 07:13:17 +02:00
struct interface;
struct sockaddr;
2006-06-25 07:13:17 +02:00
/**
* UDP constants
*/
/**
* A UDP header
*/
struct udp_header {
/** Source port */
uint16_t src;
/** Destination port */
uint16_t dest;
/** Length */
2006-06-28 09:46:28 +02:00
uint16_t len;
/** Checksum */
2006-06-28 09:46:28 +02:00
uint16_t chksum;
2006-06-25 07:13:17 +02:00
};
2006-06-18 01:34:48 +02:00
extern int udp_open_promisc ( struct interface *xfer );
extern int udp_open ( struct interface *xfer, struct sockaddr *peer,
struct sockaddr *local );
2006-06-25 07:13:17 +02:00
#endif /* _IPXE_UDP_H */