git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge to kernel-2.6.20-1.2949.fc6.vs2.2.0.1
[linux-2.6.git]
/
drivers
/
net
/
ibm_emac
/
ibm_emac_phy.c
diff --git
a/drivers/net/ibm_emac/ibm_emac_phy.c
b/drivers/net/ibm_emac/ibm_emac_phy.c
index
67935dd
..
9074f76
100644
(file)
--- a/
drivers/net/ibm_emac/ibm_emac_phy.c
+++ b/
drivers/net/ibm_emac/ibm_emac_phy.c
@@
-12,7
+12,6
@@
* (c) 2004-2005, Eugene Surovegin <ebs@ebshome.net>
*
*/
* (c) 2004-2005, Eugene Surovegin <ebs@ebshome.net>
*
*/
-#include <linux/config.h>
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/types.h>
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/types.h>
@@
-310,7
+309,7
@@
int mii_phy_probe(struct mii_phy *phy, int address)
{
struct mii_phy_def *def;
int i;
{
struct mii_phy_def *def;
int i;
-
u32
id;
+
int
id;
phy->autoneg = AUTONEG_DISABLE;
phy->advertising = 0;
phy->autoneg = AUTONEG_DISABLE;
phy->advertising = 0;
@@
-325,6
+324,8
@@
int mii_phy_probe(struct mii_phy *phy, int address)
/* Read ID and find matching entry */
id = (phy_read(phy, MII_PHYSID1) << 16) | phy_read(phy, MII_PHYSID2);
/* Read ID and find matching entry */
id = (phy_read(phy, MII_PHYSID1) << 16) | phy_read(phy, MII_PHYSID2);
+ if (id < 0)
+ return -ENODEV;
for (i = 0; (def = mii_phy_table[i]) != NULL; i++)
if ((id & def->phy_id_mask) == def->phy_id)
break;
for (i = 0; (def = mii_phy_table[i]) != NULL; i++)
if ((id & def->phy_id_mask) == def->phy_id)
break;