Rename uip_poll->devif_poll and uip_timer->devif_timer

This commit is contained in:
Gregory Nutt 2014-06-30 18:40:41 -06:00
parent b18ac3c778
commit b0c1b7ef47
23 changed files with 109 additions and 108 deletions

View File

@ -958,7 +958,7 @@ static int c5471_transmit(struct c5471_driver_s *c5471)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -1403,7 +1403,7 @@ static void c5471_txdone(struct c5471_driver_s *c5471)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&c5471->c_dev, c5471_uiptxpoll);
(void)devif_poll(&c5471->c_dev, c5471_uiptxpoll);
}
/****************************************************************************
@ -1522,7 +1522,7 @@ static void c5471_txtimeout(int argc, uint32_t arg, ...)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&c5471->c_dev, c5471_uiptxpoll);
(void)devif_poll(&c5471->c_dev, c5471_uiptxpoll);
}
/****************************************************************************
@ -1554,7 +1554,7 @@ static void c5471_polltimer(int argc, uint32_t arg, ...)
{
/* If so, update TCP timing states and poll uIP for new XMIT data */
(void)uip_timer(&c5471->c_dev, c5471_uiptxpoll, C5471_POLLHSEC);
(void)devif_timer(&c5471->c_dev, c5471_uiptxpoll, C5471_POLLHSEC);
}
/* Setup the watchdog poll timer again */
@ -1715,7 +1715,7 @@ static int c5471_txavail(struct net_driver_s *dev)
{
/* If so, then poll uIP for new XMIT data */
(void)uip_poll(&c5471->c_dev, c5471_uiptxpoll);
(void)devif_poll(&c5471->c_dev, c5471_uiptxpoll);
}
}

View File

@ -415,7 +415,7 @@ static int kinetis_transmit(FAR struct kinetis_driver_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -609,7 +609,7 @@ static void kinetis_txdone(FAR struct kinetis_driver_s *priv)
* data
*/
(void)uip_poll(&priv->dev, kinetis_uiptxpoll);
(void)devif_poll(&priv->dev, kinetis_uiptxpoll);
}
/****************************************************************************
@ -722,7 +722,7 @@ static void kinetis_txtimeout(int argc, uint32_t arg, ...)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&priv->dev, kinetis_uiptxpoll);
(void)devif_poll(&priv->dev, kinetis_uiptxpoll);
}
/****************************************************************************
@ -758,7 +758,7 @@ static void kinetis_polltimer(int argc, uint32_t arg, ...)
* we will missing TCP time state updates?
*/
(void)uip_timer(&priv->dev, kinetis_uiptxpoll, KINETIS_POLLHSEC);
(void)devif_timer(&priv->dev, kinetis_uiptxpoll, KINETIS_POLLHSEC);
}
/* Setup the watchdog poll timer again in any case */
@ -973,7 +973,7 @@ static int kinetis_txavail(struct net_driver_s *dev)
* XMIT data.
*/
(void)uip_poll(&priv->dev, kinetis_uiptxpoll);
(void)devif_poll(&priv->dev, kinetis_uiptxpoll);
}
}

View File

@ -647,7 +647,7 @@ static int lpc17_transmit(struct lpc17_driver_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -977,7 +977,7 @@ static void lpc17_txdone(struct lpc17_driver_s *priv)
else
{
(void)uip_poll(&priv->lp_dev, lpc17_uiptxpoll);
(void)devif_poll(&priv->lp_dev, lpc17_uiptxpoll);
}
}
@ -1188,7 +1188,7 @@ static void lpc17_txtimeout(int argc, uint32_t arg, ...)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&priv->lp_dev, lpc17_uiptxpoll);
(void)devif_poll(&priv->lp_dev, lpc17_uiptxpoll);
}
}
@ -1225,7 +1225,7 @@ static void lpc17_polltimer(int argc, uint32_t arg, ...)
* we will missing TCP time state updates?
*/
(void)uip_timer(&priv->lp_dev, lpc17_uiptxpoll, LPC17_POLLHSEC);
(void)devif_timer(&priv->lp_dev, lpc17_uiptxpoll, LPC17_POLLHSEC);
}
/* Setup the watchdog poll timer again */
@ -1482,7 +1482,7 @@ static int lpc17_txavail(struct net_driver_s *dev)
{
/* If so, then poll uIP for new XMIT data */
(void)uip_poll(&priv->lp_dev, lpc17_uiptxpoll);
(void)devif_poll(&priv->lp_dev, lpc17_uiptxpoll);
}
}

