lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 5 Oct 2007 18:49:49 +0200
From:	Ingo Oeser <netdev@...eo.de>
To:	David Miller <davem@...emloft.net>
Cc:	netdev@...r.kernel.org, Ariel.Hendel@....com, greg.onufer@....com,
	jeff@...zik.org, Ashley.Saulsbury@....com, Matheos.Worku@....com
Subject: Re: [PATCH]: Third (final?) release of Sun Neptune driver

Ingo Oeser schrieb:
> > +static void niu_init_xif(struct niu *);
> > +
> > +static int link_status_10g(struct niu *np, int *link_up_p)
> > +{
> > +	unsigned long flags;
> > +	int err, link_up;
> > +
> > +	if (np->link_config.loopback_mode != LOOPBACK_DISABLED)
> > +		return -EINVAL;
> > +
> > +	link_up = 0;
> > +
> > +	spin_lock_irqsave(&np->lock, flags);
> > +
> > +	err = mdio_read(np, np->phy_addr, BCM8704_PMA_PMD_DEV_ADDR,
> > +			BCM8704_PMD_RCV_SIGDET);
> > +	if (err < 0)
> > +		return err;
> 
> missing spin_unlock_irqsave()?

I mean spin_unlock_irqrestore()

> > +	if (!(err & PMD_RCV_SIGDET_GLOBAL))
> > +		goto out;
> > +
> > +	err = mdio_read(np, np->phy_addr, BCM8704_PCS_DEV_ADDR,
> > +			BCM8704_PCS_10G_R_STATUS);
> > +	if (err < 0)
> > +		return err;
> missing spin_unlock_irqsave()?

I mean spin_unlock_irqrestore()
 
> > +	if (!(err & PCS_10G_R_STATUS_BLK_LOCK))
> > +		goto out;
> > +
> > +	err = mdio_read(np, np->phy_addr, BCM8704_PHYXS_DEV_ADDR,
> > +			BCM8704_PHYXS_XGXS_LANE_STAT);
> > +	if (err < 0)
> > +		return err;
> > +
> > +	if (err != (PHYXS_XGXS_LANE_STAT_ALINGED |
> > +		    PHYXS_XGXS_LANE_STAT_MAGIC |
> > +		    PHYXS_XGXS_LANE_STAT_LANE3 |
> > +		    PHYXS_XGXS_LANE_STAT_LANE2 |
> > +		    PHYXS_XGXS_LANE_STAT_LANE1 |
> > +		    PHYXS_XGXS_LANE_STAT_LANE0))
> > +		goto out;
> > +
> > +	link_up = 1;
> > +	np->link_config.active_speed = SPEED_10000;
> > +	np->link_config.active_duplex = DUPLEX_FULL;
> > +
> > +out:
> > +	spin_unlock_irqrestore(&np->lock, flags);
> > +
> > +	*link_up_p = link_up;
> > +	return 0;
> > +}
> 

Ok, enough for today...

Best Regards

Ingo Oeser
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists