@@ -19,8 +19,6 @@
#include <string.h>
#include <inttypes.h>
-#include <target.h>
-
#include "main.h"
static int getcfam(struct pdbg_target *target, uint32_t index, uint64_t *addr, uint64_t *unused)
@@ -29,11 +29,12 @@
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
+#include <assert.h>
#include <ccan/array_size/array_size.h>
-#include <target.h>
-#include <operations.h>
+#include <libpdbg.h>
+#include <bitutils.h>
#include "main.h"
@@ -16,8 +16,6 @@
#include <inttypes.h>
#include <stdio.h>
-#include <target.h>
-
int run_htm_start(int optind, int argc, char *argv[]);
int run_htm_stop(int optind, int argc, char *argv[]);
int run_htm_status(int optind, int argc, char *argv[]);
@@ -31,9 +31,9 @@
#include <config.h>
#include <libpdbg.h>
+#include <target.h>
#include "main.h"
-#include "bitutils.h"
#include "cfam.h"
#include "scom.h"
#include "reg.h"
@@ -13,9 +13,11 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+
#include <inttypes.h>
+#include <stdbool.h>
-#include <target.h>
+#include <libpdbg.h>
enum backend { FSI, I2C, KERNEL, FAKE, HOST };
@@ -19,9 +19,9 @@
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
+#include <assert.h>
-#include <operations.h>
-#include <target.h>
+#include <libpdbg.h>
#include "main.h"
#include "progress.h"
@@ -19,8 +19,7 @@
#include <stdlib.h>
#include <string.h>
-#include <target.h>
-#include <operations.h>
+#include <libpdbg.h>
#include "main.h"
@@ -19,7 +19,7 @@
#include <string.h>
#include <inttypes.h>
-#include <target.h>
+#include <libpdbg.h>
#include "main.h"
@@ -15,6 +15,4 @@
*/
#include <inttypes.h>
-#include <target.h>
-
int handle_scoms(int optind, int argc, char *argv[]);
@@ -19,11 +19,9 @@
#include <stdlib.h>
#include <string.h>
+#include <libpdbg.h>
#include <bitutils.h>
-#include <target.h>
-#include <operations.h>
-
#include "main.h"
#include "mem.h"
@@ -15,8 +15,6 @@
*/
#include <inttypes.h>
-#include <target.h>
-
int thread_start(int optind, int argc, char *argv[]);
int thread_step(int optind, int argc, char *argv[]);
int thread_stop(int optind, int argc, char *argv[]);
There are few execptions: - src/thread.c, src/htm.c These require bitutils.h. The correct fix might be to include thread abstraction in libpdbg. - src/main.c This requires target.h. Signed-off-by: Amitay Isaacs <amitay@ozlabs.org> --- src/cfam.c | 2 -- src/htm.c | 5 +++-- src/htm.h | 2 -- src/main.c | 2 +- src/main.h | 4 +++- src/mem.c | 4 ++-- src/reg.c | 3 +-- src/scom.c | 2 +- src/scom.h | 2 -- src/thread.c | 4 +--- src/thread.h | 2 -- 11 files changed, 12 insertions(+), 20 deletions(-)