From owner-freebsd-embedded@FreeBSD.ORG Fri Aug 23 20:28:06 2013 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 2949B16F for ; Fri, 23 Aug 2013 20:28:06 +0000 (UTC) (envelope-from hapvbk@yahoo.co.uk) Received: from nm5-vm0.bullet.mail.ird.yahoo.com (nm5-vm0.bullet.mail.ird.yahoo.com [77.238.189.207]) by mx1.freebsd.org (Postfix) with SMTP id 1360421EA for ; Fri, 23 Aug 2013 20:28:04 +0000 (UTC) Received: from [77.238.189.236] by nm5.bullet.mail.ird.yahoo.com with NNFMP; 23 Aug 2013 20:28:03 -0000 Received: from [212.82.108.253] by tm17.bullet.mail.ird.yahoo.com with NNFMP; 23 Aug 2013 20:28:03 -0000 Received: from [127.0.0.1] by omp1018.mail.ird.yahoo.com with NNFMP; 23 Aug 2013 20:28:03 -0000 X-Yahoo-Newman-Property: ymail-3 X-Yahoo-Newman-Id: 538960.43396.bm@omp1018.mail.ird.yahoo.com Received: (qmail 4475 invoked by uid 60001); 23 Aug 2013 20:28:03 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.co.uk; s=s1024; t=1377289683; bh=eRt+7nlQbSoJxRyP7SnTdIhwu/2PiZvj6wBZHvap15s=; h=X-YMail-OSG:Received:X-Rocket-MIMEInfo:X-Mailer:Message-ID:Date:From:Reply-To:Subject:To:MIME-Version:Content-Type; b=A/Qy7QcrG6l1AsS9idvBMh0ULobehiCeQwQgMTwcNOpPb5s6utSJc8gstTm/4IBD7tdbrlt/d0ssmU3dXISlCW7iRbktqvI2JR6Y9QnSWnuZ9mR09f5WuaYZsSIHNoBWbM5smlMc0MfgeFI6jea6SKcskMTkAGeV4LwAq3gJBnM= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.co.uk; h=X-YMail-OSG:Received:X-Rocket-MIMEInfo:X-Mailer:Message-ID:Date:From:Reply-To:Subject:To:MIME-Version:Content-Type; b=Bvdv8kxwqE+QBT4ELHznjMswnW37uMc9GXtlo4OdfItVJYiYn7Le9EZX8NA/giZvo5T/AiYJr7UlK8O1OYCyMvmok2rYX009gp+A/gJxDrwYdqC9SsBl7S5HVCeSYWUhYfx/9VBSYRKmK6IY46gL5BOIvAFr/2w/dQDmbHgqo6M=; X-YMail-OSG: hpbFzAgVM1nyuwmDdWeKy6hDX7RQyLl.7WWwfD0fcLUW4L3 aS9y4pKqyvurtgjBdrfqF5ndQYJBda.ga23KctR0K8ni8WY08UFhEQhjUEpc toVwX4me.Zn3RKK2syRM5eC5A8kQarFJYAWnYamwkkFlOW1jaNY1vceP7gT1 qi1XZgOhspTof7.sj9AMCEOt9R.SIhoQLvEk1DGwjmY..ZmLli7SgtKLrVxl 0S.zLY3RrDSNggRYBoAovS.5PPivvDeD8qbUzEClXLRLx.K4lSU7kiBwA3.p yV_emUdXNvYBS8GKDNmPYjEfGSsrClu55flc11SN.CTit5xRFyfiVHDgnzXI HbrkXAiH1AuJPux04N2usNlzlt9CC8L2fwSZEsNfTn.L1L8QjMENby27p7gI dtfKZEabdSfxtVNoevMmTYgEs92ASl72R8hLQIWMN9CGs0pWyy2RwhFeb6ob AycDrHwUt8_t1x2umL1ynCifY0AHiVa8N0nn257IyCuQWXxjFtuYZN6jSLGA xKIqNUMhTNScYB5Ep.0Hd1WcIFEUqBBI1_wAFK.QqApdM15sVGgMIRfydqC9 OGTw2LcK6ZMA7dKfcVdENf81dQaMaGAL4_j70DYK5pAhVn.getyhRi2TQ5aU a06_ORdHGZuZTYQOeCPt6QX790XDhbIohZdc.6w48W2lpF2vQycHrWy99_lP K Received: from [204.138.59.246] by web171205.mail.ir2.yahoo.com via HTTP; Fri, 23 Aug 2013 21:28:03 BST X-Rocket-MIMEInfo: 002.001, SGkgdGhlcmUsCgpJIGFtIHJ1bm5pbmcgbmFub2JzZCBvbiBhIE1JUFMgcGxhdGZvcm0sIHdoaWNoIGlzIGFuIEFSNzE2MSBDUFUgd2l0aCBBUjgzMTYgc3dpdGNoLiBCb3RoIGFyZ2UgaW50ZXJmYWNlcyBzaG93IHVwIGhvd2V2ZXIgdGhlIGxpbmsgc3RhdHVzIGlzIG5vdCBjb3JyZWN0bHkgdXBkYXRlZC7CoAoKYXJnZTEgKHRoZSBXQU4gaW50ZXJmYWNlKSBhbHdheXMgc2hvdyBhY3RpdmUsIGV2ZW4gdGhlcmUgaXMgbm8gZXRoZXJuZXQgY2FibGUgcGx1Z2dlZCBpbi7CoAoKSW4gYSBwb3N0LCBBZHJpYW4gbWUBMAEBAQE- X-Mailer: YahooMailWebService/0.8.155.576 Message-ID: <1377289683.3816.YahooMailNeo@web171205.mail.ir2.yahoo.com> Date: Fri, 23 Aug 2013 21:28:03 +0100 (BST) From: Pham Viet Ha Subject: Arge1 link status is not updated To: freebsd-embedded MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.14 X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: Pham Viet Ha List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Aug 2013 20:28:06 -0000 Hi there,=0A=0AI am running nanobsd on a MIPS platform, which is an AR7161 = CPU with AR8316 switch. Both arge interfaces show up however the link statu= s is not correctly updated.=A0=0A=0Aarge1 (the WAN interface) always show a= ctive, even there is no ethernet cable plugged in.=A0=0A=0AIn a post, Adria= n mentioned this (http://lists.freebsd.org/pipermail/freebsd-embedded/2013-= July/001871.html):=0A=0AThen arge1 is glued to this "WAN" PHY. It's not own= ed by arswitch (but=0Ait could be!) as then arge1 couldn't link to it to ge= t notifications=0Aabout link, speed/duplex changes.=0A=0AMy question is how= can we make arge1 update its link status (no carrier/active) when the link= is disconnected/connected?=A0=0A=0AShould it be in arge driver or in the s= witch driver?=A0=0A=0AAt this time I compiled and load the switch in a sepa= rated module.=A0=0A=0A=0AThe log from boot:=A0=0Aargemdio0: at mem 0x19000000-0x19000fff= on nexus0=0Amdio0: on argemdio0=0Amdioproxy0: on mdio0=0Aarge0: at me= m 0x19000000-0x19000fff irq 2 on nexus0=0Aarge0: Overriding MAC from EEPROM= =0Aarge0: arge_attach: overriding MII mode to 'RGMII'=0Aarge0: sc->arge_mac= _unit 0 phymask 15=0Aarge0: finishing attachment, phymask 000f, proxy null= =0Amiibus0: on arge0=0Aukphy0: PHY 0 on miibus0=0Aukphy0: =A0none, 10baseT, 10baseT-FDX, 100baseTX, 10= 0baseTX-FDX, 1000baseT-FDX, 1000baseT-FDX-master, auto=0Aukphy1: PHY 1 on miibus0=0Aukphy1: =A0none, 10baseT, 10= baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT-FDX, 1000baseT-FDX-master, a= uto=0Aukphy2: PHY 2 on miibus0=0Aukph= y2: =A0none, 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT-FDX,= 1000baseT-FDX-master, auto=0Aukphy3: = PHY 3 on miibus0=0Aukphy3: =A0none, 10baseT, 10baseT-FDX, 100baseTX, 100ba= seTX-FDX, 1000baseT-FDX, 1000baseT-FDX-master, auto=0Aarge0: Ethernet addre= ss: 00:03:7f:12:20:00=0Aarge1: = at mem 0x1a000000-0x1a000fff irq 3 on nexus0=0Aarge1: arge_attach: overrid= ing MII mode to 'RGMII'=0Aarge1: sc->arge_mac_unit 1 phymask 16=0Aarge1: fi= nishing attachment, phymask 0010, proxy null=0Aarge1: No PHY, use hard-code= d values: arge_multiphy_mediachange, arge_multiphy_mediastatus.=0Aarge1: Et= hernet address: 00:03:7f:12:20:01=0A=0A=0AThank you so much.=0A=0AViet-Ha P= ham From owner-freebsd-embedded@FreeBSD.ORG Fri Aug 23 21:21:10 2013 Return-Path: Delivered-To: freebsd-embedded@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id EE4F956C for ; Fri, 23 Aug 2013 21:21:10 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-wi0-x22c.google.com (mail-wi0-x22c.google.com [IPv6:2a00:1450:400c:c05::22c]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 70EAF2514 for ; Fri, 23 Aug 2013 21:21:10 +0000 (UTC) Received: by mail-wi0-f172.google.com with SMTP id hj13so2453814wib.17 for ; Fri, 23 Aug 2013 14:21:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=3Ovus3EV9kQVwuyl3AQ+uNUkKY3INYYTNceY/2s+RHk=; b=cXMtlhcGGUff5TDf1pybD9qwqXwJD5xq6lmOj6v2LHRzOkNTEiZ1mjSZ8wdsmuPc19 kLbCkf8dHSglazAo/n7+4y07qLyGel/xVd9hd42huEsjT5jcMQML7NdFoMY4IID+Jumi XwmQQivkscb58Af6maoEqVyuG9PuBPQysi3+k7Al62FORew+KR2I1Mr+RiKX9VBNeZKs /sFivc+91ZTwYgMgvb+52fDc6NTC3uyIanXwrXpvlvL9q5dG5fpzVI3/CBSMrvB/FLjz tIJhKku9q9ZLLw28CjA1bgfDbSzw2rH1MZ2Z3W2nyO9H7phINBAqj09YRUvvEhu2ejit +5Gg== MIME-Version: 1.0 X-Received: by 10.194.201.202 with SMTP id kc10mr1322220wjc.1.1377292868178; Fri, 23 Aug 2013 14:21:08 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.217.116.136 with HTTP; Fri, 23 Aug 2013 14:21:08 -0700 (PDT) In-Reply-To: <1377289683.3816.YahooMailNeo@web171205.mail.ir2.yahoo.com> References: <1377289683.3816.YahooMailNeo@web171205.mail.ir2.yahoo.com> Date: Fri, 23 Aug 2013 14:21:08 -0700 X-Google-Sender-Auth: 6EOR-sg9gpwuM_ApXo_rn3uRNNM Message-ID: Subject: Re: Arge1 link status is not updated From: Adrian Chadd To: Pham Viet Ha Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: freebsd-embedded X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Aug 2013 21:21:11 -0000 The second port doesn't have a link status per se. It's connected to the AR8316 switch PHY. Use etherswitchcfg to see the link status of the child switch ports. -adrian On 23 August 2013 13:28, Pham Viet Ha wrote: > Hi there, > > I am running nanobsd on a MIPS platform, which is an AR7161 CPU with > AR8316 switch. Both arge interfaces show up however the link status is not > correctly updated. > > arge1 (the WAN interface) always show active, even there is no ethernet > cable plugged in. > > In a post, Adrian mentioned this ( > http://lists.freebsd.org/pipermail/freebsd-embedded/2013-July/001871.html > ): > > Then arge1 is glued to this "WAN" PHY. It's not owned by arswitch (but > it could be!) as then arge1 couldn't link to it to get notifications > about link, speed/duplex changes. > > My question is how can we make arge1 update its link status (no > carrier/active) when the link is disconnected/connected? > > Should it be in arge driver or in the switch driver? > > At this time I compiled and load the switch in a separated module. > > > The log from boot: > argemdio0: > at mem 0x19000000-0x19000fff on nexus0 > mdio0: on argemdio0 > mdioproxy0: on mdio0 > arge0: at mem > 0x19000000-0x19000fff irq 2 on nexus0 > arge0: Overriding MAC from EEPROM > arge0: arge_attach: overriding MII mode to 'RGMII' > arge0: sc->arge_mac_unit 0 phymask 15 > arge0: finishing attachment, phymask 000f, proxy null > miibus0: on arge0 > ukphy0: PHY 0 on miibus0 > ukphy0: none, 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, > 1000baseT-FDX, 1000baseT-FDX-master, auto > ukphy1: PHY 1 on miibus0 > ukphy1: none, 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, > 1000baseT-FDX, 1000baseT-FDX-master, auto > ukphy2: PHY 2 on miibus0 > ukphy2: none, 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, > 1000baseT-FDX, 1000baseT-FDX-master, auto > ukphy3: PHY 3 on miibus0 > ukphy3: none, 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, > 1000baseT-FDX, 1000baseT-FDX-master, auto > arge0: Ethernet address: 00:03:7f:12:20:00 > arge1: at mem > 0x1a000000-0x1a000fff irq 3 on nexus0 > arge1: arge_attach: overriding MII mode to 'RGMII' > arge1: sc->arge_mac_unit 1 phymask 16 > arge1: finishing attachment, phymask 0010, proxy null > arge1: No PHY, use hard-coded values: arge_multiphy_mediachange, > arge_multiphy_mediastatus. > arge1: Ethernet address: 00:03:7f:12:20:01 > > > Thank you so much. > > Viet-Ha Pham > _______________________________________________ > freebsd-embedded@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-embedded > To unsubscribe, send any mail to "freebsd-embedded-unsubscribe@freebsd.org > " >