summaryrefslogtreecommitdiff
path: root/drivers/net/rtl8169.c
diff options
context:
space:
mode:
authorBin Meng <bmeng.cn@gmail.com>2016-03-17 23:27:44 -0700
committerTom Rini <trini@konsulko.com>2016-03-27 09:12:25 -0400
commitdbe253861a61f7c9407fa52dc6ddd75667b00458 (patch)
tree6fce7c2277c9553178ff02c0f6a961a75a2e933a /drivers/net/rtl8169.c
parent7863ce589105bdcae9c5c45a33458f0d40536b01 (diff)
downloadu-boot-imx-dbe253861a61f7c9407fa52dc6ddd75667b00458.zip
u-boot-imx-dbe253861a61f7c9407fa52dc6ddd75667b00458.tar.gz
u-boot-imx-dbe253861a61f7c9407fa52dc6ddd75667b00458.tar.bz2
net: rtl8169: Fix build error when DEBUG is on
When DEBUG_RTL8169 is on, a build error occurs in function 'rtl_init': error: 'dev' undeclared. Fix this. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Tom Rini <trini@konsulko.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
Diffstat (limited to 'drivers/net/rtl8169.c')
-rw-r--r--drivers/net/rtl8169.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/net/rtl8169.c b/drivers/net/rtl8169.c
index 9e60adf..163b9df 100644
--- a/drivers/net/rtl8169.c
+++ b/drivers/net/rtl8169.c
@@ -995,7 +995,7 @@ static int rtl_init(unsigned long dev_ioaddr, const char *name,
/* Force RTL8169 in 10/100/1000 Full/Half mode. */
if (option > 0) {
#ifdef DEBUG_RTL8169
- printf("%s: Force-mode Enabled.\n", dev->name);
+ printf("%s: Force-mode Enabled.\n", name);
#endif
Cap10_100 = 0, Cap1000 = 0;
switch (option) {
@@ -1027,7 +1027,7 @@ static int rtl_init(unsigned long dev_ioaddr, const char *name,
} else {
#ifdef DEBUG_RTL8169
printf("%s: Auto-negotiation Enabled.\n",
- dev->name);
+ name);
#endif
/* enable 10/100 Full/Half Mode, leave PHY_AUTO_NEGO_REG bit4:0 unchanged */
mdio_write(PHY_AUTO_NEGO_REG,
@@ -1054,12 +1054,12 @@ static int rtl_init(unsigned long dev_ioaddr, const char *name,
if (option & _1000bpsF) {
#ifdef DEBUG_RTL8169
printf("%s: 1000Mbps Full-duplex operation.\n",
- dev->name);
+ name);
#endif
} else {
#ifdef DEBUG_RTL8169
printf("%s: %sMbps %s-duplex operation.\n",
- dev->name,
+ name,
(option & _100bps) ? "100" :
"10",
(option & FullDup) ? "Full" :
@@ -1077,7 +1077,7 @@ static int rtl_init(unsigned long dev_ioaddr, const char *name,
#ifdef DEBUG_RTL8169
printf
("%s: 1000Mbps Full-duplex operation, TBI Link %s!\n",
- dev->name,
+ name,
(RTL_R32(TBICSR) & TBILinkOK) ? "OK" : "Failed");
#endif
}