From owner-p4-projects@FreeBSD.ORG Wed Jun 14 02:55:30 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 75DB716A482; Wed, 14 Jun 2006 02:55:30 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 514EE16A47D for ; Wed, 14 Jun 2006 02:55:30 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 19ABB43D49 for ; Wed, 14 Jun 2006 02:55:30 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k5E2r8U8026975 for ; Wed, 14 Jun 2006 02:53:08 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k5E2r8EN026972 for perforce@freebsd.org; Wed, 14 Jun 2006 02:53:08 GMT (envelope-from imp@freebsd.org) Date: Wed, 14 Jun 2006 02:53:08 GMT Message-Id: <200606140253.k5E2r8EN026972@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 99194 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Jun 2006 02:55:30 -0000 http://perforce.freebsd.org/chv.cgi?CH=99194 Change 99194 by imp@imp_Speedy on 2006/06/14 02:52:33 Add a bit of a delay and print the registers out of the mii chip for debug for the hardware guys. Affected files ... .. //depot/projects/arm/src/sys/boot/arm/at91/libat91/emac.c#16 edit Differences ... ==== //depot/projects/arm/src/sys/boot/arm/at91/libat91/emac.c#16 (text+ko) ==== @@ -384,9 +384,9 @@ { unsigned short stat2; unsigned update; -#if 0 unsigned sec; int i; +#if 0 // AT91F_MII_WritePhy(pEmac, 20, 0x70); AT91F_MII_WritePhy(pEmac, 0x0, 0x3300); @@ -415,8 +415,13 @@ stat2 = AT91F_MII_ReadPhy(pEmac, MII_STS_REG); stat2 = AT91F_MII_ReadPhy(pEmac, MII_STS_REG); if (!(stat2 & MII_STS_LINK_STAT)) { + sec = GetSeconds(); printf("emac: missing link status 0x%x\r\n", stat2); - printf("%x\r\n", AT91F_MII_ReadPhy(pEmac, MII_SPEC_STS_REG)); + for (i = 0; i <= 0x18; i++) + printf("%x ", AT91F_MII_ReadPhy(pEmac, i)); + printf("\r\n"); + while (GetSeconds() <= sec + 2) continue; + sec = GetSeconds(); AT91F_MII_WritePhy(pEmac, 0x0, 0x3300); while (AT91F_MII_ReadPhy(pEmac, 0x0) & (1 << 9)); goto again;