Date: Wed, 8 Nov 2006 00:54:38 GMT From: Warner Losh <imp@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 109500 for review Message-ID: <200611080054.kA80scNJ004087@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=109500 Change 109500 by imp@imp_lighthouse on 2006/11/08 00:54:16 Add perliminary support for KB9202{,A} to boot2. Affected files ... .. //depot/projects/arm/src/sys/boot/arm/at91/Makefile.inc#24 edit .. //depot/projects/arm/src/sys/boot/arm/at91/boot2/Makefile#8 edit .. //depot/projects/arm/src/sys/boot/arm/at91/libat91/at91rm9200_lowlevel.c#11 edit .. //depot/projects/arm/src/sys/boot/arm/at91/libat91/at91rm9200_lowlevel.h#8 edit .. //depot/projects/arm/src/sys/boot/arm/at91/libat91/emac.c#36 edit .. //depot/projects/arm/src/sys/boot/arm/at91/libat91/emac.h#15 edit .. //depot/projects/arm/src/sys/boot/arm/at91/libat91/emac_init.c#8 edit Differences ... ==== //depot/projects/arm/src/sys/boot/arm/at91/Makefile.inc#24 (text+ko) ==== @@ -5,6 +5,9 @@ __at91_boot_Makefile.inc__: +# tsc, kb920x are the supported flavors +BOOT_FLAVOR=kb920x + CFLAGS=-Os -mcpu=arm9 -ffreestanding \ -I${.CURDIR}/../libat91 \ -I${.CURDIR}/../../../.. \ @@ -18,8 +21,7 @@ # -Wmissing-declarations # -Wstrict-prototypes -CFLAGS+=-DBOOT_TSC -#CFLAGS+=-DBOOT_KB9202 +CFLAGS+=-DBOOT_${BOOT_FLAVOR:U} LIBAT91=${.OBJDIR}/../libat91/libat91.a ==== //depot/projects/arm/src/sys/boot/arm/at91/boot2/Makefile#8 (text+ko) ==== @@ -4,7 +4,7 @@ P=boot2 FILES=${P} -SRCS=arm_init.S boot2.c tsc_board.c ee.c +SRCS=arm_init.S boot2.c ${BOOT_FLAVOR}_board.c ee.c NO_MAN= LDFLAGS=-e 0 -T ${.CURDIR}/../linker.cfg OBJS+= ${SRCS:N*.h:R:S/$/.o/g} ==== //depot/projects/arm/src/sys/boot/arm/at91/libat91/at91rm9200_lowlevel.c#11 (text) ==== @@ -100,7 +100,7 @@ while (!(AT91C_BASE_PMC->PMC_SR & AT91C_PMC_MCKRDY)) continue; -#ifdef BOOT_KB9202 +#ifdef BOOT_KB920X // setup flash access (allow ample margin) // 9 wait states, 1 setup, 1 hold, 1 float for 8-bit device ((AT91PS_SMC2)AT91C_BASE_SMC2)->SMC2_CSR[0] = ==== //depot/projects/arm/src/sys/boot/arm/at91/libat91/at91rm9200_lowlevel.h#8 (text) ==== @@ -31,7 +31,7 @@ #define SDRAM_BASE 0x20000000 -#ifdef BOOT_KB9202 +#ifdef BOOT_KB920X /* The following divisor sets PLLA frequency: e.g. 10/5 * 90 = 180MHz */ #define OSC_MAIN_FREQ_DIV 5 /* for 10MHz osc */ #define SDRAM_WIDTH AT91C_SDRC_DBW_16_BITS ==== //depot/projects/arm/src/sys/boot/arm/at91/libat91/emac.c#36 (text+ko) ==== @@ -384,7 +384,7 @@ unsigned sec; int i; #endif -#ifdef BOOT_KB9202 +#ifdef BOOT_KB920X stat2 = AT91F_MII_ReadPhy(pEmac, MII_STS2_REG); if (!(stat2 & MII_STS2_LINK)) return ; ==== //depot/projects/arm/src/sys/boot/arm/at91/libat91/emac.h#15 (text+ko) ==== @@ -114,7 +114,7 @@ /* MII registers definition */ #define MII_STS_REG 0x01 #define MII_STS_LINK_STAT 0x04 -#ifdef BOOT_KB9202 +#ifdef BOOT_KB920X #define MII_STS2_REG 0x11 #define MII_STS2_LINK 0x400 #define MII_STS2_100TX 0x4000 ==== //depot/projects/arm/src/sys/boot/arm/at91/libat91/emac_init.c#8 (text+ko) ==== @@ -94,7 +94,7 @@ AT91C_PA8_ETXEN | AT91C_PA16_EMDIO | AT91C_PA9_ETX0 | AT91C_PA10_ETX1 | AT91C_PA11_ECRS_ECRSDV | AT91C_PA15_EMDC | AT91C_PA7_ETXCK_EREFCK; -#ifdef BOOT_KB9202 /* Really !RMII */ +#ifdef BOOT_KB920X /* Really !RMII */ AT91C_BASE_PIOB->PIO_BSR = AT91C_PB12_ETX2 | AT91C_PB13_ETX3 | AT91C_PB14_ETXER | AT91C_PB15_ERX2 | AT91C_PB16_ERX3 | AT91C_PB17_ERXDV |
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200611080054.kA80scNJ004087>