Received: by 2002:a05:7412:cfc7:b0:fc:a2b0:25d7 with SMTP id by7csp1379480rdb; Mon, 19 Feb 2024 13:38:14 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVeNDuOKOD0iCJ4asrlzPmFjJd7MZyw0XjBtR/7Xt1TbrYxAfRoRuVYyWPyvlUSJg/jH8nqU76sLYNoBzrE594IU8eUrOj2ZNJnYfUwWw== X-Google-Smtp-Source: AGHT+IFzioGb4cM8WIYtKxJ9wXwQPIKtapJr2dx1MpPmwHMboR7kN10HCpnF0pDYGoPeHCMBPje0 X-Received: by 2002:a0c:dc05:0:b0:68f:3df6:cd6f with SMTP id s5-20020a0cdc05000000b0068f3df6cd6fmr9116612qvk.23.1708378694111; Mon, 19 Feb 2024 13:38:14 -0800 (PST) Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id r12-20020ad4576c000000b0068f13883684si7092532qvx.291.2024.02.19.13.38.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Feb 2024 13:38:14 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-72018-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@outlook.com header.s=selector1 header.b=dJ+yyIdD; arc=fail (signature failed); spf=pass (google.com: domain of linux-kernel+bounces-72018-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-72018-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id BF5C31C214CA for ; Mon, 19 Feb 2024 21:38:13 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 2543754FA2; Mon, 19 Feb 2024 21:37:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=outlook.com header.i=@outlook.com header.b="dJ+yyIdD" Received: from APC01-SG2-obe.outbound.protection.outlook.com (mail-sgaapc01olkn2089.outbound.protection.outlook.com [40.92.53.89]) (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 2993954F9D; Mon, 19 Feb 2024 21:37:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.92.53.89 ARC-Seal:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708378675; cv=fail; b=M/711frZn0ygdxZjLVhC11VuXsgnPFZtobWFa927krR3l8LAmTot/0XydfffHSZcMwnSwzYkh04VVXdYbvX5jfjYRJ8X5kaaUFNuGox5Af4nHbYljJ45ad3BPCDVzuzRnUhvp2fefh1oM7OIqVrZMr6NszezPajsoz5p+zUbwns= ARC-Message-Signature:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708378675; c=relaxed/simple; bh=N0UH3i4dHLtgK7u8PxTeJNrqugNLACdBigGNBslrk74=; h=Message-ID:Date:Subject:To:Cc:References:From:In-Reply-To: Content-Type:MIME-Version; b=hQeuIr4yLFNsrCHwHD6zI+4TdXr+SesuRfajINapMzAwbDIsF4Qg4yZasKF+y7QQI+fGdd+iNJknYIDPFQidVtQ+Yp9WULQZ4jfSvihOxQrJPiKP3K/MiWsZMwszi0lEtz6ATx0XAZ3UtKDEIOIhPKLvjSW7tuBSaY3q4+vf5jA= ARC-Authentication-Results:i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=outlook.com; spf=pass smtp.mailfrom=outlook.com; dkim=pass (2048-bit key) header.d=outlook.com header.i=@outlook.com header.b=dJ+yyIdD; arc=fail smtp.client-ip=40.92.53.89 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=outlook.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=outlook.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ZdqAYLxBC6e+O32PI9C+lKyKt/lqGLSmuducctR26LrKh8/XKpX5bd7mrJii6MscmFYLMHhZj/ytHc7T/mdMIkILciAzxXNJ2t8VAOD75YfTLLm5PVcD3axDcqO1ROS0aXtJXUfE/Hg1cyWA4zajdsFfHk3GLH1ed9XiBu4gAht3X4kalEldv6n8fUia7gKMnzC6Zim4atcxMJil+3Ho14Cv/T0496EcUoxCtXdXEllCQ0ROjm+S434qaDbKmHRTTa/5MoNJV5UVJ986Q3UJczUuIFTHXd9+EEUS+k5CxJJL/D7bgqODckwtE3bx9Oauv5LY5SAteMGIqCFylrHtEg== 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=5FT1UoDxPixqD5RIiaCaXtujmi/2sdZozbjQknH+Ae8=; b=XjRo3FymiBDNvNQDqVgZfd4G/rx0/PnubRjEjNViJkvXxGWRJIFT/zGk6ta4tNEJr394g1dm2rDuPq/9iYC8mHPSB4U42U0dEs4CXvid1cVHhmdcw5MwGqDCUuOKvUWzQJjcVVSZSGIjhrVBnjb+nxHFWLp3etvqAbuYaGKMo2xYWKeHC8DXmCzXvVnhst5jY8QjxtFbsJje9D/ZyoVjNGN9sFjKyccBPYl0u6VBnj6G8wE/O2OOa3Y5Dy55Y0zNjkV7azpPqMOz8Y6i8zyFZtpx8T4qjD+SHmN3ra7Sf6ofM2Vmn39Hn4BI1KSSAUaqeZ+yB4DaRkBxIlq8FiQvGA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=5FT1UoDxPixqD5RIiaCaXtujmi/2sdZozbjQknH+Ae8=; b=dJ+yyIdDbaWI3xvonOn4He6tVXA3UbxFGjSwiNTYOqpBGIUbaSsry+Otx9YaouW38XVaURzzZxMYfb1a6EcXWh/h3Lx61uPGybcI18Cam4ruvzGHqhqFZG7jPW/Haq/vif9OmM67UC5iNp7/N11g3r6B8Z0c6MjSQl2ASGCe1D+vt5QvNuq6fzSMgIn+krWiSIO0ZEh+bsYCshY9Le0dvvwS7FPH/TTYQeQN7KKlWAiW+K4AgI7D+fkZqxYJV9V0ki2qeKMP7ukchkIobNHPlGg4n72K8Rk5Ebd0o5boVKKDEBp6UXIqFRbFi8KsrYwHlHAKdoMpNsFro8mKGfMrfQ== Received: from SEZPR06MB6959.apcprd06.prod.outlook.com (2603:1096:101:1ed::14) by TYZPR06MB4413.apcprd06.prod.outlook.com (2603:1096:400:73::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7292.39; Mon, 19 Feb 2024 21:37:48 +0000 Received: from SEZPR06MB6959.apcprd06.prod.outlook.com ([fe80::53da:a8a:83cb:b9ad]) by SEZPR06MB6959.apcprd06.prod.outlook.com ([fe80::53da:a8a:83cb:b9ad%4]) with mapi id 15.20.7292.036; Mon, 19 Feb 2024 21:37:48 +0000 Message-ID: Date: Tue, 20 Feb 2024 05:37:43 +0800 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH RFC v3 4/5] phy: hisilicon: hisi-inno-phy: add support for Hi3798MV200 INNO PHY Content-Language: en-US To: Krzysztof Kozlowski , Vinod Koul , Kishon Vijay Abraham I , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Jiancheng Xue , Shawn Guo , Philipp Zabel Cc: linux-phy@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Kishon Vijay Abraham I , David Yang References: <20240220-inno-phy-v3-0-893cdf8633b4@outlook.com> <20240220-inno-phy-v3-4-893cdf8633b4@outlook.com> <271c7f14-abbe-4922-91ea-809e50be46cd@linaro.org> From: Yang Xiwen In-Reply-To: <271c7f14-abbe-4922-91ea-809e50be46cd@linaro.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-TMN: [3lg3OipTytNDu/ce3vVBUaaLQFFDFvfEDLhPtXQxceOi26XyX+tyb3JeqPqvscuV] X-ClientProxiedBy: TYCP301CA0041.JPNP301.PROD.OUTLOOK.COM (2603:1096:400:380::7) To SEZPR06MB6959.apcprd06.prod.outlook.com (2603:1096:101:1ed::14) X-Microsoft-Original-Message-ID: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB6959:EE_|TYZPR06MB4413:EE_ X-MS-Office365-Filtering-Correlation-Id: 2df6b4a4-43e0-49fa-0222-08dc31930406 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 9DWADyFCN/zhJ3uPoTtDpQgs1ru3wAIktF7Udy6g8rF3IBzrM/Ylf+aYHnJPVRfnKLMQG+PnmIDfD0zwtl42EHznSy9l57k6rwjVgQHaBjvqcUvPKSTz4nDpx9EAe7Mgc7qLwnf9etOJmp0kbuE53K2ZW1Q3uO0o47U7+dOJEGJO6gwj65SvJ34JVtwFtzPI4xRvTl5sX6UFWGzv3+4WxPgFjI1VMO2CV8kAZxGmZ2BjuyL04ctTAOk7HlpQYdgWYBCvLxMxUl6aqFic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ZBRTJGVnpwVGxYR1B1K1hySEZjeXMrcUZn?= =?utf-8?B?YzdWaHZBQ3dpdzErR1B4YkRvK29MV0liQTNzSlV3dXB1eVpjVUJlcVQ5SWow?= =?utf-8?B?aXdlT1ZpUlIwazdsTmljZUovUDN6djB0Ymd6MlNWb21ZVmwyUm1TRlYwY0Fs?= =?utf-8?B?N1F3UGtWeTc1TE54RkczOThQQnZYMUFHMDVDWHN2a2xkYXRmQ1djcStPUnl3?= =?utf-8?B?bUJKTGdqZHZGU2NVTUcra2tSNXNNQlY5WnBpTmJucE1SdzR3dWd3cXpTN1pK?= =?utf-8?Q?GS/UJfob8fOJqorfeXIbuANa2d1lUD8aa//dYmc?= X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2df6b4a4-43e0-49fa-0222-08dc31930406 X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB6959.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Feb 2024 21:37:47.8471 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYZPR06MB4413 On 2/20/2024 5:34 AM, Krzysztof Kozlowski wrote: > On 19/02/2024 22:28, Yang Xiwen via B4 Relay wrote: >> From: Yang Xiwen >> >> Direct MMIO resgiter access is used by Hi3798MV200. For other models, >> of_iomap() returns 0 due to insufficient length. So they are unaffected. >> >> Also Hi3798MV200 INNO PHY has an extra reset required to be deasserted, >> switch to reset_control_bulk_() APIs to resolve this. >> >> Signed-off-by: Yang Xiwen >> --- >> drivers/phy/hisilicon/phy-hisi-inno-usb2.c | 65 ++++++++++++++++++------------ >> 1 file changed, 39 insertions(+), 26 deletions(-) >> >> diff --git a/drivers/phy/hisilicon/phy-hisi-inno-usb2.c b/drivers/phy/hisilicon/phy-hisi-inno-usb2.c >> index b7e740eb4752..5175e5a351ac 100644 >> --- a/drivers/phy/hisilicon/phy-hisi-inno-usb2.c >> +++ b/drivers/phy/hisilicon/phy-hisi-inno-usb2.c >> @@ -10,6 +10,7 @@ >> #include >> #include >> #include >> +#include >> #include >> #include >> #include >> @@ -43,6 +44,7 @@ >> #define PHY_CLK_ENABLE BIT(2) >> >> struct hisi_inno_phy_port { >> + void __iomem *base; >> struct reset_control *utmi_rst; >> struct hisi_inno_phy_priv *priv; >> }; >> @@ -50,7 +52,7 @@ struct hisi_inno_phy_port { >> struct hisi_inno_phy_priv { >> void __iomem *mmio; >> struct clk *ref_clk; >> - struct reset_control *por_rst; >> + struct reset_control *rsts; > This does not look related to this patch at all. I should emphasize this in commit log. Hi3798MV200 have two resets rather than one. To make things easier, I simply used reset_control_array APIs instead. > >> unsigned int type; >> struct hisi_inno_phy_port ports[INNO_PHY_PORT_NUM]; >> }; > > > Best regards, > Krzysztof > -- Regards, Yang Xiwen