staging: line6: Add support for POD HD400 to line6usb driver
authorChris Bajumpaa <cbajumpa@gmail.com>
Sat, 21 Dec 2013 22:51:24 +0000 (17:51 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 22 Dec 2013 00:03:34 +0000 (16:03 -0800)
This patch adds support for the Line 6 POD HD400 to the line6usb driver.

Signed-off-by: Chris Bajumpaa <cbajumpa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/line6/driver.c
drivers/staging/line6/pcm.c
drivers/staging/line6/usbdefs.h

index cc5d62d2b01f4a37f373a3ef9f0fdb8faa256c7d..7a6d85ebb29b006b235261c0f180c85e61296b23 100644 (file)
@@ -38,6 +38,7 @@ static const struct usb_device_id line6_id_table[] = {
        {USB_DEVICE(LINE6_VENDOR_ID, LINE6_DEVID_GUITARPORT)},
        {USB_DEVICE(LINE6_VENDOR_ID, LINE6_DEVID_POCKETPOD)},
        {USB_DEVICE(LINE6_VENDOR_ID, LINE6_DEVID_PODHD300)},
+       {USB_DEVICE(LINE6_VENDOR_ID, LINE6_DEVID_PODHD400)},
        {USB_DEVICE(LINE6_VENDOR_ID, LINE6_DEVID_PODHD500)},
        {USB_DEVICE(LINE6_VENDOR_ID, LINE6_DEVID_PODSTUDIO_GX)},
        {USB_DEVICE(LINE6_VENDOR_ID, LINE6_DEVID_PODSTUDIO_UX1)},
@@ -64,6 +65,7 @@ static struct line6_properties line6_properties_table[] = {
        { LINE6_BIT_GUITARPORT,    "GuitarPort",    "GuitarPort",       LINE6_BIT_PCM               },
        { LINE6_BIT_POCKETPOD,     "PocketPOD",     "Pocket POD",       LINE6_BIT_CONTROL           },
        { LINE6_BIT_PODHD300,      "PODHD300",      "POD HD300",        LINE6_BIT_CONTROL_PCM_HWMON },
+       { LINE6_BIT_PODHD400,      "PODHD400",      "POD HD400",        LINE6_BIT_CONTROL_PCM_HWMON },
        { LINE6_BIT_PODHD500,      "PODHD500",      "POD HD500",        LINE6_BIT_CONTROL_PCM_HWMON },
        { LINE6_BIT_PODSTUDIO_GX,  "PODStudioGX",   "POD Studio GX",    LINE6_BIT_PCM               },
        { LINE6_BIT_PODSTUDIO_UX1, "PODStudioUX1",  "POD Studio UX1",   LINE6_BIT_PCM               },
@@ -352,6 +354,7 @@ static void line6_data_received(struct urb *urb)
                        break;
 
                case LINE6_DEVID_PODHD300:
+               case LINE6_DEVID_PODHD400:
                case LINE6_DEVID_PODHD500:
                        break; /* let userspace handle MIDI */
 
@@ -684,6 +687,7 @@ static int line6_probe(struct usb_interface *interface,
        case LINE6_DEVID_PODXT:
        case LINE6_DEVID_PODXTPRO:
        case LINE6_DEVID_PODHD300:
+       case LINE6_DEVID_PODHD400:
                alternate = 5;
                break;
 
@@ -738,6 +742,7 @@ static int line6_probe(struct usb_interface *interface,
                break;
 
        case LINE6_DEVID_PODHD300:
+       case LINE6_DEVID_PODHD400:
                size = sizeof(struct usb_line6_podhd);
                ep_read = 0x84;
                ep_write = 0x03;
@@ -896,6 +901,7 @@ static int line6_probe(struct usb_interface *interface,
                break;
 
        case LINE6_DEVID_PODHD300:
+       case LINE6_DEVID_PODHD400:
        case LINE6_DEVID_PODHD500:
                ret = line6_podhd_init(interface,
                                       (struct usb_line6_podhd *)line6);
@@ -1023,6 +1029,7 @@ static void line6_disconnect(struct usb_interface *interface)
                        break;
 
                case LINE6_DEVID_PODHD300:
+               case LINE6_DEVID_PODHD400:
                case LINE6_DEVID_PODHD500:
                        line6_podhd_disconnect(interface);
                        break;
index 6a0648cd03a7012b42abf518f1807a3da97dcec8..df8331bce1754a71206d86d426209ba2fab33075 100644 (file)
@@ -436,6 +436,7 @@ int line6_init_pcm(struct usb_line6 *line6,
        case LINE6_DEVID_PODXTLIVE:
        case LINE6_DEVID_PODXTPRO:
        case LINE6_DEVID_PODHD300:
+       case LINE6_DEVID_PODHD400:
                ep_read = 0x82;
                ep_write = 0x01;
                break;
index 43eb54008a2b6585b9f8ac5f0f27391633a95344..90cadddec56ecda6c9f604699671927af8c4b034 100644 (file)
@@ -25,6 +25,7 @@
 #define LINE6_DEVID_GUITARPORT    0x4750
 #define LINE6_DEVID_POCKETPOD     0x5051
 #define LINE6_DEVID_PODHD300      0x5057
+#define LINE6_DEVID_PODHD400      0x5058
 #define LINE6_DEVID_PODHD500      0x414D
 #define LINE6_DEVID_PODSTUDIO_GX  0x4153
 #define LINE6_DEVID_PODSTUDIO_UX1 0x4150
@@ -48,6 +49,7 @@ enum {
        LINE6_INDEX_GUITARPORT,
        LINE6_INDEX_POCKETPOD,
        LINE6_INDEX_PODHD300,
+       LINE6_INDEX_PODHD400,
        LINE6_INDEX_PODHD500,
        LINE6_INDEX_PODSTUDIO_GX,
        LINE6_INDEX_PODSTUDIO_UX1,
@@ -68,6 +70,7 @@ enum {
        LINE6_BIT(GUITARPORT),
        LINE6_BIT(POCKETPOD),
        LINE6_BIT(PODHD300),
+       LINE6_BIT(PODHD400),
        LINE6_BIT(PODHD500),
        LINE6_BIT(PODSTUDIO_GX),
        LINE6_BIT(PODSTUDIO_UX1),
@@ -88,7 +91,9 @@ enum {
        LINE6_BITS_PODXTALL = LINE6_BIT_PODXT | LINE6_BIT_PODXTLIVE |
                              LINE6_BIT_PODXTPRO,
        LINE6_BITS_PODX3ALL = LINE6_BIT_PODX3 | LINE6_BIT_PODX3LIVE,
-       LINE6_BITS_PODHDALL = LINE6_BIT_PODHD300 | LINE6_BIT_PODHD500,
+       LINE6_BITS_PODHDALL =   LINE6_BIT_PODHD300 |
+                               LINE6_BIT_PODHD400 |
+                               LINE6_BIT_PODHD500,
        LINE6_BITS_BASSPODXTALL = LINE6_BIT_BASSPODXT |
                                  LINE6_BIT_BASSPODXTLIVE |
                                  LINE6_BIT_BASSPODXTPRO