From owner-p4-projects@FreeBSD.ORG Tue Apr 11 04:43:27 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 5B10516A402; Tue, 11 Apr 2006 04:43:27 +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 3875C16A406 for ; Tue, 11 Apr 2006 04:43:27 +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 EDA2343D49 for ; Tue, 11 Apr 2006 04:43:26 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id k3B4hQbX075588 for ; Tue, 11 Apr 2006 04:43:26 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id k3B4hQce075585 for perforce@freebsd.org; Tue, 11 Apr 2006 04:43:26 GMT (envelope-from imp@freebsd.org) Date: Tue, 11 Apr 2006 04:43:26 GMT Message-Id: <200604110443.k3B4hQce075585@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 94969 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: Tue, 11 Apr 2006 04:43:27 -0000 http://perforce.freebsd.org/chv.cgi?CH=94969 Change 94969 by imp@imp_hammer on 2006/04/11 04:43:14 Write a stupid memory test. It is so stupid that I would have thought it impossible to fail. Our current board, alas, fails. The KB9202 board doesn't. Affected files ... .. //depot/projects/arm/src/sys/boot/arm/kb920x/boot0/main.c#7 edit Differences ... ==== //depot/projects/arm/src/sys/boot/arm/kb920x/boot0/main.c#7 (text+ko) ==== @@ -23,19 +23,40 @@ */ #include "AT91RM9200.h" -#include "at91rm9200_lowlevel.h" +#include "lib.h" typedef void fn_t(void); int main(void) { +#if 0 char *addr = (char *)0x20000000 + (1 << 20); /* Load to base + 1MB */ fn_t *fn = (fn_t *)addr; - AT91C_BASE_PIOC->PIO_SODR = AT91C_PIO_PC10; - xmodem_rx(addr); +// AT91C_BASE_PIOC->PIO_SODR = AT91C_PIO_PC10; + while (xmodem_rx(addr) == -1) + continue; +// AT91C_BASE_PIOC->PIO_CODR = AT91C_PIO_PC10; + fn(); +#else + int *addr = (int *)0x20000000; /* Load to base + 1MB */ + int i; + + while (1) { + int sec = GetSeconds(); + while (sec == GetSeconds()) + continue; + putc('A'); + for (i = 0; i < 1024; i++) + addr[i] = i * 2; + for (i = 0; i < 1024; i++) + if (addr[i] != i * 2) { + putc('N'); + break; + } + } AT91C_BASE_PIOC->PIO_CODR = AT91C_PIO_PC10; - fn(); +#endif return (1); }