Mercurial > ecos
comparison packages/hal/sh/cq7750/current/include/plf_stub.h @ 134:d2f49caf9e38 ecos-sw-2000-11-03
Merge from eCos master repository on 2000-11-03-09:00:49-GMT
| author | jlarmour |
|---|---|
| date | Fri, 03 Nov 2000 21:17:40 +0000 |
| parents | |
| children | 25e238959bae |
comparison
equal
deleted
inserted
replaced
| 133:98d71f4d8243 | 134:d2f49caf9e38 |
|---|---|
| 1 #ifndef CYGONCE_HAL_PLF_STUB_H | |
| 2 #define CYGONCE_HAL_PLF_STUB_H | |
| 3 | |
| 4 //============================================================================= | |
| 5 // | |
| 6 // plf_stub.h | |
| 7 // | |
| 8 // Platform header for GDB stub support. | |
| 9 // | |
| 10 //============================================================================= | |
| 11 //####COPYRIGHTBEGIN#### | |
| 12 // | |
| 13 // ------------------------------------------- | |
| 14 // The contents of this file are subject to the Red Hat eCos Public License | |
| 15 // Version 1.1 (the "License"); you may not use this file except in | |
| 16 // compliance with the License. You may obtain a copy of the License at | |
| 17 // http://www.redhat.com/ | |
| 18 // | |
| 19 // Software distributed under the License is distributed on an "AS IS" | |
| 20 // basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the | |
| 21 // License for the specific language governing rights and limitations under | |
| 22 // the License. | |
| 23 // | |
| 24 // The Original Code is eCos - Embedded Configurable Operating System, | |
| 25 // released September 30, 1998. | |
| 26 // | |
| 27 // The Initial Developer of the Original Code is Red Hat. | |
| 28 // Portions created by Red Hat are | |
| 29 // Copyright (C) 1998, 1999, 2000 Red Hat, Inc. | |
| 30 // All Rights Reserved. | |
| 31 // ------------------------------------------- | |
| 32 // | |
| 33 //####COPYRIGHTEND#### | |
| 34 //============================================================================= | |
| 35 //#####DESCRIPTIONBEGIN#### | |
| 36 // | |
| 37 // Author(s): jskov | |
| 38 // Contributors:jskov | |
| 39 // Date: 1999-05-18 | |
| 40 // Purpose: Platform HAL stub support for Hitachi/CQ boards. | |
| 41 // Usage: #include <cyg/hal/plf_stub.h> | |
| 42 // | |
| 43 //####DESCRIPTIONEND#### | |
| 44 // | |
| 45 //============================================================================= | |
| 46 | |
| 47 #include <pkgconf/system.h> | |
| 48 #include <pkgconf/hal.h> | |
| 49 | |
| 50 #ifdef CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS | |
| 51 | |
| 52 #include <cyg/infra/cyg_type.h> // CYG_UNUSED_PARAM, externC | |
| 53 | |
| 54 #include <cyg/hal/sh_stub.h> // architecture stub support | |
| 55 | |
| 56 #include <cyg/hal/hal_diag.h> // hal_diag_led_on | |
| 57 | |
| 58 //---------------------------------------------------------------------------- | |
| 59 // Define some platform specific communication details. This is mostly | |
| 60 // handled by hal_if now, but we need to make sure the comms tables are | |
| 61 // properly initialized. | |
| 62 | |
| 63 externC void cyg_hal_plf_comms_init(void); | |
| 64 | |
| 65 #define HAL_STUB_PLATFORM_INIT_SERIAL() cyg_hal_plf_comms_init() | |
| 66 | |
| 67 #define HAL_STUB_PLATFORM_SET_BAUD_RATE(baud) CYG_UNUSED_PARAM(int, (baud)) | |
| 68 #define HAL_STUB_PLATFORM_INTERRUPTIBLE 0 | |
| 69 | |
| 70 //---------------------------------------------------------------------------- | |
| 71 // Stub initializer. | |
| 72 #ifdef CYGSEM_HAL_ROM_MONITOR | |
| 73 # define HAL_STUB_PLATFORM_INIT() hal_diag_led_on() | |
| 74 #else | |
| 75 # define HAL_STUB_PLATFORM_INIT() CYG_EMPTY_STATEMENT | |
| 76 #endif | |
| 77 | |
| 78 #endif // ifdef CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS | |
| 79 | |
| 80 //---------------------------------------------------------------------------- | |
| 81 // Reset. | |
| 82 // Block interrupts and cause an exception. This forces a reset. | |
| 83 #define HAL_STUB_PLATFORM_RESET() \ | |
| 84 asm volatile ("ldc %0,sr;trapa #0x00;" : : "r" (CYGARC_REG_SR_BL)) | |
| 85 | |
| 86 #define HAL_STUB_PLATFORM_RESET_ENTRY 0xa0000000 | |
| 87 | |
| 88 //----------------------------------------------------------------------------- | |
| 89 #endif // CYGONCE_HAL_PLF_STUB_H | |
| 90 // End of plf_stub.h |
