From owner-freebsd-current@FreeBSD.ORG Thu Aug 31 03:25:14 2006 Return-Path: X-Original-To: freebsd-current@freebsd.org Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C02E616A4DA for ; Thu, 31 Aug 2006 03:25:14 +0000 (UTC) (envelope-from delphij@delphij.net) Received: from tarsier.geekcn.org (tarsier.geekcn.org [210.51.165.229]) by mx1.FreeBSD.org (Postfix) with ESMTP id A5CE543D46 for ; Thu, 31 Aug 2006 03:25:12 +0000 (GMT) (envelope-from delphij@delphij.net) Received: from localhost (tarsier.geekcn.org [210.51.165.229]) by tarsier.geekcn.org (Postfix) with ESMTP id CC228EB4119; Thu, 31 Aug 2006 11:25:09 +0800 (CST) X-Virus-Scanned: amavisd-new at geekcn.org Received: from tarsier.geekcn.org ([210.51.165.229]) by localhost (mail.geekcn.org [210.51.165.229]) (amavisd-new, port 10024) with ESMTP id cOwEDZm93E1c; Thu, 31 Aug 2006 11:25:01 +0800 (CST) Received: from [10.217.12.84] (sina152-194.staff.sina.com.cn [61.135.152.194]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by tarsier.geekcn.org (Postfix) with ESMTP id CE7B8EB3A5A; Thu, 31 Aug 2006 11:24:59 +0800 (CST) DomainKey-Signature: a=rsa-sha1; s=default; d=delphij.net; c=nofws; q=dns; h=message-id:date:from:organization:user-agent:mime-version:to:cc: subject:references:in-reply-to:x-enigmail-version:content-type; b=R/q/s5pShaOkckD1ueLxK9bNb74ayS3RMOiF6LrW4QvwKm7qwymkvQZeKjNeZr1y7 spDE/8m6n+RNHS2WuKWDA== Message-ID: <44F65687.2050108@delphij.net> Date: Thu, 31 Aug 2006 11:24:55 +0800 From: LI Xin Organization: The FreeBSD Project User-Agent: Thunderbird 1.5.0.5 (Macintosh/20060719) MIME-Version: 1.0 To: David Christensen References: <09BFF2FA5EAB4A45B6655E151BBDD90301E2F1CF@NT-IRVA-0750.brcm.ad.broadcom.com> In-Reply-To: <09BFF2FA5EAB4A45B6655E151BBDD90301E2F1CF@NT-IRVA-0750.brcm.ad.broadcom.com> X-Enigmail-Version: 0.94.1.0 Content-Type: multipart/signed; micalg=pgp-ripemd160; protocol="application/pgp-signature"; boundary="------------enig3BABA608393D6FCFBF2360A5" Cc: freebsd-current@freebsd.org Subject: Re: bge(4) on BCM 5752 A02 panic due to media autoselect X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 31 Aug 2006 03:25:14 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig3BABA608393D6FCFBF2360A5 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable David Christensen wrote: >> Recently one of my colleagues found that BCM 5752 A02 on Dell Latitude= >> D820 would get "panic: invalid ife->ifm_data (0xa) in=20 >> mii_phy_setmedia". >> After some investigation I have found that removing BCMR_ANEG from >> mii_capabilities in ukphy.c would work around the problem,=20 >> and it turns >> out that without explicitly specifying media type, the code=20 >> will finally >> get to pass the "intentionally invalid index" to mii_phy_setmedia and >> trigger an assertion fail. >> >> I have not tested the situation in -STABLE yet, but it was=20 >> said to work >> there, though. Is there anyone can shed some light to me about how to= >> debug the issue? Thanks in advance! >> >> PS. During the debugging I have found that the attached patch can make= >> "bge0: firmware handshake timeout" issue disappear from the said chip.= >> Because I do not have Broadcom specification at hand I would=20 >> like to see >> if there is someone to give appropriate review for it. >=20 > Try the attached patch instead and let me know if it works. When > FastBoot > is enabled on supported Broadcom controllers it allows the controller t= o > skip rereading firmware after a reset, allowing the driver to complete = > its initialization more quickly. The Linux driver specifically disable= s > FastBoot because it performs some read/write tests to controller memory= , > potentially corrupting the firmware, so FastBoot is disabled to insure > an > error free firmware reload. We don't do the same test so the same > change > isn't necessary. The patch happens to work because the bge driver > doesn't > perform firmware synchronization correctly, and the firmware initialize= s > too fast for the driver. Thank you for the patch. I have just tested the patch under FreeBSD/i386 -CURRENT and the I can confirm that the firmware timeout goes away. Will you please commit it? (Note that the panic still persists, I will try to get brgphy attach to see if things changes). Cheers, --=20 Xin LI http://www.delphij.net/ FreeBSD - The Power to Serve! --------------enig3BABA608393D6FCFBF2360A5 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.3 (Darwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFE9laHOfuToMruuMARAwfxAJ9pqEK2AVypE92hwFklpkbCSzwCKgCcCfCs EoN/oUlOnKhxghJoBjKQC1k= =vw7t -----END PGP SIGNATURE----- --------------enig3BABA608393D6FCFBF2360A5--