From owner-freebsd-new-bus@FreeBSD.ORG Thu Oct 26 13:24:56 2006 Return-Path: X-Original-To: freebsd-new-bus@freebsd.org Delivered-To: freebsd-new-bus@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C6FB016A416 for ; Thu, 26 Oct 2006 13:24:56 +0000 (UTC) (envelope-from namaskar_alok@yahoo.co.in) Received: from web8904.mail.in.yahoo.com (web8904.mail.in.yahoo.com [203.84.221.32]) by mx1.FreeBSD.org (Postfix) with SMTP id B684743D46 for ; Thu, 26 Oct 2006 13:24:55 +0000 (GMT) (envelope-from namaskar_alok@yahoo.co.in) Received: (qmail 48512 invoked by uid 60001); 26 Oct 2006 13:24:53 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.co.in; h=Message-ID:Received:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=M77sshUJWiyp86acL86NuVCnrbY96B+qOo751brms8+rpq/DOIKK17TCllasCPGr7kKb4qH0+NdyXbRFX/7td5h8FSFhWYkOFcG7anRnvL834a+U+KFyLBtLYflW1Ha0edjHY7XAoHCW+w0qRxhWBEsgU0zZrh0Umw3s2x848KE= ; Message-ID: <20061026132453.48510.qmail@web8904.mail.in.yahoo.com> Received: from [220.225.33.101] by web8904.mail.in.yahoo.com via HTTP; Thu, 26 Oct 2006 06:24:53 PDT Date: Thu, 26 Oct 2006 06:24:53 -0700 (PDT) From: Alok Barsode To: freebsd-new-bus@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Subject: Network device driver issues. X-BeenThere: freebsd-new-bus@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD's new-bus architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Oct 2006 13:24:56 -0000 Hello, I am porting freeBSD 4.10 to a embedded board. The board has 2 Three speed Ethernet Controller and a Cicada PHY. I have implemented a pseudo-bus (called mpcbus) which attaches itself to nexus. i plan to attach all the devices to the mpcbus. (i will be calling the IDENTIFY function for each device-driver).All the devices are memory mapped. Now i have 2 TSEC(Three-Speed Ethernet Controller)on the board(say TSEC0 and TSEC1). During the IDENTIFY routine, should the function BUS_ADD_CHILD() called twice ,once for each TSEC? I also dont what the PHY to be configured sepatately. (I right now dont want any "mii" stuff) I will configure the PHY manually. is this fine with the freeBSD point of view? I dont understand the struct xxx_mii_frame. i am looking at the National Semiconductor DP83820/DP83821 gigabit ethernet driver (i.e /dev/nge/if_nge.c) The frame structure is: struct nge_mii_frame { u_int8_t mii_stdelim; u_int8_t mii_opcode; u_int8_t mii_phyaddr; u_int8_t mii_regaddr; u_int8_t mii_turnaround; u_int16_t mii_data; };All the drivers use this kind of frame structure. Is this a generic one? how does one use it? is there a simple driver i can look at? or a simple tutorial on network drivers? the National Semiconductor driver is a bit complex. Thanks, alok. __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com