View File

@ -789,7 +789,7 @@ static int sam_transmit(struct sam_emac_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -873,7 +873,7 @@ static void sam_dopoll(struct sam_emac_s *priv)
{
/* If we have the descriptor, then poll uIP for new XMIT data. */
(void)uip_poll(dev, sam_uiptxpoll);
(void)devif_poll(dev, sam_uiptxpoll);
}
}
@ -1517,7 +1517,7 @@ static void sam_polltimer(int argc, uint32_t arg, ...)
{
/* Update TCP timing states and poll uIP for new XMIT data. */
(void)uip_timer(dev, sam_uiptxpoll, SAM_POLLHSEC);
(void)devif_timer(dev, sam_uiptxpoll, SAM_POLLHSEC);
}
/* Setup the watchdog poll timer again */

View File

@ -799,7 +799,7 @@ static int sam_transmit(struct sam_emac_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -883,7 +883,7 @@ static void sam_dopoll(struct sam_emac_s *priv)
{
/* If we have the descriptor, then poll uIP for new XMIT data. */
(void)uip_poll(dev, sam_uiptxpoll);
(void)devif_poll(dev, sam_uiptxpoll);
}
}
@ -1558,7 +1558,7 @@ static void sam_polltimer(int argc, uint32_t arg, ...)
{
/* Update TCP timing states and poll uIP for new XMIT data. */
(void)uip_timer(dev, sam_uiptxpoll, SAM_POLLHSEC);
(void)devif_timer(dev, sam_uiptxpoll, SAM_POLLHSEC);
}
/* Setup the watchdog poll timer again */

View File

@ -1114,7 +1114,7 @@ static int sam_transmit(struct sam_emac_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -1198,7 +1198,7 @@ static void sam_dopoll(struct sam_emac_s *priv)
{
/* If we have the descriptor, then poll uIP for new XMIT data. */
(void)uip_poll(dev, sam_uiptxpoll);
(void)devif_poll(dev, sam_uiptxpoll);
}
}
@ -1903,7 +1903,7 @@ static void sam_polltimer(int argc, uint32_t arg, ...)
{
/* Update TCP timing states and poll uIP for new XMIT data. */
(void)uip_timer(dev, sam_uiptxpoll, SAM_POLLHSEC);
(void)devif_timer(dev, sam_uiptxpoll, SAM_POLLHSEC);
}
/* Setup the watchdog poll timer again */

View File

@ -731,7 +731,7 @@ static int sam_transmit(struct sam_gmac_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -815,7 +815,7 @@ static void sam_dopoll(struct sam_gmac_s *priv)
{
/* If we have the descriptor, then poll uIP for new XMIT data. */
(void)uip_poll(dev, sam_uiptxpoll);
(void)devif_poll(dev, sam_uiptxpoll);
}
}
@ -1510,7 +1510,7 @@ static void sam_polltimer(int argc, uint32_t arg, ...)
{
/* Update TCP timing states and poll uIP for new XMIT data. */
(void)uip_timer(dev, sam_uiptxpoll, SAM_POLLHSEC);
(void)devif_timer(dev, sam_uiptxpoll, SAM_POLLHSEC);
}
/* Setup the watchdog poll timer again */

View File

