Skip to content

Commit

Permalink
usb: acm gadget: Null termintate strings table
Browse files Browse the repository at this point in the history
commit d257221 upstream.

The gadget strings table should be null terminated.
usb_gadget_get_string() loops through the table
expecting a null at the end of the list.

Signed-off-by: Graham Williams <gwilli@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Graham Williams authored and gregkh committed Sep 14, 2013
1 parent a091ec1 commit a14894e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/usb/gadget/f_acm.c
Expand Up @@ -285,6 +285,7 @@ static struct usb_string acm_string_defs[] = {
[ACM_CTRL_IDX].s = "CDC Abstract Control Model (ACM)",
[ACM_DATA_IDX].s = "CDC ACM Data",
[ACM_IAD_IDX ].s = "CDC Serial",
{ } /* end of list */
};

static struct usb_gadget_strings acm_string_table = {
Expand Down

0 comments on commit a14894e

Please sign in to comment.