From owner-freebsd-hardware@FreeBSD.ORG Wed Mar 3 10:25:45 2010 Return-Path: Delivered-To: hardware@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AC2E7106566C for ; Wed, 3 Mar 2010 10:25:45 +0000 (UTC) (envelope-from ray@dlink.ua) Received: from dlink.ua (smtp.dlink.ua [193.138.187.146]) by mx1.freebsd.org (Postfix) with ESMTP id 329888FC13 for ; Wed, 3 Mar 2010 10:25:44 +0000 (UTC) Received: from gw ([192.168.10.10] helo=terran) by dlink.ua with esmtpsa (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.63) (envelope-from ) id 1NmljV-00043t-Jk; Wed, 03 Mar 2010 12:23:13 +0200 Date: Wed, 3 Mar 2010 12:26:04 +0200 From: Alexandr Rybalko To: ticso@cicely.de Message-Id: <20100303122604.b8835c32.ray@dlink.ua> In-Reply-To: <20100302211703.GP58319@cicely7.cicely.de> References: <20100302180242.824f4726.ray@dlink.ua> <20100302211703.GP58319@cicely7.cicely.de> Organization: D-Link X-Mailer: Sylpheed 2.7.1 (GTK+ 2.16.6; i386-portbld-freebsd8.0) Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Bernd Walter , hardware@freebsd.org Subject: Re: Pseudo PHY and fake PHY ID X-BeenThere: freebsd-hardware@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: General discussion of FreeBSD hardware List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 Mar 2010 10:25:45 -0000 On Tue, 2 Mar 2010 22:17:03 +0100 Bernd Walter wrote: >> On Tue, Mar 02, 2010 at 06:02:42PM +0200, Alexandr Rybalko wrote: >> > Hi, >> > >> > I making correct driver for SoC switch which is Pseudo PHY on bfe interface. >> > Someone can point me correct way to fake PHY ID for make it possible auto attach bfeswitch pseudo PHY driver? >> >> Has the switch an MDIO connection? Yes. >> I wrote the rtlswitch pseudo PHY driver for the RTL8305SC , which AFAIK still >> is the only one. >> The switch identifies without problem via identifiers, but it occupies multiple >> addresses and to avoid other drivers to claim the other IDs the rtlswitch >> driver claims all, but only attaches one time. My problem different, switch use one PHY address, but they (as I know) don`t provide identification. And I have to devices one on BCM5354 they have one bfe and one switch second on BCM5350 they have two bfe and one switch So I can`t only set hardcoded link bfe to bfeswitch. I need way for keeping auto probe and to know how fake switch id depend on outer info. >> >> ate0: mem 0xdffbc000-0xdffbffff irq 24 on atmelarm0 >> miibus0: on ate0 >> rlswitch0: PHY 0 on miibus0 >> rlswitch0: 100baseTX-FDX >> rlswitch1: PHY 1 on miibus0 >> rlswitch1: ignoring this PHY, non-zero instance >> device_attach: rlswitch1 attach returned 6 >> rlswitch2: PHY 2 on miibus0 >> rlswitch2: ignoring this PHY, non-zero instance >> device_attach: rlswitch2 attach returned 6 >> rlswitch3: PHY 3 on miibus0 >> rlswitch3: ignoring this PHY, non-zero instance >> device_attach: rlswitch3 attach returned 6 >> rlswitch4: PHY 4 on miibus0 >> rlswitch4: ignoring this PHY, non-zero instance >> device_attach: rlswitch4 attach returned 6 >> rlswitch5: PHY 5 on miibus0 >> rlswitch5: ignoring this PHY, non-zero instance >> device_attach: rlswitch5 attach returned 6 >> >> Beside from loocking strange it works fine this way. >> >> -- >> B.Walter http://www.bwct.de >> Modbus/TCP Ethernet I/O Baugruppen, ARM basierte FreeBSD Rechner uvm. -- Рыбалко Александр Консультант D-Link Украина