@ -1140,7 +1140,7 @@ static int stm32_transmit(FAR struct stm32_ethmac_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -1266,7 +1266,7 @@ static void stm32_dopoll(FAR struct stm32_ethmac_s *priv)
if (dev->d_buf)
{
(void)uip_poll(dev, stm32_uiptxpoll);
(void)devif_poll(dev, stm32_uiptxpoll);
/* We will, most likely end up with a buffer to be freed. But it
* might not be the same one that we allocated above.
@ -1994,7 +1994,7 @@ static void stm32_polltimer(int argc, uint32_t arg, ...)
/* Update TCP timing states and poll uIP for new XMIT data.
*/
(void)uip_timer(dev, stm32_uiptxpoll, STM32_POLLHSEC);
(void)devif_timer(dev, stm32_uiptxpoll, STM32_POLLHSEC);
/* We will, most likely end up with a buffer to be freed. But it
* might not be the same one that we allocated above.

View File

@ -577,7 +577,7 @@ static int tiva_transmit(struct tiva_driver_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -839,7 +839,7 @@ static void tiva_txdone(struct tiva_driver_s *priv)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&priv->ld_dev, tiva_uiptxpoll);
(void)devif_poll(&priv->ld_dev, tiva_uiptxpoll);
}
/****************************************************************************
@ -963,7 +963,7 @@ static void tiva_txtimeout(int argc, uint32_t arg, ...)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&priv->ld_dev, tiva_uiptxpoll);
(void)devif_poll(&priv->ld_dev, tiva_uiptxpoll);
}
/****************************************************************************
@ -999,7 +999,7 @@ static void tiva_polltimer(int argc, uint32_t arg, ...)
{
/* If so, update TCP timing states and poll uIP for new XMIT data */
(void)uip_timer(&priv->ld_dev, tiva_uiptxpoll, TIVA_POLLHSEC);
(void)devif_timer(&priv->ld_dev, tiva_uiptxpoll, TIVA_POLLHSEC);
/* Setup the watchdog poll timer again */
@ -1285,7 +1285,7 @@ static int tiva_txavail(struct net_driver_s *dev)
* for new Tx data
*/
(void)uip_poll(&priv->ld_dev, tiva_uiptxpoll);
(void)devif_poll(&priv->ld_dev, tiva_uiptxpoll);
}
irqrestore(flags);

View File

@ -183,7 +183,7 @@ static int emac_transmit(FAR struct emac_driver_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -323,7 +323,7 @@ static void emac_txdone(FAR struct emac_driver_s *priv)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&priv->d_dev, emac_uiptxpoll);
(void)devif_poll(&priv->d_dev, emac_uiptxpoll);
}
/****************************************************************************
@ -394,7 +394,7 @@ static void emac_txtimeout(int argc, uint32_t arg, ...)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&priv->d_dev, emac_uiptxpoll);
(void)devif_poll(&priv->d_dev, emac_uiptxpoll);
}
/****************************************************************************
@ -428,7 +428,7 @@ static void emac_polltimer(int argc, uint32_t arg, ...)
* we will missing TCP time state updates?
*/
(void)uip_timer(&priv->d_dev, emac_uiptxpoll, HCS12_POLLHSEC);
(void)devif_timer(&priv->d_dev, emac_uiptxpoll, HCS12_POLLHSEC);
/* Setup the watchdog poll timer again */
@ -554,7 +554,7 @@ static int emac_txavail(struct net_driver_s *dev)
/* If so, then poll uIP for new XMIT data */
(void)uip_poll(&priv->d_dev, emac_uiptxpoll);
(void)devif_poll(&priv->d_dev, emac_uiptxpoll);
}
irqrestore(flags);

View File

