ChangeSet 1.2181.4.64, 2005/03/24 15:29:17-08:00, [EMAIL PROTECTED]
[PATCH] USB: usb gadget misc sparse fixes [1/5]
This lets the file_storage gadget appear again in Kconfig, and fixes
some minor "sparse" warnings.
Signed-off-by: David Brownell <[EMAIL PROTECTED]>
Signed-off-by: Greg Kroah-Hartman <[EMAIL PROTECTED]>
Kconfig | 2 --
config.c | 1 +
usbstring.c | 4 ++--
3 files changed, 3 insertions(+), 4 deletions(-)
diff -Nru a/drivers/usb/gadget/Kconfig b/drivers/usb/gadget/Kconfig
--- a/drivers/usb/gadget/Kconfig 2005-03-30 15:17:44 -08:00
+++ b/drivers/usb/gadget/Kconfig 2005-03-30 15:17:44 -08:00
@@ -344,8 +344,6 @@
config USB_FILE_STORAGE
tristate "File-backed Storage Gadget"
- # we don't support the SA1100 because of its limitations
- depends on USB_GADGET_SA1100 = n
help
The File-backed Storage Gadget acts as a USB Mass Storage
disk drive. As its storage repository it can use a regular
diff -Nru a/drivers/usb/gadget/config.c b/drivers/usb/gadget/config.c
--- a/drivers/usb/gadget/config.c 2005-03-30 15:17:44 -08:00
+++ b/drivers/usb/gadget/config.c 2005-03-30 15:17:44 -08:00
@@ -25,6 +25,7 @@
#include <linux/device.h>
#include <linux/usb_ch9.h>
+#include <linux/usb_gadget.h>
/**
diff -Nru a/drivers/usb/gadget/usbstring.c b/drivers/usb/gadget/usbstring.c
--- a/drivers/usb/gadget/usbstring.c 2005-03-30 15:17:44 -08:00
+++ b/drivers/usb/gadget/usbstring.c 2005-03-30 15:17:44 -08:00
@@ -20,7 +20,7 @@
#include <asm/unaligned.h>
-static int utf8_to_utf16le(const char *s, u16 *cp, unsigned len)
+static int utf8_to_utf16le(const char *s, __le16 *cp, unsigned len)
{
int count = 0;
u8 c;
@@ -126,7 +126,7 @@
/* string descriptors have length, tag, then UTF16-LE text */
len = min ((size_t) 126, strlen (s->s));
memset (buf + 2, 0, 2 * len); /* zero all the bytes */
- len = utf8_to_utf16le(s->s, (u16 *)&buf[2], len);
+ len = utf8_to_utf16le(s->s, (__le16 *)&buf[2], len);
if (len < 0)
return -EINVAL;
buf [0] = (len + 1) * 2;
-
To unsubscribe from this list: send the line "unsubscribe bk-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html