Skip to content

Commit

Permalink
usbdev: Fix build error with BOARD_USBDEV_SERIALSTR
Browse files Browse the repository at this point in the history
  • Loading branch information
SPRESENSE committed Sep 15, 2023
1 parent 50e6dcb commit f371bf5
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
4 changes: 4 additions & 0 deletions drivers/usbdev/composite.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@
#include <nuttx/usb/usbdev.h>
#include <nuttx/usb/usbdev_trace.h>

#ifdef CONFIG_BOARD_USBDEV_SERIALSTR
# include <nuttx/board.h>
#endif

#include "composite.h"

/****************************************************************************
Expand Down
7 changes: 7 additions & 0 deletions drivers/usbdev/composite.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,13 @@
#define COMPOSITE_CONFIGIDNONE (0) /* Config ID = 0 means to return to address mode */
#define COMPOSITE_CONFIGID (1) /* The only supported configuration ID */

/* Descriptor strings */

#define COMPOSITE_MANUFACTURERSTRID (1)
#define COMPOSITE_PRODUCTSTRID (2)
#define COMPOSITE_SERIALSTRID (3)
#define COMPOSITE_CONFIGSTRID (4)

/****************************************************************************
* Public Types
****************************************************************************/
Expand Down
7 changes: 0 additions & 7 deletions drivers/usbdev/composite_desc.c
Original file line number Diff line number Diff line change
Expand Up @@ -93,13 +93,6 @@

#define COMPOSITE_STR_LANGUAGE (0x0409) /* en-us */

/* Descriptor strings */

#define COMPOSITE_MANUFACTURERSTRID (1)
#define COMPOSITE_PRODUCTSTRID (2)
#define COMPOSITE_SERIALSTRID (3)
#define COMPOSITE_CONFIGSTRID (4)

/****************************************************************************
* Private Data
****************************************************************************/
Expand Down

0 comments on commit f371bf5

Please sign in to comment.