Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 66850
b: refs/heads/master
c: 9ff8c68
h: refs/heads/master
v: v3
  • Loading branch information
Maciej W. Rozycki authored and David S. Miller committed Oct 10, 2007
1 parent 9c40ea6 commit 1ba09f0
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 15 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1f8f4559f8c5829348a010a9e0bbb423310060d1
refs/heads/master: 9ff8c68b3c722f732c7a13d6631b149cca8c7091
24 changes: 12 additions & 12 deletions trunk/drivers/net/phy/phy.c
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,7 @@ int phy_start_aneg(struct phy_device *phydev)
{
int err;

spin_lock(&phydev->lock);
spin_lock_bh(&phydev->lock);

if (AUTONEG_DISABLE == phydev->autoneg)
phy_sanitize_settings(phydev);
Expand All @@ -445,7 +445,7 @@ int phy_start_aneg(struct phy_device *phydev)
}

out_unlock:
spin_unlock(&phydev->lock);
spin_unlock_bh(&phydev->lock);
return err;
}
EXPORT_SYMBOL(phy_start_aneg);
Expand Down Expand Up @@ -490,10 +490,10 @@ void phy_stop_machine(struct phy_device *phydev)
{
del_timer_sync(&phydev->phy_timer);

spin_lock(&phydev->lock);
spin_lock_bh(&phydev->lock);
if (phydev->state > PHY_UP)
phydev->state = PHY_UP;
spin_unlock(&phydev->lock);
spin_unlock_bh(&phydev->lock);

phydev->adjust_state = NULL;
}
Expand Down Expand Up @@ -537,9 +537,9 @@ static void phy_force_reduction(struct phy_device *phydev)
*/
void phy_error(struct phy_device *phydev)
{
spin_lock(&phydev->lock);
spin_lock_bh(&phydev->lock);
phydev->state = PHY_HALTED;
spin_unlock(&phydev->lock);
spin_unlock_bh(&phydev->lock);
}

/**
Expand Down Expand Up @@ -690,10 +690,10 @@ static void phy_change(struct work_struct *work)
if (err)
goto phy_err;

spin_lock(&phydev->lock);
spin_lock_bh(&phydev->lock);
if ((PHY_RUNNING == phydev->state) || (PHY_NOLINK == phydev->state))
phydev->state = PHY_CHANGELINK;
spin_unlock(&phydev->lock);
spin_unlock_bh(&phydev->lock);

enable_irq(phydev->irq);

Expand All @@ -718,7 +718,7 @@ static void phy_change(struct work_struct *work)
*/
void phy_stop(struct phy_device *phydev)
{
spin_lock(&phydev->lock);
spin_lock_bh(&phydev->lock);

if (PHY_HALTED == phydev->state)
goto out_unlock;
Expand All @@ -734,7 +734,7 @@ void phy_stop(struct phy_device *phydev)
}

out_unlock:
spin_unlock(&phydev->lock);
spin_unlock_bh(&phydev->lock);

/*
* Cannot call flush_scheduled_work() here as desired because
Expand Down Expand Up @@ -782,7 +782,7 @@ static void phy_timer(unsigned long data)
int needs_aneg = 0;
int err = 0;

spin_lock(&phydev->lock);
spin_lock_bh(&phydev->lock);

if (phydev->adjust_state)
phydev->adjust_state(phydev->attached_dev);
Expand Down Expand Up @@ -948,7 +948,7 @@ static void phy_timer(unsigned long data)
break;
}

spin_unlock(&phydev->lock);
spin_unlock_bh(&phydev->lock);

if (needs_aneg)
err = phy_start_aneg(phydev);
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/net/phy/phy_device.c
Original file line number Diff line number Diff line change
Expand Up @@ -670,9 +670,9 @@ static int phy_remove(struct device *dev)

phydev = to_phy_device(dev);

spin_lock(&phydev->lock);
spin_lock_bh(&phydev->lock);
phydev->state = PHY_DOWN;
spin_unlock(&phydev->lock);
spin_unlock_bh(&phydev->lock);

if (phydev->drv->remove)
phydev->drv->remove(phydev);
Expand Down

0 comments on commit 1ba09f0

Please sign in to comment.