[Pdbg] [PATCH v2 16/16] libpdbg: Remove device.h

Alistair Popple alistair at popple.id.au
Wed Nov 7 16:39:43 AEDT 2018


Signed-off-by: Alistair Popple <alistair at popple.id.au>
---
 Makefile.am       |  1 -
 libpdbg/bmcfsi.c  |  1 -
 libpdbg/device.c  |  6 ++++--
 libpdbg/device.h  | 26 --------------------------
 libpdbg/libpdbg.c |  1 -
 libpdbg/libpdbg.h |  2 ++
 libpdbg/target.c  |  1 -
 libpdbg/target.h  |  1 -
 src/htm.c         |  1 -
 9 files changed, 6 insertions(+), 34 deletions(-)
 delete mode 100644 libpdbg/device.h

diff --git a/Makefile.am b/Makefile.am
index ad2bbec..b8f38ca 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -151,7 +151,6 @@ libpdbg_la_SOURCES = \
 	libpdbg/debug.c \
 	libpdbg/debug.h \
 	libpdbg/device.c \
-	libpdbg/device.h \
 	libpdbg/fake.c \
 	libpdbg/host.c \
 	libpdbg/htm.c \
diff --git a/libpdbg/bmcfsi.c b/libpdbg/bmcfsi.c
index a233106..f9cee3d 100644
--- a/libpdbg/bmcfsi.c
+++ b/libpdbg/bmcfsi.c
@@ -27,7 +27,6 @@
 
 #include "bitutils.h"
 #include "operations.h"
-#include "device.h"
 #include "target.h"
 #include "debug.h"
 
diff --git a/libpdbg/device.c b/libpdbg/device.c
index 8e58135..cce5ccf 100644
--- a/libpdbg/device.c
+++ b/libpdbg/device.c
@@ -14,17 +14,19 @@
  * limitations under the License.
  */
 
-#include "device.h"
 #include <stdio.h>
 #include <stdlib.h>
 #include <stdarg.h>
 #include "target.h"
 #include <libfdt/libfdt.h>
 #include <libfdt/libfdt_internal.h>
+#include <ccan/list/list.h>
+#include <ccan/short_types/short_types.h>
 #include <ccan/str/str.h>
 #include <endian.h>
 
 #include "debug.h"
+#include "compiler.h"
 
 #define zalloc(size) calloc(1, size)
 #define prerror printf
@@ -34,7 +36,7 @@
 	list_for_each(&parent->children, node, list)
 
 /* Used to give unique handles. */
-static u32 last_phandle = 0;
+static uint32_t last_phandle = 0;
 
 static struct pdbg_target *pdbg_dt_root;
 
diff --git a/libpdbg/device.h b/libpdbg/device.h
deleted file mode 100644
index 4a4a06f..0000000
--- a/libpdbg/device.h
+++ /dev/null
@@ -1,26 +0,0 @@
-/* Copyright 2013-2014 IBM Corp.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * 	http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- * implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __DEVICE_H
-#define __DEVICE_H
-#include <ccan/list/list.h>
-#include <ccan/short_types/short_types.h>
-#include "compiler.h"
-
-/* Any property or node with this prefix will not be passed to the kernel. */
-#define DT_PRIVATE	"skiboot,"
-
-#endif /* __DEVICE_H */
diff --git a/libpdbg/libpdbg.c b/libpdbg/libpdbg.c
index b59590d..13acaa8 100644
--- a/libpdbg/libpdbg.c
+++ b/libpdbg/libpdbg.c
@@ -1,7 +1,6 @@
 #include <string.h>
 
 #include "target.h"
-#include "device.h"
 #include "libpdbg.h"
 
 static pdbg_progress_tick_t progress_tick;
diff --git a/libpdbg/libpdbg.h b/libpdbg/libpdbg.h
index b61a75c..069f87e 100644
--- a/libpdbg/libpdbg.h
+++ b/libpdbg/libpdbg.h
@@ -8,6 +8,8 @@
 
 #include <stdbool.h>
 
+#include <ccan/short_types/short_types.h>
+
 struct pdbg_target;
 struct pdbg_target_class;
 
diff --git a/libpdbg/target.c b/libpdbg/target.c
index 5ebe71d..1fc8457 100644
--- a/libpdbg/target.c
+++ b/libpdbg/target.c
@@ -7,7 +7,6 @@
 
 #include "bitutils.h"
 #include "target.h"
-#include "device.h"
 #include "operations.h"
 #include "debug.h"
 
diff --git a/libpdbg/target.h b/libpdbg/target.h
index 258c576..7cc855d 100644
--- a/libpdbg/target.h
+++ b/libpdbg/target.h
@@ -21,7 +21,6 @@
 #include <ccan/str/str.h>
 #include <ccan/container_of/container_of.h>
 #include "compiler.h"
-#include "device.h"
 #include "libpdbg.h"
 
 enum chip_type {CHIP_UNKNOWN, CHIP_P8, CHIP_P8NV, CHIP_P9};
diff --git a/src/htm.c b/src/htm.c
index 8dd7303..10e35ae 100644
--- a/src/htm.c
+++ b/src/htm.c
@@ -34,7 +34,6 @@
 #include <ccan/array_size/array_size.h>
 
 #include <libpdbg.h>
-#include <device.h>
 #include <bitutils.h>
 
 #include "main.h"
-- 
2.11.0



More information about the Pdbg mailing list