2 * TS5300 specific initialization code.
3 * written by Stefan Reinauer <stepan@coresystems.de>
4 * (c) 2006 coresystems GmbH
9 #define ASM_CONSOLE_LOGLEVEL 6
11 #include <device/pci_def.h>
13 #include <device/pnp_def.h>
14 #include <arch/romcc_io.h>
16 #include "pc80/mc146818rtc_early.c"
17 #include "pc80/serial.c"
18 #include "arch/i386/lib/console.c"
19 #include "lib/ramtest.c"
20 #include "cpu/x86/bist.h"
22 #define TS5300_LED_OFF outb((inb(0x77)&0xfe), 0x77)
23 #define TS5300_LED_ON outb((inb(0x77)|1), 0x77)
25 #define TS9500_LED_OFF outb((inb(0x19a)&0xfe), 0x19a)
26 #define TS9500_LED_ON outb((inb(0x19a)|1), 0x19a)
28 /* PAR register setup */
31 volatile unsigned long *par;
32 par = (unsigned long *) 0xfffef088;
34 /* NOTE: Ron says, move this to mainboard.c */
48 *par++ = 0x8a07c940; /* Flash setup */
53 #include "cpu/amd/sc520/raminit.c"
55 static void identify_ts9500(void)
61 print_err("TS-9500 add-on found:\r\n");
65 print_err_char(i+0x31);
78 print_err_char(i+0x30-5);
90 static void identify_system(void)
94 print_err("Mainboard: ");
97 case 0x50: print_err("TS-5300\r\n"); break;
98 case 0x40: print_err("TS-5400\r\n"); break;
99 case 0x60: print_err("TS-5500\r\n"); break;
100 case 0x20: print_err("TS-5600\r\n"); break;
101 case 0x70: print_err("TS-5700\r\n"); break;
102 default: print_err("unknown\r\n"); break;
106 print_err(" SRAM option: ");
107 if((val&1)==0) print_err("not ");
108 print_err("installed\r\n");
110 print_err(" RS-485 option: ");
111 if((val&2)==0) print_err("not ");
112 print_err("installed\r\n");
115 print_err(" Temp. range: ");
116 if((val&2)==0) print_err("commercial\r\n");
117 else print_err("industrial\r\n");
122 for (i=1; i<8; i++) {
124 print_err_char(i+0x30);
129 print_err("off\r\n");
140 static void hard_reset(void)
142 print_err("Hard reset called.\n");
146 static void main(unsigned long bist)
153 // Let the hardware settle a bit.
154 for(i = 0; i < 100; i++)
162 print_err("Technologic Systems TS5300 - http://www.embeddedx86.com/\r\n");
164 print_err("Memory initialized: 32MB\r\n");
171 // Check 32MB of memory @ 0 (very slow!)
172 print_err("Checking memory:\r\n");
173 ram_check(0x00000000, 0x000a0000);
174 ram_check(0x000b0000, 0x02000000);