From owner-p4-projects@FreeBSD.ORG Mon Aug 21 20:58:29 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 B6B0F16A556; Mon, 21 Aug 2006 20:58:29 +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 94CDF16A554 for ; Mon, 21 Aug 2006 20:58:29 +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 BEE4F43D64 for ; Mon, 21 Aug 2006 20:58:23 +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 k7LKwNYN047777 for ; Mon, 21 Aug 2006 20:58:23 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k7LKwNNU047774 for perforce@freebsd.org; Mon, 21 Aug 2006 20:58:23 GMT (envelope-from imp@freebsd.org) Date: Mon, 21 Aug 2006 20:58:23 GMT Message-Id: <200608212058.k7LKwNNU047774@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 104722 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: Mon, 21 Aug 2006 20:58:29 -0000 http://perforce.freebsd.org/chv.cgi?CH=104722 Change 104722 by imp@imp_lighthouse on 2006/08/21 20:58:02 Init bss Affected files ... .. //depot/projects/arm/src/sys/boot/arm/at91/libat91/at91rm9200_lowlevel.c#8 edit Differences ... ==== //depot/projects/arm/src/sys/boot/arm/at91/libat91/at91rm9200_lowlevel.c#8 (text) ==== @@ -30,6 +30,9 @@ #include "at91rm9200.h" #include "at91rm9200_lowlevel.h" +extern void *__bss_start__; +extern void *__bss_end__; + #define BAUD 115200 #define AT91C_US_ASYNC_MODE (AT91C_US_USMODE_NORMAL | AT91C_US_NBSTOP_1_BIT | \ AT91C_US_PAR_NONE | AT91C_US_CHRL_8_BITS | AT91C_US_CLKS_CLOCK) @@ -42,6 +45,8 @@ void _init(void) { + int *i; + AT91PS_USART pUSART = (AT91PS_USART)AT91C_BASE_DBGU; AT91PS_PDC pPDC = (AT91PS_PDC)&(pUSART->US_RPR); @@ -195,4 +200,9 @@ pUSART->US_MR = AT91C_US_ASYNC_MODE; pUSART->US_CR = AT91C_US_TXEN; pUSART->US_CR = AT91C_US_RXEN; + + /* Zero BSS now that we have memory setup */ + i = (int *)__bss_start__; + while (i < (int *)__bss_end__) + *i++ = 0; }