So, given that NetBSD's if_qt.c doesn't do anything with multicast (except setting IFF_MULTICAST, which seems to be a lie), I was looking for the simplest solution. Apart from properly doing multicast, that is. a) I didn't find a simple "receive broadcasts" bit b) neither a simple "receive all multicasts" bit c) so the next best thing seems to be to set the multicast filter wide open, to all 1s. d) doing it properly would mean changing the multicast filter after initialization, which may differ from setting a fixed filter. Something like the below. I haven't tested it, or even thought out yet how to test it (maybe I have to break simh again :)... Index: if_qt.c =================================================================== RCS file: /cvsroot/src/sys/dev/qbus/if_qt.c,v retrieving revision 1.25 diff -u -u -5 -r1.25 if_qt.c --- if_qt.c 29 Jan 2020 05:57:21 -0000 1.25 +++ if_qt.c 11 Dec 2021 19:50:47 -0000 @@ -277,11 +277,11 @@ sc->is_addr[4] = QT_RCSR(8); sc->is_addr[5] = QT_RCSR(10); strcpy(ifp->if_xname, device_xname(sc->sc_dev)); ifp->if_softc = sc; - ifp->if_flags = IFF_BROADCAST|IFF_MULTICAST; + ifp->if_flags = IFF_BROADCAST|IFF_ALLMULTI; ifp->if_ioctl = qtioctl; ifp->if_start = qtstart; ifp->if_init = qtinit; ifp->if_stop = qtstop; IFQ_SET_READY(&ifp->if_snd); @@ -377,10 +377,11 @@ memset(sc->sc_ib, 0, sizeof(struct qt_cdata)); iniblk = &sc->sc_ib->qc_init; iniblk->vector = sc->vector; memcpy(iniblk->paddr, sc->is_addr, 6); + memset(iniblk->laddr, 0xFF, sizeof(iniblk->laddr)); iniblk->options = INIT_OPTIONS_INT; iniblk->rx_lo = loint(&sc->sc_pib->qc_r); iniblk->rx_hi = hiint(&sc->sc_pib->qc_r); iniblk->tx_lo = loint(&sc->sc_pib->qc_t); Does ifp->if_flags indicte a current setting, or a capability? Can something change it behind our back? -Olaf. -- ___ "Buying carbon credits is a bit like a serial killer paying someone else to \X/ have kids to make his activity cost neutral." -The BOFH falu.nl@rhialto
Attachment:
signature.asc
Description: PGP signature