summaryrefslogtreecommitdiffstats
path: root/drivers/net/r8169.c
diff options
context:
space:
mode:
authorIvan Vecera <ivecera@redhat.com>2011-02-15 03:08:39 +0100
committerDavid S. Miller <davem@davemloft.net>2011-02-17 23:09:57 +0100
commit0d672e9f8ac320c6d1ea9103db6df7f99ea20361 (patch)
treefb5c67e5bb769601fc7f762b7e86e10f9b7aa30e /drivers/net/r8169.c
parentixgbe: work around for DDP last buffer size (diff)
downloadlinux-0d672e9f8ac320c6d1ea9103db6df7f99ea20361.tar.xz
linux-0d672e9f8ac320c6d1ea9103db6df7f99ea20361.zip
drivers/net: Call netif_carrier_off at the end of the probe
Without calling of netif_carrier_off at the end of the probe the operstate is unknown when the device is initially opened. By default the carrier is on so when the device is opened and netif_carrier_on is called the link watch event is not fired and operstate remains zero (unknown). This patch fixes this behavior in forcedeth and r8169. Signed-off-by: Ivan Vecera <ivecera@redhat.com> Acked-by: Francois Romieu <romieu@fr.zoreil.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to '')
-rw-r--r--drivers/net/r8169.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c
index 59ccf0c5c610..469ab0b7ce31 100644
--- a/drivers/net/r8169.c
+++ b/drivers/net/r8169.c
@@ -3190,6 +3190,8 @@ rtl8169_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
if (pci_dev_run_wake(pdev))
pm_runtime_put_noidle(&pdev->dev);
+ netif_carrier_off(dev);
+
out:
return rc;