summaryrefslogtreecommitdiffstats
path: root/drivers/staging/usbip
diff options
context:
space:
mode:
authormatt mooney <mfm@muteddisk.com>2011-06-19 22:44:37 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2011-07-05 20:11:33 -0700
commit099f79fa5a02c909ca1a621768fe454b664a7efa (patch)
treec4d5d215544ae1033d47f99d3e39af5d2c05f9c0 /drivers/staging/usbip
parentc93be5b178ca7f3f4599da7a26a5828ab36aafb4 (diff)
downloadblackbird-op-linux-099f79fa5a02c909ca1a621768fe454b664a7efa.tar.gz
blackbird-op-linux-099f79fa5a02c909ca1a621768fe454b664a7efa.zip
staging: usbip: userspace: libsrc: remove usbip.h
Remove the library version of usbip.h because its sole purpose was to include other headers, which is bad practice. Also modify include guards for consistency. Signed-off-by: matt mooney <mfm@muteddisk.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/usbip')
-rw-r--r--drivers/staging/usbip/userspace/Makefile.am2
-rw-r--r--drivers/staging/usbip/userspace/libsrc/Makefile.am2
-rw-r--r--drivers/staging/usbip/userspace/libsrc/stub_driver.c3
-rw-r--r--drivers/staging/usbip/userspace/libsrc/stub_driver.h11
-rw-r--r--drivers/staging/usbip/userspace/libsrc/usbip.h19
-rw-r--r--drivers/staging/usbip/userspace/libsrc/usbip_common.c2
-rw-r--r--drivers/staging/usbip/userspace/libsrc/vhci_driver.c4
-rw-r--r--drivers/staging/usbip/userspace/libsrc/vhci_driver.h13
8 files changed, 21 insertions, 35 deletions
diff --git a/drivers/staging/usbip/userspace/Makefile.am b/drivers/staging/usbip/userspace/Makefile.am
index 4b66cbed9e4b..d557fe90ade0 100644
--- a/drivers/staging/usbip/userspace/Makefile.am
+++ b/drivers/staging/usbip/userspace/Makefile.am
@@ -1,6 +1,6 @@
SUBDIRS := libsrc src
includedir := @includedir@/usbip
include_HEADERS := $(addprefix libsrc/, \
- usbip.h usbip_common.h vhci_driver.h stub_driver.h)
+ usbip_common.h vhci_driver.h stub_driver.h)
dist_man_MANS := $(addprefix doc/, usbip.8 usbipd.8 usbip_bind_driver.8)
diff --git a/drivers/staging/usbip/userspace/libsrc/Makefile.am b/drivers/staging/usbip/userspace/libsrc/Makefile.am
index 77ecf6b844b7..6696aa70eea4 100644
--- a/drivers/staging/usbip/userspace/libsrc/Makefile.am
+++ b/drivers/staging/usbip/userspace/libsrc/Makefile.am
@@ -3,5 +3,5 @@ libusbip_la_CFLAGS := @EXTRA_CFLAGS@
libusbip_la_LDFLAGS := -version-info @LIBUSBIP_VERSION@
lib_LTLIBRARIES := libusbip.la
-libusbip_la_SOURCES := names.c names.h stub_driver.c stub_driver.h usbip.h \
+libusbip_la_SOURCES := names.c names.h stub_driver.c stub_driver.h \
usbip_common.c usbip_common.h vhci_driver.c vhci_driver.h
diff --git a/drivers/staging/usbip/userspace/libsrc/stub_driver.c b/drivers/staging/usbip/userspace/libsrc/stub_driver.c
index b62f6b2363e1..0f9593b71ba9 100644
--- a/drivers/staging/usbip/userspace/libsrc/stub_driver.c
+++ b/drivers/staging/usbip/userspace/libsrc/stub_driver.c
@@ -8,7 +8,8 @@
#include <errno.h>
#include <unistd.h>
-#include "usbip.h"
+#include "usbip_common.h"
+#include "stub_driver.h"
#undef PROGNAME
#define PROGNAME "libusbip"
diff --git a/drivers/staging/usbip/userspace/libsrc/stub_driver.h b/drivers/staging/usbip/userspace/libsrc/stub_driver.h
index 332ebc5b3da3..9eaf92c00cde 100644
--- a/drivers/staging/usbip/userspace/libsrc/stub_driver.h
+++ b/drivers/staging/usbip/userspace/libsrc/stub_driver.h
@@ -2,11 +2,11 @@
* Copyright (C) 2005-2007 Takahiro Hirofuchi
*/
-#ifndef _USBIP_STUB_DRIVER_H
-#define _USBIP_STUB_DRIVER_H
-
-#include "usbip.h"
+#ifndef __USBIP_STUB_DRIVER_H
+#define __USBIP_STUB_DRIVER_H
+#include <stdint.h>
+#include "usbip_common.h"
struct usbip_stub_driver {
int ndevs;
@@ -33,4 +33,5 @@ int usbip_stub_refresh_device_list(void);
int usbip_stub_export_device(struct usbip_exported_device *edev, int sockfd);
struct usbip_exported_device *usbip_stub_get_device(int num);
-#endif
+
+#endif /* __USBIP_STUB_DRIVER_H */
diff --git a/drivers/staging/usbip/userspace/libsrc/usbip.h b/drivers/staging/usbip/userspace/libsrc/usbip.h
deleted file mode 100644
index 7cb8e6fef35d..000000000000
--- a/drivers/staging/usbip/userspace/libsrc/usbip.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*
- * Copyright (C) 2005-2007 Takahiro Hirofuchi
- */
-
-#ifndef _USBIP_H
-#define _USBIP_H
-
-#ifdef HAVE_CONFIG_H
-#include "../config.h"
-#endif
-
-#include "usbip_common.h"
-#include "stub_driver.h"
-#include "vhci_driver.h"
-#ifdef DMALLOC
-#include <dmalloc.h>
-#endif
-
-#endif
diff --git a/drivers/staging/usbip/userspace/libsrc/usbip_common.c b/drivers/staging/usbip/userspace/libsrc/usbip_common.c
index 6ac4361946cb..e0ec23f2e4c1 100644
--- a/drivers/staging/usbip/userspace/libsrc/usbip_common.c
+++ b/drivers/staging/usbip/userspace/libsrc/usbip_common.c
@@ -2,7 +2,7 @@
* Copyright (C) 2005-2007 Takahiro Hirofuchi
*/
-#include "usbip.h"
+#include "usbip_common.h"
#include "names.h"
#undef PROGNAME
diff --git a/drivers/staging/usbip/userspace/libsrc/vhci_driver.c b/drivers/staging/usbip/userspace/libsrc/vhci_driver.c
index f10121c3fce5..e663fabf319c 100644
--- a/drivers/staging/usbip/userspace/libsrc/vhci_driver.c
+++ b/drivers/staging/usbip/userspace/libsrc/vhci_driver.c
@@ -2,8 +2,8 @@
* Copyright (C) 2005-2007 Takahiro Hirofuchi
*/
-
-#include "usbip.h"
+#include "usbip_common.h"
+#include "vhci_driver.h"
#undef PROGNAME
#define PROGNAME "libusbip"
diff --git a/drivers/staging/usbip/userspace/libsrc/vhci_driver.h b/drivers/staging/usbip/userspace/libsrc/vhci_driver.h
index a2f7db19cbc6..89949aa7c313 100644
--- a/drivers/staging/usbip/userspace/libsrc/vhci_driver.h
+++ b/drivers/staging/usbip/userspace/libsrc/vhci_driver.h
@@ -2,13 +2,15 @@
* Copyright (C) 2005-2007 Takahiro Hirofuchi
*/
-#ifndef _VHCI_DRIVER_H
-#define _VHCI_DRIVER_H
+#ifndef __VHCI_DRIVER_H
+#define __VHCI_DRIVER_H
-#include "usbip.h"
+#include <sysfs/libsysfs.h>
+#include <stdint.h>
-#define USBIP_VHCI_BUS_TYPE "platform"
+#include "usbip_common.h"
+#define USBIP_VHCI_BUS_TYPE "platform"
#define MAXNPORT 128
struct usbip_class_device {
@@ -61,4 +63,5 @@ int usbip_vhci_attach_device(uint8_t port, int sockfd, uint8_t busnum,
uint8_t devnum, uint32_t speed);
int usbip_vhci_detach_device(uint8_t port);
-#endif
+
+#endif /* __VHCI_DRIVER_H */
OpenPOWER on IntegriCloud