]> Git Repo - J-u-boot.git/blobdiff - drivers/usb/gadget/usbstring.c
Use correct spelling of "U-Boot"
[J-u-boot.git] / drivers / usb / gadget / usbstring.c
index 4dbe060d6f2359c377be128e6e0a344218836a01..3e24fbf80eaf0fd5834f7b604991ec2097456047 100644 (file)
@@ -1,19 +1,15 @@
 /*
  * Copyright (C) 2003 David Brownell
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License as published
- * by the Free Software Foundation; either version 2.1 of the License, or
- * (at your option) any later version.
+ * SPDX-License-Identifier:    LGPL-2.1+
  *
- * Ported to U-boot by: Thomas Smits <[email protected]> and
+ * Ported to U-Boot by: Thomas Smits <[email protected]> and
  *                      Remy Bohmer <[email protected]>
  */
 
 #include <common.h>
 #include <asm/errno.h>
 #include <linux/usb/ch9.h>
-#include <usbdescriptors.h>
 #include <linux/usb/gadget.h>
 
 #include <asm/unaligned.h>
@@ -112,6 +108,9 @@ usb_gadget_get_string(struct usb_gadget_strings *table, int id, u8 *buf)
        struct usb_string       *s;
        int                     len;
 
+       if (!table)
+               return -EINVAL;
+
        /* descriptor 0 has the language id */
        if (id == 0) {
                buf[0] = 4;
This page took 0.020833 seconds and 4 git commands to generate.