struct sonic_local *lp = (struct sonic_local *) dev->priv; unsigned int base_addr = dev->base_addr; 
struct sonic_local *lp = netdev_priv(dev); 
static void sonic_multicast_list(struct net_device *dev){	struct sonic_local *lp = (struct sonic_local *) dev->priv;	unsigned int base_addr = dev->base_addr;	unsigned int rcr;	struct dev_mc_list *dmi = dev->mc_list;	unsigned char *addr;	int i;	rcr = SONIC_READ(SONIC_RCR) & ~(SONIC_RCR_PRO | SONIC_RCR_AMC);	rcr |= SONIC_RCR_BRD;	/* accept broadcast packets */	if (dev->flags & IFF_PROMISC) {	/* set promiscuous mode */		rcr |= SONIC_RCR_PRO;	} else {		if ((dev->flags & IFF_ALLMULTI) || (dev->mc_count > 15)) {			rcr |= SONIC_RCR_AMC;		} else {			if (sonic_debug > 2)				printk				    ("sonic_multicast_list: mc_count %d\n",				     dev->mc_count);			lp->cda.cam_enable = 1;	/* always enable our own address */			for (i = 1; i <= dev->mc_count; i++) {				addr = dmi->dmi_addr;				dmi = dmi->next;				lp->cda.cam_desc[i].cam_cap0 =				    addr[1] << 8 | addr[0];				lp->cda.cam_desc[i].cam_cap1 =				    addr[3] << 8 | addr[2];				lp->cda.cam_desc[i].cam_cap2 =				    addr[5] << 8 | addr[4];				lp->cda.cam_enable |= (1 << i);			}			SONIC_WRITE(SONIC_CDC, 16);			/* issue Load CAM command */			SONIC_WRITE(SONIC_CDP, lp->cda_laddr & 0xffff);			SONIC_WRITE(SONIC_CMD, SONIC_CR_LCAM);		}	}	if (sonic_debug > 2)		printk("sonic_multicast_list: setting RCR=%x\n", rcr);	SONIC_WRITE(SONIC_RCR, rcr);}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/efcce839360fb3a7b6dedeacaec80f68b0f2d052/sonic.c/clean/drivers/net/sonic.c