Skip to content

Commit

Permalink
[netdrvr] b44: handle excessive multicast groups
Browse files Browse the repository at this point in the history
If there are more than B44_MCAST_TABLE_SIZE groups in the dev->mc_list,
it will only listen to the first B44_MCAST_TABLE_SIZE that it sees.

This change makes the driver go into RXCONFIG_ALLMULTI mode if there
are more than B44_MCAST_TABLE_SIZE groups being subscribed to, similar
to other network drivers.

Noticed by Bill Helfinstine <bhelf@flitterfly.whirpon.com>

Signed-off-by: Jeff Garzik <jeff@garzik.org>
  • Loading branch information
Jeff Garzik committed Oct 5, 2006
1 parent 39984a9 commit 2f614fe
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions drivers/net/b44.c
Original file line number Diff line number Diff line change
Expand Up @@ -1706,14 +1706,15 @@ static void __b44_set_rx_mode(struct net_device *dev)

__b44_set_mac_addr(bp);

if (dev->flags & IFF_ALLMULTI)
if ((dev->flags & IFF_ALLMULTI) ||
(dev->mc_count > B44_MCAST_TABLE_SIZE))
val |= RXCONFIG_ALLMULTI;
else
i = __b44_load_mcast(bp, dev);

for (; i < 64; i++) {
for (; i < 64; i++)
__b44_cam_write(bp, zero, i);
}

bw32(bp, B44_RXCONFIG, val);
val = br32(bp, B44_CAM_CTRL);
bw32(bp, B44_CAM_CTRL, val | CAM_CTRL_ENABLE);
Expand Down

0 comments on commit 2f614fe

Please sign in to comment.