From: till straumann <till.straum...@alumni.tu-berlin.de>

NOTE: apparently we now must use rtems_bsdnet_event_send(). The
combination of rtems_event_send()/rtems_bsdnet_event_receive()
apparently no longer works (rtems-5).

Update #4344
---
 .../beatnik/net/if_mve/mv643xx_eth_bsdnet.c        | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)

diff --git a/bsps/powerpc/beatnik/net/if_mve/mv643xx_eth_bsdnet.c 
b/bsps/powerpc/beatnik/net/if_mve/mv643xx_eth_bsdnet.c
index 308b992479..2bafe09ac7 100644
--- a/bsps/powerpc/beatnik/net/if_mve/mv643xx_eth_bsdnet.c
+++ b/bsps/powerpc/beatnik/net/if_mve/mv643xx_eth_bsdnet.c
@@ -877,6 +877,17 @@ int                                        f;
 
 /* DRIVER TASK */
 
+static void mveth_isr(void *arg)
+{
+struct mveth_softc     *sc = (struct mveth_softc*) arg;
+int                 idx = (sc - &theMvEths[0]);
+       BSP_mve_disable_irqs( sc->pvt );
+#ifdef MVETH_DEBUG
+       printk(DRVNAME": bsdnet isr; posting event %i to 0x%08x\n", idx, 
BSP_mve_get_tid( sc->pvt ));
+#endif
+       rtems_bsdnet_event_send( BSP_mve_get_tid( sc->pvt ), (1<<idx) );
+}
+
 /* Daemon task does all the 'interrupt' work */
 static void mveth_daemon(void *arg)
 {
@@ -997,8 +1008,9 @@ struct     ifnet           *ifp;
                        ifcfg->xbuf_count = MV643XX_TX_RING_SIZE;
                }
 
-               if ( !BSP_mve_setup( unit,
+               if ( !mve_setup_bsd( unit,
                                                     mveth_tid,
+                                    mveth_isr, (void*)sc,
                                                     release_tx_mbuf, ifp,
                                                     alloc_mbuf_rx,
                                                     consume_rx_mbuf, ifp,
-- 
2.26.2

_______________________________________________
devel mailing list
devel@rtems.org
http://lists.rtems.org/mailman/listinfo/devel

Reply via email to