Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/evbppc New umbrella-port for PowerPC-based evaluati...
details: https://anonhg.NetBSD.org/src/rev/760fb1ee7722
branches: trunk
changeset: 540288:760fb1ee7722
user: scw <scw%NetBSD.org@localhost>
date: Mon Dec 09 12:15:48 2002 +0000
description:
New umbrella-port for PowerPC-based evaluation boards.
The first board to be included here is the port to the 405GP-based
Walnut evaluation board, which up until now lived in arch/walnut.
arch/walnut will go away soon, once all the remaining walnut-isms
in the tree have been dealt with.
diffstat:
sys/arch/evbppc/Makefile | 33 +
sys/arch/evbppc/compile/walnut-mkimg.sh | 35 +
sys/arch/evbppc/conf/INSTALL_WALNUT | 24 +
sys/arch/evbppc/conf/Makefile.evbppc.inc | 3 +
sys/arch/evbppc/conf/Makefile.walnut.inc | 18 +
sys/arch/evbppc/conf/WALNUT | 257 +++++++++++
sys/arch/evbppc/conf/files.evbppc | 14 +
sys/arch/evbppc/conf/files.walnut | 72 +++
sys/arch/evbppc/conf/majors.evbppc | 56 ++
sys/arch/evbppc/conf/std.walnut | 20 +
sys/arch/evbppc/evbppc/bus_dma.c | 651 +++++++++++++++++++++++++++++
sys/arch/evbppc/evbppc/evbppc_machdep.c | 114 +++++
sys/arch/evbppc/evbppc/genassym.cf | 80 +++
sys/arch/evbppc/evbppc/procfs_machdep.c | 21 +
sys/arch/evbppc/include/Makefile | 24 +
sys/arch/evbppc/include/ansi.h | 3 +
sys/arch/evbppc/include/aout_machdep.h | 3 +
sys/arch/evbppc/include/asm.h | 3 +
sys/arch/evbppc/include/bswap.h | 4 +
sys/arch/evbppc/include/bus.h | 17 +
sys/arch/evbppc/include/cdefs.h | 3 +
sys/arch/evbppc/include/cpu.h | 51 ++
sys/arch/evbppc/include/db_machdep.h | 3 +
sys/arch/evbppc/include/dcr.h | 47 ++
sys/arch/evbppc/include/disklabel.h | 52 ++
sys/arch/evbppc/include/elf_machdep.h | 3 +
sys/arch/evbppc/include/endian.h | 3 +
sys/arch/evbppc/include/endian_machdep.h | 3 +
sys/arch/evbppc/include/float.h | 3 +
sys/arch/evbppc/include/fpu.h | 3 +
sys/arch/evbppc/include/frame.h | 93 ++++
sys/arch/evbppc/include/ieee.h | 3 +
sys/arch/evbppc/include/ieeefp.h | 3 +
sys/arch/evbppc/include/int_const.h | 3 +
sys/arch/evbppc/include/int_fmtio.h | 3 +
sys/arch/evbppc/include/int_limits.h | 3 +
sys/arch/evbppc/include/int_mwgwtypes.h | 3 +
sys/arch/evbppc/include/int_types.h | 3 +
sys/arch/evbppc/include/intr.h | 211 +++++++++
sys/arch/evbppc/include/ipkdb.h | 3 +
sys/arch/evbppc/include/kcore.h | 3 +
sys/arch/evbppc/include/limits.h | 3 +
sys/arch/evbppc/include/loadfile_machdep.h | 56 ++
sys/arch/evbppc/include/lock.h | 3 +
sys/arch/evbppc/include/macho_machdep.h | 3 +
sys/arch/evbppc/include/math.h | 3 +
sys/arch/evbppc/include/param.h | 137 ++++++
sys/arch/evbppc/include/pcb.h | 3 +
sys/arch/evbppc/include/pci_machdep.h | 89 +++
sys/arch/evbppc/include/pio.h | 3 +
sys/arch/evbppc/include/pmap.h | 13 +
sys/arch/evbppc/include/pmc.h | 3 +
sys/arch/evbppc/include/powerpc.h | 43 +
sys/arch/evbppc/include/proc.h | 3 +
sys/arch/evbppc/include/profile.h | 3 +
sys/arch/evbppc/include/psl.h | 23 +
sys/arch/evbppc/include/pte.h | 3 +
sys/arch/evbppc/include/ptrace.h | 3 +
sys/arch/evbppc/include/reg.h | 3 +
sys/arch/evbppc/include/reloc.h | 3 +
sys/arch/evbppc/include/rnd.h | 3 +
sys/arch/evbppc/include/rtc.h | 61 ++
sys/arch/evbppc/include/setjmp.h | 3 +
sys/arch/evbppc/include/signal.h | 3 +
sys/arch/evbppc/include/stdarg.h | 3 +
sys/arch/evbppc/include/tlb.h | 11 +
sys/arch/evbppc/include/trap.h | 3 +
sys/arch/evbppc/include/types.h | 5 +
sys/arch/evbppc/include/varargs.h | 3 +
sys/arch/evbppc/include/vmparam.h | 119 +++++
sys/arch/evbppc/include/walnut.h | 154 ++++++
sys/arch/evbppc/walnut/autoconf.c | 90 ++++
sys/arch/evbppc/walnut/consinit.c | 134 +++++
sys/arch/evbppc/walnut/dev/ds1743.c | 269 +++++++++++
sys/arch/evbppc/walnut/dev/ds1743reg.h | 66 ++
sys/arch/evbppc/walnut/dev/pbus.c | 204 +++++++++
sys/arch/evbppc/walnut/dev/pbusvar.h | 46 ++
sys/arch/evbppc/walnut/dev/pckbc_pbus.c | 151 ++++++
sys/arch/evbppc/walnut/dev/todclock.c | 324 ++++++++++++++
sys/arch/evbppc/walnut/dev/todclockvar.h | 55 ++
sys/arch/evbppc/walnut/disksubr.c | 311 +++++++++++++
sys/arch/evbppc/walnut/machdep.c | 637 ++++++++++++++++++++++++++++
sys/arch/evbppc/walnut/pci/pchb.c | 204 +++++++++
sys/arch/evbppc/walnut/pci/pci_machdep.c | 261 +++++++++++
sys/arch/evbppc/walnut/walnut_start.S | 282 ++++++++++++
85 files changed, 5756 insertions(+), 0 deletions(-)
diffs (truncated from 6096 to 300 lines):
diff -r 7ea38d55bdc0 -r 760fb1ee7722 sys/arch/evbppc/Makefile
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/arch/evbppc/Makefile Mon Dec 09 12:15:48 2002 +0000
@@ -0,0 +1,33 @@
+# $NetBSD: Makefile,v 1.1 2002/12/09 12:15:48 scw Exp $
+
+ETAGS?= etags
+
+SUBDIR= include
+
+# XXX Fix this to deal with multiple "evbppc" ports.
+SEVBPPC= evbppc/*.[ch] include/*.h
+AEVBPPC=
+
+SPPC= ../powerpc/ibm4xx/*.[ch] ../powerpc/powerpc/*.[ch] \
+ ../powerpc/include/*.h ../powerpc/include/ibm4xx/*.h \
+ ../powerpc/fpu/*.[ch]
+APPC= ../powerpc/ibm4xx/*.[sS] ../powerpc/powerpc/*.[sS]
+LPPC= ../../lib/libkern/arch/powerpc/*.[chsS] \
+ ../../lib/libkern/*.[ch] \
+ ../../lib/libsa/*.[ch]
+
+SYSDIR= ../..
+.include "../../kern/Make.tags.inc"
+
+.ifmake TAGS
+COMM!= find ${SYSDIR} -name "arch" -prune -o -name "*.[ch]" -print
+.endif
+
+TAGS: ${SEVBPPC} ${COMM} ${SPPC} ${COMM} ${ASPARC64}
+ @echo Making TAGS...
+ @${ETAGS} ${SEVBPPC} ${COMM} ${SPPC} ${COMM} "--regex=/^GLOBAL(\(.*\))/\1/" \
+ "--regex=/^_C_LABEL(\(.*\)):/\1/" "--regex=/^\(.*\):/\1/" \
+ "--regex=/^ENTRY(\(.*\)):/\1/" "--regex=/^ASENTRY(\(.*\)):/\1/" \
+ ${APPC} ${AEVBPPC}
+
+.include <bsd.subdir.mk>
diff -r 7ea38d55bdc0 -r 760fb1ee7722 sys/arch/evbppc/compile/walnut-mkimg.sh
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/arch/evbppc/compile/walnut-mkimg.sh Mon Dec 09 12:15:48 2002 +0000
@@ -0,0 +1,35 @@
+#!/bin/sh
+# $NetBSD: walnut-mkimg.sh,v 1.1 2002/12/09 12:15:50 scw Exp $
+
+# Convert a kernel to an tftp image loadable by the walnut IBM openbios.
+
+if [ $# -ne 2 ] ; then
+ echo usage: $0 kernel image 1>&2
+ exit 1
+fi
+
+kernel=$1; shift
+output=$1; shift
+
+: ${OBJDUMP=objdump}
+: ${OBJCOPY=objcopy}
+
+start=`${OBJDUMP} -f ${kernel} | awk '/start address/ { print $NF }'`
+start=`printf "%d" $start`
+${OBJCOPY} -O binary ${kernel} ${kernel}.bin.$$
+size=`/bin/ls -l ${kernel}.bin.$$ | awk '{ printf "%d", ( $5 + 511 ) / 512 }'`
+
+printf "%d\n%d\n0\n%d\n0\n0\n0\n" $start $size $start |
+ awk 'BEGIN { printf "\x00\x52\x50\x4f" }
+ {
+ printf "%c", $0 / 256 / 256 / 256 ;
+ printf "%c", $0 / 256 / 256 ;
+ printf "%c", $0 / 256 ;
+ printf "%c", $0 ;
+ }
+ ' > ${output}
+
+cat ${kernel}.bin.$$ >> ${output}
+
+rm -f ${kernel}.bin.$$
+exit
diff -r 7ea38d55bdc0 -r 760fb1ee7722 sys/arch/evbppc/conf/INSTALL_WALNUT
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/arch/evbppc/conf/INSTALL_WALNUT Mon Dec 09 12:15:48 2002 +0000
@@ -0,0 +1,24 @@
+# $NetBSD: INSTALL_WALNUT,v 1.1 2002/12/09 12:15:51 scw Exp $
+
+include "arch/evbppc/conf/WALNUT"
+
+#ident "INSTALL_WALNUT-$Revision: 1.1 $"
+
+# DEBUG options turned on:
+
+#options LOCKDEBUG
+options DIAGNOSTIC
+#makeoptions DEBUG="-g"
+options DEBUG
+#options SYSCALL_DEBUG
+options PIPE_SOCKETPAIR # smaller, but slower pipe(2)
+options MALLOC_NOINLINE # Not inlining MALLOC saves memory
+options VNODE_OP_NOINLINE # Not inlining vnode op calls saves mem
+
+# Enable the hooks used for initializing the root memory-disk.
+options MEMORY_DISK_HOOKS
+options MEMORY_DISK_IS_ROOT # force root on memory disk
+options MEMORY_DISK_SERVER=0 # no userspace memory disk support
+## The ramdisk size must be kept in sync manually with the size of
+## the `ramdisk' image (which is built in distrib/walnut/ramdisk/ramdisk).
+options MEMORY_DISK_ROOT_SIZE=16384 # size of memory disk, in blocks
diff -r 7ea38d55bdc0 -r 760fb1ee7722 sys/arch/evbppc/conf/Makefile.evbppc.inc
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/arch/evbppc/conf/Makefile.evbppc.inc Mon Dec 09 12:15:48 2002 +0000
@@ -0,0 +1,3 @@
+# $NetBSD: Makefile.evbppc.inc,v 1.1 2002/12/09 12:15:51 scw Exp $
+
+.-include "${THISPPC}/conf/Makefile.${BOARDTYPE}.inc"
diff -r 7ea38d55bdc0 -r 760fb1ee7722 sys/arch/evbppc/conf/Makefile.walnut.inc
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/arch/evbppc/conf/Makefile.walnut.inc Mon Dec 09 12:15:48 2002 +0000
@@ -0,0 +1,18 @@
+# $NetBSD: Makefile.walnut.inc,v 1.1 2002/12/09 12:15:52 scw Exp $
+
+MKIMG?= ${THISPPC}/compile/walnut-mkimg.sh
+CFLAGS+=-mcpu=403
+AFLAGS+=-mcpu=403
+TEXTADDR?= 25000
+
+SYSTEM_FIRST_OBJ= walnut_start.o
+SYSTEM_FIRST_SFILE= ${THISPPC}/walnut/walnut_start.S
+
+.ifdef DBSYM
+SYSTEM_LD_TAIL_EXTRA+=; echo ${DBSYM} $@; ${DBSYM} $@
+.endif
+
+SYSTEM_LD_TAIL_EXTRA+=; \
+ echo ${MKIMG} netbsd netbsd.img ; \
+ OBJDUMP=${OBJDUMP}; OBJCOPY=${OBJCOPY}; export OBJDUMP OBJCOPY; \
+ ${MKIMG} $@ $@.img
diff -r 7ea38d55bdc0 -r 760fb1ee7722 sys/arch/evbppc/conf/WALNUT
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/arch/evbppc/conf/WALNUT Mon Dec 09 12:15:48 2002 +0000
@@ -0,0 +1,257 @@
+# $NetBSD: WALNUT,v 1.1 2002/12/09 12:15:52 scw Exp $
+#
+# GENERIC -- everything that's currently supported
+#
+
+include "arch/evbppc/conf/std.walnut"
+
+#options INCLUDE_CONFIG_FILE # embed config file in kernel binary
+
+#ident "WALNUT"
+
+maxusers 32
+
+#options UVMHIST
+#options UVMHIST_PRINT
+
+# Options for necessary to use MD
+#options MEMORY_DISK_HOOKS
+#options MEMORY_DISK_IS_ROOT # force root on memory disk
+#options MEMORY_DISK_SERVER=0 # no userspace memory disk support
+#options MEMORY_DISK_ROOT_SIZE=16384 # size of memory disk, in blocks
+
+
+#options UCONSOLE # users can use TIOCCONS (for xconsole)
+#options INSECURE # disable kernel security levels
+#options NTP # NTP phase/frequency locked loop
+options KTRACE # system call tracing via ktrace(1)
+
+options SYSVMSG # System V message queues
+options SYSVSEM # System V semaphores
+options SYSVSHM # System V shared memory
+#options SHMMAXPGS=1024 # 1024 pages is the default
+
+#options LKM # loadable kernel modules
+
+options USERCONF # userconf(4) support
+#options PIPE_SOCKETPAIR # smaller, but slower pipe(2)
+
+# Diagnostic/debugging support options
+#options DIAGNOSTIC # cheap kernel consistency checks
+#options DEBUG # expensive debugging checks/support
+options DDB # in-kernel debugger
+options DDB_HISTORY_SIZE=512 # enable history editing in DDB
+options TRAP_PANICWAIT
+options SYMTAB_SPACE=300000 # size for embedded symbol table
+
+makeoptions DEBUG="-g" # compile full symbol table
+
+# Compatibility options
+#options COMPAT_09 # NetBSD 0.9,
+#options COMPAT_10 # NetBSD 1.0,
+#options COMPAT_11 # NetBSD 1.1,
+#options COMPAT_12 # NetBSD 1.2,
+options COMPAT_13 # NetBSD 1.3,
+options COMPAT_14 # NetBSD 1.4,
+options COMPAT_43 # and 4.3BSD
+#options COMPAT_386BSD_MBRPART # recognize old partition ID
+#options TCP_COMPAT_42 # 4.2BSD TCP/IP bug compat. Not recommended.
+
+# File systems
+file-system FFS # UFS
+file-system EXT2FS # second extended file system (linux)
+file-system LFS # log-structured file system
+file-system MFS # memory file system
+file-system NFS # Network File System client
+file-system CD9660 # ISO 9660 + Rock Ridge file system
+file-system MSDOSFS # MS-DOS file system
+file-system FDESC # /dev/fd
+file-system KERNFS # /kern
+file-system NULLFS # loopback file system
+file-system OVERLAY # overlay file system
+file-system PORTAL # portal filesystem (still experimental)
+file-system PROCFS # /proc
+file-system UMAPFS # NULLFS + uid and gid remapping
+file-system UNION # union file system
+
+# File system options
+options QUOTA # UFS quotas
+#options FFS_EI # FFS Endian Independant support
+options SOFTDEP # FFS soft updates support.
+options NFSSERVER # Network File System server
+options EXT2FS_SYSTEM_FLAGS # makes ext2fs file flags (append and
+ # immutable) behave as system flags.
+
+options NFS_BOOT_DHCP # Support DHCP NFS root
+
+# Networking options
+#options GATEWAY # packet forwarding
+options INET # IP + ICMP + TCP + UDP
+options INET6 # IPV6
+#options IPSEC # IP security
+#options IPSEC_ESP # IP security (encryption part; define w/IPSEC)
+#options IPSEC_DEBUG # debug for IP security
+#options MROUTING # IP multicast routing
+#options DIRECTED_BROADCAST # allow broadcasts through routers
+#options NS # XNS
+#options NSIP # XNS tunneling over IP
+options ISO,TPIP # OSI
+#options EON # OSI tunneling over IP
+#options CCITT,LLC,HDLC # X.25
+#options NETATALK # AppleTalk networking protocols
+options PPP_BSDCOMP # BSD-Compress compression support for PPP
+options PPP_DEFLATE # Deflate compression support for PPP
+options PPP_FILTER # Active filter support for PPP (requires bpf)
+options PFIL_HOOKS # pfil(9) packet filter hooks
+options IPFILTER_LOG # ipmon(8) log support
+#options TCP_DEBUG # Record last TCP_NDEBUG packets with SO_DEBUG
+options NMBCLUSTERS=1024
+
+# These options enable verbose messages for several subsystems.
+# Warning, these may compile large string tables into the kernel!
+options PCIVERBOSE # verbose PCI device autoconfig messages
+options MIIVERBOSE # verbose PHY autoconfig messages
+#options PCI_CONFIG_DUMP # verbosely dump PCI config space
+options SCSIVERBOSE # human readable SCSI error messages
+options PCI_NETBSD_CONFIGURE # Do not rely on BIOS/whatever to configure PCI devices
+#options PCI_CONFIGURE_VERBOSE # Show PCI config information
+
+# wscons options
+#options WSEMUL_SUN # sun terminal emulation
+#options WSEMUL_VT100 # VT100 / VT220 emulation
+
+# Kernel root file system and dump configuration.
+config netbsd root on ? type ?
+
+#
+# Device configuration
+#
+
+plb0 at root # Processor Local Bus
+
+cpu0 at plb?
+
+ecc0 at plb? irq 16 # On-chip ECC controller
+
+opb* at plb? # On-chip Peripheral Bus
+
+wdog* at opb? # Watchdog timer
+
+com* at opb? addr ? irq ? # UARTs
+
+emac0 at opb? addr ? irq ? # Ethernet Media Access Controller
+options EMAC_EVENT_COUNTERS
+
+pchb0 at plb? # PCI-Host bridges
+
+pci* at pchb?
+ppb* at pci? dev ? function ? # PCI-PCI bridges
+
+fpa* at pci? dev ? function ? # DEC PCI FDDI (DEFPA) Controller
+ep* at pci? dev ? function ? # 3Com 3c59x
+epic* at pci? dev ? function ? # SMC EPIC/100 Ethernet
+ex* at pci? dev ? function ? # 3Com 90x[B]
+fxp* at pci? dev ? function ? # Intel EtherExpress PRO 10+/100B
+ne* at pci? dev ? function ? # NE2000-compatible Ethernet
+rtk* at pci? dev ? function ? # Realtek 8129/8139
+sip* at pci? dev ? function ? # SiS 900/7016 Ethernet
+tlp* at pci? dev ? function ? # DECchip 21x4x and clones
+adv* at pci? dev ? function ? # AdvanSys 1200[A,B], 9xx[U,UA] SCSI
+adw* at pci? dev ? function ? # AdvanSys 9x0UW[D], 3940U[2,3]W SCSI
+ahc* at pci? dev ? function ? # Adaptec 294x, aic78x0 SCSI
+bha* at pci? dev ? function ? # BusLogic 9xx SCSI
+isp* at pci? dev ? function ? # Qlogic ISP 10x0/2xx0 SCSI/Fibre Chan
Home |
Main Index |
Thread Index |
Old Index