@ -1113,7 +1113,7 @@ static int pic32mx_transmit(struct pic32mx_driver_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -1212,7 +1212,7 @@ static void pic32mx_poll(struct pic32mx_driver_s *priv)
/* And perform the poll */
priv->pd_polling = true;
(void)uip_poll(&priv->pd_dev, pic32mx_uiptxpoll);
(void)devif_poll(&priv->pd_dev, pic32mx_uiptxpoll);
/* Free any buffer left attached after the poll */
@ -1258,7 +1258,7 @@ static void pic32mx_timerpoll(struct pic32mx_driver_s *priv)
/* And perform the poll */
priv->pd_polling = true;
(void)uip_timer(&priv->pd_dev, pic32mx_uiptxpoll, PIC32MX_POLLHSEC);
(void)devif_timer(&priv->pd_dev, pic32mx_uiptxpoll, PIC32MX_POLLHSEC);
/* Free any buffer left attached after the poll */

View File

@ -202,7 +202,7 @@ void uipdriver_loop(void)
else if (timer_expired(&g_periodic_timer))
{
timer_reset(&g_periodic_timer);
uip_timer(&g_sim_dev, sim_uiptxpoll, 1);
devif_timer(&g_sim_dev, sim_uiptxpoll, 1);
}
sched_unlock();
}

View File

@ -1048,7 +1048,7 @@ static int ez80emac_transmit(struct ez80emac_driver_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -1578,7 +1578,7 @@ static void ez80emac_txtimeout(int argc, uint32_t arg, ...)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&priv->dev, ez80emac_uiptxpoll);
(void)devif_poll(&priv->dev, ez80emac_uiptxpoll);
}
/****************************************************************************
@ -1604,7 +1604,7 @@ static void ez80emac_polltimer(int argc, uint32_t arg, ...)
/* Poll uIP for new XMIT data */
(void)uip_timer(&priv->dev, ez80emac_uiptxpoll, EMAC_POLLHSEC);
(void)devif_timer(&priv->dev, ez80emac_uiptxpoll, EMAC_POLLHSEC);
/* Setup the watchdog poll timer again */
@ -1791,7 +1791,7 @@ static int ez80emac_txavail(struct net_driver_s *dev)
/* If so, then poll uIP for new XMIT data */
(void)uip_poll(&priv->dev, ez80emac_uiptxpoll);
(void)devif_poll(&priv->dev, ez80emac_uiptxpoll);
}
irqrestore(flags);

View File

@ -311,7 +311,7 @@ static int cs89x0_transmit(struct cs89x0_driver_s *cs89x0)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -518,7 +518,7 @@ static void cs89x0_txdone(struct cs89x0_driver_s *cs89x0, uint16_t isq)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&cs89x0->cs_dev, cs89x0_uiptxpoll);
(void)devif_poll(&cs89x0->cs_dev, cs89x0_uiptxpoll);
}
/****************************************************************************
@ -663,7 +663,7 @@ static void cs89x0_txtimeout(int argc, uint32_t arg, ...)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&cs89x0->cs_dev, cs89x0_uiptxpoll);
(void)devif_poll(&cs89x0->cs_dev, cs89x0_uiptxpoll);
}
/****************************************************************************
@ -692,7 +692,7 @@ static void cs89x0_polltimer(int argc, uint32_t arg, ...)
/* If so, update TCP timing states and poll uIP for new XMIT data */
(void)uip_timer(&cs89x0->cs_dev, cs89x0_uiptxpoll, CS89x0_POLLHSEC);
(void)devif_timer(&cs89x0->cs_dev, cs89x0_uiptxpoll, CS89x0_POLLHSEC);
/* Setup the watchdog poll timer again */
@ -811,7 +811,7 @@ static int cs89x0_txavail(struct net_driver_s *dev)
/* If so, then poll uIP for new XMIT data */
(void)uip_poll(&cs89x0->cs_dev, cs89x0_uiptxpoll);
(void)devif_poll(&cs89x0->cs_dev, cs89x0_uiptxpoll);
}
irqrestore(flags);

View File

