Net: Fix some errors introduced into the ENC28J60 driver; fix type of wd_start arguments.
This commit is contained in:
parent
b5024263e9
commit
216eea4543
|
@ -305,7 +305,8 @@ static int cs89x0_transmit(struct cs89x0_driver_s *cs89x0)
|
|||
|
||||
/* Setup the TX timeout watchdog (perhaps restarting the timer) */
|
||||
|
||||
(void)wd_start(cs89x0->cs_txtimeout, CS89x0_TXTIMEOUT, cs89x0_txtimeout, 1, (uint32_t)cs89x0);
|
||||
(void)wd_start(cs89x0->cs_txtimeout, CS89x0_TXTIMEOUT, cs89x0_txtimeout,
|
||||
1, (wdparm_t)cs89x0);
|
||||
return OK;
|
||||
}
|
||||
|
||||
|
@ -793,7 +794,8 @@ static void cs89x0_polltimer(int argc, uint32_t arg, ...)
|
|||
|
||||
/* Setup the watchdog poll timer again */
|
||||
|
||||
(void)wd_start(cs89x0->cs_txpoll, CS89x0_WDDELAY, cs89x0_polltimer, 1, arg);
|
||||
(void)wd_start(cs89x0->cs_txpoll, CS89x0_WDDELAY, cs89x0_polltimer, 1,
|
||||
(wdparm_t)arg);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
|
@ -826,7 +828,8 @@ static int cs89x0_ifup(struct net_driver_s *dev)
|
|||
|
||||
/* Set and activate a timer process */
|
||||
|
||||
(void)wd_start(cs89x0->cs_txpoll, CS89x0_WDDELAY, cs89x0_polltimer, 1, (uint32_t)cs89x0);
|
||||
(void)wd_start(cs89x0->cs_txpoll, CS89x0_WDDELAY, cs89x0_polltimer, 1,
|
||||
(wdparm_t)cs89x0);
|
||||
|
||||
/* Enable the Ethernet interrupt */
|
||||
|
||||
|
|
|
@ -726,7 +726,8 @@ static int dm9x_transmit(struct dm9x_driver_s *dm9x)
|
|||
|
||||
/* Setup the TX timeout watchdog (perhaps restarting the timer) */
|
||||
|
||||
(void)wd_start(dm9x->dm_txtimeout, DM6X_TXTIMEOUT, dm9x_txtimeout, 1, (uint32_t)dm9x);
|
||||
(void)wd_start(dm9x->dm_txtimeout, DM6X_TXTIMEOUT, dm9x_txtimeout, 1,
|
||||
(wdparm_t)dm9x);
|
||||
return OK;
|
||||
}
|
||||
return -EBUSY;
|
||||
|
@ -1270,7 +1271,8 @@ static void dm9x_polltimer(int argc, uint32_t arg, ...)
|
|||
|
||||
/* Setup the watchdog poll timer again */
|
||||
|
||||
(void)wd_start(dm9x->dm_txpoll, DM6X_WDDELAY, dm9x_polltimer, 1, arg);
|
||||
(void)wd_start(dm9x->dm_txpoll, DM6X_WDDELAY, dm9x_polltimer, 1,
|
||||
(wdparm_t)arg);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
|
@ -1374,7 +1376,8 @@ static int dm9x_ifup(struct net_driver_s *dev)
|
|||
|
||||
/* Set and activate a timer process */
|
||||
|
||||
(void)wd_start(dm9x->dm_txpoll, DM6X_WDDELAY, dm9x_polltimer, 1, (uint32_t)dm9x);
|
||||
(void)wd_start(dm9x->dm_txpoll, DM6X_WDDELAY, dm9x_polltimer, 1,
|
||||
(wdparm_t)dm9x);
|
||||
|
||||
/* Enable the DM9X interrupt */
|
||||
|
||||
|
|
|
@ -453,7 +453,8 @@ static int e1000_transmit(struct e1000_dev *e1000)
|
|||
|
||||
/* Setup the TX timeout watchdog (perhaps restarting the timer) */
|
||||
|
||||
wd_start(e1000->txtimeout, E1000_TXTIMEOUT, e1000_txtimeout, 1, (uint32_t)e1000);
|
||||
wd_start(e1000->txtimeout, E1000_TXTIMEOUT, e1000_txtimeout, 1,
|
||||
(wdparm_t)e1000);
|
||||
return OK;
|
||||
}
|
||||
|
||||
|
@ -773,7 +774,8 @@ static void e1000_polltimer(int argc, uint32_t arg, ...)
|
|||
|
||||
/* Setup the watchdog poll timer again */
|
||||
|
||||
(void)wd_start(e1000->txpoll, E1000_WDDELAY, e1000_polltimer, 1, arg);
|
||||
(void)wd_start(e1000->txpoll, E1000_WDDELAY, e1000_polltimer, 1,
|
||||
(wdparm_t)arg);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
|
@ -807,7 +809,8 @@ static int e1000_ifup(struct net_driver_s *dev)
|
|||
|
||||
/* Set and activate a timer process */
|
||||
|
||||
(void)wd_start(e1000->txpoll, E1000_WDDELAY, e1000_polltimer, 1, (uint32_t)e1000);
|
||||
(void)wd_start(e1000->txpoll, E1000_WDDELAY, e1000_polltimer, 1,
|
||||
(wdparm_t)e1000);
|
||||
|
||||
if (e1000_inl(e1000, E1000_STATUS) & 2)
|
||||
{
|
||||
|
|
|
@ -1145,7 +1145,8 @@ static int enc_transmit(FAR struct enc_driver_s *priv)
|
|||
* the timer is started?
|
||||
*/
|
||||
|
||||
(void)wd_start(priv->txtimeout, ENC_TXTIMEOUT, enc_txtimeout, 1, (uint32_t)priv);
|
||||
(void)wd_start(priv->txtimeout, ENC_TXTIMEOUT, enc_txtimeout, 1,
|
||||
(wdparm_t)priv);
|
||||
return OK;
|
||||
}
|
||||
|
||||
|
@ -1284,7 +1285,8 @@ static void enc_txif(FAR struct enc_driver_s *priv)
|
|||
* interrupted.
|
||||
*/
|
||||
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1, arg);
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1,
|
||||
(wdparm_t)priv);
|
||||
|
||||
/* Then poll uIP for new XMIT data */
|
||||
|
||||
|
@ -1999,7 +2001,8 @@ static void enc_pollworker(FAR void *arg)
|
|||
|
||||
/* Setup the watchdog poll timer again */
|
||||
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1, arg);
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1,
|
||||
(wdparm_t)arg);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
|
@ -2097,7 +2100,8 @@ static int enc_ifup(struct net_driver_s *dev)
|
|||
|
||||
/* Set and activate a timer process */
|
||||
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1, (uint32_t)priv);
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1,
|
||||
(wdparm_t)priv);
|
||||
|
||||
/* Mark the interface up and enable the Ethernet interrupt at the
|
||||
* controller
|
||||
|
|
|
@ -1057,7 +1057,7 @@ static int enc_transmit(FAR struct enc_driver_s *priv)
|
|||
*/
|
||||
|
||||
(void)wd_start(priv->txtimeout, ENC_TXTIMEOUT, enc_txtimeout, 1,
|
||||
(uint32_t)priv);
|
||||
(wdparm_t)priv);
|
||||
|
||||
/* free the descriptor */
|
||||
|
||||
|
@ -1293,7 +1293,8 @@ static void enc_txif(FAR struct enc_driver_s *priv)
|
|||
* interrupted.
|
||||
*/
|
||||
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1, arg);
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1,
|
||||
(wdparm_t)priv);
|
||||
|
||||
/* Poll for TX packets from the networking layer */
|
||||
|
||||
|
@ -2165,7 +2166,7 @@ static void enc_pollworker(FAR void *arg)
|
|||
|
||||
/* Setup the watchdog poll timer again */
|
||||
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1, arg);
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1, (wdparm_t)arg);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
|
@ -2266,7 +2267,8 @@ static int enc_ifup(struct net_driver_s *dev)
|
|||
|
||||
/* Set and activate a timer process */
|
||||
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1, (uint32_t)priv);
|
||||
(void)wd_start(priv->txpoll, ENC_WDDELAY, enc_polltimer, 1,
|
||||
(wdparm_t)priv);
|
||||
|
||||
/* Mark the interface up and enable the Ethernet interrupt at the
|
||||
* controller
|
||||
|
|
|
@ -321,7 +321,7 @@ static int ftmac100_transmit(FAR struct ftmac100_driver_s *priv)
|
|||
/* Setup the TX timeout watchdog (perhaps restarting the timer) */
|
||||
|
||||
(void)wd_start(priv->ft_txtimeout, FTMAC100_TXTIMEOUT,
|
||||
ftmac100_txtimeout_expiry, 1, (uint32_t)priv);
|
||||
ftmac100_txtimeout_expiry, 1, (wdparm_t)priv);
|
||||
|
||||
//irqrestore(flags);
|
||||
return OK;
|
||||
|
@ -846,7 +846,8 @@ static void ftmac100_txdone(FAR struct ftmac100_driver_s *priv)
|
|||
* certain race conditions where the polling sequence can be interrupted.
|
||||
*/
|
||||
|
||||
(void)wd_start(priv->ft_txpoll, FTMAC100_WDDELAY, ftmac100_poll_expiry, 1, priv);
|
||||
(void)wd_start(priv->ft_txpoll, FTMAC100_WDDELAY, ftmac100_poll_expiry, 1,
|
||||
(wdparm_t)priv);
|
||||
|
||||
/* Then poll uIP for new XMIT data */
|
||||
|
||||
|
@ -1203,7 +1204,8 @@ static inline void ftmac100_poll_process(FAR struct ftmac100_driver_s *priv)
|
|||
|
||||
/* Setup the watchdog poll timer again */
|
||||
|
||||
(void)wd_start(priv->ft_txpoll, FTMAC100_WDDELAY, ftmac100_poll_expiry, 1, priv);
|
||||
(void)wd_start(priv->ft_txpoll, FTMAC100_WDDELAY, ftmac100_poll_expiry, 1,
|
||||
(wdparm_t)priv);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
|
@ -1276,7 +1278,8 @@ static void ftmac100_poll_expiry(int argc, uint32_t arg, ...)
|
|||
* cycle.
|
||||
*/
|
||||
|
||||
(void)wd_start(priv->ft_txpoll, FTMAC100_WDDELAY, ftmac100_poll_expiry, 1, arg);
|
||||
(void)wd_start(priv->ft_txpoll, FTMAC100_WDDELAY, ftmac100_poll_expiry,
|
||||
1, (wdparm_t)arg);
|
||||
}
|
||||
|
||||
#else
|
||||
|
@ -1337,7 +1340,8 @@ static int ftmac100_ifup(struct net_driver_s *dev)
|
|||
|
||||
/* Set and activate a timer process */
|
||||
|
||||
(void)wd_start(priv->ft_txpoll, FTMAC100_WDDELAY, ftmac100_poll_expiry, 1, (uint32_t)priv);
|
||||
(void)wd_start(priv->ft_txpoll, FTMAC100_WDDELAY, ftmac100_poll_expiry, 1,
|
||||
(wdparm_t)priv);
|
||||
|
||||
/* Enable the Ethernet interrupt */
|
||||
|
||||
|
|
|
@ -521,7 +521,8 @@ static void vnet_polltimer(int argc, uint32_t arg, ...)
|
|||
|
||||
/* Setup the watchdog poll timer again */
|
||||
|
||||
(void)wd_start(vnet->sk_txpoll, VNET_WDDELAY, vnet_polltimer, 1, arg);
|
||||
(void)wd_start(vnet->sk_txpoll, VNET_WDDELAY, vnet_polltimer, 1,
|
||||
(wdparm_t)arg);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
|
@ -553,7 +554,8 @@ static int vnet_ifup(struct net_driver_s *dev)
|
|||
|
||||
/* Set and activate a timer process */
|
||||
|
||||
(void)wd_start(vnet->sk_txpoll, VNET_WDDELAY, vnet_polltimer, 1, (uint32_t)vnet);
|
||||
(void)wd_start(vnet->sk_txpoll, VNET_WDDELAY, vnet_polltimer, 1,
|
||||
(wdparm_t)vnet);
|
||||
|
||||
vnet->sk_bifup = true;
|
||||
return OK;
|
||||
|
|
Loading…
Reference in New Issue