From patchwork Fri Nov 11 08:56:25 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johan Hovold X-Patchwork-Id: 18558 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp625821wru; Fri, 11 Nov 2022 00:59:17 -0800 (PST) X-Google-Smtp-Source: AA0mqf5HKVF+45HN/q+PTBiGUyZiuq3uJXlL7TFP87wiyAZVdS/al215Wf5LWiyrhJRixaF9JxWd X-Received: by 2002:a50:9f61:0:b0:463:b8dc:893f with SMTP id b88-20020a509f61000000b00463b8dc893fmr683723edf.28.1668157157243; Fri, 11 Nov 2022 00:59:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668157157; cv=none; d=google.com; s=arc-20160816; b=yR5KxW42kU9rcsUpmXGmrIw7kXDOOYcGeL8mI0L06dHNfuAzx+ibONwf/AbesWA4J1 frI3PJ4N4RACH1qmUd9yJ1xiW17+IRIG8tvFUb2L1YF/PsDxvwgApvVFTeaEp3F0V+XG BzOfw57GVl0Rrg4nX9mcr9RYSEVA5cObZQeeSleXFwQEAZAXHb+lERtx3Q9Eeubtm3td tvj+kbu4pCenL5EZawCUIbjpivcC6t+B5dRE4RjAS3R6IGwKuZEJa+zMNo7ivf6MurM2 qYmHkTC/Rc1UwWb+/B4YbC9HPiK24F6X7Pm8wi36tX8VLFgqgUuiYnlYiJkmaDVUEBvm zDoQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=ROS2/afw++g0wOqRFIf4QccHH79GRHYXQYe92qIJ1F4=; b=yOluHORyD9Ml5G4BVH678L12tCDNH+1Yi9F0hoMaIjEVAcEA/j+nLf5YV2FIDzcpT3 DFLva4IrZydiWvOnQp5iReL7AeMVVLPAn7vvxOku5ntx5plOGYhBBghQ5dx/AMXmpZyc ThrOa6UdC6ugg3CqD6sZO4ru9jRePjtXZzDgOKzVDcZl6UAsuk+XPCaYClYZbTpQNw5v 9w2j1GjJyUVJZ7xwV1ZlOJDTZM54JymLtYRu8TKqPFj2ZBoKLW/b7FsWkzRO/t5sgEa5 i51+d7rXiu387lpwWvnvKPyJLDcGhfWUbuwdgPPnkhjVHIzVFqwVKrltWaAQ4+15954F qCXw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Hr+iCVqa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id nb36-20020a1709071ca400b007a45e4f4ff2si1885008ejc.853.2022.11.11.00.58.53; Fri, 11 Nov 2022 00:59:17 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Hr+iCVqa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233428AbiKKI50 (ORCPT + 99 others); Fri, 11 Nov 2022 03:57:26 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44848 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231167AbiKKI5Y (ORCPT ); Fri, 11 Nov 2022 03:57:24 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0966B79D18; Fri, 11 Nov 2022 00:57:24 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 99ED661EFC; Fri, 11 Nov 2022 08:57:23 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E8B40C43145; Fri, 11 Nov 2022 08:57:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1668157043; bh=8dymqpuzXcztunwC+qLMQlrAR1UOIg2+qt0/dP7pvt4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Hr+iCVqaHcQ81ybHqTryh/Vjay9sVzbzUN5Liko9sRi9WDwl6HPV8BD/FN5Wyk+4F CtY0Nxb8UB8Ofkku8HI/Dlfhhs9LBRU+EGPd3GC/FShdfu/JTrWcJoV+aU1LQa5xfb S1kBXGjDr05FlcrnfOtx4P4YLpILMZz5SEmyCU14cmPjK1woaIOubrPN6eVzPP94f/ HbKxM3egKSb3wWam7N3WKxC9Gxh3krqaxXVkPU3lE75RMhh4uCzhajmg09TC0eiT2T 22wEmzAUHfxdR3PlaWlpfT4bH/prJ/xisQ/yOIoJctrfSyJGg/a+TxbdtN/xuGWZmH 5KgPORDx5/b5A== Received: from johan by xi.lan with local (Exim 4.94.2) (envelope-from ) id 1otPqJ-0002Tv-52; Fri, 11 Nov 2022 09:56:55 +0100 From: Johan Hovold To: Vinod Koul Cc: Andy Gross , Bjorn Andersson , Konrad Dybcio , Dmitry Baryshkov , linux-arm-msm@vger.kernel.org, linux-phy@lists.infradead.org, linux-kernel@vger.kernel.org, Johan Hovold Subject: [PATCH 04/22] phy: qcom-qmp-combo: rename PHY ops structures Date: Fri, 11 Nov 2022 09:56:25 +0100 Message-Id: <20221111085643.9478-5-johan+linaro@kernel.org> X-Mailer: git-send-email 2.37.4 In-Reply-To: <20221111085643.9478-1-johan+linaro@kernel.org> References: <20221111085643.9478-1-johan+linaro@kernel.org> MIME-Version: 1.0 X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1749189559212138630?= X-GMAIL-MSGID: =?utf-8?q?1749189559212138630?= Rename the PHY operation structures so that they have a "phy_ops" suffix and move them next to the implementation. Signed-off-by: Johan Hovold Reviewed-by: Dmitry Baryshkov --- drivers/phy/qualcomm/phy-qcom-qmp-combo.c | 40 +++++++++++------------ 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-combo.c b/drivers/phy/qualcomm/phy-qcom-qmp-combo.c index 2ac29b71d3b7..13800c2243e1 100644 --- a/drivers/phy/qualcomm/phy-qcom-qmp-combo.c +++ b/drivers/phy/qualcomm/phy-qcom-qmp-combo.c @@ -2118,6 +2118,24 @@ static int qmp_combo_set_mode(struct phy *phy, enum phy_mode mode, int submode) return 0; } +static const struct phy_ops qmp_combo_usb_phy_ops = { + .init = qmp_combo_enable, + .exit = qmp_combo_disable, + .set_mode = qmp_combo_set_mode, + .owner = THIS_MODULE, +}; + +static const struct phy_ops qmp_combo_dp_phy_ops = { + .init = qmp_combo_init, + .configure = qcom_qmp_dp_phy_configure, + .power_on = qmp_combo_power_on, + .calibrate = qcom_qmp_dp_phy_calibrate, + .power_off = qmp_combo_power_off, + .exit = qmp_combo_exit, + .set_mode = qmp_combo_set_mode, + .owner = THIS_MODULE, +}; + static void qmp_combo_enable_autonomous_mode(struct qmp_phy *qphy) { const struct qmp_phy_cfg *cfg = qphy->cfg; @@ -2542,24 +2560,6 @@ static int phy_dp_clks_register(struct qcom_qmp *qmp, struct qmp_phy *qphy, return devm_add_action_or_reset(qmp->dev, phy_clk_release_provider, np); } -static const struct phy_ops qmp_combo_usb_ops = { - .init = qmp_combo_enable, - .exit = qmp_combo_disable, - .set_mode = qmp_combo_set_mode, - .owner = THIS_MODULE, -}; - -static const struct phy_ops qmp_combo_dp_ops = { - .init = qmp_combo_init, - .configure = qcom_qmp_dp_phy_configure, - .power_on = qmp_combo_power_on, - .calibrate = qcom_qmp_dp_phy_calibrate, - .power_off = qmp_combo_power_off, - .exit = qmp_combo_exit, - .set_mode = qmp_combo_set_mode, - .owner = THIS_MODULE, -}; - static int qmp_combo_create(struct device *dev, struct device_node *np, int id, void __iomem *serdes, const struct qmp_phy_cfg *cfg) { @@ -2632,9 +2632,9 @@ static int qmp_combo_create(struct device *dev, struct device_node *np, int id, } if (cfg->type == PHY_TYPE_DP) - ops = &qmp_combo_dp_ops; + ops = &qmp_combo_dp_phy_ops; else - ops = &qmp_combo_usb_ops; + ops = &qmp_combo_usb_phy_ops; generic_phy = devm_phy_create(dev, np, ops); if (IS_ERR(generic_phy)) {