@ -823,7 +823,7 @@ static int dm9x_transmit(struct dm9x_driver_s *dm9x)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the DM90x0 is reset
@ -1086,7 +1086,7 @@ static void dm9x_txdone(struct dm9x_driver_s *dm9x)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&dm9x->dm_dev, dm9x_uiptxpoll);
(void)devif_poll(&dm9x->dm_dev, dm9x_uiptxpoll);
}
/****************************************************************************
@ -1249,7 +1249,7 @@ static void dm9x_txtimeout(int argc, uint32_t arg, ...)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&dm9x->dm_dev, dm9x_uiptxpoll);
(void)devif_poll(&dm9x->dm_dev, dm9x_uiptxpoll);
}
/****************************************************************************
@ -1291,7 +1291,7 @@ static void dm9x_polltimer(int argc, uint32_t arg, ...)
{
/* If so, update TCP timing states and poll uIP for new XMIT data */
(void)uip_timer(&dm9x->dm_dev, dm9x_uiptxpoll, DM6X_POLLHSEC);
(void)devif_timer(&dm9x->dm_dev, dm9x_uiptxpoll, DM6X_POLLHSEC);
}
/* Setup the watchdog poll timer again */
@ -1499,7 +1499,7 @@ static int dm9x_txavail(struct net_driver_s *dev)
{
/* If so, then poll uIP for new XMIT data */
(void)uip_poll(&dm9x->dm_dev, dm9x_uiptxpoll);
(void)devif_poll(&dm9x->dm_dev, dm9x_uiptxpoll);
}
}
irqrestore(flags);

View File

@ -457,7 +457,7 @@ static int e1000_transmit(struct e1000_dev *e1000)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -641,7 +641,7 @@ static void e1000_txtimeout(int argc, uint32_t arg, ...)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&e1000->netdev, e1000_uiptxpoll);
(void)devif_poll(&e1000->netdev, e1000_uiptxpoll);
}
/****************************************************************************
@ -681,7 +681,7 @@ static void e1000_polltimer(int argc, uint32_t arg, ...)
* we will missing TCP time state updates?
*/
(void)uip_timer(&e1000->netdev, e1000_uiptxpoll, E1000_POLLHSEC);
(void)devif_timer(&e1000->netdev, e1000_uiptxpoll, E1000_POLLHSEC);
/* Setup the watchdog poll timer again */
@ -819,7 +819,7 @@ static int e1000_txavail(struct net_driver_s *dev)
if (e1000->tx_ring.desc[tail].desc_status)
{
(void)uip_poll(&e1000->netdev, e1000_uiptxpoll);
(void)devif_poll(&e1000->netdev, e1000_uiptxpoll);
}
}
@ -938,7 +938,7 @@ static irqreturn_t e1000_interrupt_handler(int irq, void *dev_id)
if (intr_cause & (1<<0))
{
uip_poll(&e1000->netdev, e1000_uiptxpoll);
devif_poll(&e1000->netdev, e1000_uiptxpoll);
}

View File

@ -1167,7 +1167,7 @@ static int enc_transmit(FAR struct enc_driver_s *priv)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -1276,7 +1276,7 @@ static void enc_txif(FAR struct enc_driver_s *priv)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&priv->dev, enc_uiptxpoll);
(void)devif_poll(&priv->dev, enc_uiptxpoll);
}
/****************************************************************************
@ -1835,7 +1835,7 @@ static void enc_toworker(FAR void *arg)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&priv->dev, enc_uiptxpoll);
(void)devif_poll(&priv->dev, enc_uiptxpoll);
/* Release lock on uIP */
@ -1924,7 +1924,7 @@ static void enc_pollworker(FAR void *arg)
* in progress, we will missing TCP time state updates?
*/
(void)uip_timer(&priv->dev, enc_uiptxpoll, ENC_POLLHSEC);
(void)devif_timer(&priv->dev, enc_uiptxpoll, ENC_POLLHSEC);
}
/* Release lock on the SPI bus and uIP */
@ -2144,7 +2144,7 @@ static int enc_txavail(struct net_driver_s *dev)
{
/* The interface is up and TX is idle; poll uIP for new XMIT data */
(void)uip_poll(&priv->dev, enc_uiptxpoll);
(void)devif_poll(&priv->dev, enc_uiptxpoll);
}
}

View File

