Skip to contentSkip to conversation

blktap: remove unused headers

PATCH New Christoph Egger 1 participant 1 message Nov 30, 2007

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 blktap: remove unused headers

Hi!

Attached patch removes unused linux specific headers and makes bswap.h ready for BSD support.

This is first step for BSD support in blktap. More to come. No functional change.

Signature · 12 lines
AMD Saxony, Dresden, Germany
Operating System Research Center

Legal Information:
AMD Saxony Limited Liability Company & Co. KG
Sitz (Geschäftsanschrift):
   Wilschdorfer Landstr. 101, 01109 Dresden, Deutschland
Registergericht Dresden: HRA 4896
vertretungsberechtigter Komplementär:
   AMD Saxony LLC (Sitz Wilmington, Delaware, USA)
Geschäftsführer der AMD Saxony LLC:
   Dr. Hans-R. Deppe, Thomas McCoy
tools/blktap/drivers/blktapctrl.c +0 -2
diff -r 3057f813da14 tools/blktap/drivers/blktapctrl.c
@@ -41,7 +41,6 @@
 #include <err.h>
 #include <errno.h>
 #include <sys/types.h>
-#include <linux/types.h>
 #include <sys/wait.h>
 #include <signal.h>
 #include <fcntl.h>
@@ -50,7 +49,6 @@
 #include <string.h>
 #include <unistd.h>
 #include <xs.h>
-#include <printf.h>
 #include <sys/time.h>
 #include <syslog.h>
                                                                      
tools/blktap/drivers/bswap.h +7 -0
diff -r 3057f813da14 tools/blktap/drivers/bswap.h
@@ -4,6 +4,11 @@
 //#include "config-host.h"
 
 #include <inttypes.h>
+
+#if defined(__NetBSD__) || defined(__OpenBSD__)
+#include <sys/endian.h>
+#include <sys/types.h>
+#else
 
 #ifdef HAVE_BYTESWAP_H
 #include <byteswap.h>
@@ -73,6 +78,8 @@ static inline void bswap64s(uint64_t *s)
     *s = bswap64(*s);
 }
 
+#endif
+
 #if defined(WORDS_BIGENDIAN)
 #define be_bswap(v, size) (v)
 #define le_bswap(v, size) bswap ## size(v)
tools/blktap/drivers/qcow-create.c +0 -1
diff -r 3057f813da14 tools/blktap/drivers/qcow-create.c
@@ -37,7 +37,6 @@
 #include <sys/statvfs.h>
 #include <sys/stat.h>
 #include <sys/ioctl.h>
-#include <linux/fs.h>
 #include <string.h>
 #include "tapdisk.h"
 
tools/blktap/drivers/tapdisk.c +0 -1
diff -r 3057f813da14 tools/blktap/drivers/tapdisk.c
@@ -27,7 +27,6 @@
 #include <poll.h>
 #include <sys/statvfs.h>
 #include <sys/ioctl.h>
-#include <linux/fs.h>
 #include "blktaplib.h"
 #include "tapdisk.h"
 
tools/blktap/lib/xenbus.c +0 -1
diff -r 3057f813da14 tools/blktap/lib/xenbus.c
@@ -37,7 +37,6 @@
 
 #include <stdio.h>
 #include <stdlib.h>
-#include <printf.h>
 #include <string.h>
 #include <err.h>
 #include <stdarg.h>
tools/blktap/lib/xs_api.c +0 -1
diff -r 3057f813da14 tools/blktap/lib/xs_api.c
@@ -34,7 +34,6 @@
 
 #include <stdio.h>
 #include <stdlib.h>
-#include <printf.h>
 #include <string.h>
 #include <err.h>
 #include <stdarg.h>

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel