Changeset View
Changeset View
Standalone View
Standalone View
sys/gdb/gdb.h
Show All 40 Lines | |||||
struct gdb_dbgport { | struct gdb_dbgport { | ||||
const char *gdb_name; | const char *gdb_name; | ||||
gdb_getc_f *gdb_getc; | gdb_getc_f *gdb_getc; | ||||
gdb_init_f *gdb_init; | gdb_init_f *gdb_init; | ||||
gdb_probe_f *gdb_probe; | gdb_probe_f *gdb_probe; | ||||
gdb_putc_f *gdb_putc; | gdb_putc_f *gdb_putc; | ||||
gdb_term_f *gdb_term; | gdb_term_f *gdb_term; | ||||
int gdb_active; | int gdb_active; | ||||
void (*gdb_sendpacket)(const void *, size_t); | |||||
int gdb_dbfeatures; | |||||
}; | }; | ||||
#define GDB_DBGP_FEAT_WANTTERM 0x1 /* Want gdb_term() invocation when | |||||
leaving GDB. gdb_term has been | |||||
deadcode and never invoked for so | |||||
long I don't want to just blindly | |||||
start invoking it without opt-in. */ | |||||
#define GDB_DBGPORT(name, probe, init, term, getc, putc) \ | #define GDB_DBGPORT(name, probe, init, term, getc, putc) \ | ||||
static struct gdb_dbgport name##_gdb_dbgport = { \ | static struct gdb_dbgport name##_gdb_dbgport = { \ | ||||
.gdb_name = #name, \ | .gdb_name = #name, \ | ||||
.gdb_probe = probe, \ | .gdb_probe = probe, \ | ||||
.gdb_init = init, \ | .gdb_init = init, \ | ||||
.gdb_term = term, \ | .gdb_term = term, \ | ||||
.gdb_getc = getc, \ | .gdb_getc = getc, \ | ||||
.gdb_putc = putc, \ | .gdb_putc = putc, \ | ||||
}; \ | }; \ | ||||
DATA_SET(gdb_dbgport_set, name##_gdb_dbgport) | DATA_SET(gdb_dbgport_set, name##_gdb_dbgport) | ||||
#endif /* !_GDB_GDB_H_ */ | #endif /* !_GDB_GDB_H_ */ |