@ -1179,7 +1179,7 @@ static int enc_txenqueue(FAR struct enc_driver_s *priv)
*
* Description:
* Enqueues uIP packets if available.
* This is a callback from uip_poll(). uip_poll() may be called:
* This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timedout and the interface is reset
@ -1305,7 +1305,7 @@ static void enc_txif(FAR struct enc_driver_s *priv)
/* Poll for uip packets */
uip_poll(&priv->dev, enc_uiptxpoll);
devif_poll(&priv->dev, enc_uiptxpoll);
}
else
{
@ -2005,7 +2005,7 @@ static void enc_toworker(FAR void *arg)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&priv->dev, enc_uiptxpoll);
(void)devif_poll(&priv->dev, enc_uiptxpoll);
/* Release uIP */
@ -2095,7 +2095,7 @@ static void enc_pollworker(FAR void *arg)
* in progress, we will missing TCP time state updates?
*/
(void)uip_timer(&priv->dev, enc_uiptxpoll, ENC_POLLHSEC);
(void)devif_timer(&priv->dev, enc_uiptxpoll, ENC_POLLHSEC);
}
/* Release lock on the SPI bus and uIP */
@ -2321,7 +2321,7 @@ static int enc_txavail(struct net_driver_s *dev)
{
/* The interface is up and TX is idle; poll uIP for new XMIT data */
(void)uip_poll(&priv->dev, enc_uiptxpoll);
(void)devif_poll(&priv->dev, enc_uiptxpoll);
}
}

View File

@ -183,7 +183,7 @@ static int skel_transmit(FAR struct skel_driver_s *skel)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -323,7 +323,7 @@ static void skel_txdone(FAR struct skel_driver_s *skel)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&skel->sk_dev, skel_uiptxpoll);
(void)devif_poll(&skel->sk_dev, skel_uiptxpoll);
}
/****************************************************************************
@ -394,7 +394,7 @@ static void skel_txtimeout(int argc, uint32_t arg, ...)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&skel->sk_dev, skel_uiptxpoll);
(void)devif_poll(&skel->sk_dev, skel_uiptxpoll);
}
/****************************************************************************
@ -428,7 +428,7 @@ static void skel_polltimer(int argc, uint32_t arg, ...)
* we will missing TCP time state updates?
*/
(void)uip_timer(&skel->sk_dev, skel_uiptxpoll, skeleton_POLLHSEC);
(void)devif_timer(&skel->sk_dev, skel_uiptxpoll, skeleton_POLLHSEC);
/* Setup the watchdog poll timer again */
@ -554,7 +554,7 @@ static int skel_txavail(struct net_driver_s *dev)
/* If so, then poll uIP for new XMIT data */
(void)uip_poll(&skel->sk_dev, skel_uiptxpoll);
(void)devif_poll(&skel->sk_dev, skel_uiptxpoll);
}
irqrestore(flags);

View File

@ -402,7 +402,7 @@ static int slip_transmit(FAR struct slip_driver_s *priv)
*
* Description:
* Check if uIP has any outgoing packets ready to send. This is a
* callback from uip_poll(). uip_poll() may be called:
* callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete, or
* 2. When the preceding TX packet send times o ]ut and the interface is reset
@ -495,7 +495,7 @@ static void slip_txtask(int argc, char *argv[])
flags = net_lock();
priv->dev.d_buf = priv->txbuf;
(void)uip_timer(&priv->dev, slip_uiptxpoll, SLIP_POLLHSEC);
(void)devif_timer(&priv->dev, slip_uiptxpoll, SLIP_POLLHSEC);
net_unlock(flags);
slip_semgive(priv);
}

View File

