linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Javier Carrasco <javier.carrasco@wolfvision.net>
To: Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>,
	 Rob Herring <robh+dt@kernel.org>,
	 Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	 Conor Dooley <conor+dt@kernel.org>,
	Matthias Kaehlcke <mka@chromium.org>,
	 Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	 Helen Koike <helen.koike@collabora.com>,
	 Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	 Maxime Ripard <mripard@kernel.org>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	 David Airlie <airlied@gmail.com>,
	Daniel Vetter <daniel@ffwll.ch>,
	 Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will@kernel.org>,
	 Russell King <linux@armlinux.org.uk>
Cc: linux-sound@vger.kernel.org, devicetree@vger.kernel.org,
	 linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org,
	 dri-devel@lists.freedesktop.org,
	linux-arm-kernel@lists.infradead.org,
	 Javier Carrasco <javier.carrasco@wolfvision.net>
Subject: [PATCH v4 8/8] usb: misc: onboard_hub: add support for XMOS XVF3500
Date: Tue, 20 Feb 2024 15:05:52 +0100	[thread overview]
Message-ID: <20240220-onboard_xvf3500-v4-8-dc1617cc5dd4@wolfvision.net> (raw)
In-Reply-To: <20240220-onboard_xvf3500-v4-0-dc1617cc5dd4@wolfvision.net>

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. Such power
sequence is already supported by the onboard_hub driver, and it can be
reused for non-hub USB devices as well.

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/

Signed-off-by: Javier Carrasco <javier.carrasco@wolfvision.net>
---
 drivers/usb/misc/onboard_usb_dev.c | 2 ++
 drivers/usb/misc/onboard_usb_dev.h | 8 ++++++++
 2 files changed, 10 insertions(+)

diff --git a/drivers/usb/misc/onboard_usb_dev.c b/drivers/usb/misc/onboard_usb_dev.c
index e66fcac93006..e717d1ca8d79 100644
--- a/drivers/usb/misc/onboard_usb_dev.c
+++ b/drivers/usb/misc/onboard_usb_dev.c
@@ -388,6 +388,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
@@ -480,6 +481,7 @@ static const struct usb_device_id onboard_dev_id_table[] = {
 	{ USB_DEVICE(VENDOR_ID_TI, 0x8142) }, /* TI USB8041 2.0 */
 	{ USB_DEVICE(VENDOR_ID_VIA, 0x0817) }, /* VIA VL817 3.1 */
 	{ USB_DEVICE(VENDOR_ID_VIA, 0x2817) }, /* VIA VL817 2.0 */
+	{ USB_DEVICE(VENDOR_ID_XMOS, 0x0013) }, /* XVF3500 */
 	{}
 };
 MODULE_DEVICE_TABLE(usb, onboard_dev_id_table);
diff --git a/drivers/usb/misc/onboard_usb_dev.h b/drivers/usb/misc/onboard_usb_dev.h
index 59dced6bd339..921a5276fc7f 100644
--- a/drivers/usb/misc/onboard_usb_dev.h
+++ b/drivers/usb/misc/onboard_usb_dev.h
@@ -89,6 +89,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, },
@@ -110,6 +117,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, },
 	{}
 };
 

-- 
2.40.1


  parent reply	other threads:[~2024-02-20 14:06 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-20 14:05 [PATCH v4 0/8] usb: misc: onboard_hub: add support for XMOS XVF3500 Javier Carrasco
2024-02-20 14:05 ` [PATCH v4 1/8] usb: misc: onboard_hub: rename to onboard_dev Javier Carrasco
2024-02-21 19:14   ` Matthias Kaehlcke
2024-02-20 14:05 ` [PATCH v4 2/8] usb: misc: onboard_dev: add support for non-hub devices Javier Carrasco
2024-02-21 19:24   ` Matthias Kaehlcke
2024-02-22 14:42     ` Javier Carrasco
2024-02-27 17:55       ` Matthias Kaehlcke
2024-02-20 14:05 ` [PATCH v4 3/8] drm: ci: arm64.config: update ONBOARD_USB_HUB to ONBOARD_USB_DEV Javier Carrasco
2024-02-20 14:33   ` Helen Koike
2024-02-20 14:05 ` [PATCH v4 4/8] arm64: defconfig: " Javier Carrasco
2024-02-20 14:05 ` [PATCH v4 5/8] ARM: multi_v7_defconfig: update ONBOARD_USB_HUB name Javier Carrasco
2024-02-20 14:05 ` [PATCH v4 6/8] usb: misc: onboard_dev: use device supply names Javier Carrasco
2024-02-21 20:25   ` Matthias Kaehlcke
2024-02-21 20:40     ` Javier Carrasco
2024-02-21 21:18       ` Matthias Kaehlcke
2024-02-21 21:33         ` Javier Carrasco
2024-02-21 21:46           ` Matthias Kaehlcke
2024-02-27 18:12   ` Matthias Kaehlcke
2024-02-20 14:05 ` [PATCH v4 7/8] ASoC: dt-bindings: xmos,xvf3500: add XMOS XVF3500 voice processor Javier Carrasco
2024-02-22 15:02   ` Krzysztof Kozlowski
2024-02-20 14:05 ` Javier Carrasco [this message]
2024-02-20 14:34 ` [PATCH v4 0/8] usb: misc: onboard_hub: add support for XMOS XVF3500 Alexander Stein

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240220-onboard_xvf3500-v4-8-dc1617cc5dd4@wolfvision.net \
    --to=javier.carrasco@wolfvision.net \
    --cc=airlied@gmail.com \
    --cc=broonie@kernel.org \
    --cc=catalin.marinas@arm.com \
    --cc=conor+dt@kernel.org \
    --cc=daniel@ffwll.ch \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=helen.koike@collabora.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mka@chromium.org \
    --cc=mripard@kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=tzimmermann@suse.de \
    --cc=will@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).