From patchwork Wed Jul 5 09:01:23 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yangtao Li X-Patchwork-Id: 13301844 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id BDCA6C0015E for ; Wed, 5 Jul 2023 09:01:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=Jkt8eeZpGMYJjdI75VWosJ9Rcyy8w51zOyQe57/SzqU=; b=3ZMZxiz7kf+IpX BOwXNC/vF5SSqQ7ogvxK9ikeACw7QoDw1XzcIqYGDMDllE3UvEhOCWFHflgfyTc3oV7+fWL3QOgBn FXqcvbhPr9wncQPqGLJqYAQPBBG/utZRV5iK9YVv1KGYLddKKJfSvWKoZFgfSOGremSVia854BawY Ntw+4hFYnqaNPbF4KOm73usvFv1l4Na71uGK/LQjs4gNbX28zvRVyFTeosT3Wb8Pq2PSeTarFoFSL FUv9nPQTSHc9vDqf9XlBU6mN3sO9yqlPEWn1aWCAZInoRyis74qt8aX6Ulob3485Vgvir3V+KfXgq l/zXjep2+yKSu9z7bJ6Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qGyOU-00FIGN-1M; Wed, 05 Jul 2023 09:01:50 +0000 Received: from mail-tyzapc01on20708.outbound.protection.outlook.com ([2a01:111:f403:704b::708] helo=APC01-TYZ-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qGyOS-00FIFK-17 for linux-phy@lists.infradead.org; Wed, 05 Jul 2023 09:01:49 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=B5tV8P+icU5MNpe+Yu8IioQJ2UqpMHgIJqw7olbShCUOlAhjSF6DW8NwCcTRWiqXixAuzzL/eCZqe6UtKpJ7D/evCZqwfFcYydm/Vz03fkhgOcxiUgKVr3K21cmqqCkd2gKzz0H5Trptuq75/M1U7euPOz41JKZk80fySPcLuyKu1E8n+pThPDEptsMkeykKeOl/nfb+UjTse93Ap7PCp4QBlHAiv2O+5fe6Q75JDm+hCddztaOql+1vC5Y1kjD9kC6b7LlB1T114b2+H3oqYalFt9Zp7qSY87984Gph2TLVnT7BESmMZAxJDtLju+CK1s44MOj57h9LQxR4yuWnWw== 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=Bi5MN2Lo1Xh02TYYVOUmZNbL2ihcOvEZTo6JAy8MYTU=; b=RvmJPcWD3oMEboOoyykuNBfE3ipiCOrTmgqgdppyK8LpCOZMIFtGVSKoRZS6MMhz9GQ4s8EZVL3AWOKWDZVVk/qHajcrek5sxNiI5g6KQespaxOj90J7VeTuhlRAXO2Mw+TzsIWh93wnaZz3ag4vZWi8qCfNn4/DZaQnklPzZ8ONxF1SkM2X36CWU0NvbC6i+pwcoCD9rYmLWehFGLCoSStrS0T6h9c6Y6wkHucmOTzdLpWqp3XuQ++lmQOhfACq/gIDsXS0+w8cQaFp1DrsdR8Dj5aI/wapy1oE3K2C4+bNHBuL2EOSE0iPg8TIk3FSpBT1CSY1QDxpMeshDIbpyw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=vivo.com; dmarc=pass action=none header.from=vivo.com; dkim=pass header.d=vivo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vivo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Bi5MN2Lo1Xh02TYYVOUmZNbL2ihcOvEZTo6JAy8MYTU=; b=RPswE7d5b6Vd9Hoa1X5z6wAyrtZyy/1f0f7QNSWpb6myRvjzt7Fcp0t4xKt/IJnZvdQvpHf0ZuPQjYpAtCJyaioIRO8kI1CF9gFy+IZO4ht6wOdJZgmfRpHPQR7yrqr3uMLYDyCAADjrLEVZCYsy4cu+ZSeVyXXP9GIKW1WAg/+PFY02YHNkXtRhJztmfPiEV8HaBr30o7n8oIeggX7s/OyVnPVRn5Vfkti66FFujZxRVkCHwFQTddGgkF2jpLf0bEG6AbbOjYwYOJUiiUrJ+cuiHQcYNO/1YHvAsveyLMj0Rgc0/SuFyRY572AwoZ5xisO970kEplemugPj7T7O1Q== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vivo.com; Received: from SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) by KL1PR0601MB4354.apcprd06.prod.outlook.com (2603:1096:820:79::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6544.24; Wed, 5 Jul 2023 09:01:36 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::fa0e:6c06:7474:285c]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::fa0e:6c06:7474:285c%5]) with mapi id 15.20.6565.016; Wed, 5 Jul 2023 09:01:36 +0000 From: Yangtao Li To: Vinod Koul , Kishon Vijay Abraham I Cc: Yangtao Li , linux-phy@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/4] phy: marvell: phy-mvebu-cp110-comphy: Use devm_platform_get_and_ioremap_resource() Date: Wed, 5 Jul 2023 17:01:23 +0800 Message-Id: <20230705090126.26854-1-frank.li@vivo.com> X-Mailer: git-send-email 2.39.0 X-ClientProxiedBy: SG2PR02CA0031.apcprd02.prod.outlook.com (2603:1096:3:18::19) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|KL1PR0601MB4354:EE_ X-MS-Office365-Filtering-Correlation-Id: 2bc4023c-0242-4600-7031-08db7d366fbb X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 2nbYAh/ljXdWpkVwx0Lxou3fWvBMqNSSIDrI4kxf4SGSiz4FNOaUGG7HnkfONWRHMHLivbKjZ431F6YFXR48ec2eIoTJJfd47PPeS8k05LCWDBYwdweXKMZkoQnUwAjwRiPq4H5GMjjDQvr5o9jZK7gm300RFJ0vrVp8xGj+RSOYuv+f8B45c4FkTD/f4z/fc3G+PlWQhk1WuHo5EFzHGhEWswZgWC3iTdK8lui4Aj9JsCFSio/4vRUVZP42Hm4z4aYKA06Txc2OVSZVVIGkhVJUsPaGO8r8tvGw0h16ryNSacE6r4la9XrLFzsJlN+bud6199JtOevJZcfjTFW1zAfSE8AoUoP7e0VcOQ8CHx0zuNC9AnS9PMsKosYnKfgXEsSk3PQkHg/1KUVZCnWnryjVH2eoF9eyCE5iYeFqnyE87uSpSl9Ijsxp04DoRE9AlYcDmDcYQSSaGubf8i7Kn8Aczlnon+aPetjioklFLb+tKoXBEQC+kVZvJ/aukNnK28uRgoSbkgw7eh/lZod3EDd9W3xVa5HFUPkHeYThTOECJkuyvBDvBQSkqqQr3PRSbJ9Fcog3EpBY0QrQ3jDQS7xRQiv9NjS5SE4VT+Ld7hGI4dQVT1ybfuAPTJ0w6oey X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR06MB5269.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(4636009)(39860400002)(346002)(376002)(366004)(136003)(396003)(451199021)(26005)(6666004)(478600001)(1076003)(6512007)(6506007)(2616005)(186003)(38100700002)(66556008)(38350700002)(66946007)(4326008)(66476007)(83380400001)(110136005)(6486002)(52116002)(316002)(86362001)(5660300002)(8936002)(8676002)(4744005)(41300700001)(2906002)(36756003);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: CQpjogTVyBlMuMEzojRZwM04uKhyJt3R3/3maLZJTpjhxwxzgDFYCRK5LaPBGRy1oGJRYDihzYROhnlb6PWKg6h8T6BbLghySK33E/FnxI7tvnQZRTiTvu7WZkvyDl8zpX/Tlb5aeWjh+JbiBVoEs6dZTAh99yf6Sj9Y107CE54YynWBn1JUG/FcFUliEBVYJxxwFYzm3WSZQgn/4alK1vuqQfizsf18aBMa5aIeLfxeRRqGhWJxuKqQgRPEg5dDk+VSsouIY9SISn3/0NUQLf6pHAwIKOBKRZioaSJyoAI6NsLGRSXBacm2+XPGk6X1Xcv8pK58gPOrQME1XDxBDpaG0PPwaShcdXV2O/Hnz6Ng9189FCCGvVi3AA9QaKz6xogc6nuyWcX7NKSlQZms9HcLq2xCCYFwI3wCHC0bESY+6GaO/+4mjkrIpSTSxn/LTABYykceO23DzdQEsQLhqklZdA81dMw9s+o3v8z/1asqc4ZZcHZXA2DlX0k3iwqFm4NujePgFbmN6SJJ5ngc2TS0wL2mLHPWiXBNweUBGIlZUtOQ8QMRYbz5iJGZKT1BeZYZJM2PjAHurmKfS9v/OVzM+VH2219Lk9h+BZ1q0E+GUkiaaC/jygWY5jv/MALL1jr9BMujEYaxD0TWYz/gpk5S5wLSP+P2Sg4Z0SRCEDrTcR47uA1SQW1GGpnLbCxroMvqysVeOj5dtp0RYqGsUKl+5OWrk4neGUVugGycYLNJCJnqka5DEGtjSBAQy8VHcN2tC8h+EypjemLNg6zN4dzZ8QBGq0fOWXmkS+sE4vCVe42g0QYkNZoTiCiRPywV0gb7nmUjBRyLtYRxjKsFq/L4/cbJcMj9agv6P5wLffvTTlRKLxoRhsHmQ0h5YTSFApuCKjtMeAS31KUcS6I8jMmJa+NbwbvE+/fPsrFo4sMPZa/T+nwo8b0SR87ghfH8e+IJ1LlF9PHUBVRaqlOh2LfW1VXXMpoxqfd2dfVj469HMMaWskM0Cebmul8rGk5vW5giYxhcpds3ixzp9zfprl/slxE0GOfFUOz6hgbVaUVsmV54S3cjBbYV7TZBfpXZn/B/IbsvX8aTC9UtjjGdzlzrrWWgx6SHBAMNZAieSmdrckRl70eCnlqjNs2SWJQoctBXOG/mrhOdNsZUeoBGX2a2hBp6KwSjkjBG8iH6X5yh7AEzRU95dTnSK7bK+6Yk2RhC3ZhJVcgKK07yPtCR4T23+jBThjI4gN1sXlShQtXOSNBjpZQTqo2JBnwuycgWh0JUxUPDrKwjWAjZ4gEHZnCxa1twBtGzBBVvlFF/hbKPpfb/QopSpsj92F06TMbhmHIWFcocdFskcck4C6NDP15hiGfFKn5fDjsmkKZ2ijuh7AfJ2G7arazkmkVtasCX3pApapcz9LuprOl0epYiXVAXmpeUg+4KJerWFic/mTc4+SKnq9Q231tmLfnnG6aFzL+GrTXJEt0x35mLaInlb4VHJK5cbplocZhpFewfRvmpfGiyECzoK7K7SQxGqNT9nGug+otkU7exREAw9kqI7RRJ5ug4tt07cOOsu7wS8XwWpCLnUQFbISGxcfTSeOfr X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2bc4023c-0242-4600-7031-08db7d366fbb X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Jul 2023 09:01:36.1480 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 923e42dc-48d5-4cbe-b582-1a797a6412ed X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: zTUBNuaHCtn+8+ATV3xiNWVL5FT+7D7FiRSsG34Wsw+MW95FLgWikmzoGDIhmjCBXk+oAtCA2+ZOT+cULjvDtA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR0601MB4354 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230705_020148_385923_CC56A24A X-CRM114-Status: UNSURE ( 8.61 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-phy@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux Phy Mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-phy" Errors-To: linux-phy-bounces+linux-phy=archiver.kernel.org@lists.infradead.org Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: Yangtao Li --- drivers/phy/marvell/phy-mvebu-cp110-comphy.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/phy/marvell/phy-mvebu-cp110-comphy.c b/drivers/phy/marvell/phy-mvebu-cp110-comphy.c index 34672e868a1e..ddaddb3c498f 100644 --- a/drivers/phy/marvell/phy-mvebu-cp110-comphy.c +++ b/drivers/phy/marvell/phy-mvebu-cp110-comphy.c @@ -1011,8 +1011,7 @@ static int mvebu_comphy_probe(struct platform_device *pdev) "marvell,system-controller"); if (IS_ERR(priv->regmap)) return PTR_ERR(priv->regmap); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - priv->base = devm_ioremap_resource(&pdev->dev, res); + priv->base = devm_platform_get_and_ioremap_resource(pdev, 0, &res); if (IS_ERR(priv->base)) return PTR_ERR(priv->base); From patchwork Wed Jul 5 09:01:24 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yangtao Li X-Patchwork-Id: 13301845 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 37605EB64DA for ; Wed, 5 Jul 2023 09:01:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=mU+XoF4mLQZP71lPpvoSxPh4+DmWUCbEF3IVL2nggG8=; b=4jE4ShKyNVIsKW D1Gx8fcvMgdqyIX+64hKgT1TI/U8wYosiki+wXDGAzerur0eLr87SkWZpB3NXVfaFLGG9EVMXvYLn IjS7/1ETMtJqLgPjcaXUTAeLWUrxv89KWIVHcv0goWbbnC7Nc2gh8HCVtQn5L54sjqAVOrq4WMVQm 0j9KT5/0mtSx1JstriVJ8nKW8pxgOHscfg3c17wo2macKZwHfLBK2OtJLK63pz80EnLUFpw8yoBbi WQmUiySmec5eSrRclQZHVdaeL4MzOVji+ikU3Ke8KMplnw2Zg3tIqbAEoFFbjDp5j/4IGl4MAg4Zc omygvoYsRrSVZJJxOTlw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qGyOW-00FIHU-2Z; Wed, 05 Jul 2023 09:01:52 +0000 Received: from mail-tyzapc01on20708.outbound.protection.outlook.com ([2a01:111:f403:704b::708] helo=APC01-TYZ-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qGyOT-00FIFK-32; Wed, 05 Jul 2023 09:01:51 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=LDeBMHIOw8e2X8wsB6X0vA2WYYoxewtaL78iZeo9Hot2F/zUbut0xhgPwPPDnm7HgPL3TOt51mX36/FJyLmFIklPnKdzmibDPkwF/4RKdY58t+nKNbOkIvioMvw3MMUVYxFqfKYPnhXzN39J4qkVTLKaOS0f0YYyyzyuPE+7VzjIJvW7xPuy24Ek4ftrorajtK47hWOcREdp+0HRuTyuoVCg5jf3i9UOtnJoo1I8xAMEWHX/PQ4dWcg2OsdH6UukvvI3V0ClUWKRYSbkHTU4u84VPKaUC0qtNZzBekPpSy/EIoCW6Jr7PPlErRg4V43Cs9nUsgUSOdxfu2YX8C3/3A== 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=b7ZCb6gBF/T5dPOtRZRsisUuFmF+iIQAx5cwFLB54f0=; b=MLU341s1/Psi9jOMWEJKUK4d5VMaZF0oowAF1tbKFIybCXviG0Qr+UMwuvkeSrBRiRjowC6z0lI6yAB7u2iHuMxzY4tQ0g9nZ92HRv2EaZH+Ijnr/82up5fVnlRKqHo0O1kGXLHieHCV4Av58uCoq0Y8NImJnDlN8RM6FTuyVgAtf/YdiGkM6BdGMyhHu6RwjC/D87tRWLzwKM/KbJjPtrnTG1Abjxo/H6oS5xhB17/79d4R5WWLrNwfeQm/knkhELvdB8fUWFF8mTgKm/jO3AhpzqGOQGSULaKPwj98OV79ULg8WVDAtjXC6XZC+7CtgB53Gw11L/UgygpUAwKZKA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=vivo.com; dmarc=pass action=none header.from=vivo.com; dkim=pass header.d=vivo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vivo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=b7ZCb6gBF/T5dPOtRZRsisUuFmF+iIQAx5cwFLB54f0=; b=ddoO4X0XN2WBsfnLeovQRRMWmrT/uawbONSss5z4SUZMCZX/eJlCb69R6IVaIKlPmJwDVcu51LCbuI2p62TmU/IgiIh7e+7qTi+pYl8jJUQViFmXmrjT0vk4lVqg5icFDHo9bMBqDGSUKv9AFB+vdgqDdh/OzITQY79amfQrxZEtBgaasEmvZfF18RLyaln1buZSFpVyo3lZkJmv5vgqc0IyiBIrrlaFFoM0gdDwP7bwasugHNp2uFeonqxO26CDBJQQ9l58kfivXNxsl93XC7NLt7ypYHcL0HfOcJoBhmW7yohEgD9wippN+o6omy5oPl9/qNS1OIkPtVhqURq+7Q== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vivo.com; Received: from SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) by KL1PR0601MB4354.apcprd06.prod.outlook.com (2603:1096:820:79::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6544.24; Wed, 5 Jul 2023 09:01:38 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::fa0e:6c06:7474:285c]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::fa0e:6c06:7474:285c%5]) with mapi id 15.20.6565.016; Wed, 5 Jul 2023 09:01:38 +0000 From: Yangtao Li To: Vinod Koul , Kishon Vijay Abraham I , Heiko Stuebner Cc: Yangtao Li , linux-phy@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/4] phy: rockchip: phy-rockchip-typec: Use devm_platform_get_and_ioremap_resource() Date: Wed, 5 Jul 2023 17:01:24 +0800 Message-Id: <20230705090126.26854-2-frank.li@vivo.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230705090126.26854-1-frank.li@vivo.com> References: <20230705090126.26854-1-frank.li@vivo.com> X-ClientProxiedBy: SG2PR02CA0031.apcprd02.prod.outlook.com (2603:1096:3:18::19) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|KL1PR0601MB4354:EE_ X-MS-Office365-Filtering-Correlation-Id: de66c3f9-59af-4460-2953-08db7d367109 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: uieH5wjL6o4OqHzGnlCzwOsW47BoZFdclbPQAxdY7g2oHXaoBEww0cgtlLb0egSsym2YrfLVCb6QYZaEB8r5LK/jhLZAKFGucX3U1K7TzT5JazqkC5YnkLfNjgouWyx8Bztloz3uEErrq75LVQno4m9ZoM1hAEtrV2Fqxiyc8tt0eq6NKG8wawfzX7gQzpkajpECF0tE8nj8pnckNMgPhTluxjU5AYdEbThRc2czjblg229t2o+mr1ImIOACok47S1DVMckMswLJiZnS4LGDNoXBCqCxUgq71s6HoizuxYa/Mm85Jp5aPV0jXxC8XeIb2dGJGqJZNCyToKW6+jYMr0JBmDAv//JJdpu59cKsY/0jl/rnlStREAcOVokQ0oevsRpHFmOabyfewiL4M2nqfJY8ieKyzO5ocCHeoBn1lJHngHmspBzy7KOGdY6YlvokJyXyFMpFhh9oTwwTBzUnjSB+yOk93grfDiXmx3eb0cX0xr+LrY1sSBnDDgJWpoAedV/EOU5IaF6+HkMSIsXBJ3UvS7XNn95U51/42ClP0NT0d6O+DK7TRhtE92CDypsaP4wmkxTgZnAQc47h1hGf/Zn+xOxf6dKs/PMcEeBPNfX7lfqQr5Jx55PKTvVgafwF X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR06MB5269.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(4636009)(39860400002)(346002)(376002)(366004)(136003)(396003)(451199021)(26005)(6666004)(478600001)(1076003)(6512007)(6506007)(2616005)(186003)(38100700002)(66556008)(38350700002)(66946007)(4326008)(66476007)(83380400001)(110136005)(6486002)(52116002)(316002)(86362001)(5660300002)(8936002)(8676002)(4744005)(41300700001)(2906002)(36756003);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 26z7S4EVtT6JYZvikY1yV1Mj15fRuZmQKKxVFt63W2fAYJMQcu0/0rnFHVLkHzzaECOJUhGo9HCw1x1pUJSkyv2p2T+O8Gb/KWokSs95Bh2dKOzLLTgssb/FEAUcXg5Kyv9nAr9gz9EIBSw+bhFacA+Pd951APIinkrEkxTuidf1xlJEZuWEfCd0dsZT+G30pa9KoLL0iTmKvp9CAEYGO8q+1N/JUEbE30JGJCm7dbhCWD039oTujNyE75AVlBrN2PkqHatm+42suIDIxeumP+Rm8LqdWJk3ZMO/g46KjZ8Jthb9Xkt0/AZZH3t9aCRuY3Hk/+0YQIchwbaDF9ZQ0EnXwuJoTD0rm9276yn9IcG/ZDSGRB15Lt0j5IanbWlNL1Kyw5HU0wMHw5x0Mmg5cQ2Bb5Nc52vXEYQAuy0GVHY5LwU4m36eU7JiYb9ZTEUXdLd9tDy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OqKkL4SSn8iCQn5zS5ofPfz38sV1uAyeKCy62NrdQHGYkw9WKJbm9VF6UDc8u9Qd2vLNEBN X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: de66c3f9-59af-4460-2953-08db7d367109 X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Jul 2023 09:01:38.3439 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 923e42dc-48d5-4cbe-b582-1a797a6412ed X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: gLewlQxSgw+ojUdirKsO1anosoOMaP0Qi2y5JPlOcUH75r5VhyTd+8lLudUrYeRC6ufAtgk/8CwvuWzJ/iMZ1Q== X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR0601MB4354 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230705_020149_984669_B4EC6057 X-CRM114-Status: UNSURE ( 9.55 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-phy@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux Phy Mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-phy" Errors-To: linux-phy-bounces+linux-phy=archiver.kernel.org@lists.infradead.org Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: Yangtao Li Reviewed-by: Heiko Stuebner --- drivers/phy/rockchip/phy-rockchip-typec.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/phy/rockchip/phy-rockchip-typec.c b/drivers/phy/rockchip/phy-rockchip-typec.c index 8b1667be4915..4efcb78b0ab1 100644 --- a/drivers/phy/rockchip/phy-rockchip-typec.c +++ b/drivers/phy/rockchip/phy-rockchip-typec.c @@ -1116,8 +1116,7 @@ static int rockchip_typec_phy_probe(struct platform_device *pdev) return -EINVAL; } - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - tcphy->base = devm_ioremap_resource(dev, res); + tcphy->base = devm_platform_get_and_ioremap_resource(pdev, 0, &res); if (IS_ERR(tcphy->base)) return PTR_ERR(tcphy->base); From patchwork Wed Jul 5 09:01:25 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yangtao Li X-Patchwork-Id: 13301846 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 884CFC0015E for ; Wed, 5 Jul 2023 09:01:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=b3uLljHApsJwGMCc4Gho54vK+d3Q4vESxU4PRwl50KY=; b=g1PKq7bEy5DxgK 50LKoH7/zta5H2VS0hq2IpeLpymfsLEfCU1zUtiLxH0Nv84dE0L5w4LH0vHwzlk1PtGZ9UmtdBWo3 rIXYwfKN2TPB28ZeIVY84XjzEw33aLfiDpxD3c2zIUAMkuV+owe4yb2J+Krt0DrW0Pwjj01X14oiB ulMQLxPEIxLMmQvK/hGd+rEmqCkGPJ1CTJ0CfnqVaVGiGndt8OvjqH7muBka3dMlD/hoVIj412YDg funHAPKFIN3LCsrD2P+F/q+t63KYxFf0x5xjqg4sq5+56nTS009fJvjkrG1Mob5qL8ljUlpDDJxqF GWQRUiymNK7kokN1dVfw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qGyOb-00FIJu-0f; Wed, 05 Jul 2023 09:01:57 +0000 Received: from mail-tyzapc01on20708.outbound.protection.outlook.com ([2a01:111:f403:704b::708] helo=APC01-TYZ-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qGyOV-00FIFK-1f for linux-phy@lists.infradead.org; Wed, 05 Jul 2023 09:01:52 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=T5I4q+XD1ETMzQGeo1Hh8DFgA30539lIcQ6a86GhtYWJVNUwVgCtGqlPWSAsTWhn+p8aMEoqg8UZJLbKr0Z23potYSSNd/vSGSYMWX8Ot1k0fW1X2KW23zoZS8voCuL63nFn9/mI1Wfw2rcghJNjTHmVRA7nb6xdtRecVJBzfwnZ7eqvm0ckUtEClAW7h4FSPIPedBmp4argDCCX88cIOyUMl0ssaxEK2EPB5M0Dvpu8GptVX0R7rngBhs62RYPVPowUKkXXSJZGMiEEL2Vz9u3HPk6JU71ecpGBaXuiKOuEwVe3cNA322YJr8OdfHic/jWI16VlUelF+nnujGSG9Q== 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=CzM3M2AMGRYBhhdgkF86J1BOluETaIU5fbdzSgyc4xk=; b=LQ6JLTtOwuNH5Ngzf7GW47k/yW9S7XbGROYkRbCiakS/xKKQRf0lOBeS6AEZ1k4pb4zbCdUGm6XV3ATO0GsTooOdW6vc9qsEEhxwal3reBCgd0OZFGW+pgsYQb4oVBVBbBY/gjO2hAqxLoI+eEtFPoV38rsf6z0B1zpBuzsPyabiJqRc7i8n5sq9c65eW6WKIISczLH8Pn8JGzGDslY7Vq3SBjHa5mEQG+ci5M4gQzSIOnJWurA1QqdYdeH9URLb2LSscEOfdWBoEBxThNbgskus1ky65Vk5Ay2Hl0fU0CYDqBCi1+OWGx5TEND1qxW+T2gYplKc1FM1sco/PQWMPg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=vivo.com; dmarc=pass action=none header.from=vivo.com; dkim=pass header.d=vivo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vivo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=CzM3M2AMGRYBhhdgkF86J1BOluETaIU5fbdzSgyc4xk=; b=U/3hByQuOPrCanzAR4DQHR5CyD8/XgS/7/2F1sRwOF/M5cLjbRw54r8Wz/argCnLkzrKcPC+x+eu/wOhm1y2S9MZaaZR9SESD1BnpKNHYt40lQ0czlY3vH4awh0sQ/qSVAEuVmc6Gvu+86/keTF/+9InzPWVQ7OvSiV4MwRgs9tm8p+KraW87KLbGv+KofNqhb5nhNAp5aNwHh4vM/9FhlB3Q1A9dcNPsv6ybKVArvehA2ow0u+eS9lWngWj1UquV43E6MrK0c0Seq260b3cHqiFJOZ51RnEZKbZuCE1FWFgALX6xB/MmV179RnP+XVX8Vjg6Vm8e+J2JAsqdJ+lzA== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vivo.com; Received: from SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) by KL1PR0601MB4354.apcprd06.prod.outlook.com (2603:1096:820:79::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6544.24; Wed, 5 Jul 2023 09:01:41 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::fa0e:6c06:7474:285c]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::fa0e:6c06:7474:285c%5]) with mapi id 15.20.6565.016; Wed, 5 Jul 2023 09:01:41 +0000 From: Yangtao Li To: Vinod Koul , Kishon Vijay Abraham I Cc: Yangtao Li , linux-phy@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 3/4] phy: renesas: r8a779f0-ether-serdes: Convert to devm_platform_ioremap_resource() Date: Wed, 5 Jul 2023 17:01:25 +0800 Message-Id: <20230705090126.26854-3-frank.li@vivo.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230705090126.26854-1-frank.li@vivo.com> References: <20230705090126.26854-1-frank.li@vivo.com> X-ClientProxiedBy: SG2PR02CA0031.apcprd02.prod.outlook.com (2603:1096:3:18::19) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|KL1PR0601MB4354:EE_ X-MS-Office365-Filtering-Correlation-Id: fc2125e1-8bf9-4e61-6e4d-08db7d367241 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: JE8fa8Dq9ijSsFcGjVXNAkNVGYmp2PLP+/qje1nKafu9x2gc70LrrYh0b2AJ4ZkrPzAd2zaBbtb7akycsxzfFwCNuLtoFhjbLS3ZHyITrCCVCor8Krgxt0kpni1LJnHnlYif+iqcFPBF2+6VAhjh/Zf4pE7DwYCvaAQpOfHCbee7yfLW/4xfcohn5b32oohpNXgVWQKjeGhYL2jqK1Q4nGHzCZDWIf0wVn00/4psNhkQhKozdWWvDhlPFylaEI59mX+VuVIKOI6tuLDyuf25dtjfEQ3dXtvcXfByXicsB4PIn03PpBp1pPznpDrSW575UTNeZesR2X7ncxx2fGB3E+VtH9C4oqF2w8DyhESO3kS56kefLj5zQCq0GY7ZxOW9WGDmmC1gnzZ3I38Hz9MHSmUH7EYEVwFeKEpn1K9Tq0FNt4bVSwIs9KI9Ai2UXKuZqRQIh3giVA18HfAcriB9BrHun9tNy77PanudpO/IzUuSmtEj1pU80ndYcksj5Gs2dmxuojpUv/vrSOMDz0/J3rwnqXEPnbddyzG9L5Hm/Z/wLLtuWXOGSmicFFKvMW5s1jQj6T3Pwt6G34+XLlOxxVI1yCL7Vc7IyQS9ci8fQGB15auhHrsmaIYKAHmDL2zO X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR06MB5269.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(4636009)(39860400002)(346002)(376002)(366004)(136003)(396003)(451199021)(26005)(6666004)(478600001)(1076003)(6512007)(6506007)(2616005)(186003)(38100700002)(66556008)(38350700002)(66946007)(4326008)(66476007)(83380400001)(110136005)(6486002)(52116002)(316002)(86362001)(5660300002)(8936002)(8676002)(41300700001)(2906002)(36756003);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: OmZKAen/9o8zatq2Nl5lhX8BdB98cesQ8qqYeorLiE9BRuSZRz/oHihnzZanT6AfYpRZ5TiLBM/k53/oUk/COJvlG7ryvEobFExUCnBv2OLTcx0YLLQ0Wk6VTHcE+FdL2c7SAjWtv78ma29uCAXSUwEk2jpEW25pi6/YicFFF+kzt9h42NJXkuVvyN+TYHnGb94v1UOPI3lhSVnhxng/JRuR155Z6ZuQRqJ2PVgWjAFZ9CIKE4HCuVUHcQx35cHP+Q8QdW88kJYlwi6b7gnjjbgfnqB1xqAfCD3U917jUqHbTLs7V8oJJcPAvj8rLB1RZw5slf1A7YCUUdt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f08/+nCgnlLMQs2Pq2sw7sw99XI9lwOl7ZOFyk5fPczu9/o7n6FKnzIlKpy3vZNHaCHoLgBiNDj0knWoUXeeEAKJAsm8kXshUcdibd+Tl+662iYv6jPcIeIYVD3mNNDbL8U5sKtGT+8DKkkZDOhEHhOy+0hdbGBJWXiBlPB9Me2Z5z3+0kWi0leBzrgbj+ksZah9C9c9 X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: fc2125e1-8bf9-4e61-6e4d-08db7d367241 X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Jul 2023 09:01:40.3773 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 923e42dc-48d5-4cbe-b582-1a797a6412ed X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: fOvh/oRfKG2eEjypqLCJATSAqsFpGx8OT50gksQCONCwviNgv0g0nT+PZoS7OHDsvEpZd8L3LF0exef69dVfeg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR0601MB4354 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230705_020151_557899_8FD23690 X-CRM114-Status: UNSURE ( 8.45 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-phy@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux Phy Mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-phy" Errors-To: linux-phy-bounces+linux-phy=archiver.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li --- drivers/phy/renesas/r8a779f0-ether-serdes.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/drivers/phy/renesas/r8a779f0-ether-serdes.c b/drivers/phy/renesas/r8a779f0-ether-serdes.c index 55b7bdfc10d3..67f4c6f8ff91 100644 --- a/drivers/phy/renesas/r8a779f0-ether-serdes.c +++ b/drivers/phy/renesas/r8a779f0-ether-serdes.c @@ -339,22 +339,15 @@ static int r8a779f0_eth_serdes_probe(struct platform_device *pdev) { struct r8a779f0_eth_serdes_drv_data *dd; struct phy_provider *provider; - struct resource *res; int i; - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - if (!res) { - dev_err(&pdev->dev, "invalid resource\n"); - return -EINVAL; - } - dd = devm_kzalloc(&pdev->dev, sizeof(*dd), GFP_KERNEL); if (!dd) return -ENOMEM; platform_set_drvdata(pdev, dd); dd->pdev = pdev; - dd->addr = devm_ioremap_resource(&pdev->dev, res); + dd->addr = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(dd->addr)) return PTR_ERR(dd->addr); From patchwork Wed Jul 5 09:01:26 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yangtao Li X-Patchwork-Id: 13301847 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4DF1CEB64DD for ; Wed, 5 Jul 2023 09:01:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=K1j0Lkgixtz4UZDB/WQbj/CFkUdR8aTdUDY24mUtQcM=; b=oWeSdz4ioQct0x gQbTKyzYo76kRb9oWJPp7d9/n6mpo9sIOLT9POzot/C9LRV6nh9h9NURVbzobyRaps8FgAbj8xZER mjukW950W/h7j9lZrBVFjCMKmv9R2S85bbZyUodOF8aDq3x5WqkeuGjn5bEHK3eXFGlMTHj5poe6T 34W5z0FtcyM2Jl/OiTwhM/vvmRgW0FWOW0hF1G8cEfp4joOaTPI+1M1iX5m+eBY5ctmlPH2P76qlH U7Ufd+fO4fdl5/LQh0Qvkr9G6QbRF9dBlSELinlvxNnKkqvCluvMjQmj0B4roi8Yb+A9iPt0bV6cN sjPyq0TTXb8KUBVfH2sA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qGyOa-00FIJR-30; Wed, 05 Jul 2023 09:01:56 +0000 Received: from mail-sgaapc01on20718.outbound.protection.outlook.com ([2a01:111:f400:feab::718] helo=APC01-SG2-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qGyOU-00FIFc-2y; Wed, 05 Jul 2023 09:01:52 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RreXiUEDWRsFlXFH4rteZgQJCiQabu5BrN2k5xzqN+pw1I7VUzvyjL9IPJAR9vkXbulVJonEzKgRpSPcLGH47JCq/tJ8r4yaBJNdIXVHSBZIl8E1+dPnlbOUwgoJPqJAq8v7xfrzflll6QXTYaiIFQTKreDQSlB1GBGywlDif3jLChbme8mFGJcRzKKfdwI7573804eQX8TE1xnwGzPpHBj8kR/fQJ3AhqA3TnZlcZHdIuvTii6JGxZyADrWMLy2hupAc8nIhGEDL+uSSifg1+/LkUtCED6TmvSR3RtLrd+ivJv/4QUFi0L5aF7xe3JV5NdeFmQqpZn1Mb3ExlE+cQ== 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=ceERcHS3vIFMT+gdi/X160XFJqjBBw4HMM1zYRm1AnM=; b=AeBFlhjSteoHryiyMWPIPGJ0jJXyA+MCgjovIjZ3hACTaqBChl43gJAKDdr/papZmcwBF6WQ/l8d1phhXr+yPLLPefL9j3MQpd8gbTGHOnMpEb2Yxb2PelFjZ/GXq68IHkScE2Cnp+ryOdWz0BPC+mPkZQpZ5z18AQ/e8KPhDIXH6cyGtsfuJMpGUDFs8+vw3oR+Xo2QrWD5/RckpErnGw4emfQvxMxj3FPWL7qYCM4ERBHWDSRvMFbjrickhRw9LapYuuhvrOknymoCWFPYbDMFZ2g35ppaqGaMPG7uxeYn/t+S33n2yUk6ORHpzaqncnKyEbQmn5gfRswhsGRTeA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=vivo.com; dmarc=pass action=none header.from=vivo.com; dkim=pass header.d=vivo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vivo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ceERcHS3vIFMT+gdi/X160XFJqjBBw4HMM1zYRm1AnM=; b=SM3uo7c4RTqfsUIWiqroqPMmR9INNhtgWcVYpEkpp6sa/ZslwlgColAzm7hTU4f/hnEWDUVq2/Cb8LFGj5BZ0LAb8BylvUZWrAcUqFN3GzWO3OHvAjNE8OCSvBUHkhzMKVtd2BHQg0cTuBzrqM7VGBxfbpbQuOLgSx9mTqMq67CP1hH8FYkk5AEy5y5LAReUiC9atTvv5/5Dm3cAOP8hC11cDkrodadnVroAnz2pa2gHM+dAC/ZZjdUKYPosT0oqmdHen9G+5z0+GF01XvxTf+rHLtZZLmLGdoNwbeblrLUdFNe3L0loKRfmsgNmpu5KLwz5jzENiVJQXYa5KLpWdg== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vivo.com; Received: from SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) by TY0PR06MB5804.apcprd06.prod.outlook.com (2603:1096:400:265::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6544.24; Wed, 5 Jul 2023 09:01:42 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::fa0e:6c06:7474:285c]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::fa0e:6c06:7474:285c%5]) with mapi id 15.20.6565.016; Wed, 5 Jul 2023 09:01:42 +0000 From: Yangtao Li To: Chunfeng Yun , Vinod Koul , Kishon Vijay Abraham I , Matthias Brugger , AngeloGioacchino Del Regno Cc: Yangtao Li , linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-phy@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 4/4] phy: mediatek: tphy: Convert to devm_platform_ioremap_resource() Date: Wed, 5 Jul 2023 17:01:26 +0800 Message-Id: <20230705090126.26854-4-frank.li@vivo.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230705090126.26854-1-frank.li@vivo.com> References: <20230705090126.26854-1-frank.li@vivo.com> X-ClientProxiedBy: SG2PR02CA0031.apcprd02.prod.outlook.com (2603:1096:3:18::19) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|TY0PR06MB5804:EE_ X-MS-Office365-Filtering-Correlation-Id: a2f6f803-67b2-4106-fdbd-08db7d3673a6 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Vx3RSBL/wOF2z9ZCcWKGfxSz9y5lpaHW5XUSZRvrV3PXOVqsLNu+C0Kn00K9lfrx1w/6mioZIOpA61AKADtIvLTAJxDAuBbkVLoz+8yvyYHW+wSL3zb0eEeTzQnWwY5tGkY+rtgzZcu3LCgYhgvJghZejOINfthuxEApjvVSOXY/9n4Ezz78NXO/6ZImiv/RbC9zy9JtUnVNq6TPgxtKm4AQgkmMwXm8WEd4rYpEmZD70VKVA8/AsI8n4DTdoN/zzGOWlHzfAR67nTjQ1FcG/jSQFaBbekUjFRwSdd5i6kMsQqK5l8WphCP3KYBDmmTw7GF1dkct36SxukLMT/Urlalm71FkybV1ShHN0gnI8IdF+EfRv+DIVvXdTjSBSeicItLlLoSoqv01XkUIe13xnz+Hv9iY46osVJUErNs4IvFtHYeq/qHxL9yjErgiqgw2zk/AcBhU2ZKhNmBzwJnTAm6PFKTo8VHOx2FC/BYZB2YjBAImGtsw5dboGbVoM419fRKZMelZYKA8CJkrBZsUFGSV5Z9nl4zDcrBiUb8NGG8r2o8IwB/pk1fcieXEaqVRant4FraM8v8FpdqdfHX79qLkf2by+Dr0J7wGPSwV3bgoHFGMd/HVTiK119M6eMSD7RK3gWOmBSyG9+bTwbw/2urnAAgRhX1RixAYJdjeoGg= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR06MB5269.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(4636009)(346002)(39860400002)(396003)(376002)(366004)(136003)(451199021)(26005)(478600001)(6506007)(1076003)(6666004)(6512007)(86362001)(2616005)(186003)(38350700002)(66556008)(38100700002)(66476007)(4326008)(66946007)(110136005)(83380400001)(52116002)(6486002)(316002)(8676002)(8936002)(41300700001)(2906002)(5660300002)(36756003);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-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MtnC2+8PZ6AX6PNWYbnM64CLNiCKhYMsoCawclJYNQuNYn2VXAdMrcrForn7JQqca9weKysCN59ErbluJeLtqlntgOHKnw4OiM9HWWAnbBEQ1y5PM69AJih/H9aQzgKixt1EL/WmEsh3p43NG+fKrp6eTtFtjbvmFli5OU1IH7UfyyFZLS5Wd9JAwgHRoakUVZzWJ46EUJzPO+oq9a+mzenHe4lg6/lvVf41N31uH7A3nrw/gQsAVcMqm2Lv3uM1i1ccliDtma3ioIgNbcBMPK/xqzfMeUdZ6WBzirnAhIq6CPju9QMCJv8WD6yLC/8wP+CFr9HDVKn0QKWir4efYZGy3zx6Ez/1uNOY6tXSfC1IQLcbHP6flFl07bHTTpzci3Q9RH95Y/+UF0fURe8IPxwzU7vEeSBObSMqrYtrjLygeAvy9FqooWE+MAWwby+GllMG3oEGfGA47WBlM8ZEpeHo9OgmtoHJ7h5FO+sCUtMD9XM0Af69j2Xf X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: a2f6f803-67b2-4106-fdbd-08db7d3673a6 X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Jul 2023 09:01:42.6609 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 923e42dc-48d5-4cbe-b582-1a797a6412ed X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: WNJ3vMXy7Un9yMJ5K25ueEIPhNDMfNjWS6y7jDbiycHG1bt+RhhFDpF3kj1HasclO/ElHyHmColtXlMH1aNWAA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: TY0PR06MB5804 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230705_020150_964237_FEE56B1C X-CRM114-Status: GOOD ( 11.72 ) X-BeenThere: linux-phy@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux Phy Mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-phy" Errors-To: linux-phy-bounces+linux-phy=archiver.kernel.org@lists.infradead.org Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li --- drivers/phy/mediatek/phy-mtk-tphy.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/drivers/phy/mediatek/phy-mtk-tphy.c b/drivers/phy/mediatek/phy-mtk-tphy.c index 0d110e50bbfd..cb7a4e6ea017 100644 --- a/drivers/phy/mediatek/phy-mtk-tphy.c +++ b/drivers/phy/mediatek/phy-mtk-tphy.c @@ -1554,7 +1554,6 @@ static int mtk_tphy_probe(struct platform_device *pdev) struct device_node *np = dev->of_node; struct device_node *child_np; struct phy_provider *provider; - struct resource *sif_res; struct mtk_tphy *tphy; struct resource res; int port, retval; @@ -1576,15 +1575,12 @@ static int mtk_tphy_probe(struct platform_device *pdev) tphy->dev = dev; platform_set_drvdata(pdev, tphy); - sif_res = platform_get_resource(pdev, IORESOURCE_MEM, 0); /* SATA phy of V1 needn't it if not shared with PCIe or USB */ - if (sif_res && tphy->pdata->version == MTK_PHY_V1) { + if (tphy->pdata->version == MTK_PHY_V1) { /* get banks shared by multiple phys */ - tphy->sif_base = devm_ioremap_resource(dev, sif_res); - if (IS_ERR(tphy->sif_base)) { - dev_err(dev, "failed to remap sif regs\n"); + tphy->sif_base = devm_platform_ioremap_resource(pdev, 0); + if (IS_ERR(tphy->sif_base) && PTR_ERR(tphy->sif_base) != -EINVAL) return PTR_ERR(tphy->sif_base); - } } if (tphy->pdata->version < MTK_PHY_V3) {