From: <he...@us...> - 2004-10-19 23:18:49
|
Update of /cvsroot/gc-linux/linux/arch/ppc/boot/simple In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25384/arch/ppc/boot/simple Modified Files: embed_config.c head.S misc-embedded.c Log Message: - Simplified the disable mmu code (the old code was a hack). - Removed hardcoded values to calculate the available memory. - Added some code to keep the compiler happy. Index: embed_config.c =================================================================== RCS file: /cvsroot/gc-linux/linux/arch/ppc/boot/simple/embed_config.c,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- embed_config.c 15 Aug 2004 22:33:03 -0000 1.5 +++ embed_config.c 19 Oct 2004 23:18:39 -0000 1.6 @@ -987,16 +987,23 @@ void embed_config(bd_t **bdp) { + u_char *cp; + int i; bd_t *bd; bd = &bdinfo; *bdp = bd; - bd->bi_memsize = 24 * 1024 * 1024; + bd->bi_memsize = GCN_MEM_SIZE; bd->bi_tbfreq = 200 * 1000 * 1000; bd->bi_intfreq = 200000000; bd->bi_busfreq = 100000000; timebase_period_ns = 1000000000 / bd->bi_tbfreq; - } - #endif + /* this is mainly to shut up compiler, we won't use this */ + cp = (u_char *)def_enet_addr; + for (i=0; i<6; i++) { + bd->bi_enetaddr[i] = *cp++; + } +} +#endif /* CONFIG_GAMECUBE */ Index: head.S =================================================================== RCS file: /cvsroot/gc-linux/linux/arch/ppc/boot/simple/head.S,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- head.S 11 Oct 2004 22:04:28 -0000 1.5 +++ head.S 19 Oct 2004 23:18:39 -0000 1.6 @@ -101,23 +101,14 @@ bl disable_6xx_mmu #endif -#ifdef CONFIG_GAMECUBE - /* convert our starting address to physical layout format */ - clrlwi r3, r3, 3 -#else +#ifndef CONFIG_GAMECUBE bl disable_6xx_l1cache CLEAR_CACHES -#endif /* CONFIG_GAMECUBE */ - -#ifdef CONFIG_GAMECUBE_CONSOLE - /* setup the framebuffer address for the early debug console */ - lis r8, 0xcc00 - lis r5, 0x00c0 - stw r5, 0x201c(r8) - addi r5, r5, 1280 - stw r5, 0x2024(r8) -#endif /* CONFIG_GAMECUBE_CONSOLE */ +#else + /* convert our starting address to physical layout format */ + clrlwi r3, r3, 3 +#endif /* !CONFIG_GAMECUBE */ #endif Index: misc-embedded.c =================================================================== RCS file: /cvsroot/gc-linux/linux/arch/ppc/boot/simple/misc-embedded.c,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- misc-embedded.c 19 Oct 2004 09:46:08 -0000 1.5 +++ misc-embedded.c 19 Oct 2004 23:18:39 -0000 1.6 @@ -213,6 +213,10 @@ } udelay(1000); /* 1 msec */ } +#else + /* shut up compiler */ + timer = 0; + ch = 0; #endif *cp = 0; puts("\nUncompressing Linux..."); |