PREP kernel for MCP750/MCPN750
Michael Stevens <[email protected]>
| Newsgroups | gmane.os.netbsd.ports.prep |
|---|---|
| Message-ID | <[email protected]> |
Hi,
Quite a while back I decided to try and get the NetBSD PREP kernel
running on some Motorola SBC's that I've got (MCP750 & MCPN750). What
I have boots and runs fine so far, but is really just an experimental
hack. This is not a real port at this stage and I likely will not get
back to this for some time, so I figured I should at least make what I
have available.
Asides from the less than clean changes I've made, there are obvious
items not covered; e.g. the large bank of FLASH has not been mapped in.
Also, as I do not have transition modules for these cPCI boards, I
have been doing everything over NFS (Boot, root, swap) and serial
ports.
I'll include my patch file for the 1.6 source tree, but the real
changes in this "hack" are:
1) arch/prep/isa/mkclock_isa.c: Exclude NVRAM size check as the clock
device is slightly different and causes boot issues ("hack" remember).
2) arch/prep/prep/mainbus.c: mainbus_attach(), lengthened the pciio
extent to 0x00027fff.
3) arch/prep/prep/platform.c: reset_unknown() now calls
reset_prep_generic().
4) dev/pci/pciconf.c: setup_iowins() test pi->address against
0xffffffff instead of -1 as there is some type issues here (likely a
real bug, but I don't recall how far I tracked this down).
Other issues: make sure that the MCP750 is in PREP boot mode (see
PPCBUG manual).
I'm providing my patch file and the configuration file. There's extra
garbage in the patch file, but nothing exciting. The configuration
file is just a very pared down version of the GENERIC one.
As I know I will not get back to this for some time, if someone wants
to start a proper port then I can likely provide an MCP750 cPCI board,
but no chassis or backplane or transition module. Also, if there is
some real interest in this platform, then I could likely be encouraged
to get back into it.
Cheers,
Michael Stevens
PREPmcp750hack.patch
(application/octet-stream, 1.5 KB)
diff -r /mnt/sys/arch/prep/isa/mkclock_isa.c sys/arch/prep/isa/mkclock_isa.c
117c117
<
---
> printf("+++ mkclock_isa_match: (1)\n"); /* ++++ PMS, debuggering ++++ */
122a123
> printf("+++ mkclock_isa_match: (2)\n"); /* ++++ PMS, debuggering ++++ */
126a128
> printf("+++ mkclock_isa_match: (3)\n"); /* ++++ PMS, debuggering ++++ */
130a133
> printf("+++ mkclock_isa_match: (4)\n"); /* ++++ PMS, debuggering ++++ */
134a138,140
> printf("+++ mkclock_isa_match: (5) %ld\n",res->VitalProductData.NvramSize
> ); /* ++++ PMS, debuggering ++++ */
> #if 0 /* ++++ PMS ,debuggering ++++ */
137c143,144
<
---
> #endif
> printf("+++ mkclock_isa_match: (6)\n"); /* ++++ PMS, debuggering ++++ */
143a151
> printf("+++ mkclock_isa_match: (7)\n"); /* ++++ PMS, debuggering ++++ */
194a203
> printf("+++ mkclock_isa_match: (8)\n"); /* ++++ PMS, debuggering ++++ */
diff -r /mnt/sys/arch/prep/prep/mainbus.c sys/arch/prep/prep/mainbus.c
131a132
> #if 0 /* ++++ PMS, debuggering ++++ */
133a135,138
> #else
> ioext = extent_create("pciio", 0x00008000, 0x00027fff, M_DEVBUF,
> NULL, 0, EX_NOWAIT);
> #endif
diff -r /mnt/sys/arch/prep/prep/platform.c sys/arch/prep/prep/platform.c
126a127,129
> /* ++++ PMS, debuggering, all code added by moi ++++ */
> /* asm ("addi 10,0,0x0063; sc"); Dropout to PPCBUG */
> reset_prep_generic();
diff -r /mnt/sys/dev/pci/pciconf.c sys/dev/pci/pciconf.c
670a671
> #if 0 /* ++++ PMS, debuggering ++++ */
671a673,675
> #else
> if (pi->address == 0xffffffff) {
> #endif
prep.pms
(application/octet-stream, 15.2 KB) - not displayed