diff mbox

ucc_geth: Intialize link state to down before register_netdev

Message ID OF3CCCBC69.C8C0BA7E-ON88257E11.005C1D2B-88257E11.005C420A@selinc.com
State Changes Requested, archived
Delegated to: David Miller
Headers show

Commit Message

cliff_clark@selinc.com March 23, 2015, 4:47 p.m. UTC
ucc_geth was indicating link up after a port is administratively enabled 
even 
when nothing is plugged in.  This causes user-space tools to see a 
spurious link 
up the first time after boot.  
  
Signed-off-by: Cliff Clark <cliff_clark@selinc.com>
---
 drivers/net/ethernet/freescale/ucc_geth.c | 3 +++
 1 file changed, 3 insertions(+)

                if (netif_msg_probe(ugeth))

Comments

Yang Li March 23, 2015, 10:03 p.m. UTC | #1
On Mon, Mar 23, 2015 at 11:47 AM,  <cliff_clark@selinc.com> wrote:
> ucc_geth was indicating link up after a port is administratively enabled
> even
> when nothing is plugged in.  This causes user-space tools to see a
> spurious link
> up the first time after boot.
>
> Signed-off-by: Cliff Clark <cliff_clark@selinc.com>

Ack for the change, but the commit message is having messy line breaks.

- Leo
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
David Miller March 24, 2015, 1:41 a.m. UTC | #2
From: Li Yang <leoli@freescale.com>
Date: Mon, 23 Mar 2015 17:03:59 -0500

> On Mon, Mar 23, 2015 at 11:47 AM,  <cliff_clark@selinc.com> wrote:
>> ucc_geth was indicating link up after a port is administratively enabled
>> even
>> when nothing is plugged in.  This causes user-space tools to see a
>> spurious link
>> up the first time after boot.
>>
>> Signed-off-by: Cliff Clark <cliff_clark@selinc.com>
> 
> Ack for the change, but the commit message is having messy line breaks.

Yes, it's really ugly, please fix this.

Don't reply upon a graphical UI or whatever to format these commit
messages properly.  Use a plain ASCII text editor and get the column
breaks right.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/drivers/net/ethernet/freescale/ucc_geth.c 
b/drivers/net/ethernet/freescale/ucc_geth.c
index 357e8b57..56b774d 100644
--- a/drivers/net/ethernet/freescale/ucc_geth.c
+++ b/drivers/net/ethernet/freescale/ucc_geth.c
@@ -3893,6 +3893,9 @@  static int ucc_geth_probe(struct platform_device* 
ofdev)
        ugeth->phy_interface = phy_interface;
        ugeth->max_speed = max_speed;
 
+       /* Carrier starts down, phylib will bring it up */
+       netif_carrier_off(dev);
+
        err = register_netdev(dev);
        if (err) {