@ -202,7 +202,7 @@ static int vnet_transmit(FAR struct vnet_driver_s *vnet)
*
* Description:
* The transmitter is available, check if uIP has any outgoing packets ready
* to send. This is a callback from uip_poll(). uip_poll() may be called:
* to send. This is a callback from devif_poll(). devif_poll() may be called:
*
* 1. When the preceding TX packet send is complete,
* 2. When the preceding TX packet send timesout and the interface is reset
@ -345,7 +345,7 @@ static void vnet_txdone(FAR struct vnet_driver_s *vnet)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&vnet->sk_dev, vnet_uiptxpoll);
(void)devif_poll(&vnet->sk_dev, vnet_uiptxpoll);
}
/****************************************************************************
@ -377,7 +377,7 @@ static void vnet_txtimeout(int argc, uint32_t arg, ...)
/* Then poll uIP for new XMIT data */
(void)uip_poll(&vnet->sk_dev, vnet_uiptxpoll);
(void)devif_poll(&vnet->sk_dev, vnet_uiptxpoll);
}
/****************************************************************************
@ -417,7 +417,7 @@ static void vnet_polltimer(int argc, uint32_t arg, ...)
* we will missing TCP time state updates?
*/
(void)uip_timer(&vnet->sk_dev, vnet_uiptxpoll, VNET_POLLHSEC);
(void)devif_timer(&vnet->sk_dev, vnet_uiptxpoll, VNET_POLLHSEC);
/* Setup the watchdog poll timer again */
@ -545,7 +545,7 @@ static int vnet_txavail(struct net_driver_s *dev)
/* If so, then poll uIP for new XMIT data */
(void)uip_poll(&vnet->sk_dev, vnet_uiptxpoll);
(void)devif_poll(&vnet->sk_dev, vnet_uiptxpoll);
}
out:

View File

