From aa7c449600d6f6d634f587de6091421a1a877af5 Mon Sep 17 00:00:00 2001 From: David Brownell Date: Mon, 16 Nov 2009 00:34:57 -0800 Subject: [PATCH] target: don't implicitly include "breakpoint.h" Most files in the tree seem to have ended up including this, and *quite* needlessly ... only code implementing or using breakpoints actually needs these declarations. So take it out of the header files which included it, and put it in files which use it ... reduce needless interdependencies. Signed-off-by: David Brownell --- src/server/gdb_server.c | 1 + src/target/arm11.c | 1 + src/target/arm7_9_common.c | 1 + src/target/arm7_9_common.h | 1 - src/target/armv4_5.c | 1 + src/target/armv7m.c | 1 + src/target/cortex_a8.c | 1 + src/target/cortex_m3.c | 1 + src/target/mips_m4k.c | 1 + src/target/target.c | 1 + src/target/target.h | 3 ++- src/target/xscale.c | 1 + 12 files changed, 12 insertions(+), 2 deletions(-) diff --git a/src/server/gdb_server.c b/src/server/gdb_server.c index 4151ec793..21db2965a 100644 --- a/src/server/gdb_server.c +++ b/src/server/gdb_server.c @@ -28,6 +28,7 @@ #endif #include "gdb_server.h" +#include "breakpoints.h" #include "target_request.h" #include "register.h" #include "server.h" diff --git a/src/target/arm11.c b/src/target/arm11.c index 348dd8755..f4e2c0d56 100644 --- a/src/target/arm11.c +++ b/src/target/arm11.c @@ -27,6 +27,7 @@ #endif #include "arm11.h" +#include "breakpoints.h" #include "arm11_dbgtap.h" #include "armv4_5.h" #include "arm_simulator.h" diff --git a/src/target/arm7_9_common.c b/src/target/arm7_9_common.c index c35c8252b..b07111eb8 100644 --- a/src/target/arm7_9_common.c +++ b/src/target/arm7_9_common.c @@ -30,6 +30,7 @@ #include "config.h" #endif +#include "breakpoints.h" #include "embeddedice.h" #include "target_request.h" #include "arm7_9_common.h" diff --git a/src/target/arm7_9_common.h b/src/target/arm7_9_common.h index d70bae265..e5a2bb713 100644 --- a/src/target/arm7_9_common.h +++ b/src/target/arm7_9_common.h @@ -29,7 +29,6 @@ #ifndef ARM7_9_COMMON_H #define ARM7_9_COMMON_H -#include "breakpoints.h" #include "armv4_5.h" #define ARM7_9_COMMON_MAGIC 0x0a790a79 /**< */ diff --git a/src/target/armv4_5.c b/src/target/armv4_5.c index f9b22b940..47b32adde 100644 --- a/src/target/armv4_5.c +++ b/src/target/armv4_5.c @@ -28,6 +28,7 @@ #endif #include "armv4_5.h" +#include "breakpoints.h" #include "arm_disassembler.h" #include "binarybuffer.h" diff --git a/src/target/armv7m.c b/src/target/armv7m.c index ff97a4cb7..6c6a9ec60 100644 --- a/src/target/armv7m.c +++ b/src/target/armv7m.c @@ -34,6 +34,7 @@ #include "config.h" #endif +#include "breakpoints.h" #include "armv7m.h" #define ARRAY_SIZE(x) ((int)(sizeof(x)/sizeof((x)[0]))) diff --git a/src/target/cortex_a8.c b/src/target/cortex_a8.c index 0d00b3aa7..832efe92f 100644 --- a/src/target/cortex_a8.c +++ b/src/target/cortex_a8.c @@ -33,6 +33,7 @@ #include "config.h" #endif +#include "breakpoints.h" #include "cortex_a8.h" #include "armv7a.h" #include "armv4_5.h" diff --git a/src/target/cortex_m3.c b/src/target/cortex_m3.c index e236df2d5..35ca5a5c1 100644 --- a/src/target/cortex_m3.c +++ b/src/target/cortex_m3.c @@ -31,6 +31,7 @@ #include "config.h" #endif +#include "breakpoints.h" #include "cortex_m3.h" #include "target_request.h" #include "target_type.h" diff --git a/src/target/mips_m4k.c b/src/target/mips_m4k.c index 6dd00ad5c..fff401c16 100644 --- a/src/target/mips_m4k.c +++ b/src/target/mips_m4k.c @@ -23,6 +23,7 @@ #include "config.h" #endif +#include "breakpoints.h" #include "mips32.h" #include "mips_m4k.h" #include "mips32_dmaacc.h" diff --git a/src/target/target.c b/src/target/target.c index f7e2ad648..f5a092a70 100644 --- a/src/target/target.c +++ b/src/target/target.c @@ -36,6 +36,7 @@ #include "target.h" #include "target_type.h" #include "target_request.h" +#include "breakpoints.h" #include "time_support.h" #include "register.h" #include "trace.h" diff --git a/src/target/target.h b/src/target/target.h index e4de2c7c5..06105ee6d 100644 --- a/src/target/target.h +++ b/src/target/target.h @@ -28,13 +28,14 @@ #include -#include "breakpoints.h" #include "algorithm.h" #include "command.h" struct reg; struct trace; struct command_context; +struct breakpoint; +struct watchpoint; /** diff --git a/src/target/xscale.c b/src/target/xscale.c index 0b5b26b3c..d8977e218 100644 --- a/src/target/xscale.c +++ b/src/target/xscale.c @@ -27,6 +27,7 @@ #include "config.h" #endif +#include "breakpoints.h" #include "xscale.h" #include "target_type.h" #include "arm7_9_common.h"