]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/usb/gadget/file_storage.c
Merge branch 'linus' into core/urgent
[linux-2.6-omap-h63xx.git] / drivers / usb / gadget / file_storage.c
index 15c24edbb61adb29a40db7a5e7c83dc63a4a777f..0c632d22a6315a116beb9bb28a06b0d273322478 100644 (file)
 #include "gadget_chips.h"
 
 
+
+/*
+ * Kbuild is not very cooperative with respect to linking separately
+ * compiled library objects into one module.  So for now we won't use
+ * separate compilation ... ensuring init/exit sections work to shrink
+ * the runtime footprint, and giving us at least some parts of what
+ * a "gcc --combine ... part1.c part2.c part3.c ... " build would.
+ */
+#include "usbstring.c"
+#include "config.c"
+#include "epautoconf.c"
+
 /*-------------------------------------------------------------------------*/
 
 #define DRIVER_DESC            "File-backed Storage Gadget"
@@ -308,7 +320,7 @@ MODULE_LICENSE("Dual BSD/GPL");
        dev_vdbg(&(d)->gadget->dev , fmt , ## args)
 #define ERROR(d, fmt, args...) \
        dev_err(&(d)->gadget->dev , fmt , ## args)
-#define WARN(d, fmt, args...) \
+#define WARNING(d, fmt, args...) \
        dev_warn(&(d)->gadget->dev , fmt , ## args)
 #define INFO(d, fmt, args...) \
        dev_info(&(d)->gadget->dev , fmt , ## args)
@@ -1091,7 +1103,7 @@ static int ep0_queue(struct fsg_dev *fsg)
        if (rc != 0 && rc != -ESHUTDOWN) {
 
                /* We can't do much more than wait for a reset */
-               WARN(fsg, "error in submission: %s --> %d\n",
+               WARNING(fsg, "error in submission: %s --> %d\n",
                                fsg->ep0->name, rc);
        }
        return rc;
@@ -1227,7 +1239,7 @@ static void received_cbi_adsc(struct fsg_dev *fsg, struct fsg_buffhd *bh)
 
        /* Save the command for later */
        if (fsg->cbbuf_cmnd_size)
-               WARN(fsg, "CB[I] overwriting previous command\n");
+               WARNING(fsg, "CB[I] overwriting previous command\n");
        fsg->cbbuf_cmnd_size = req->actual;
        memcpy(fsg->cbbuf_cmnd, req->buf, fsg->cbbuf_cmnd_size);
 
@@ -1506,7 +1518,7 @@ static void start_transfer(struct fsg_dev *fsg, struct usb_ep *ep,
                 * submissions if DMA is enabled. */
                if (rc != -ESHUTDOWN && !(rc == -EOPNOTSUPP &&
                                                req->length == 0))
-                       WARN(fsg, "error in submission: %s --> %d\n",
+                       WARNING(fsg, "error in submission: %s --> %d\n",
                                        ep->name, rc);
        }
 }
@@ -2294,7 +2306,7 @@ static int halt_bulk_in_endpoint(struct fsg_dev *fsg)
                VDBG(fsg, "delayed bulk-in endpoint halt\n");
        while (rc != 0) {
                if (rc != -EAGAIN) {
-                       WARN(fsg, "usb_ep_set_halt -> %d\n", rc);
+                       WARNING(fsg, "usb_ep_set_halt -> %d\n", rc);
                        rc = 0;
                        break;
                }
@@ -2317,7 +2329,7 @@ static int wedge_bulk_in_endpoint(struct fsg_dev *fsg)
                VDBG(fsg, "delayed bulk-in endpoint wedge\n");
        while (rc != 0) {
                if (rc != -EAGAIN) {
-                       WARN(fsg, "usb_ep_set_wedge -> %d\n", rc);
+                       WARNING(fsg, "usb_ep_set_wedge -> %d\n", rc);
                        rc = 0;
                        break;
                }
@@ -3755,7 +3767,7 @@ static int __init check_parameters(struct fsg_dev *fsg)
                if (gcnum >= 0)
                        mod_data.release = 0x0300 + gcnum;
                else {
-                       WARN(fsg, "controller '%s' not recognized\n",
+                       WARNING(fsg, "controller '%s' not recognized\n",
                                fsg->gadget->name);
                        mod_data.release = 0x0399;
                }