diff options
| -rw-r--r-- | drivers/usb/gadget/ether.c | 3 | ||||
| -rw-r--r-- | drivers/usb/gadget/gadget_chips.h | 8 |
2 files changed, 11 insertions, 0 deletions
diff --git a/drivers/usb/gadget/ether.c b/drivers/usb/gadget/ether.c index 96df8413f391..1dd8b57f4420 100644 --- a/drivers/usb/gadget/ether.c +++ b/drivers/usb/gadget/ether.c | |||
| @@ -282,6 +282,9 @@ MODULE_PARM_DESC(host_addr, "Host Ethernet Address"); | |||
| 282 | #define DEV_CONFIG_CDC | 282 | #define DEV_CONFIG_CDC |
| 283 | #endif | 283 | #endif |
| 284 | 284 | ||
| 285 | #ifdef CONFIG_USB_GADGET_FSL_USB2 | ||
| 286 | #define DEV_CONFIG_CDC | ||
| 287 | #endif | ||
| 285 | 288 | ||
| 286 | /* For CDC-incapable hardware, choose the simple cdc subset. | 289 | /* For CDC-incapable hardware, choose the simple cdc subset. |
| 287 | * Anything that talks bulk (without notable bugs) can do this. | 290 | * Anything that talks bulk (without notable bugs) can do this. |
diff --git a/drivers/usb/gadget/gadget_chips.h b/drivers/usb/gadget/gadget_chips.h index 2e3d6620d216..d041b919e7b8 100644 --- a/drivers/usb/gadget/gadget_chips.h +++ b/drivers/usb/gadget/gadget_chips.h | |||
| @@ -99,6 +99,12 @@ | |||
| 99 | #define gadget_is_imx(g) 0 | 99 | #define gadget_is_imx(g) 0 |
| 100 | #endif | 100 | #endif |
| 101 | 101 | ||
| 102 | #ifdef CONFIG_USB_GADGET_FSL_USB2 | ||
| 103 | #define gadget_is_fsl_usb2(g) !strcmp("fsl-usb2-udc", (g)->name) | ||
| 104 | #else | ||
| 105 | #define gadget_is_fsl_usb2(g) 0 | ||
| 106 | #endif | ||
| 107 | |||
| 102 | /* Mentor high speed function controller */ | 108 | /* Mentor high speed function controller */ |
| 103 | #ifdef CONFIG_USB_GADGET_MUSBHSFC | 109 | #ifdef CONFIG_USB_GADGET_MUSBHSFC |
| 104 | #define gadget_is_musbhsfc(g) !strcmp("musbhsfc_udc", (g)->name) | 110 | #define gadget_is_musbhsfc(g) !strcmp("musbhsfc_udc", (g)->name) |
| @@ -177,5 +183,7 @@ static inline int usb_gadget_controller_number(struct usb_gadget *gadget) | |||
| 177 | return 0x17; | 183 | return 0x17; |
| 178 | else if (gadget_is_husb2dev(gadget)) | 184 | else if (gadget_is_husb2dev(gadget)) |
| 179 | return 0x18; | 185 | return 0x18; |
| 186 | else if (gadget_is_fsl_usb2(gadget)) | ||
| 187 | return 0x19; | ||
| 180 | return -ENOENT; | 188 | return -ENOENT; |
| 181 | } | 189 | } |
