usb: misc: onboard_dev: add support for XMOS XVF3500
authorJavier Carrasco <javier.carrasco@wolfvision.net>
Mon, 25 Mar 2024 09:15:18 +0000 (10:15 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 27 Mar 2024 06:57:16 +0000 (07:57 +0100)
The XMOS XVF3500 VocalFusion Voice Processor[1] is a low-latency, 32-bit
multicore controller for voice processing.

This device requires a specific power sequence, which consists of
enabling the regulators that control the 3V3 and 1V0 device supplies,
and a reset de-assertion after a delay of at least 100ns.

Once in normal operation, the XVF3500 registers itself as a USB device,
and it does not require any device-specific operations in the driver.

[1] https://www.xmos.com/xvf3500/

Acked-by: Matthias Kaehlcke <mka@chromium.org>
Signed-off-by: Javier Carrasco <javier.carrasco@wolfvision.net>
Link: https://lore.kernel.org/r/20240325-onboard_xvf3500-v8-8-29e3f9222922@wolfvision.net
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/misc/onboard_usb_dev.c
drivers/usb/misc/onboard_usb_dev.h

index f72f47edd87ea657a93ac6fdaa2a77120ac76626..648ea933bdad9c5b294a7826c672f56ea5e98fe3 100644 (file)
@@ -407,6 +407,7 @@ static struct platform_driver onboard_dev_driver = {
 #define VENDOR_ID_REALTEK      0x0bda
 #define VENDOR_ID_TI           0x0451
 #define VENDOR_ID_VIA          0x2109
+#define VENDOR_ID_XMOS         0x20B1
 
 /*
  * Returns the onboard_dev platform device that is associated with the USB
@@ -501,6 +502,7 @@ static const struct usb_device_id onboard_dev_id_table[] = {
        { USB_DEVICE(VENDOR_ID_TI, 0x8142) }, /* TI USB8041 2.0 HUB */
        { USB_DEVICE(VENDOR_ID_VIA, 0x0817) }, /* VIA VL817 3.1 HUB */
        { USB_DEVICE(VENDOR_ID_VIA, 0x2817) }, /* VIA VL817 2.0 HUB */
+       { USB_DEVICE(VENDOR_ID_XMOS, 0x0013) }, /* XMOS XVF3500 Voice Processor */
        {}
 };
 MODULE_DEVICE_TABLE(usb, onboard_dev_id_table);
index b6fd73f960bc7e4eeafac9bf009556ea3dc4c7cc..fbba549c0f47bf2560edf2f7c34ac484863a1bc1 100644 (file)
@@ -85,6 +85,13 @@ static const struct onboard_dev_pdata vialab_vl817_data = {
        .is_hub = true,
 };
 
+static const struct onboard_dev_pdata xmos_xvf3500_data = {
+       .reset_us = 1,
+       .num_supplies = 2,
+       .supply_names = { "vdd", "vddio" },
+       .is_hub = false,
+};
+
 static const struct of_device_id onboard_dev_match[] = {
        { .compatible = "usb424,2412", .data = &microchip_usb424_data, },
        { .compatible = "usb424,2514", .data = &microchip_usb424_data, },
@@ -108,6 +115,7 @@ static const struct of_device_id onboard_dev_match[] = {
        { .compatible = "usbbda,5414", .data = &realtek_rts5411_data, },
        { .compatible = "usb2109,817", .data = &vialab_vl817_data, },
        { .compatible = "usb2109,2817", .data = &vialab_vl817_data, },
+       { .compatible = "usb20b1,0013", .data = &xmos_xvf3500_data, },
        {}
 };