URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Subversion Repositories openrisc
Compare Revisions
- This comparison shows the changes necessary to convert path
/openrisc/trunk/rtos/rtems/c/src/lib/libbsp/no_cpu
- from Rev 30 to Rev 173
- ↔ Reverse comparison
Rev 30 → Rev 173
/no_bsp/shmsupp/getcfg.c
0,0 → 1,76
/* void Shm_Get_configuration( localnode, &shmcfg ) |
* |
* This routine initializes, if necessary, and returns a pointer |
* to the Shared Memory Configuration Table for the XXX target. |
* |
* INPUT PARAMETERS: |
* localnode - local node number |
* shmcfg - address of pointer to SHM Config Table |
* |
* OUTPUT PARAMETERS: |
* *shmcfg - pointer to SHM Config Table |
* |
XXX: FIX THE COMMENTS BELOW WHEN THE CPU IS KNOWN |
* NOTES: The XYZ does not have an interprocessor interrupt. |
* |
* The following table illustrates the configuration limitations: |
* |
* BUS MAX |
* MODE ENDIAN NODES |
* ========= ====== ======= |
* POLLED BIG 2+ |
* INTERRUPT **** NOT SUPPORTED **** |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: getcfg.c,v 1.2 2001-09-27 12:00:27 chris Exp $ |
*/ |
|
#include <rtems.h> |
#include <bsp.h> |
#include <shm_driver.h> |
|
/* |
* configured if currently polling of interrupt driven |
*/ |
|
#define INTERRUPT 0 /* XXX: */ |
#define POLLING 1 /* XXX: fix me -- is polling ONLY!!! */ |
|
|
shm_config_table BSP_shm_cfgtbl; |
|
void Shm_Get_configuration( |
rtems_unsigned32 localnode, |
shm_config_table **shmcfg |
) |
{ |
BSP_shm_cfgtbl.base = 0x0; |
BSP_shm_cfgtbl.length = 1 * MEGABYTE; |
BSP_shm_cfgtbl.format = SHM_BIG; |
|
/* |
* Override cause_intr or shm_isr if your target has |
* special requirements. |
*/ |
|
BSP_shm_cfgtbl.cause_intr = Shm_Cause_interrupt; |
|
#ifdef NEUTRAL_BIG |
BSP_shm_cfgtbl.convert = NULL_CONVERT; |
#else |
BSP_shm_cfgtbl.convert = CPU_swap_u32; |
#endif |
|
BSP_shm_cfgtbl.poll_intr = POLLED_MODE; |
BSP_shm_cfgtbl.Intr.address = NO_INTERRUPT; |
BSP_shm_cfgtbl.Intr.value = NO_INTERRUPT; |
BSP_shm_cfgtbl.Intr.length = NO_INTERRUPT; |
|
*shmcfg = &BSP_shm_cfgtbl; |
} |
/no_bsp/shmsupp/addrconv.c
0,0 → 1,30
/* Shm_Convert_address |
* |
* No address range conversion is required. |
* |
* Input parameters: |
* address - address to convert |
* |
* Output parameters: |
* returns - converted address |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: addrconv.c,v 1.2 2001-09-27 12:00:27 chris Exp $ |
*/ |
|
#include <rtems.h> |
#include <bsp.h> |
#include <shm_driver.h> |
|
void *Shm_Convert_address( |
void *address |
) |
{ |
return ( address ); |
} |
/no_bsp/shmsupp/Makefile.am
0,0 → 1,33
## |
## $Id: Makefile.am,v 1.2 2001-09-27 12:00:27 chris Exp $ |
## |
|
AUTOMAKE_OPTIONS = foreign 1.4 |
|
PGM = $(ARCH)/shmsupp.rel |
|
## C source names |
C_FILES = addrconv.c getcfg.c lock.c mpisr.c |
C_O_FILES = $(C_FILES:%.c=$(ARCH)/%.o) |
|
OBJS = $(C_O_FILES) |
|
include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg |
include $(top_srcdir)/../../../../../../automake/lib.am |
|
# |
# (OPTIONAL) Add local stuff here using += |
# |
|
$(PGM): $(OBJS) |
$(make-rel) |
|
if HAS_MP |
all-local: $(ARCH) $(PGM) |
endif |
|
# the .rel file built here will be put into libbsp.a by ../wrapup/Makefile |
|
EXTRA_DIST = addrconv.c getcfg.c lock.c mpisr.c |
|
include $(top_srcdir)/../../../../../../automake/local.am |
/no_bsp/shmsupp/lock.c
0,0 → 1,85
/* Shared Memory Lock Routines |
* |
* This shared memory locked queue support routine need to be |
* able to lock the specified locked queue. Interrupts are |
* disabled while the queue is locked to prevent preemption |
* and deadlock when two tasks poll for the same lock. |
* previous level. |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: lock.c,v 1.2 2001-09-27 12:00:27 chris Exp $ |
*/ |
|
#include <rtems.h> |
#include <bsp.h> |
#include <shm_driver.h> |
|
/* |
* Shm_Initialize_lock |
* |
* Initialize the lock for the specified locked queue. |
*/ |
|
void Shm_Initialize_lock( |
Shm_Locked_queue_Control *lq_cb |
) |
{ |
lq_cb->lock = LQ_UNLOCKED; |
} |
|
/* void _Shm_Lock( &lq_cb ) |
* |
* This shared memory locked queue support routine locks the |
* specified locked queue. It disables interrupts to prevent |
* a deadlock condition. |
*/ |
|
void Shm_Lock( |
Shm_Locked_queue_Control *lq_cb |
) |
{ |
rtems_unsigned32 isr_level; |
rtems_unsigned32 *lockptr = (rtems_unsigned32 *) &lq_cb->lock; |
rtems_unsigned32 lock_value; |
|
lock_value = 0x80000000; |
rtems_interrupt_disable( isr_level ); |
|
Shm_isrstat = isr_level; |
while ( lock_value ) { |
asm volatile( "" |
: "=r" (lockptr), "=r" (lock_value) |
: "0" (lockptr), "1" (lock_value) |
); |
/* |
* If not available, then may want to delay to reduce load on lock. |
*/ |
|
if ( lock_value ) |
delay( 10 ); /* approximately 10 microseconds */ |
} |
} |
|
/* |
* Shm_Unlock |
* |
* Unlock the lock for the specified locked queue. |
*/ |
|
void Shm_Unlock( |
Shm_Locked_queue_Control *lq_cb |
) |
{ |
rtems_unsigned32 isr_level; |
|
lq_cb->lock = SHM_UNLOCK_VALUE; |
isr_level = Shm_isrstat; |
rtems_interrupt_enable( isr_level ); |
} |
|
/no_bsp/shmsupp/mpisr.c
0,0 → 1,46
/* Shm_isr_nobsp() |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: mpisr.c,v 1.2 2001-09-27 12:00:27 chris Exp $ |
*/ |
|
#include <rtems.h> |
#include <bsp.h> |
#include <shm_driver.h> |
|
rtems_isr Shm_isr_nobsp( void ) |
{ |
/* |
* If this routine has to do anything other than the mpisr.c |
* found in the generic driver, then copy the contents of the generic |
* mpisr.c and augment it to satisfy this particular board. Typically, |
* you need to have a board specific mpisr.c when the interrupt |
* must be cleared. |
* |
* If the generic mpisr.c satisifies your requirements, then |
* remove this routine from your target's shmsupp/mpisb.c file. |
* Then simply install the generic Shm_isr in the Shm_setvec |
* routine below. |
*/ |
} |
|
/* Shm_setvec |
* |
* This driver routine sets the SHM interrupt vector to point to the |
* driver's SHM interrupt service routine. |
* |
* Input parameters: NONE |
* |
* Output parameters: NONE |
*/ |
|
void Shm_setvec( void ) |
{ |
/* XXX: FIX ME!!! */ |
} |
/no_bsp/timer/timerisr.c
0,0 → 1,36
/* timerisr.s |
* |
* If required this ISR is used to bump a count of interval "overflow" |
* interrupts which have occurred since the timer was started. The |
* number of overflows is taken into account in the Read_timer() |
* routine if necessary. |
* |
* To reduce overhead this is best to be the "rawest" hardware interupt |
* handler you can write. This should be the only interrupt which can |
* occur during the measured time period. |
* |
* NOTE: This file is USUALLY in assembly and is LEAN AND MEAN. |
* Any code in this isr is pure overhead which can perturb |
* the accuracy of the Timing Test Suite. |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: timerisr.c,v 1.2 2001-09-27 12:00:27 chris Exp $ |
*/ |
|
#include <rtems.h> |
|
extern rtems_unsigned32 _Timer_interrupts; |
|
void timerisr( void ) |
{ |
/* |
* _Timer_interrupts += TIMER_BETWEEN_OVERFLOWS (usually in microseconds) |
* return from interrupt |
*/ |
} |
/no_bsp/timer/timer.c
0,0 → 1,104
/* timer.c |
* |
* This file manages the benchmark timer used by the RTEMS Timing Test |
* Suite. Each measured time period is demarcated by calls to |
* Timer_initialize() and Read_timer(). Read_timer() usually returns |
* the number of microseconds since Timer_initialize() exitted. |
* |
* NOTE: It is important that the timer start/stop overhead be |
* determined when porting or modifying this code. |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: timer.c,v 1.2 2001-09-27 12:00:27 chris Exp $ |
*/ |
|
#include <rtems.h> |
#include <bsp.h> |
|
rtems_unsigned32 Timer_interrupts; |
rtems_boolean Timer_driver_Find_average_overhead; |
|
void Timer_initialize( void ) |
{ |
|
/* |
* Timer has never overflowed. This may not be necessary on some |
* implemenations of timer but .... |
*/ |
|
Timer_interrupts = 0; |
|
/* |
* Somehow start the timer |
*/ |
} |
|
/* |
* The following controls the behavior of Read_timer(). |
* |
* AVG_OVEREHAD is the overhead for starting and stopping the timer. It |
* is usually deducted from the number returned. |
* |
* LEAST_VALID is the lowest number this routine should trust. Numbers |
* below this are "noise" and zero is returned. |
*/ |
|
#define AVG_OVERHEAD 0 /* It typically takes X.X microseconds */ |
/* (Y countdowns) to start/stop the timer. */ |
/* This value is in microseconds. */ |
#define LEAST_VALID 1 /* Don't trust a clicks value lower than this */ |
|
int Read_timer( void ) |
{ |
rtems_unsigned32 clicks; |
rtems_unsigned32 total; |
|
/* |
* Read the timer and see how many clicks it has been since we started. |
*/ |
|
clicks = 0; /* XXX: read some HW here */ |
|
/* |
* Total is calculated by taking into account the number of timer overflow |
* interrupts since the timer was initialized and clicks since the last |
* interrupts. |
*/ |
|
total = clicks * 0; |
|
if ( Timer_driver_Find_average_overhead == 1 ) |
return total; /* in XXX microsecond units */ |
else { |
if ( total < LEAST_VALID ) |
return 0; /* below timer resolution */ |
/* |
* Somehow convert total into microseconds |
*/ |
return (total - AVG_OVERHEAD); |
} |
} |
|
/* |
* Empty function call used in loops to measure basic cost of looping |
* in Timing Test Suite. |
*/ |
|
rtems_status_code Empty_function( void ) |
{ |
return RTEMS_SUCCESSFUL; |
} |
|
void Set_find_average_overhead( |
rtems_boolean find_flag |
) |
{ |
Timer_driver_Find_average_overhead = find_flag; |
} |
|
/no_bsp/timer/Makefile.am
0,0 → 1,32
## |
## $Id: Makefile.am,v 1.2 2001-09-27 12:00:27 chris Exp $ |
## |
|
AUTOMAKE_OPTIONS = foreign 1.4 |
|
PGM = $(ARCH)/timer.rel |
|
C_FILES = timer.c timerisr.c |
C_O_FILES = $(C_FILES:%.c=$(ARCH)/%.o) |
|
OBJS = $(C_O_FILES) |
|
include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg |
include $(top_srcdir)/../../../../../../automake/lib.am |
|
# |
# (OPTIONAL) Add local stuff here using += |
# |
|
$(PGM): $(OBJS) |
$(make-rel) |
|
# the .rel file built here will be put into libbsp.a by ../wrapup/Makefile |
|
all-local: $(ARCH) $(OBJS) $(PGM) |
|
.PRECIOUS: $(PGM) |
|
EXTRA_DIST = timer.c timerisr.c |
|
include $(top_srcdir)/../../../../../../automake/local.am |
/no_bsp/bsp_specs
0,0 → 1,12
%rename cpp old_cpp |
%rename lib old_lib |
|
*cpp: |
%(old_cpp) %{qrtems: -D__embedded__} -Asystem(embedded) |
|
*lib: |
%{!qrtems: %(old_lib)} \ |
%{qrtems: --start-group %{!qrtems_debug: -lrtemsall } %{qrtems_debug: -lrtemsall_g} \ |
-lc -lgcc --end-group \ |
%{!qnolinkcmds: -T linkcmds%s}} |
|
/no_bsp/times
0,0 → 1,194
# |
# Timing Test Suite Results for the NO_BSP |
# |
# NOTE: This is just a template. The times are irrelevant since this BSP |
# can only be compiled -- not executed. |
# |
# $Id: times,v 1.2 2001-09-27 12:00:25 chris Exp $ |
# |
|
Board: |
CPU: include coprocessor if applicable |
Clock Speed: |
Memory Configuration: SRAM, DRAM, cache, etc |
Wait States: |
|
Times Reported in: cycles, microseconds, etc |
Timer Source: Count Down Timer, on-CPU cycle counter, etc |
|
Column X: |
Column Y: |
|
# DESCRIPTION A B |
== ================================================================= ==== ==== |
1 rtems_semaphore_create 20 |
rtems_semaphore_delete 21 |
rtems_semaphore_obtain: available 15 |
rtems_semaphore_obtain: not available -- NO_WAIT 15 |
rtems_semaphore_release: no waiting tasks 16 |
|
2 rtems_semaphore_obtain: not available -- caller blocks 62 |
|
3 rtems_semaphore_release: task readied -- preempts caller 55 |
|
4 rtems_task_restart: blocked task -- preempts caller 77 |
rtems_task_restart: ready task -- preempts caller 70 |
rtems_semaphore_release: task readied -- returns to caller 25 |
rtems_task_create 57 |
rtems_task_start 31 |
rtems_task_restart: suspended task -- returns to caller 36 |
rtems_task_delete: suspended task 47 |
rtems_task_restart: ready task -- returns to caller 37 |
rtems_task_restart: blocked task -- returns to caller 46 |
rtems_task_delete: blocked task 50 |
|
5 rtems_task_suspend: calling task 51 |
rtems_task_resume: task readied -- preempts caller 49 |
|
6 rtems_task_restart: calling task 59 |
rtems_task_suspend: returns to caller 18 |
rtems_task_resume: task readied -- returns to caller 19 |
rtems_task_delete: ready task 50 |
|
7 rtems_task_restart: suspended task -- preempts caller 70 |
|
8 rtems_task_set_priority: obtain current priority 12 |
rtems_task_set_priority: returns to caller 27 |
rtems_task_mode: obtain current mode 5 |
rtems_task_mode: no reschedule 5 |
rtems_task_mode: reschedule -- returns to caller 8 |
rtems_task_mode: reschedule -- preempts caller 39 |
rtems_task_set_note 13 |
rtems_task_get_note 13 |
rtems_clock_set 33 |
rtems_clock_get 3 |
|
9 rtems_message_queue_create 110 |
rtems_message_queue_send: no waiting tasks 37 |
rtems_message_queue_urgent: no waiting tasks 37 |
rtems_message_queue_receive: available 31 |
rtems_message_queue_flush: no messages flushed 12 |
rtems_message_queue_flush: messages flushed 16 |
rtems_message_queue_delete 26 |
|
10 rtems_message_queue_receive: not available -- NO_WAIT 15 |
rtems_message_queue_receive: not available -- caller blocks 62 |
|
11 rtems_message_queue_send: task readied -- preempts caller 72 |
|
12 rtems_message_queue_send: task readied -- returns to caller 39 |
|
13 rtems_message_queue_urgent: task readied -- preempts caller 72 |
|
14 rtems_message_queue_urgent: task readied -- returns to caller 39 |
|
15 rtems_event_receive: obtain current events 1 |
rtems_event_receive: not available -- NO_WAIT 12 |
rtems_event_receive: not available -- caller blocks 56 |
rtems_event_send: no task readied 12 |
rtems_event_receive: available 12 |
rtems_event_send: task readied -- returns to caller 24 |
|
16 rtems_event_send: task readied -- preempts caller 55 |
|
17 rtems_task_set_priority: preempts caller 62 |
|
18 rtems_task_delete: calling task 83 |
|
19 rtems_signal_catch 9 |
rtems_signal_send: returns to caller 15 |
rtems_signal_send: signal to self 18 |
exit ASR overhead: returns to calling task 22 |
exit ASR overhead: returns to preempting task 49 |
|
20 rtems_partition_create 35 |
rtems_region_create 23 |
rtems_partition_get_buffer: available 15 |
rtems_partition_get_buffer: not available 13 |
rtems_partition_return_buffer 18 |
rtems_partition_delete 16 |
rtems_region_get_segment: available 22 |
rtems_region_get_segment: not available -- NO_WAIT 21 |
rtems_region_return_segment: no waiting tasks 19 |
rtems_region_get_segment: not available -- caller blocks 64 |
rtems_region_return_segment: task readied -- preempts caller 74 |
rtems_region_return_segment: task readied -- returns to caller 44 |
rtems_region_delete 16 |
rtems_io_initialize 2 |
rtems_io_open 1 |
rtems_io_close 1 |
rtems_io_read 1 |
rtems_io_write 1 |
rtems_io_control 1 |
|
21 rtems_task_ident 149 |
rtems_message_queue_ident 145 |
rtems_semaphore_ident 156 |
rtems_partition_ident 145 |
rtems_region_ident 148 |
rtems_port_ident 145 |
rtems_timer_ident 145 |
rtems_rate_monotonic_ident 145 |
|
22 rtems_message_queue_broadcast: task readied -- returns to caller 42 |
rtems_message_queue_broadcast: no waiting tasks 17 |
rtems_message_queue_broadcast: task readied -- preempts caller 78 |
|
23 rtems_timer_create 14 |
rtems_timer_fire_after: inactive 22 |
rtems_timer_fire_after: active 24 |
rtems_timer_cancel: active 15 |
rtems_timer_cancel: inactive 13 |
rtems_timer_reset: inactive 21 |
rtems_timer_reset: active 23 |
rtems_timer_fire_when: inactive 34 |
rtems_timer_fire_when: active 34 |
rtems_timer_delete: active 19 |
rtems_timer_delete: inactive 17 |
rtems_task_wake_when 69 |
|
24 rtems_task_wake_after: yield -- returns to caller 9 |
rtems_task_wake_after: yields -- preempts caller 45 |
|
25 rtems_clock_tick 4 |
|
26 _ISR_Disable 0 |
_ISR_Flash 1 |
_ISR_Enable 1 |
_Thread_Disable_dispatch 0 |
_Thread_Enable_dispatch 7 |
_Thread_Set_state 11 |
_Thread_Disptach (NO FP) 31 |
context switch: no floating point contexts 21 |
context switch: self 10 |
context switch: to another task 10 |
context switch: restore 1st FP task 25 |
fp context switch: save idle, restore idle 31 |
fp context switch: save idle, restore initialized 19 |
fp context switch: save initialized, restore initialized 20 |
_Thread_Resume 7 |
_Thread_Unblock 7 |
_Thread_Ready 9 |
_Thread_Get 4 |
_Semaphore_Get 2 |
_Thread_Get: invalid id 0 |
|
27 interrupt entry overhead: returns to interrupted task 6 |
interrupt exit overhead: returns to interrupted task 6 |
interrupt entry overhead: returns to nested interrupt 6 |
interrupt exit overhead: returns to nested interrupt 5 |
interrupt entry overhead: returns to preempting task 7 |
interrupt exit overhead: returns to preempting task 36 |
|
28 rtems_port_create 16 |
rtems_port_external_to_internal 11 |
rtems_port_internal_to_external 11 |
rtems_port_delete 16 |
|
29 rtems_rate_monotonic_create 15 |
rtems_rate_monotonic_period: initiate period -- returns to caller 21 |
rtems_rate_monotonic_period: obtain status 13 |
rtems_rate_monotonic_cancel 16 |
rtems_rate_monotonic_delete: inactive 18 |
rtems_rate_monotonic_delete: active 20 |
rtems_rate_monotonic_period: conclude periods -- caller blocks 53 |
/no_bsp/console/console.c
0,0 → 1,221
/* |
* This file contains the template for a console IO package. |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: console.c,v 1.2 2001-09-27 12:00:26 chris Exp $ |
*/ |
|
#define NO_BSP_INIT |
|
#include <bsp.h> |
#include <rtems/libio.h> |
|
/* console_initialize |
* |
* This routine initializes the console IO driver. |
* |
* Input parameters: NONE |
* |
* Output parameters: NONE |
* |
* Return values: |
*/ |
|
rtems_device_driver console_initialize( |
rtems_device_major_number major, |
rtems_device_minor_number minor, |
void *arg |
) |
{ |
rtems_status_code status; |
|
status = rtems_io_register_name( |
"/dev/console", |
major, |
(rtems_device_minor_number) 0 |
); |
|
if (status != RTEMS_SUCCESSFUL) |
rtems_fatal_error_occurred(status); |
|
return RTEMS_SUCCESSFUL; |
} |
|
|
/* is_character_ready |
* |
* This routine returns TRUE if a character is available. |
* |
* Input parameters: NONE |
* |
* Output parameters: NONE |
* |
* Return values: |
*/ |
|
rtems_boolean is_character_ready( |
char *ch |
) |
{ |
*ch = '\0'; /* return NULL for no particular reason */ |
return(TRUE); |
} |
|
/* inbyte |
* |
* This routine reads a character from the SOURCE. |
* |
* Input parameters: NONE |
* |
* Output parameters: NONE |
* |
* Return values: |
* character read from SOURCE |
*/ |
|
char inbyte( void ) |
{ |
/* |
* If polling, wait until a character is available. |
*/ |
|
return '\0'; |
} |
|
/* outbyte |
* |
* This routine transmits a character out the SOURCE. It may support |
* XON/XOFF flow control. |
* |
* Input parameters: |
* ch - character to be transmitted |
* |
* Output parameters: NONE |
*/ |
|
void outbyte( |
char ch |
) |
{ |
/* |
* If polling, wait for the transmitter to be ready. |
* Check for flow control requests and process. |
* Then output the character. |
*/ |
|
/* |
* Carriage Return/New line translation. |
*/ |
|
if ( ch == '\n' ) |
outbyte( '\r' ); |
} |
|
|
/* |
* Open entry point |
*/ |
|
rtems_device_driver console_open( |
rtems_device_major_number major, |
rtems_device_minor_number minor, |
void * arg |
) |
{ |
return RTEMS_SUCCESSFUL; |
} |
|
/* |
* Close entry point |
*/ |
|
rtems_device_driver console_close( |
rtems_device_major_number major, |
rtems_device_minor_number minor, |
void * arg |
) |
{ |
return RTEMS_SUCCESSFUL; |
} |
|
/* |
* read bytes from the serial port. We only have stdin. |
*/ |
|
rtems_device_driver console_read( |
rtems_device_major_number major, |
rtems_device_minor_number minor, |
void * arg |
) |
{ |
rtems_libio_rw_args_t *rw_args; |
char *buffer; |
int maximum; |
int count = 0; |
|
rw_args = (rtems_libio_rw_args_t *) arg; |
|
buffer = rw_args->buffer; |
maximum = rw_args->count; |
|
for (count = 0; count < maximum; count++) { |
buffer[ count ] = inbyte(); |
if (buffer[ count ] == '\n' || buffer[ count ] == '\r') { |
buffer[ count++ ] = '\n'; |
break; |
} |
} |
|
rw_args->bytes_moved = count; |
return (count >= 0) ? RTEMS_SUCCESSFUL : RTEMS_UNSATISFIED; |
} |
|
/* |
* write bytes to the serial port. Stdout and stderr are the same. |
*/ |
|
rtems_device_driver console_write( |
rtems_device_major_number major, |
rtems_device_minor_number minor, |
void * arg |
) |
{ |
int count; |
int maximum; |
rtems_libio_rw_args_t *rw_args; |
char *buffer; |
|
rw_args = (rtems_libio_rw_args_t *) arg; |
|
buffer = rw_args->buffer; |
maximum = rw_args->count; |
|
for (count = 0; count < maximum; count++) { |
if ( buffer[ count ] == '\n') { |
outbyte('\r'); |
} |
outbyte( buffer[ count ] ); |
} |
|
rw_args->bytes_moved = maximum; |
return 0; |
} |
|
/* |
* IO Control entry point |
*/ |
|
rtems_device_driver console_control( |
rtems_device_major_number major, |
rtems_device_minor_number minor, |
void * arg |
) |
{ |
return RTEMS_SUCCESSFUL; |
} |
/no_bsp/console/Makefile.am
0,0 → 1,32
## |
## $Id: Makefile.am,v 1.2 2001-09-27 12:00:26 chris Exp $ |
## |
|
AUTOMAKE_OPTIONS = foreign 1.4 |
|
PGM = $(ARCH)/console.rel |
|
C_FILES = console.c |
C_O_FILES = $(C_FILES:%.c=$(ARCH)/%.o) |
|
OBJS = $(C_O_FILES) |
|
include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg |
include $(top_srcdir)/../../../../../../automake/lib.am |
|
# |
# (OPTIONAL) Add local stuff here using += |
# |
|
$(PGM): $(OBJS) |
$(make-rel) |
|
# the .rel file built here will be put into libbsp.a by ../wrapup/Makefile |
|
all-local: $(ARCH) $(OBJS) $(PGM) |
|
.PRECIOUS: $(PGM) |
|
EXTRA_DIST = console.c |
|
include $(top_srcdir)/../../../../../../automake/local.am |
/no_bsp/startup/bspstart.c
0,0 → 1,105
/* |
* This routine starts the application. It includes application, |
* board, and monitor specific initialization and configuration. |
* The generic CPU dependent initialization has been performed |
* before this routine is invoked. |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: bspstart.c,v 1.2 2001-09-27 12:00:27 chris Exp $ |
*/ |
|
#include <bsp.h> |
#include <rtems/libio.h> |
|
#include <libcsupport.h> |
|
#include <string.h> |
|
/* |
* The original table from the application and our copy of it with |
* some changes. |
*/ |
|
extern rtems_configuration_table Configuration; |
|
rtems_configuration_table BSP_Configuration; |
|
rtems_cpu_table Cpu_table; |
|
char *rtems_progname; |
|
/* |
* Use the shared implementations of the following routines |
*/ |
|
void bsp_postdriver_hook(void); |
void bsp_libc_init( void *, unsigned32, int ); |
|
/* |
* Function: bsp_pretasking_hook |
* Created: 95/03/10 |
* |
* Description: |
* BSP pretasking hook. Called just before drivers are initialized. |
* Used to setup libc and install any BSP extensions. |
* |
* NOTES: |
* Must not use libc (to do io) from here, since drivers are |
* not yet initialized. |
* |
*/ |
|
void bsp_pretasking_hook(void) |
{ |
extern int end; |
rtems_unsigned32 heap_start; |
|
heap_start = (rtems_unsigned32) &end; |
if (heap_start & (CPU_ALIGNMENT-1)) |
heap_start = (heap_start + CPU_ALIGNMENT) & ~(CPU_ALIGNMENT-1); |
|
bsp_libc_init((void *) heap_start, 64 * 1024, 0); |
|
#ifdef RTEMS_DEBUG |
rtems_debug_enable( RTEMS_DEBUG_ALL_MASK ); |
#endif |
} |
|
/* |
* bsp_start |
* |
* This routine does the bulk of the system initialization. |
*/ |
|
void bsp_start( void ) |
{ |
/* |
* Allocate the memory for the RTEMS Work Space. This can come from |
* a variety of places: hard coded address, malloc'ed from outside |
* RTEMS world (e.g. simulator or primitive memory manager), or (as |
* typically done by stock BSPs) by subtracting the required amount |
* of work space from the last physical address on the CPU board. |
*/ |
|
/* |
* Need to "allocate" the memory for the RTEMS Workspace and |
* tell the RTEMS configuration where it is. This memory is |
* not malloc'ed. It is just "pulled from the air". |
*/ |
|
BSP_Configuration.work_space_start = (void *) 0; |
|
/* |
* initialize the CPU table for this BSP |
*/ |
|
Cpu_table.pretasking_hook = bsp_pretasking_hook; /* init libc, etc. */ |
Cpu_table.postdriver_hook = bsp_postdriver_hook; |
Cpu_table.interrupt_stack_size = CONFIGURE_INTERRUPT_STACK_MEMORY; |
} |
/no_bsp/startup/linkcmds
0,0 → 1,63
/* |
* This file contains directives for the GNU linker which are specific |
* to the NO_CPU NO_BSP BOARD. |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: linkcmds,v 1.2 2001-09-27 12:00:27 chris Exp $ |
*/ |
|
MEMORY |
{ |
ram : org = 0x0, l = 1M |
} |
|
SECTIONS |
{ |
.text 0x0 : |
{ |
text_start = . ; |
_text_start = . ; |
*(.text) |
. = ALIGN (16); |
|
*(.eh_fram) |
. = ALIGN (16); |
|
/* |
* C++ constructors |
*/ |
__CTOR_LIST__ = .; |
LONG((__CTOR_END__ - __CTOR_LIST__) / 4 - 2) |
*(.ctors) |
LONG(0) |
__CTOR_END__ = .; |
__DTOR_LIST__ = .; |
LONG((__DTOR_END__ - __DTOR_LIST__) / 4 - 2) |
*(.dtors) |
LONG(0) |
__DTOR_END__ = .; |
_etext = ALIGN( 0x10 ) ; |
} |
.data ADDR( .text ) + SIZEOF( .text ): |
{ |
data_start = . ; |
_data_start = . ; |
*(.data) |
_edata = ALIGN( 0x10 ) ; |
} |
.bss ADDR( .data ) + SIZEOF( .data ): |
{ |
bss_start = . ; |
_bss_start = . ; |
*(.bss) |
*(COMMON) |
end = . ; |
__end = . ; |
} |
} |
/no_bsp/startup/main.c
0,0 → 1,37
/* main() |
* |
* This is the entry point for the application. It calls |
* the bsp_start routine to the actual dirty work. |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: main.c,v 1.2 2001-09-27 12:00:27 chris Exp $ |
*/ |
|
#include <rtems.h> |
#include <bsp.h> |
|
int main( |
int argc, |
char **argv, |
char **environp |
) |
{ |
extern void bsp_start( int, char**, char ** ); |
|
bsp_start( argc, argv, environp ); |
|
/* |
* May be able to return to the "crt/start.s" code but also |
* may not be able to. Do something here which is board dependent. |
*/ |
|
rtems_fatal_error_occurred( 0 ); |
|
return 0; /* just to satisfy the native compiler */ |
} |
/no_bsp/startup/bspclean.c
0,0 → 1,25
/* bsp_cleanup() |
* |
* This routine normally is part of start.s and usually returns |
* control to a monitor. |
* |
* INPUT: NONE |
* |
* OUTPUT: NONE |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: bspclean.c,v 1.2 2001-09-27 12:00:27 chris Exp $ |
*/ |
|
#include <rtems.h> |
#include <bsp.h> |
|
void bsp_cleanup( void ) |
{ |
} |
/no_bsp/startup/Makefile.am
0,0 → 1,38
## |
## $Id: Makefile.am,v 1.2 2001-09-27 12:00:27 chris Exp $ |
## |
|
AUTOMAKE_OPTIONS = foreign 1.4 |
|
VPATH = @srcdir@:@srcdir@/../../../shared |
|
PGM = $(ARCH)/startup.rel |
|
C_FILES = bspclean.c bsplibc.c bsppost.c bspstart.c main.c bootcard.c sbrk.c \ |
setvec.c gnatinstallhandler.c |
C_O_FILES = $(C_FILES:%.c=$(ARCH)/%.o) |
|
OBJS = $(C_O_FILES) |
|
include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg |
include $(top_srcdir)/../../../../../../automake/lib.am |
|
# |
# (OPTIONAL) Add local stuff here using += |
# |
|
$(PGM): $(OBJS) |
$(make-rel) |
|
$(PROJECT_RELEASE)/lib/linkcmds: linkcmds |
$(INSTALL_DATA) $< $@ |
|
TMPINSTALL_FILES += $(PROJECT_RELEASE)/lib/linkcmds |
|
all-local: $(ARCH) $(OBJS) $(PGM) $(TMPINSTALL_FILES) |
|
.PRECIOUS: $(PGM) |
|
EXTRA_DIST = bspclean.c bspstart.c linkcmds main.c setvec.c |
|
include $(top_srcdir)/../../../../../../automake/local.am |
/no_bsp/startup/setvec.c
0,0 → 1,43
/* set_vector |
* |
* This routine installs an interrupt vector on the target Board/CPU. |
* This routine is allowed to be as board dependent as necessary. |
* |
* INPUT: |
* handler - interrupt handler entry point |
* vector - vector number |
* type - 0 indicates raw hardware connect |
* 1 indicates RTEMS interrupt connect |
* |
* RETURNS: |
* address of previous interrupt handler |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: setvec.c,v 1.2 2001-09-27 12:00:27 chris Exp $ |
*/ |
|
#include <rtems.h> |
#include <bsp.h> |
|
no_cpu_isr_entry set_vector( /* returns old vector */ |
rtems_isr_entry handler, /* isr routine */ |
rtems_vector_number vector, /* vector number */ |
int type /* RTEMS or RAW intr */ |
) |
{ |
no_cpu_isr_entry previous_isr; |
|
if ( type ) |
rtems_interrupt_catch( handler, vector, (rtems_isr_entry *) &previous_isr ); |
else { |
/* XXX: install non-RTEMS ISR as "raw" interupt */ |
} |
return previous_isr; |
} |
|
/no_bsp/include/Makefile.am
0,0 → 1,25
## |
## $Id: Makefile.am,v 1.2 2001-09-27 12:00:26 chris Exp $ |
## |
|
AUTOMAKE_OPTIONS = foreign 1.4 |
|
H_FILES = bsp.h |
|
$(PROJECT_INCLUDE): |
$(mkinstalldirs) $@ |
|
$(PROJECT_INCLUDE)/bsp.h: bsp.h |
$(INSTALL_DATA) $< $@ |
|
$(PROJECT_INCLUDE)/coverhd.h: $(srcdir)/../../../shared/include/coverhd.h |
$(INSTALL_DATA) $< $@ |
|
TMPINSTALL_FILES += $(PROJECT_INCLUDE) $(PROJECT_INCLUDE)/bsp.h \ |
$(PROJECT_INCLUDE)/coverhd.h |
|
all-local: $(TMPINSTALL_FILES) |
|
EXTRA_DIST = bsp.h |
|
include $(top_srcdir)/../../../../../../automake/local.am |
/no_bsp/include/bsp.h
0,0 → 1,107
/* bsp.h |
* |
* This include file contains all board IO definitions. |
* |
* XXX : put yours in here |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: bsp.h,v 1.2 2001-09-27 12:00:26 chris Exp $ |
*/ |
|
#ifndef __NO_BSP_h |
#define __NO_BSP_h |
|
#ifdef __cplusplus |
extern "C" { |
#endif |
|
#include <rtems.h> |
#include <console.h> |
#include <clockdrv.h> |
|
/* |
* confdefs.h overrides for this BSP: |
* - number of 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) |
|
/* |
* 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 */ |
|
/* |
* Stuff for Time Test 27 |
*/ |
|
#define MUST_WAIT_FOR_INTERRUPT 0 |
|
#define Install_tm27_vector( handler ) set_vector( (handler), 0, 1 ) |
|
#define Cause_tm27_intr() |
|
#define Clear_tm27_intr() |
|
#define Lower_tm27_intr() |
|
/* |
* Simple spin delay in microsecond units for device drivers. |
* This is very dependent on the clock speed of the target. |
*/ |
|
#define delay( microseconds ) \ |
{ \ |
} |
|
/* Constants */ |
|
#define RAM_START 0 |
#define RAM_END 0x100000 |
|
/* miscellaneous stuff assumed to exist */ |
|
extern rtems_configuration_table BSP_Configuration; |
|
/* |
* Device Driver Table Entries |
*/ |
|
/* |
* NOTE: Use the standard Console driver entry |
*/ |
|
/* |
* NOTE: Use the standard Clock driver entry |
*/ |
|
/* functions */ |
|
void bsp_cleanup( void ); |
|
no_cpu_isr_entry set_vector( /* returns old vector */ |
rtems_isr_entry handler, /* isr routine */ |
rtems_vector_number vector, /* vector number */ |
int type /* RTEMS or RAW intr */ |
); |
|
#ifdef __cplusplus |
} |
#endif |
|
#endif |
/* end of include file */ |
/no_bsp/configure.in
0,0 → 1,37
dnl Process this file with autoconf to produce a configure script. |
dnl |
dnl $Id: configure.in,v 1.2 2001-09-27 12:00:25 chris Exp $ |
|
AC_PREREQ(2.13) |
AC_INIT(bsp_specs) |
RTEMS_TOP(../../../../../..) |
AC_CONFIG_AUX_DIR(../../../../../..) |
|
RTEMS_CANONICAL_TARGET_CPU |
AM_INIT_AUTOMAKE(rtems-c-src-lib-libbsp-no_cpu-no_bsp,$RTEMS_VERSION,no) |
AM_MAINTAINER_MODE |
|
RTEMS_PROG_CC_FOR_TARGET |
RTEMS_CANONICALIZE_TOOLS |
RTEMS_ENABLE_MULTIPROCESSING |
|
RTEMS_ENV_RTEMSBSP |
RTEMS_CHECK_CUSTOM_BSP(RTEMS_BSP) |
RTEMS_CHECK_BSP_CACHE(RTEMS_BSP) |
RTEMS_CHECK_MULTIPROCESSING(RTEMS_BSP) |
RTEMS_CANONICAL_HOST |
|
AM_CONDITIONAL(HAS_MP,test "$HAS_MP" = "yes") |
|
RTEMS_PROJECT_ROOT |
|
# Explicitly list all Makefiles here |
AC_OUTPUT( |
Makefile |
clock/Makefile |
console/Makefile |
include/Makefile |
shmsupp/Makefile |
startup/Makefile |
timer/Makefile |
wrapup/Makefile) |
/no_bsp/Makefile.am
0,0 → 1,17
## |
## $Id: Makefile.am,v 1.2 2001-09-27 12:00:25 chris Exp $ |
## |
|
AUTOMAKE_OPTIONS = foreign 1.4 |
ACLOCAL_AMFLAGS = -I $(RTEMS_TOPdir)/aclocal |
|
# wrapup is the one that actually builds and installs the library |
# from the individual .rel files built in other directories |
SUBDIRS = include startup clock console shmsupp timer wrapup |
|
include $(top_srcdir)/../../bsp.am |
|
EXTRA_DIST = bsp_specs times |
|
include $(top_srcdir)/../../../../../../automake/subdirs.am |
include $(top_srcdir)/../../../../../../automake/local.am |
/no_bsp/clock/ckinit.c
0,0 → 1,180
/* ckinit.c |
* |
* This file provides a template for the clock device driver initialization. |
* |
* COPYRIGHT (c) 1989-1999. |
* On-Line Applications Research Corporation (OAR). |
* |
* 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. |
* |
* $Id: ckinit.c,v 1.2 2001-09-27 12:00:26 chris Exp $ |
*/ |
|
#include <stdlib.h> |
|
#include <rtems.h> |
#include <rtems/libio.h> |
#include <bsp.h> |
|
void Clock_exit( void ); |
rtems_isr Clock_isr( rtems_vector_number vector ); |
|
|
/* |
* The interrupt vector number associated with the clock tick device |
* driver. |
*/ |
|
#define CLOCK_VECTOR 4 |
|
/* |
* Clock_driver_ticks is a monotonically increasing counter of the |
* number of clock ticks since the driver was initialized. |
*/ |
|
volatile rtems_unsigned32 Clock_driver_ticks; |
|
/* |
* Clock_isrs is the number of clock ISRs until the next invocation of |
* the RTEMS clock tick routine. The clock tick device driver |
* gets an interrupt once a millisecond and counts down until the |
* length of time between the user configured microseconds per tick |
* has passed. |
*/ |
|
rtems_unsigned32 Clock_isrs; /* ISRs until next tick */ |
|
/* |
* These are set by clock driver during its init |
*/ |
|
rtems_device_major_number rtems_clock_major = ~0; |
rtems_device_minor_number rtems_clock_minor; |
|
/* |
* The previous ISR on this clock tick interrupt vector. |
*/ |
|
rtems_isr_entry Old_ticker; |
|
void Clock_exit( void ); |
|
|
/* |
* Isr Handler |
*/ |
|
rtems_isr Clock_isr( |
rtems_vector_number vector |
) |
{ |
/* |
* bump the number of clock driver ticks since initialization |
* |
* determine if it is time to announce the passing of tick as configured |
* to RTEMS through the rtems_clock_tick directive |
* |
* perform any timer dependent tasks |
*/ |
} |
|
/* |
* Install_clock |
* |
* Install a clock tick handler and reprograms the chip. This |
* is used to initially establish the clock tick. |
*/ |
|
void Install_clock( |
rtems_isr_entry clock_isr |
) |
{ |
/* |
* Initialize the clock tick device driver variables |
*/ |
|
Clock_driver_ticks = 0; |
Clock_isrs = BSP_Configuration.microseconds_per_tick / 1000; |
|
Old_ticker = (rtems_isr_entry) set_vector( clock_isr, CLOCK_VECTOR, 1 ); |
/* |
* Hardware specific initialize goes here |
*/ |
|
/* XXX */ |
|
/* |
* Schedule the clock cleanup routine to execute if the application exits. |
*/ |
|
atexit( Clock_exit ); |
} |
|
/* |
* Clean up before the application exits |
*/ |
|
void Clock_exit( void ) |
{ |
/* XXX: turn off the timer interrupts */ |
|
/* XXX: If necessary, restore the old vector */ |
} |
|
/* |
* Clock_initialize |
* |
* Device driver entry point for clock tick driver initialization. |
*/ |
|
rtems_device_driver Clock_initialize( |
rtems_device_major_number major, |
rtems_device_minor_number minor, |
void *pargp |
) |
{ |
Install_clock( Clock_isr ); |
|
/* |
* make major/minor avail to others such as shared memory driver |
*/ |
|
rtems_clock_major = major; |
rtems_clock_minor = minor; |
|
return RTEMS_SUCCESSFUL; |
} |
|
rtems_device_driver Clock_control( |
rtems_device_major_number major, |
rtems_device_minor_number minor, |
void *pargp |
) |
{ |
rtems_unsigned32 isrlevel; |
rtems_libio_ioctl_args_t *args = pargp; |
|
if (args == 0) |
goto done; |
|
/* |
* This is hokey, but until we get a defined interface |
* to do this, it will just be this simple... |
*/ |
|
if (args->command == rtems_build_name('I', 'S', 'R', ' ')) |
{ |
Clock_isr(CLOCK_VECTOR); |
} |
else if (args->command == rtems_build_name('N', 'E', 'W', ' ')) |
{ |
rtems_interrupt_disable( isrlevel ); |
(void) set_vector( args->buffer, CLOCK_VECTOR, 1 ); |
rtems_interrupt_enable( isrlevel ); |
} |
|
done: |
return RTEMS_SUCCESSFUL; |
} |
/no_bsp/clock/Makefile.am
0,0 → 1,32
## |
## $Id: Makefile.am,v 1.2 2001-09-27 12:00:26 chris Exp $ |
## |
|
AUTOMAKE_OPTIONS = foreign 1.4 |
|
PGM = $(ARCH)/clock.rel |
|
C_FILES = ckinit.c |
C_O_FILES = $(C_FILES:%.c=$(ARCH)/%.o) |
|
OBJS = $(C_O_FILES) |
|
include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg |
include $(top_srcdir)/../../../../../../automake/lib.am |
|
# |
# (OPTIONAL) Add local stuff here using += |
# |
|
$(PGM): $(OBJS) |
$(make-rel) |
|
# the .rel file built here will be put into libbsp.a by ../wrapup/Makefile |
|
all-local: $(ARCH) $(OBJS) $(PGM) |
|
.PRECIOUS: $(PGM) |
|
EXTRA_DIST = ckinit.c |
|
include $(top_srcdir)/../../../../../../automake/local.am |
/no_bsp/README
0,0 → 1,69
# |
# $Id: README,v 1.2 2001-09-27 12:00:25 chris Exp $ |
# |
# This is a sample hardware description file for a BSP. This comment |
# block does not have to appear in a real one. The intention of this |
# file is to provide a central place to look when searching for |
# information about a board when starting a new BSP. For example, |
# you may want to find an existing timer driver for the chip you are |
# using on your board. It is easier to grep for the chip name in |
# all of the HARDWARE files than to peruse the source tree. Hopefully, |
# making the HARDDWARE files accurate will also alleviate the common |
# problem of not knowing anything about a board based on its BSP |
# name. |
# |
# NOTE: If you have a class of peripheral chip on board which |
# is not in this list please add it to this file so |
# others will also use the same name. |
# |
# Timer resolution is the way it is configured in this BSP. |
# On a counting timer, this is the length of time which |
# corresponds to 1 count. |
# |
|
BSP NAME: fastsbc1 |
BOARD: Fasssst Computers, Fast SBC-1 |
BUS: SchoolBus |
CPU FAMILY: i386 |
CPU: Intel Hexium |
COPROCESSORS: Witch Hex87 |
MODE: 32 bit mode |
|
DEBUG MONITOR: HexBug |
|
PERIPHERALS |
=========== |
TIMERS: Intel i8254 |
RESOLUTION: .0001 microseconds |
SERIAL PORTS: Zilog Z8530 (with 2 ports) |
REAL-TIME CLOCK: RTC-4 |
DMA: Intel i8259 |
VIDEO: none |
SCSI: none |
NETWORKING: none |
|
DRIVER INFORMATION |
================== |
CLOCK DRIVER: RTC-4 |
IOSUPP DRIVER: Zilog Z8530 port A |
SHMSUPP: polled and interrupts |
TIMER DRIVER: Intel i8254 |
TTY DRIVER: stub only |
|
STDIO |
===== |
PORT: Console port 0 |
ELECTRICAL: RS-232 |
BAUD: 9600 |
BITS PER CHARACTER: 8 |
PARITY: None |
STOP BITS: 1 |
|
NOTES |
===== |
|
(1) 900 Mhz and 950 Mhz versions. |
|
(2) 1 Gb or 2 Gb RAM. |
|
(3) PC compatible if HexBug not enabled. |
/no_bsp/wrapup/Makefile.am
0,0 → 1,42
## |
## $Id: Makefile.am,v 1.2 2001-09-27 12:00:27 chris Exp $ |
## |
|
AUTOMAKE_OPTIONS = foreign 1.4 |
|
if HAS_MP |
GENERIC_MP_REL_FILES = shmdr |
endif |
GENERIC_FILES = $(GENERIC_MP_REL_FILES) |
|
if HAS_MP |
BSP_MP_O_FILES = shmsupp |
endif |
BSP_FILES = startup clock console timer $(BSP_MP_O_FILES) |
|
# bummer; have to use $foreach since % pattern subst rules only replace 1x |
OBJS = $(foreach piece, $(BSP_FILES), $(wildcard ../$(piece)/$(ARCH)/*.o)) \ |
$(foreach piece, $(GENERIC_FILES), ../../../$(piece)/$(ARCH)/$(piece).rel) |
|
LIB = $(ARCH)/libbsp.a |
|
include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg |
include $(top_srcdir)/../../../../../../automake/lib.am |
|
# |
# (OPTIONAL) Add local stuff here using += |
# |
|
$(LIB): $(OBJS) |
$(make-library) |
|
$(PROJECT_RELEASE)/lib/libbsp$(LIB_VARIANT).a: $(LIB) |
$(INSTALL_DATA) $< $@ |
|
TMPINSTALL_FILES += $(PROJECT_RELEASE)/lib/libbsp$(LIB_VARIANT).a |
|
all-local: $(ARCH) $(OBJS) $(LIB) $(TMPINSTALL_FILES) |
|
.PRECIOUS: $(LIB) |
|
include $(top_srcdir)/../../../../../../automake/local.am |
/configure.in
0,0 → 1,24
dnl Process this file with autoconf to produce a configure script. |
dnl |
dnl $Id: configure.in,v 1.2 2001-09-27 12:00:25 chris Exp $ |
|
AC_PREREQ(2.13) |
AC_INIT(no_bsp) |
RTEMS_TOP(../../../../..) |
AC_CONFIG_AUX_DIR(../../../../..) |
|
RTEMS_CANONICAL_TARGET_CPU |
AM_INIT_AUTOMAKE(rtems-c-src-lib-libbsp-no_cpu,$RTEMS_VERSION,no) |
AM_MAINTAINER_MODE |
|
RTEMS_ENV_RTEMSBSP |
RTEMS_CHECK_CUSTOM_BSP(RTEMS_BSP) |
RTEMS_CHECK_BSP_CACHE(RTEMS_BSP) |
RTEMS_PROJECT_ROOT |
|
RTEMS_BSP_ALIAS(${RTEMS_BSP},bspdir) |
AC_CONFIG_SUBDIRS($bspdir) |
|
# Explicitly list all Makefiles here |
AC_OUTPUT( |
Makefile) |
/Makefile.am
0,0 → 1,12
## |
## $Id: Makefile.am,v 1.2 2001-09-27 12:00:25 chris Exp $ |
## |
|
AUTOMAKE_OPTIONS = foreign 1.4 |
ACLOCAL_AMFLAGS = -I $(RTEMS_TOPdir)/aclocal |
|
# Descend into the $(RTEMS_BSP_FAMILY) directory |
SUBDIRS = $(RTEMS_BSP_FAMILY) |
|
include $(top_srcdir)/../../../../../automake/subdirs.am |
include $(top_srcdir)/../../../../../automake/local.am |