From 52cfc7de8720e1f0fdbff21a2092ce65abd9a3b9 Mon Sep 17 00:00:00 2001 From: Ralf Corsepius Date: Thu, 22 Apr 2004 13:04:07 +0000 Subject: 2004-04-22 Ralf Corsepius * include/bsp.h: Split out tmtest27 support. * include/tm27.h: New. --- c/src/lib/libbsp/sh/gensh1/ChangeLog | 5 +++ c/src/lib/libbsp/sh/gensh1/include/bsp.h | 18 ---------- c/src/lib/libbsp/sh/gensh1/include/tm27.h | 38 ++++++++++++++++++++ c/src/lib/libbsp/sh/gensh2/ChangeLog | 5 +++ c/src/lib/libbsp/sh/gensh2/include/bsp.h | 18 ---------- c/src/lib/libbsp/sh/gensh2/include/tm27.h | 38 ++++++++++++++++++++ c/src/lib/libbsp/sh/gensh4/ChangeLog | 5 +++ c/src/lib/libbsp/sh/gensh4/include/bsp.h | 39 -------------------- c/src/lib/libbsp/sh/gensh4/include/tm27.h | 59 +++++++++++++++++++++++++++++++ c/src/lib/libbsp/sh/shsim/ChangeLog | 5 +++ c/src/lib/libbsp/sh/shsim/include/bsp.h | 12 ------- c/src/lib/libbsp/sh/shsim/include/tm27.h | 32 +++++++++++++++++ c/src/lib/libbsp/sh/simsh4/ChangeLog | 5 +++ c/src/lib/libbsp/sh/simsh4/include/bsp.h | 18 ---------- c/src/lib/libbsp/sh/simsh4/include/tm27.h | 38 ++++++++++++++++++++ 15 files changed, 230 insertions(+), 105 deletions(-) create mode 100644 c/src/lib/libbsp/sh/gensh1/include/tm27.h create mode 100644 c/src/lib/libbsp/sh/gensh2/include/tm27.h create mode 100644 c/src/lib/libbsp/sh/gensh4/include/tm27.h create mode 100644 c/src/lib/libbsp/sh/shsim/include/tm27.h create mode 100644 c/src/lib/libbsp/sh/simsh4/include/tm27.h (limited to 'c') diff --git a/c/src/lib/libbsp/sh/gensh1/ChangeLog b/c/src/lib/libbsp/sh/gensh1/ChangeLog index f679753509..9cd56e6b7e 100644 --- a/c/src/lib/libbsp/sh/gensh1/ChangeLog +++ b/c/src/lib/libbsp/sh/gensh1/ChangeLog @@ -1,3 +1,8 @@ +2004-04-22 Ralf Corsepius + + * include/bsp.h: Split out tmtest27 support. + * include/tm27.h: New. + 2004-04-21 Ralf Corsepius PR 613/bsps diff --git a/c/src/lib/libbsp/sh/gensh1/include/bsp.h b/c/src/lib/libbsp/sh/gensh1/include/bsp.h index ce64947e8a..8a49df2eef 100644 --- a/c/src/lib/libbsp/sh/gensh1/include/bsp.h +++ b/c/src/lib/libbsp/sh/gensh1/include/bsp.h @@ -55,24 +55,6 @@ extern "C" { #define BSP_CONSOLE_DRIVER_TABLE_ENTRY DEVSCI_DRIVER_TABLE_ENTRY #endif -/* - * Stuff for Time Test 27 - */ - -#define MUST_WAIT_FOR_INTERRUPT 0 - -#define Install_tm27_vector( handler ) \ -{ \ - rtems_isr_entry ignored ; \ - rtems_interrupt_catch( (handler), 0, &ignored ) ; \ -} - -#define Cause_tm27_intr() - -#define Clear_tm27_intr() - -#define Lower_tm27_intr() - /* Constants */ /* diff --git a/c/src/lib/libbsp/sh/gensh1/include/tm27.h b/c/src/lib/libbsp/sh/gensh1/include/tm27.h new file mode 100644 index 0000000000..fb1fc51b34 --- /dev/null +++ b/c/src/lib/libbsp/sh/gensh1/include/tm27.h @@ -0,0 +1,38 @@ +/* + * 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 _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 + */ + +#define MUST_WAIT_FOR_INTERRUPT 0 + +#define Install_tm27_vector( handler ) \ +{ \ + rtems_isr_entry ignored ; \ + rtems_interrupt_catch( (handler), 0, &ignored ) ; \ +} + +#define Cause_tm27_intr() + +#define Clear_tm27_intr() + +#define Lower_tm27_intr() + + + +#endif diff --git a/c/src/lib/libbsp/sh/gensh2/ChangeLog b/c/src/lib/libbsp/sh/gensh2/ChangeLog index 063c53eb20..eb2a0a3e1a 100644 --- a/c/src/lib/libbsp/sh/gensh2/ChangeLog +++ b/c/src/lib/libbsp/sh/gensh2/ChangeLog @@ -1,3 +1,8 @@ +2004-04-22 Ralf Corsepius + + * include/bsp.h: Split out tmtest27 support. + * include/tm27.h: New. + 2004-04-21 Ralf Corsepius PR 613/bsps diff --git a/c/src/lib/libbsp/sh/gensh2/include/bsp.h b/c/src/lib/libbsp/sh/gensh2/include/bsp.h index 1c593df54a..4e158ec4f8 100644 --- a/c/src/lib/libbsp/sh/gensh2/include/bsp.h +++ b/c/src/lib/libbsp/sh/gensh2/include/bsp.h @@ -71,24 +71,6 @@ extern "C" { #define BSP_CONSOLE_DEVICE_TERMIOS_HANDLERS (sh_sci_get_termios_handlers(TRUE)) #endif -/* - * Stuff for Time Test 27 - */ - -#define MUST_WAIT_FOR_INTERRUPT 0 - -#define Install_tm27_vector( handler ) \ -{ \ - rtems_isr_entry ignored ; \ - rtems_interrupt_catch( (handler), 0, &ignored ) ; \ -} - -#define Cause_tm27_intr() - -#define Clear_tm27_intr() - -#define Lower_tm27_intr() - /* Constants */ /* diff --git a/c/src/lib/libbsp/sh/gensh2/include/tm27.h b/c/src/lib/libbsp/sh/gensh2/include/tm27.h new file mode 100644 index 0000000000..fb1fc51b34 --- /dev/null +++ b/c/src/lib/libbsp/sh/gensh2/include/tm27.h @@ -0,0 +1,38 @@ +/* + * 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 _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 + */ + +#define MUST_WAIT_FOR_INTERRUPT 0 + +#define Install_tm27_vector( handler ) \ +{ \ + rtems_isr_entry ignored ; \ + rtems_interrupt_catch( (handler), 0, &ignored ) ; \ +} + +#define Cause_tm27_intr() + +#define Clear_tm27_intr() + +#define Lower_tm27_intr() + + + +#endif diff --git a/c/src/lib/libbsp/sh/gensh4/ChangeLog b/c/src/lib/libbsp/sh/gensh4/ChangeLog index 16bd828ffa..823885d494 100644 --- a/c/src/lib/libbsp/sh/gensh4/ChangeLog +++ b/c/src/lib/libbsp/sh/gensh4/ChangeLog @@ -1,3 +1,8 @@ +2004-04-22 Ralf Corsepius + + * include/bsp.h: Split out tmtest27 support. + * include/tm27.h: New. + 2004-04-21 Ralf Corsepius PR 613/bsps diff --git a/c/src/lib/libbsp/sh/gensh4/include/bsp.h b/c/src/lib/libbsp/sh/gensh4/include/bsp.h index bc73d3e792..29c54f80e6 100644 --- a/c/src/lib/libbsp/sh/gensh4/include/bsp.h +++ b/c/src/lib/libbsp/sh/gensh4/include/bsp.h @@ -60,45 +60,6 @@ extern "C" { /* #define CONFIGURE_NUMBER_OF_TERMIOS_PORTS 2 */ #define CONFIGURE_INTERRUPT_STACK_MEMORY (4 * 1024) -/* - * Stuff for Time Test 27 - */ - -#define MUST_WAIT_FOR_INTERRUPT 1 - -#ifndef SH7750_EVT_WDT_ITI -# error "..." -#endif - -#define Install_tm27_vector( handler ) \ -{ \ - rtems_isr_entry old_handler; \ - rtems_status_code status; \ - status = rtems_interrupt_catch( (handler), \ - SH7750_EVT_TO_NUM(SH7750_EVT_WDT_ITI), &old_handler); \ - if (status != RTEMS_SUCCESSFUL) \ - printf("Status of rtems_interrupt_catch = %d", status); \ -} - -#define Cause_tm27_intr() \ -{ \ - *(volatile uint16_t*)SH7750_IPRB |= 0xf000; \ - *(volatile uint16_t*)SH7750_WTCSR = SH7750_WTCSR_KEY; \ - *(volatile uint16_t*)SH7750_WTCNT = SH7750_WTCNT_KEY | 0xfe; \ - *(volatile uint16_t*)SH7750_WTCSR = \ - SH7750_WTCSR_KEY | SH7750_WTCSR_TME; \ -} - -#define Clear_tm27_intr() \ -{ \ - *(volatile uint16_t*)SH7750_WTCSR = SH7750_WTCSR_KEY; \ -} - -#define Lower_tm27_intr() \ -{ \ - sh_set_interrupt_level((SH7750_IPRB & 0xf000) << SH4_SR_IMASK_S); \ -} - /* Constants */ /* diff --git a/c/src/lib/libbsp/sh/gensh4/include/tm27.h b/c/src/lib/libbsp/sh/gensh4/include/tm27.h new file mode 100644 index 0000000000..7ffed338bf --- /dev/null +++ b/c/src/lib/libbsp/sh/gensh4/include/tm27.h @@ -0,0 +1,59 @@ +/* + * 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 _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 + */ + +#define MUST_WAIT_FOR_INTERRUPT 1 + +#ifndef SH7750_EVT_WDT_ITI +# error "..." +#endif + +#define Install_tm27_vector( handler ) \ +{ \ + rtems_isr_entry old_handler; \ + rtems_status_code status; \ + status = rtems_interrupt_catch( (handler), \ + SH7750_EVT_TO_NUM(SH7750_EVT_WDT_ITI), &old_handler); \ + if (status != RTEMS_SUCCESSFUL) \ + printf("Status of rtems_interrupt_catch = %d", status); \ +} + +#define Cause_tm27_intr() \ +{ \ + *(volatile uint16_t*)SH7750_IPRB |= 0xf000; \ + *(volatile uint16_t*)SH7750_WTCSR = SH7750_WTCSR_KEY; \ + *(volatile uint16_t*)SH7750_WTCNT = SH7750_WTCNT_KEY | 0xfe; \ + *(volatile uint16_t*)SH7750_WTCSR = \ + SH7750_WTCSR_KEY | SH7750_WTCSR_TME; \ +} + +#define Clear_tm27_intr() \ +{ \ + *(volatile uint16_t*)SH7750_WTCSR = SH7750_WTCSR_KEY; \ +} + +#define Lower_tm27_intr() \ +{ \ + sh_set_interrupt_level((SH7750_IPRB & 0xf000) << SH4_SR_IMASK_S); \ +} + + + +#endif diff --git a/c/src/lib/libbsp/sh/shsim/ChangeLog b/c/src/lib/libbsp/sh/shsim/ChangeLog index 07b4643189..c9a390d9f7 100644 --- a/c/src/lib/libbsp/sh/shsim/ChangeLog +++ b/c/src/lib/libbsp/sh/shsim/ChangeLog @@ -1,3 +1,8 @@ +2004-04-22 Ralf Corsepius + + * include/bsp.h: Split out tmtest27 support. + * include/tm27.h: New. + 2004-04-21 Ralf Corsepius PR 613/bsps diff --git a/c/src/lib/libbsp/sh/shsim/include/bsp.h b/c/src/lib/libbsp/sh/shsim/include/bsp.h index 1a92261d62..58cf0418a9 100644 --- a/c/src/lib/libbsp/sh/shsim/include/bsp.h +++ b/c/src/lib/libbsp/sh/shsim/include/bsp.h @@ -49,18 +49,6 @@ extern "C" { #include #include -/* - * Stuff for Time Test 27 - * - * FIXME: This should not be here. - */ - -#define MUST_WAIT_FOR_INTERRUPT 0 - -#define Install_tm27_vector( handler ) -#define Cause_tm27_intr() -#define Clear_tm27_intr() - /* Constants */ /* diff --git a/c/src/lib/libbsp/sh/shsim/include/tm27.h b/c/src/lib/libbsp/sh/shsim/include/tm27.h new file mode 100644 index 0000000000..bbf0c7c4ab --- /dev/null +++ b/c/src/lib/libbsp/sh/shsim/include/tm27.h @@ -0,0 +1,32 @@ +/* + * 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 _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 + * + * FIXME: This should not be here. + */ + +#define MUST_WAIT_FOR_INTERRUPT 0 + +#define Install_tm27_vector( handler ) +#define Cause_tm27_intr() +#define Clear_tm27_intr() + + + +#endif diff --git a/c/src/lib/libbsp/sh/simsh4/ChangeLog b/c/src/lib/libbsp/sh/simsh4/ChangeLog index aa3607cda3..0d0a0b03d2 100644 --- a/c/src/lib/libbsp/sh/simsh4/ChangeLog +++ b/c/src/lib/libbsp/sh/simsh4/ChangeLog @@ -1,3 +1,8 @@ +2004-04-22 Ralf Corsepius + + * include/bsp.h: Split out tmtest27 support. + * include/tm27.h: New. + 2004-04-21 Ralf Corsepius PR 613/bsps diff --git a/c/src/lib/libbsp/sh/simsh4/include/bsp.h b/c/src/lib/libbsp/sh/simsh4/include/bsp.h index a0b61fa3f9..a3ddac38b0 100644 --- a/c/src/lib/libbsp/sh/simsh4/include/bsp.h +++ b/c/src/lib/libbsp/sh/simsh4/include/bsp.h @@ -64,24 +64,6 @@ extern "C" { /* !!! Should be defined in accordance to simulator considerations.*/ #define CLOCK_VECTOR 32 -/* - * Stuff for Time Test 27 - */ - -#define MUST_WAIT_FOR_INTERRUPT 0 - -#define Install_tm27_vector( handler ) \ -{ \ - rtems_isr_entry ignored ; \ - rtems_interrupt_catch( (handler), 0, &ignored ) ; \ -} - -#define Cause_tm27_intr() - -#define Clear_tm27_intr() - -#define Lower_tm27_intr() - /* Constants */ /* diff --git a/c/src/lib/libbsp/sh/simsh4/include/tm27.h b/c/src/lib/libbsp/sh/simsh4/include/tm27.h new file mode 100644 index 0000000000..fb1fc51b34 --- /dev/null +++ b/c/src/lib/libbsp/sh/simsh4/include/tm27.h @@ -0,0 +1,38 @@ +/* + * 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 _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 + */ + +#define MUST_WAIT_FOR_INTERRUPT 0 + +#define Install_tm27_vector( handler ) \ +{ \ + rtems_isr_entry ignored ; \ + rtems_interrupt_catch( (handler), 0, &ignored ) ; \ +} + +#define Cause_tm27_intr() + +#define Clear_tm27_intr() + +#define Lower_tm27_intr() + + + +#endif -- cgit v1.2.3