From patchwork Tue Jan 30 12:26:57 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Javier Carrasco X-Patchwork-Id: 768396 Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04on2069.outbound.protection.outlook.com [40.107.6.69]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8DAB26A34F; Tue, 30 Jan 2024 12:27:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.6.69 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706617632; cv=fail; b=focjufY3D8w5hpQdDw6xISKvrPcp84ouEwQYOqf/9cY5Y/aegXWfmUsvEvZcyPgbQOmF3fNEmUlGq58bIisxBP6rqYsUMKkjYibsHnDfD4ci72+BVo/McSPyrEkxqJ2VU+mmGAU6fUiOh4ix8N8xiw6mveFrAw2W108oLn90gPc= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706617632; c=relaxed/simple; bh=V7NsmgNnWJFlF/itQ9Ex8RWjiqi0iPRtBiqkbxjiYig=; h=From:Date:Subject:Content-Type:Message-Id:References:In-Reply-To: To:Cc:MIME-Version; b=TOQkfI7NKh1NN+6HvH65JT3jrOKtaVXwNJ3G7f9C4fAbq2bon1sCwx4x2JafwSPv96VBEnqLJaRgVpQk2AWH2SFZ9zWw4bZvz9uIOWTPTH2Rj4GdwGmhrawoXayfoSiQm/fZ5mJ2Q7XFgciCIwWxFz1fEfth2p3y7lgwye/HhII= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=wolfvision.net; spf=pass smtp.mailfrom=wolfvision.net; dkim=pass (1024-bit key) header.d=wolfvision.net header.i=@wolfvision.net header.b=Oy6Y69yu; arc=fail smtp.client-ip=40.107.6.69 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=wolfvision.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=wolfvision.net Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=wolfvision.net header.i=@wolfvision.net header.b="Oy6Y69yu" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HMT1ckDfPdp6fsbd34dE/rM50lgqJK6QQ5QooZTYfaO5FPivxoU1HyCxqblwaMTZ0GOg9v+HJmgPsuIgmETiz6kTDEdFgJ1T6TGdb5RyIEryNqlgBCi6+zhe7LkEoJHzDyDti92rI/SnoBthn1jbqVNdUDuQHBfTSdSXCWbIHOko1slX8b7UAcTBz6iY+96nHNJNopQNJcm2/tslsTM2ml93KtJfIEzOrURCyjAa4rtecOzfIyZy6eTJZ4rH14cfvR0l/LWxRf5FK+4GWSbQxY8YjNHFsQ3QGH5fEUlv8ghuFjzRI0ksdI3XZo+3LO+t0mSBtPx9V2wLVl9cITzrfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=cxa4RP8RQluOUry7+pBnwhCmr9F9NYfO0oJ5ANkCN40=; b=bRFj78qy/9ZSelMVEVXVbqx9dJ3HKnx1ujwVRB/TVzhbMljpoVbX1OtraF4fWUqi26al1IsoOQ4QqAeSWSj19qW1jnbTnm9cwqphEn7CuTDDJse1hGvE+BAijiabHAYBqV8p3ehyIoUbKr/dxYRqlJzK6+QhV7r99V46OtPgb1xwfZE8cKfLryYnOFBHh1Q0sJnCbB35xAV/fEko/sVzekIhnbcvigCMNcmiIPkw/bC7DLdtZwgwGuAWojJsRyfIr1WteRwYAkmqOXDyvaxQlApwvmO8Nzl4wQw16/HRny1pJPNqEhuvxDNQmpgDrcMu4QWACyV0pc/Ld++EauE9Eg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=wolfvision.net; dmarc=pass action=none header.from=wolfvision.net; dkim=pass header.d=wolfvision.net; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=wolfvision.net; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=cxa4RP8RQluOUry7+pBnwhCmr9F9NYfO0oJ5ANkCN40=; b=Oy6Y69yuKmefOfpGxiWTr/4V49PfTSJFa5I7gAbVWbGodLo5Z7Ia1JvYFOe8c78yK8sCEEPDXUoaDN648ExFFefiV2gXytwy9g0cnPskN+510t1vLcKxOxt7FzJPWADnkZFtRS/jp75W0bagaPYwRo/E5JfB4OA8jO+W1p90gE4= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=wolfvision.net; Received: from VE1PR08MB4974.eurprd08.prod.outlook.com (2603:10a6:803:111::15) by AS8PR08MB9954.eurprd08.prod.outlook.com (2603:10a6:20b:638::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7228.34; Tue, 30 Jan 2024 12:27:04 +0000 Received: from VE1PR08MB4974.eurprd08.prod.outlook.com ([fe80::c8ee:9414:a0c6:42ab]) by VE1PR08MB4974.eurprd08.prod.outlook.com ([fe80::c8ee:9414:a0c6:42ab%7]) with mapi id 15.20.7228.029; Tue, 30 Jan 2024 12:27:04 +0000 From: Javier Carrasco Date: Tue, 30 Jan 2024 13:26:57 +0100 Subject: [PATCH 2/2] usb: misc: onboard_hub: add support for XMOS XVF3500 Message-Id: <20240130-onboard_xvf3500-v1-2-51b5398406cb@wolfvision.net> References: <20240130-onboard_xvf3500-v1-0-51b5398406cb@wolfvision.net> In-Reply-To: <20240130-onboard_xvf3500-v1-0-51b5398406cb@wolfvision.net> To: Liam Girdwood , Mark Brown , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Matthias Kaehlcke , Greg Kroah-Hartman Cc: linux-sound@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org, Javier Carrasco X-Mailer: b4 0.13-dev-0434a X-Developer-Signature: v=1; a=ed25519-sha256; t=1706617622; l=2715; i=javier.carrasco@wolfvision.net; s=20230509; h=from:subject:message-id; bh=V7NsmgNnWJFlF/itQ9Ex8RWjiqi0iPRtBiqkbxjiYig=; b=MCS3mXR0vHTv4dzlSeBa4msa32KzBT9J4dBEVwp+qtrx+xg9v12V0SBWTNUKEyJowaMEQ1746 bOMbD5QlMqGAa0WIn1ezAF56C7avM+OVHbrCzIgOQ9UEfxJn0b/mOqm X-Developer-Key: i=javier.carrasco@wolfvision.net; a=ed25519; pk=tIGJV7M+tCizagNijF0eGMBGcOsPD+0cWGfKjl4h6K8= X-ClientProxiedBy: VE1PR03CA0017.eurprd03.prod.outlook.com (2603:10a6:802:a0::29) To VE1PR08MB4974.eurprd08.prod.outlook.com (2603:10a6:803:111::15) Precedence: bulk X-Mailing-List: linux-usb@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: VE1PR08MB4974:EE_|AS8PR08MB9954:EE_ X-MS-Office365-Filtering-Correlation-Id: a0290ae5-b9d8-4e6c-0ee6-08dc218ec493 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 1MwoWPveET13T8DqLg2XRca2fvip9QDZ2u+qATwI+C8jbzcoYTrfTx/rLmpUpeY3J2LvjzSLToEUi+dvflInPsbQlKYKQha9rVJMd5yuJsMqxx4IjG7VBMn8njcAZ751FsP9+m7WkuuhK3rvF2kcQ7G9mz7EwkB+UQstvLRLVAofTYGiRmAyrf84DBDS2o4XvyZa5rQ8p7rfigSYr9Y98ERFcF3AL39CuY3WMKPd7cel4twupiDfVAr3nTUOYGXZANpR9NxNLGR/85mfyNACiBvKYsX4CeDhCoHllrwnCUk8zoNe0hl+Ckxmpm/c0De5gvu+nqr77eulr6dT0/iHTh1TO7pFxlH0BziFAuZ1RjC1NvuRPmZHEdFo3NhFM8GU/8K6jwxHAgaNq4e/QSlOVRbRVpYbXwXe9us0KT/bmjv3q41PodztxQxUdfXFIlv1wnEvTMqiWpLqr+1i5NI/wDT1lFL3hyhquondkMzLr9chwJ+7EZa8Yl5q1JxISkP7zJg1HDYRgvYAs567cb1AVNNHl3O2ifMQtBYUATr7vgPjR/wZd23vLyMDsgb7MuNKd1z0PBiYp+0FWTi64h1B02Z+YoIWYsKcCzw4SvKTnOQ= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:VE1PR08MB4974.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(136003)(396003)(39850400004)(366004)(346002)(376002)(230922051799003)(186009)(451199024)(64100799003)(1800799012)(26005)(7416002)(38100700002)(5660300002)(2906002)(41300700001)(44832011)(38350700005)(36756003)(316002)(86362001)(6486002)(478600001)(966005)(107886003)(6512007)(6506007)(2616005)(6666004)(4326008)(8676002)(8936002)(66556008)(66946007)(110136005)(52116002)(66476007); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?ThlmK9HvaFpadoVSfp0UvAEhjEY8?= =?utf-8?q?w3Lj68x/purM0QHYZPS8pHJ+PtMSSENdVqdMwuQ9XfG/yCK/rATDViuFB8NE7m+Mc?= =?utf-8?q?m9PGHa1iMu9EuChqNPiPUbcZyeupatiTV6TJwdCFELSM3FYOm6LrIWP1RwrROM9EJ?= =?utf-8?q?vd6TAiPRMIvZlpnKIevYd24S94XEIFscw3eY7a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JKtDN49KVZvHtgnI+s?= =?utf-8?q?OJSfR82r3I5YaQgfL/UEN4Bvb7z0426HNSIrl/dNgr+C8xyuyZecwtXfXeWDp1dyF?= =?utf-8?q?Iv6egCMjKUvAPiupTEUHcYlxF+LAya7adFHlskUQ1/+nTSIvp+NGQ7VaF3Q7imuVY?= =?utf-8?q?3fQ1haNC8s5Ni7ryk+AKSB8GeE2BGZzVNZ760BH7NlKo0auxqT2MtA8fmqSBNgHAc?= =?utf-8?q?0d5t0TOsnQPHnaV6Gv3f+N9YgMvze2Lv8j8/39oZOXaP/s3b0kXJouAIR75Wq9ekw?= =?utf-8?q?r/izI7RcZ/42yDq4OTg3YATAvp2zqgwD8S+OWadFxCRbeCbC0Wq0Q/c7GXFTiqAH9?= =?utf-8?q?YqYpJTBkgZXd6zXU3dBqO9ENucPyybyCVqBTtoB3dIBhIjwAqbcd2jNVX59HlEs00?= =?utf-8?q?/AVrtnhPjRnNPaFDlbPEz641urp5pHo1hK3vjkJuTJUBS8LPV5AVRy7PKvXsCc+rM?= =?utf-8?q?Uez5hob78l7LZftCC/M6qq/O292o1WX7XvNslgmn0yM5EjCEF2CugFw=3D?= X-OriginatorOrg: wolfvision.net X-MS-Exchange-CrossTenant-Network-Message-Id: a0290ae5-b9d8-4e6c-0ee6-08dc218ec493 X-MS-Exchange-CrossTenant-AuthSource: VE1PR08MB4974.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jan 2024 12:27:04.8012 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: e94ec9da-9183-471e-83b3-51baa8eb804f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: y6dgNtrHRG5UHzD80o68YfWS8LSFwUinnI0UjLmgafSkkqwlLxhqL/olavEso25z3GRTkCZFvEMSqsW26/sGQ7RM4qyEGx3c+pZsJJBjpwE= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR08MB9954 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 --- drivers/usb/misc/onboard_usb_hub.c | 2 ++ drivers/usb/misc/onboard_usb_hub.h | 6 ++++++ 2 files changed, 8 insertions(+) diff --git a/drivers/usb/misc/onboard_usb_hub.c b/drivers/usb/misc/onboard_usb_hub.c index 0dd2b032c90b..f16ea3053f84 100644 --- a/drivers/usb/misc/onboard_usb_hub.c +++ b/drivers/usb/misc/onboard_usb_hub.c @@ -366,6 +366,7 @@ static struct platform_driver onboard_hub_driver = { #define VENDOR_ID_REALTEK 0x0bda #define VENDOR_ID_TI 0x0451 #define VENDOR_ID_VIA 0x2109 +#define VENDOR_ID_XMOS 0x20B1 /* * Returns the onboard_hub platform device that is associated with the USB @@ -458,6 +459,7 @@ static const struct usb_device_id onboard_hub_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) }, /* XMOS XVF3500 */ {} }; MODULE_DEVICE_TABLE(usb, onboard_hub_id_table); diff --git a/drivers/usb/misc/onboard_usb_hub.h b/drivers/usb/misc/onboard_usb_hub.h index f360d5cf8d8a..1809c0923b98 100644 --- a/drivers/usb/misc/onboard_usb_hub.h +++ b/drivers/usb/misc/onboard_usb_hub.h @@ -56,6 +56,11 @@ static const struct onboard_hub_pdata vialab_vl817_data = { .num_supplies = 1, }; +static const struct onboard_hub_pdata xmos_xvf3500_data = { + .reset_us = 1, + .num_supplies = 2, +}; + static const struct of_device_id onboard_hub_match[] = { { .compatible = "usb424,2412", .data = µchip_usb424_data, }, { .compatible = "usb424,2514", .data = µchip_usb424_data, }, @@ -77,6 +82,7 @@ static const struct of_device_id onboard_hub_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, }, {} };