4.104.114.84.95
Last change
on this file since d8cdc1f5 was
d8cdc1f5,
checked in by Joel Sherrill <joel.sherrill@…>, on 10/12/01 at 21:09:05
|
2001-10-12 Joel Sherrill <joel@…>
- startup/linkcmds: Fixed typo.
|
-
Property mode set to
100644
|
File size:
1.2 KB
|
Line | |
---|
1 | /* gdb_glue |
---|
2 | * |
---|
3 | * Interface to initialize the GDB. |
---|
4 | * |
---|
5 | * COPYRIGHT (c) 1989-1998. |
---|
6 | * On-Line Applications Research Corporation (OAR). |
---|
7 | * |
---|
8 | * The license and distribution terms for this file may be |
---|
9 | * found in the file LICENSE in this distribution or at |
---|
10 | * http://www.OARcorp.com/rtems/license.html. |
---|
11 | * |
---|
12 | * $Id$ |
---|
13 | */ |
---|
14 | |
---|
15 | #include <bsp.h> |
---|
16 | #include <stdio.h> |
---|
17 | #include <uart.h> |
---|
18 | |
---|
19 | #define BREAKPOINT() asm(" int $3"); |
---|
20 | |
---|
21 | extern int BSPConsolePort; |
---|
22 | |
---|
23 | /* Init GDB glue */ |
---|
24 | void init_remote_gdb( void ) |
---|
25 | { |
---|
26 | if(BSPConsolePort != BSP_UART_COM2) |
---|
27 | { |
---|
28 | /* |
---|
29 | * If com2 is not used as console use it for |
---|
30 | * debugging |
---|
31 | */ |
---|
32 | |
---|
33 | i386_stub_glue_init(BSP_UART_COM2); |
---|
34 | printf( "Remote GDB using COM2...\n" ); |
---|
35 | |
---|
36 | } |
---|
37 | else |
---|
38 | { |
---|
39 | /* Otherwise use com1 */ |
---|
40 | i386_stub_glue_init(BSP_UART_COM1); |
---|
41 | printf( "Remote GDB using COM1...\n" ); |
---|
42 | } |
---|
43 | |
---|
44 | printf( "Remote GDB: setting traps...\n" ); |
---|
45 | /* Init GDB stub itself */ |
---|
46 | set_debug_traps(); |
---|
47 | |
---|
48 | |
---|
49 | printf( "Remote GDB: waiting remote connection....\n" ); |
---|
50 | |
---|
51 | /* |
---|
52 | * Init GDB break in capability, |
---|
53 | * has to be called after |
---|
54 | * set_debug_traps |
---|
55 | */ |
---|
56 | i386_stub_glue_init_breakin(); |
---|
57 | |
---|
58 | /* Put breakpoint in */ |
---|
59 | /* breakpoint(); */ |
---|
60 | /* BREAKPOINT(); */ |
---|
61 | } |
---|
62 | |
---|
Note: See
TracBrowser
for help on using the repository browser.