summaryrefslogtreecommitdiff
path: root/c/src/lib/libbsp/m68k/csb360/include
diff options
context:
space:
mode:
authorJay Monkman <jtm@smoothsmoothie.com>2004-08-03 05:01:51 +0000
committerJay Monkman <jtm@smoothsmoothie.com>2004-08-03 05:01:51 +0000
commit02e708dc257687b6fe5eb624af9020e688094085 (patch)
treebf62686a2df10a6069e834c0d10e62c4a0159658 /c/src/lib/libbsp/m68k/csb360/include
parent3cfd52051fffed2ff9497283e7400480befc6d32 (diff)
2004-08-03 Jay Monkman <jtm@lopingdog.com>
* .cvsignore, ChangeLog, Makefile.am, README, bsp_specs, configure.ac, times, console/.cvsignore, console/console-io.c, include/.cvsignore, include/bsp.h, include/coverhd.h, include/tm27.h, network/network.c, start/.cvsignore, start/start.S, startup/.cvsignore, startup/bspclean.c, startup/bspstart.c, startup/init5272.c, startup/linkcmds: New files.
Diffstat (limited to 'c/src/lib/libbsp/m68k/csb360/include')
-rw-r--r--c/src/lib/libbsp/m68k/csb360/include/.cvsignore6
-rw-r--r--c/src/lib/libbsp/m68k/csb360/include/bsp.h218
-rw-r--r--c/src/lib/libbsp/m68k/csb360/include/coverhd.h82
-rw-r--r--c/src/lib/libbsp/m68k/csb360/include/tm27.h33
4 files changed, 339 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/m68k/csb360/include/.cvsignore b/c/src/lib/libbsp/m68k/csb360/include/.cvsignore
new file mode 100644
index 0000000000..b0be3c54e6
--- /dev/null
+++ b/c/src/lib/libbsp/m68k/csb360/include/.cvsignore
@@ -0,0 +1,6 @@
+Makefile
+Makefile.in
+bspopts.h
+bspopts.h.in
+stamp-h
+stamp-h.in
diff --git a/c/src/lib/libbsp/m68k/csb360/include/bsp.h b/c/src/lib/libbsp/m68k/csb360/include/bsp.h
new file mode 100644
index 0000000000..c41d8355b1
--- /dev/null
+++ b/c/src/lib/libbsp/m68k/csb360/include/bsp.h
@@ -0,0 +1,218 @@
+/*
+ * Board Support Package for CSB360 evaluation board
+ * BSP definitions
+ *
+ * Copyright 2004 Cogent Computer Systems
+ * Author: Jay Monkman <jtm@lopingdog.com>
+ *
+ * Derived from mcf5206elite BSP:
+ * Copyright (C) 2000 OKTET Ltd., St.-Petersburg, Russia
+ * Author: Victor V. Vengerov <vvv@oktet.ru>
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ *
+ * http://www.OARcorp.com/rtems/license.html.
+ *
+ * bsp.h,v 1.1 2001/10/26 19:30:10 joel Exp
+ */
+
+#ifndef __CSB360_BSP_H__
+#define __CSB360_BSP_H__
+
+#include <mcf5272/mcf5272.h>
+
+
+/*** Board resources allocation ***/
+#define BSP_MEM_ADDR_SRAM 0x20000000
+#define BSP_MEM_SIZE_SRAM 4096
+
+/* Location and size of sdram. Note this includes space used by
+ * umon.
+ */
+#define BSP_MEM_ADDR_SDRAM 0x00000000
+#define BSP_MEM_MASK_SDRAM 0x01ffffff
+#define BSP_MEM_SIZE_SDRAM (32 * 1024 * 1024)
+
+/* Address to put SIM Modules */
+#define BSP_MBAR 0x10000000
+
+/* Address to put SRAM */
+#define BSP_RAMBAR BSP_MEM_ADDR_SRAM
+
+/* Interrupt Vectors */
+#define BSP_INTVEC_INT1 65
+#define BSP_INTVEC_INT2 66
+#define BSP_INTVEC_INT3 67
+#define BSP_INTVEC_INT4 68
+#define BSP_INTVEC_TMR0 69
+#define BSP_INTVEC_TMR1 70
+#define BSP_INTVEC_TMR2 71
+#define BSP_INTVEC_TMR3 72
+#define BSP_INTVEC_UART1 73
+#define BSP_INTVEC_UART2 74
+#define BSP_INTVEC_PLIP 75
+#define BSP_INTVEC_PLIA 76
+#define BSP_INTVEC_USB0 77
+#define BSP_INTVEC_USB1 78
+#define BSP_INTVEC_USB2 79
+#define BSP_INTVEC_USB3 80
+#define BSP_INTVEC_USB4 81
+#define BSP_INTVEC_USB5 82
+#define BSP_INTVEC_USB6 83
+#define BSP_INTVEC_USB7 84
+#define BSP_INTVEC_DMA 85
+#define BSP_INTVEC_ERX 86
+#define BSP_INTVEC_ETX 87
+#define BSP_INTVEC_ENTC 88
+#define BSP_INTVEC_QSPI 89
+#define BSP_INTVEC_INT5 90
+#define BSP_INTVEC_INT6 91
+#define BSP_INTVEC_SWTO 92
+
+#define BSP_INTLVL_INT1 1
+#define BSP_INTLVL_INT2 1
+#define BSP_INTLVL_INT3 1
+#define BSP_INTLVL_INT4 1
+#define BSP_INTLVL_TMR0 1
+#define BSP_INTLVL_TMR1 1
+#define BSP_INTLVL_TMR2 1
+#define BSP_INTLVL_TMR3 1
+#define BSP_INTLVL_UART1 1
+#define BSP_INTLVL_UART2 1
+#define BSP_INTLVL_PLIP 1
+#define BSP_INTLVL_PLIA 1
+#define BSP_INTLVL_USB0 1
+#define BSP_INTLVL_USB1 1
+#define BSP_INTLVL_USB2 1
+#define BSP_INTLVL_USB3 1
+#define BSP_INTLVL_USB4 1
+#define BSP_INTLVL_USB5 1
+#define BSP_INTLVL_USB6 1
+#define BSP_INTLVL_USB7 1
+#define BSP_INTLVL_DMA 1
+#define BSP_INTLVL_ERX 1
+#define BSP_INTLVL_ETX 1
+#define BSP_INTLVL_ENTC 1
+#define BSP_INTLVL_QSPI 1
+#define BSP_INTLVL_INT5 1
+#define BSP_INTLVL_INT6 1
+#define BSP_INTLVL_SWTO 1
+
+
+
+#ifndef ASM
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#include <bspopts.h>
+#include <rtems.h>
+#include <rtems/console.h>
+#include <rtems/iosupp.h>
+#include <rtems/clockdrv.h>
+
+struct rtems_bsdnet_ifconfig;
+extern int rtems_enet_driver_attach (struct rtems_bsdnet_ifconfig *config);
+#define RTEMS_BSP_NETWORK_DRIVER_NAME "eth0"
+#define RTEMS_BSP_NETWORK_DRIVER_ATTACH rtems_enet_driver_attach
+
+/*
+ * confdefs.h overrides for this BSP:
+ * - termios serial ports (defaults to 1)
+ * - Interrupt stack space is not minimum if defined.
+ */
+
+#define CONFIGURE_NUMBER_OF_TERMIOS_PORTS 2
+#define CONFIGURE_INTERRUPT_STACK_MEMORY (4 * 1024)
+
+/* System frequency */
+#define BSP_SYSTEM_FREQUENCY (66 * 1000 * 1000)
+
+/*
+ * Define the time limits for RTEMS Test Suite test durations.
+ * Long test and short test duration limits are provided. These
+ * values are in seconds and need to be converted to ticks for the
+ * application.
+ *
+ */
+
+#define MAX_LONG_TEST_DURATION 300 /* 5 minutes = 300 seconds */
+#define MAX_SHORT_TEST_DURATION 3 /* 3 seconds */
+
+/*
+ * Simple spin delay in microsecond units for device drivers.
+ * This is very dependent on the clock speed of the target.
+ */
+
+#define delay( microseconds ) \
+ { register rtems_unsigned32 _delay=(microseconds); \
+ register rtems_unsigned32 _tmp=123; \
+ asm volatile( "0: \
+ nbcd %0 ; \
+ nbcd %0 ; \
+ dbf %1,0b" \
+ : "=d" (_tmp), "=d" (_delay) \
+ : "0" (_tmp), "1" (_delay) ); \
+ }
+
+/* Constants */
+
+/* Structures */
+
+/*
+ * Device Driver Table Entries
+ */
+
+/*
+ * NOTE: Use the standard Console driver entry
+ */
+
+/*
+ * NOTE: Use the standard Clock driver entry
+ */
+
+/*
+ * Real-Time Clock Driver Table Entry
+ * NOTE: put this entry to the device driver table AFTER I2C bus driver!
+ */
+#define RTC_DRIVER_TABLE_ENTRY \
+ { rtc_initialize, NULL, NULL, NULL, NULL, NULL }
+extern rtems_device_driver rtc_initialize(
+ rtems_device_major_number major,
+ rtems_device_minor_number minor,
+ void *arg
+);
+
+/* miscellaneous stuff assumed to exist */
+
+extern rtems_configuration_table BSP_Configuration;
+
+extern m68k_isr_entry M68Kvec[]; /* vector table address */
+
+extern rtems_isr (*rtems_clock_hook)(rtems_vector_number);
+
+/* functions */
+
+void bsp_cleanup( void );
+
+m68k_isr_entry set_vector(
+ rtems_isr_entry handler,
+ rtems_vector_number vector,
+ int type
+);
+
+/*
+ * Values assigned by link editor
+ */
+extern void *_RomBase, *_RamBase;
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* ASM */
+
+#endif
+/* end of include file */
diff --git a/c/src/lib/libbsp/m68k/csb360/include/coverhd.h b/c/src/lib/libbsp/m68k/csb360/include/coverhd.h
new file mode 100644
index 0000000000..e102b5ddbf
--- /dev/null
+++ b/c/src/lib/libbsp/m68k/csb360/include/coverhd.h
@@ -0,0 +1,82 @@
+/*
+ * This file based on output of tmoverhd test.
+ *
+ * $Id$
+ */
+
+#ifndef __COVERHD_H__
+#define __COVERHD_H__
+
+#define CALLING_OVERHEAD_INITIALIZE_EXECUTIVE 0
+#define CALLING_OVERHEAD_SHUTDOWN_EXECUTIVE 0
+#define CALLING_OVERHEAD_TASK_CREATE 1
+#define CALLING_OVERHEAD_TASK_IDENT 0
+#define CALLING_OVERHEAD_TASK_START 0
+#define CALLING_OVERHEAD_TASK_RESTART 0
+#define CALLING_OVERHEAD_TASK_DELETE 0
+#define CALLING_OVERHEAD_TASK_SUSPEND 0
+#define CALLING_OVERHEAD_TASK_RESUME 0
+#define CALLING_OVERHEAD_TASK_SET_PRIORITY 0
+#define CALLING_OVERHEAD_TASK_MODE 0
+#define CALLING_OVERHEAD_TASK_GET_NOTE 0
+#define CALLING_OVERHEAD_TASK_SET_NOTE 0
+#define CALLING_OVERHEAD_TASK_WAKE_WHEN 2
+#define CALLING_OVERHEAD_TASK_WAKE_AFTER 0
+#define CALLING_OVERHEAD_INTERRUPT_CATCH 0
+#define CALLING_OVERHEAD_CLOCK_GET 2
+#define CALLING_OVERHEAD_CLOCK_SET 2
+#define CALLING_OVERHEAD_CLOCK_TICK 0
+#define CALLING_OVERHEAD_TIMER_CREATE 0
+#define CALLING_OVERHEAD_TIMER_DELETE 0
+#define CALLING_OVERHEAD_TIMER_IDENT 0
+#define CALLING_OVERHEAD_TIMER_FIRE_AFTER 0
+#define CALLING_OVERHEAD_TIMER_FIRE_WHEN 2
+#define CALLING_OVERHEAD_TIMER_RESET 0
+#define CALLING_OVERHEAD_TIMER_CANCEL 0
+#define CALLING_OVERHEAD_SEMAPHORE_CREATE 1
+#define CALLING_OVERHEAD_SEMAPHORE_DELETE 0
+#define CALLING_OVERHEAD_SEMAPHORE_IDENT 0
+#define CALLING_OVERHEAD_SEMAPHORE_OBTAIN 0
+#define CALLING_OVERHEAD_SEMAPHORE_RELEASE 0
+#define CALLING_OVERHEAD_MESSAGE_QUEUE_CREATE 0
+#define CALLING_OVERHEAD_MESSAGE_QUEUE_IDENT 0
+#define CALLING_OVERHEAD_MESSAGE_QUEUE_DELETE 0
+#define CALLING_OVERHEAD_MESSAGE_QUEUE_SEND 0
+#define CALLING_OVERHEAD_MESSAGE_QUEUE_URGENT 0
+#define CALLING_OVERHEAD_MESSAGE_QUEUE_BROADCAST 0
+#define CALLING_OVERHEAD_MESSAGE_QUEUE_RECEIVE 0
+#define CALLING_OVERHEAD_MESSAGE_QUEUE_FLUSH 0
+#define CALLING_OVERHEAD_EVENT_SEND 0
+#define CALLING_OVERHEAD_EVENT_RECEIVE 0
+#define CALLING_OVERHEAD_SIGNAL_CATCH 0
+#define CALLING_OVERHEAD_SIGNAL_SEND 0
+#define CALLING_OVERHEAD_PARTITION_CREATE 1
+#define CALLING_OVERHEAD_PARTITION_IDENT 0
+#define CALLING_OVERHEAD_PARTITION_DELETE 0
+#define CALLING_OVERHEAD_PARTITION_GET_BUFFER 0
+#define CALLING_OVERHEAD_PARTITION_RETURN_BUFFER 0
+#define CALLING_OVERHEAD_REGION_CREATE 1
+#define CALLING_OVERHEAD_REGION_IDENT 0
+#define CALLING_OVERHEAD_REGION_DELETE 0
+#define CALLING_OVERHEAD_REGION_GET_SEGMENT 1
+#define CALLING_OVERHEAD_REGION_RETURN_SEGMENT 0
+#define CALLING_OVERHEAD_PORT_CREATE 1
+#define CALLING_OVERHEAD_PORT_IDENT 0
+#define CALLING_OVERHEAD_PORT_DELETE 0
+#define CALLING_OVERHEAD_PORT_EXTERNAL_TO_INTERNAL 0
+#define CALLING_OVERHEAD_PORT_INTERNAL_TO_EXTERNAL 0
+#define CALLING_OVERHEAD_IO_INITIALIZE 0
+#define CALLING_OVERHEAD_IO_OPEN 0
+#define CALLING_OVERHEAD_IO_CLOSE 0
+#define CALLING_OVERHEAD_IO_READ 0
+#define CALLING_OVERHEAD_IO_WRITE 0
+#define CALLING_OVERHEAD_IO_CONTROL 0
+#define CALLING_OVERHEAD_FATAL_ERROR_OCCURRED 0
+#define CALLING_OVERHEAD_RATE_MONOTONIC_CREATE 0
+#define CALLING_OVERHEAD_RATE_MONOTONIC_IDENT 0
+#define CALLING_OVERHEAD_RATE_MONOTONIC_DELETE 0
+#define CALLING_OVERHEAD_RATE_MONOTONIC_CANCEL 0
+#define CALLING_OVERHEAD_RATE_MONOTONIC_PERIOD 0
+#define CALLING_OVERHEAD_MULTIPROCESSING_ANNOUNCE 0
+
+#endif /* __COVERHD_H__ */
diff --git a/c/src/lib/libbsp/m68k/csb360/include/tm27.h b/c/src/lib/libbsp/m68k/csb360/include/tm27.h
new file mode 100644
index 0000000000..44886acafc
--- /dev/null
+++ b/c/src/lib/libbsp/m68k/csb360/include/tm27.h
@@ -0,0 +1,33 @@
+/*
+ * tm27.h
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.rtems.com/license/LICENSE.
+ *
+ * $Id$
+ */
+
+#ifndef _RTEMS_TMTEST27
+#error "This is an RTEMS internal file you must not include directly."
+#endif
+
+#ifndef __tm27_h
+#define __tm27_h
+
+/*
+ * Stuff for Time Test 27
+ * Don't bother with hardware -- just use a software-interrupt
+ */
+
+#define MUST_WAIT_FOR_INTERRUPT 0
+
+#define Install_tm27_vector( handler ) set_vector( (handler), 34, 1 )
+
+#define Cause_tm27_intr() asm volatile ("trap #2");
+
+#define Clear_tm27_intr() /* empty */
+
+#define Lower_tm27_intr() /* empty */
+
+#endif