Rename ip_eth_hdr to eth_hdr_s
This commit is contained in:
parent
f57024406a
commit
621097b6c8
@ -270,7 +270,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)c5471->c_dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)c5471->c_dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -140,7 +140,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)priv->dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -152,7 +152,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)priv->lp_dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)priv->lp_dev.d_buf)
|
||||
|
||||
/* This is the number of ethernet GPIO pins that must be configured */
|
||||
|
||||
|
@ -243,7 +243,7 @@
|
||||
* header
|
||||
*/
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)priv->dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -248,7 +248,7 @@
|
||||
* header
|
||||
*/
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)priv->dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -308,7 +308,7 @@
|
||||
* header
|
||||
*/
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)priv->dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -174,7 +174,7 @@
|
||||
* header
|
||||
*/
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)priv->dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -552,7 +552,7 @@
|
||||
* header
|
||||
*/
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)priv->dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -151,7 +151,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define ETHBUF ((struct uip_eth_hdr *)priv->ld_dev.d_buf)
|
||||
#define ETHBUF ((struct eth_hdr_s *)priv->ld_dev.d_buf)
|
||||
|
||||
#define TIVA_MAX_MDCCLK 2500000
|
||||
|
||||
|
@ -78,7 +78,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)priv->d_dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)priv->d_dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -213,7 +213,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)priv->pd_dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)priv->pd_dev.d_buf)
|
||||
|
||||
/* PHYs *********************************************************************/
|
||||
/* Select PHY-specific values. Add more PHYs as needed. */
|
||||
|
@ -60,7 +60,7 @@ extern int uipdriver_setmacaddr(unsigned char *macaddr);
|
||||
* Pre-processor Definitions
|
||||
****************************************************************************/
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)&uip_buf[0])
|
||||
#define BUF ((struct eth_hdr_s *)&uip_buf[0])
|
||||
|
||||
#ifndef CONFIG_EXAMPLES_UIP_DHCPC
|
||||
# define UIP_IPADDR (10 << 24 | 0 << 16 | 0 << 8 | 1)
|
||||
|
@ -233,7 +233,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define ETHBUF ((struct uip_eth_hdr *)priv->dev.d_buf)
|
||||
#define ETHBUF ((struct eth_hdr_s *)priv->dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -80,7 +80,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)cs89x0->cs_dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)cs89x0->cs_dev.d_buf)
|
||||
|
||||
/* If there is only one CS89x0 instance, then mapping the CS89x0 IRQ to
|
||||
* a driver state instance is trivial.
|
||||
|
@ -270,7 +270,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)dm9x->dm_dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)dm9x->dm_dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -81,7 +81,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)e1000->uip_dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)e1000->uip_dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -186,7 +186,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)priv->dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
|
||||
|
||||
/* Debug ********************************************************************/
|
||||
|
||||
|
@ -178,7 +178,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)priv->dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)priv->dev.d_buf)
|
||||
|
||||
/* Debug ********************************************************************/
|
||||
|
||||
|
@ -78,7 +78,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)skel->sk_dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)skel->sk_dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -85,7 +85,7 @@
|
||||
|
||||
/* This is a helper pointer for accessing the contents of the Ethernet header */
|
||||
|
||||
#define BUF ((struct uip_eth_hdr *)vnet->sk_dev.d_buf)
|
||||
#define BUF ((struct eth_hdr_s *)vnet->sk_dev.d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
@ -77,7 +77,7 @@
|
||||
* some compilers refuse to pack 6 byte structures.
|
||||
*/
|
||||
|
||||
struct uip_eth_hdr
|
||||
struct eth_hdr_s
|
||||
{
|
||||
uint8_t dest[6]; /* Ethernet destination address (6 bytes) */
|
||||
uint8_t src[6]; /* Ethernet source address (6 bytes) */
|
||||
@ -99,7 +99,8 @@ struct arp_entry
|
||||
|
||||
#ifdef __cplusplus
|
||||
#define EXTERN extern "C"
|
||||
extern "C" {
|
||||
extern "C"
|
||||
{
|
||||
#else
|
||||
#define EXTERN extern
|
||||
#endif
|
||||
|
@ -236,7 +236,7 @@ struct uip_driver_s
|
||||
* Ethernet, you will need to call the uIP ARP code before calling
|
||||
* this function:
|
||||
*
|
||||
* #define BUF ((struct uip_eth_hdr *)&dev->d_buf[0])
|
||||
* #define BUF ((struct eth_hdr_s *)&dev->d_buf[0])
|
||||
* dev->d_len = ethernet_devicedrver_poll();
|
||||
* if (dev->d_len > 0)
|
||||
* {
|
||||
|
@ -80,7 +80,7 @@
|
||||
|
||||
#define RASIZE 4 /* Size of ROUTER ALERT */
|
||||
|
||||
#define ETHBUF ((struct uip_eth_hdr *)&dev->d_buf[0])
|
||||
#define ETHBUF ((struct eth_hdr_s *)&dev->d_buf[0])
|
||||
#define ARPBUF ((struct arp_hdr_s *)&dev->d_buf[UIP_LLH_LEN])
|
||||
#define IPBUF ((struct arp_iphdr_s *)&dev->d_buf[UIP_LLH_LEN])
|
||||
|
||||
@ -253,7 +253,7 @@ void arp_arpin(struct uip_driver_s *dev)
|
||||
|
||||
if (uip_ipaddr_cmp(ipaddr, dev->d_ipaddr))
|
||||
{
|
||||
struct uip_eth_hdr *peth = ETHBUF;
|
||||
struct eth_hdr_s *peth = ETHBUF;
|
||||
|
||||
/* First, we register the one who made the request in our ARP
|
||||
* table, since it is likely that we will do more communication
|
||||
@ -322,7 +322,7 @@ void arp_out(struct uip_driver_s *dev)
|
||||
{
|
||||
const struct arp_entry *tabptr = NULL;
|
||||
struct arp_hdr_s *parp = ARPBUF;
|
||||
struct uip_eth_hdr *peth = ETHBUF;
|
||||
struct eth_hdr_s *peth = ETHBUF;
|
||||
struct arp_iphdr_s *pip = IPBUF;
|
||||
in_addr_t ipaddr;
|
||||
in_addr_t destipaddr;
|
||||
|
@ -207,7 +207,7 @@ void uip_pktfree(struct uip_pkt_conn *conn)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
struct uip_pkt_conn *uip_pktactive(struct uip_eth_hdr *buf)
|
||||
struct uip_pkt_conn *uip_pktactive(struct eth_hdr_s *buf)
|
||||
{
|
||||
#define uip_ethaddr_cmp(addr1, addr2) \
|
||||
((addr1[0] == addr2[0]) && (addr1[1] == addr2[1]) && \
|
||||
|
@ -58,7 +58,7 @@
|
||||
* Pre-processor Definitions
|
||||
****************************************************************************/
|
||||
|
||||
#define PKTBUF ((struct uip_eth_hdr *)&dev->d_buf)
|
||||
#define PKTBUF ((struct eth_hdr_s *)&dev->d_buf)
|
||||
|
||||
/****************************************************************************
|
||||
* Public Variables
|
||||
@ -98,7 +98,7 @@
|
||||
int uip_pktinput(struct uip_driver_s *dev)
|
||||
{
|
||||
struct uip_pkt_conn *conn;
|
||||
struct uip_eth_hdr *pbuf = (struct uip_eth_hdr *)dev->d_buf;
|
||||
struct eth_hdr_s *pbuf = (struct eth_hdr_s *)dev->d_buf;
|
||||
int ret = OK;
|
||||
|
||||
conn = uip_pktactive(pbuf);
|
||||
|
@ -110,7 +110,7 @@ uint16_t uip_callbackexecute(FAR struct uip_driver_s *dev, void *pvconn,
|
||||
void uip_pktinit(void);
|
||||
struct uip_pkt_conn *uip_pktalloc(void);
|
||||
void uip_pktfree(struct uip_pkt_conn *conn);
|
||||
struct uip_pkt_conn *uip_pktactive(struct uip_eth_hdr *buf);
|
||||
struct uip_pkt_conn *uip_pktactive(struct eth_hdr_s *buf);
|
||||
struct uip_pkt_conn *uip_nextpktconn(struct uip_pkt_conn *conn);
|
||||
|
||||
/* Defined in uip_pktcallback.c *********************************************/
|
||||
|
Loading…
Reference in New Issue
Block a user