[1495] in linux-net channel archive

home help back first fref pref prev next nref lref last post

Re: 3C590 driver

daemon@ATHENA.MIT.EDU (Craig Metz)
Wed Dec 6 14:16:27 1995

To: Donald Gene Coffin <webguy@connectsoft.com>
Cc: becker@cesdis1.gsfc.nasa.gov, linux-net@vger.rutgers.edu
In-Reply-To: Your message of "Mon, 04 Dec 1995 15:29:37 PST."
             <Pine.LNX.3.91.951204152601.6319N-100000@eidolon.connectsoft.com> 
Date: Tue, 05 Dec 1995 19:20:53 -0500
From: Craig Metz <cmetz@inner.net>

-----BEGIN PGP SIGNED MESSAGE-----

Content-Type: text/plain; charset=us-ascii

In message <Pine.LNX.3.91.951204152601.6319N-100000@eidolon.connectsoft.com>, y
ou write:
>Anybody else played with this?

	I asked Don Becker about this a couple of times and got no response,
so I played with it and (I believe) fixed it myself. Replace the function
set_multicast_list in the Vortex 0.08 driver with this one, fix the prototype
(left as an exercise to the reader ;), and it should work again.

	As an aside, it would be really nice (<hint> Don and Linus!) if this
driver were to get into the standard 1.3.x kernel package - other than this
interface change, it seems pretty stable.

									-Craig

/* Set or clear the multicast filter for this adaptor.
   num_addrs == -1              Promiscuous mode, receive all packets
   num_addrs == 0               Normal mode, clear multicast list
   num_addrs > 0                Multicast mode, receive normal and MC packets, 
and do
                                                best-effort filtering.
 */
static void
set_multicast_list(struct device *dev)
{
        short ioaddr = dev->base_addr;
        if (vortex_debug > 1) {
                struct dev_mc_list *dmi = dev->mc_list;
                unsigned char *addrp;
                static int old = 0;
                if (old != dev->mc_count) {
                        int i,j;
                        old = dev->mc_count;
                        printk("%s: Setting Rx mode to %d addresses.\n ",
                                   dev->name, dev->mc_count);
                        for (i = 0; i < dev->mc_count; i++) {
                                addrp = (unsigned char *)dmi->dmi_addr;
                                for (j = 0; j < 5; j++) { 
                                }
                                printk("%2.2x\n ", *addrp++);
                        }
                }
        }
        if (dev->mc_count || (dev->flags&IFF_ALLMULTI)) {
                outw(SetRxFilter | RxStation | RxMulticast | RxBroadcast, 
ioaddr + EL3_CMD);
        } else if (dev->flags&IFF_PROMISC) {
                outw(SetRxFilter | RxStation | RxMulticast | RxBroadcast | 
RxProm,
                         ioaddr + EL3_CMD);
        } else
                outw(SetRxFilter | RxStation | RxBroadcast, ioaddr + EL3_CMD);
}


-----BEGIN PGP SIGNATURE-----
Version: 2.6.2

iQCVAwUBMMTh5cVlLbS5pqQNAQF5RwP6A5u8qvmdCjfvVHquECwst0S5WCe/JDT8
JSbuoY23ppWavReEdWaIFhW9c14BkHfDmDvJPmqSzM8U4ukG54/IJ8sMK/NqhfSq
m8GR9NwF3xp27/uDcAF24yzhqnmavM773FjmbLdgH+2kKqXIWNwcVEGxeRfDS6hO
1rtQYqXCv88=
=DmGh
-----END PGP SIGNATURE-----

home help back first fref pref prev next nref lref last post