From b99af3f6ba36a9b63c15f85552e25161b7a259bb Mon Sep 17 00:00:00 2001 From: matt mooney Date: Fri, 27 May 2011 01:44:11 -0700 Subject: [PATCH] userspace: move header includes out utils.h The includes have been moved out of utils.h to their respective source files where they are suppose to be. An include guard is also added to utils.h Signed-off-by: matt mooney Signed-off-by: Greg Kroah-Hartman --- userspace/src/usbip_bind.c | 3 ++- userspace/src/utils.c | 6 +++++- userspace/src/utils.h | 25 ++++--------------------- 3 files changed, 11 insertions(+), 23 deletions(-) diff --git a/userspace/src/usbip_bind.c b/userspace/src/usbip_bind.c index 26cfbadb..9869db27 100644 --- a/userspace/src/usbip_bind.c +++ b/userspace/src/usbip_bind.c @@ -18,11 +18,12 @@ #include +#include #include #include -#include #include +#include #include #include "usbip_common.h" diff --git a/userspace/src/utils.c b/userspace/src/utils.c index 35b05e45..6dbfdbd1 100644 --- a/userspace/src/utils.c +++ b/userspace/src/utils.c @@ -4,9 +4,13 @@ */ #include + +#include +#include +#include + #include #include -#include #include #include "usbip_common.h" diff --git a/userspace/src/utils.h b/userspace/src/utils.h index 423716dd..36ee8d5b 100644 --- a/userspace/src/utils.h +++ b/userspace/src/utils.h @@ -1,26 +1,7 @@ +#ifndef __UTILS_H +#define __UTILS_H -#ifdef HAVE_CONFIG_H -#include "../config.h" -#endif - -#define _GNU_SOURCE -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include #include -#include -#include - - /* Be sync to kernel header */ #define BUS_ID_SIZE 20 @@ -37,3 +18,5 @@ int write_bConfigurationValue(char *busid, int config); int read_bDeviceClass(char *busid); int readline(int sockfd, char *str, int strlen); int writeline(int sockfd, char *buff, int bufflen); + +#endif /* __UTILS_H */