spin_unlock_irq(&tp->lock); 
spin_unlock_bh(&tp->lock); 
static int tg3_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd){	struct mii_ioctl_data *data = if_mii(ifr);	struct tg3 *tp = netdev_priv(dev);	int err;	switch(cmd) {	case SIOCGMIIPHY:		data->phy_id = PHY_ADDR;		/* fallthru */	case SIOCGMIIREG: {		u32 mii_regval;		if (tp->tg3_flags2 & TG3_FLG2_PHY_SERDES)			break;			/* We have no PHY */		spin_lock_irq(&tp->lock);		err = tg3_readphy(tp, data->reg_num & 0x1f, &mii_regval);		spin_unlock_irq(&tp->lock);		data->val_out = mii_regval;		return err;	}	case SIOCSMIIREG:		if (tp->tg3_flags2 & TG3_FLG2_PHY_SERDES)			break;			/* We have no PHY */		if (!capable(CAP_NET_ADMIN))			return -EPERM;		spin_lock_irq(&tp->lock);		err = tg3_writephy(tp, data->reg_num & 0x1f, data->val_in);		spin_unlock_irq(&tp->lock);		return err;	default:		/* do nothing */		break;	}	return -EOPNOTSUPP;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/f47c11eeccc8820010992eb32dbe7370a08f8bd3/tg3.c/buggy/drivers/net/tg3.c