@ -163,8 +163,8 @@ struct net_driver_s
uint16_t d_len;
/* When d_buf contains outgoing xmit data, d_sndlen is nonzero and represents
* the amount of appllcation data after d_snddata
/* When d_buf contains outgoing xmit data, d_sndlen is non-zero and represents
* the amount of application data after d_snddata
*/
uint16_t d_sndlen;
@ -196,6 +196,8 @@ struct net_driver_s
void *d_private;
};
typedef int (*devif_poll_callback_t)(struct net_driver_s *dev);
/****************************************************************************
* Public Variables
****************************************************************************/
@ -268,15 +270,15 @@ int devif_input(struct net_driver_s *dev);
/* Polling of connections
*
* These functions will traverse each active uIP connection structure and
* perform appropriate operatios: uip_timer() will perform TCP timer
* operations (and UDP polling operations); uip_poll() will perform TCP
* perform appropriate operations: devif_timer() will perform TCP timer
* operations (and UDP polling operations); devif_poll() will perform TCP
* and UDP polling operations. The CAN driver MUST implement logic to
* periodically call uip_timer(); uip_poll() may be called asychronously
* periodically call devif_timer(); devif_poll() may be called asynchronously
* from the network driver can accept another outgoing packet.
*
* In both cases, these functions will call the provided callback function
* for every active connection. Polling will continue until all connections
* have been polled or until the user-suplied function returns a non-zero
* have been polled or until the user-supplied function returns a non-zero
* value (which it should do only if it cannot accept further write data).
*
* When the callback function is called, there may be an outbound packet
@ -296,7 +298,7 @@ int devif_input(struct net_driver_s *dev);
* }
*
* ...
* uip_poll(dev, driver_callback);
* devif_poll(dev, driver_callback);
*
* Note: If you are writing a uIP device driver that needs ARP (Address
* Resolution Protocol), e.g., when running uIP over Ethernet, you will
@ -315,9 +317,8 @@ int devif_input(struct net_driver_s *dev);
* }
*/
typedef int (*uip_poll_callback_t)(struct net_driver_s *dev);
int uip_poll(struct net_driver_s *dev, uip_poll_callback_t callback);
int uip_timer(struct net_driver_s *dev, uip_poll_callback_t callback, int hsec);
int devif_poll(struct net_driver_s *dev, devif_poll_callback_t callback);
int devif_timer(struct net_driver_s *dev, devif_poll_callback_t callback, int hsec);
/* Carrier detection
* Call netdev_carrier_on when the carrier has become available and the device

View File

@ -75,7 +75,7 @@
#if defined(CONFIG_NET_PKT)
static int devif_poll_pkt_connections(FAR struct net_driver_s *dev,
uip_poll_callback_t callback)
devif_poll_callback_t callback)
{
FAR struct pkt_conn_s *pkt_conn = NULL;
int bstop = 0;
@ -111,7 +111,7 @@ static int devif_poll_pkt_connections(FAR struct net_driver_s *dev,
#if defined(CONFIG_NET_ICMP) && defined(CONFIG_NET_ICMP_PING)
static inline int devif_poll_icmp(FAR struct net_driver_s *dev,
uip_poll_callback_t callback)
devif_poll_callback_t callback)
{
/* Perform the UDP TX poll */
@ -137,7 +137,7 @@ static inline int devif_poll_icmp(FAR struct net_driver_s *dev,
#ifdef CONFIG_NET_IGMP
static inline int devif_poll_igmp(FAR struct net_driver_s *dev,
uip_poll_callback_t callback)
devif_poll_callback_t callback)
{
/* Perform the IGMP TX poll */
@ -163,7 +163,7 @@ static inline int devif_poll_igmp(FAR struct net_driver_s *dev,
#ifdef CONFIG_NET_UDP
static int devif_poll_udp_connections(FAR struct net_driver_s *dev,
uip_poll_callback_t callback)
devif_poll_callback_t callback)
{
FAR struct udp_conn_s *conn = NULL;
int bstop = 0;
@ -199,7 +199,7 @@ static int devif_poll_udp_connections(FAR struct net_driver_s *dev,
#ifdef CONFIG_NET_TCP
static inline int devif_poll_tcp_connections(FAR struct net_driver_s *dev,
uip_poll_callback_t callback)
devif_poll_callback_t callback)
{
FAR struct tcp_conn_s *conn = NULL;
int bstop = 0;
@ -238,7 +238,7 @@ static inline int devif_poll_tcp_connections(FAR struct net_driver_s *dev,
#ifdef CONFIG_NET_TCP
static inline int devif_poll_tcp_timer(FAR struct net_driver_s *dev,
uip_poll_callback_t callback, int hsec)
devif_poll_callback_t callback, int hsec)
{
FAR struct tcp_conn_s *conn = NULL;
int bstop = 0;
@ -267,11 +267,11 @@ static inline int devif_poll_tcp_timer(FAR struct net_driver_s *dev,
****************************************************************************/
/****************************************************************************
* Function: uip_poll
* Function: devif_poll
*
* Description:
* This function will traverse each active uIP connection structure and
* will perform TCP and UDP polling operations. uip_poll() may be called
* will perform TCP and UDP polling operations. devif_poll() may be called
* asynchronously with the network driver can accept another outgoing
* packet.
*
@ -291,7 +291,7 @@ static inline int devif_poll_tcp_timer(FAR struct net_driver_s *dev,
*
****************************************************************************/
int uip_poll(FAR struct net_driver_s *dev, uip_poll_callback_t callback)
int devif_poll(FAR struct net_driver_s *dev, devif_poll_callback_t callback)
{
int bstop;
@ -343,12 +343,12 @@ int uip_poll(FAR struct net_driver_s *dev, uip_poll_callback_t callback)
}
/****************************************************************************
* Function: uip_timer
* Function: devif_timer
*
* Description:
* These function will traverse each active uIP connection structure and
* perform TCP timer operations (and UDP polling operations). The Ethernet
* driver MUST implement logic to periodically call uip_timer().
* driver MUST implement logic to periodically call devif_timer().
*
* This function will call the provided callback function for every active
* connection. Polling will continue until all connections have been polled
@ -366,8 +366,8 @@ int uip_poll(FAR struct net_driver_s *dev, uip_poll_callback_t callback)
*
****************************************************************************/
int uip_timer(FAR struct net_driver_s *dev, uip_poll_callback_t callback,
int hsec)
int devif_timer(FAR struct net_driver_s *dev, devif_poll_callback_t callback,
int hsec)
{
int bstop;