lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1d34c9bf-24c2-84ea-8a85-7cd15e09d6d0@linaro.org>
Date:   Tue, 20 Sep 2022 15:51:11 +0200
From:   Neil Armstrong <neil.armstrong@...aro.org>
To:     Johan Hovold <johan+linaro@...nel.org>,
        Vinod Koul <vkoul@...nel.org>
Cc:     Andy Gross <agross@...nel.org>,
        Bjorn Andersson <andersson@...nel.org>,
        Konrad Dybcio <konrad.dybcio@...ainline.org>,
        Kishon Vijay Abraham I <kishon@...com>,
        Dmitry Baryshkov <dmitry.baryshkov@...aro.org>,
        linux-arm-msm@...r.kernel.org, linux-phy@...ts.infradead.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH 04/17] phy: qcom-qmp-usb: drop unused type from config

On 20/09/2022 09:38, Johan Hovold wrote:
> The configuration PHY type is no longer needed since the QMP driver
> split so drop it from the configuration and suspend callbacks.
> 
> Signed-off-by: Johan Hovold <johan+linaro@...nel.org>
> ---
>   drivers/phy/qualcomm/phy-qcom-qmp-usb.c | 26 -------------------------
>   1 file changed, 26 deletions(-)
> 
> diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
> index 93994f1a46e2..03481b6f1c35 100644
> --- a/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
> +++ b/drivers/phy/qualcomm/phy-qcom-qmp-usb.c
> @@ -1431,8 +1431,6 @@ struct qmp_phy;
>   
>   /* struct qmp_phy_cfg - per-PHY initialization config */
>   struct qmp_phy_cfg {
> -	/* phy-type - PCIE/UFS/USB */
> -	unsigned int type;
>   	/* number of lanes provided by phy */
>   	int nlanes;
>   
> @@ -1609,7 +1607,6 @@ static const char * const qmp_phy_vreg_l[] = {
>   };
>   
>   static const struct qmp_phy_cfg ipq8074_usb3phy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= ipq8074_usb3_serdes_tbl,
> @@ -1634,7 +1631,6 @@ static const struct qmp_phy_cfg ipq8074_usb3phy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg msm8996_usb3phy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= msm8996_usb3_serdes_tbl,
> @@ -1659,7 +1655,6 @@ static const struct qmp_phy_cfg msm8996_usb3phy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg qmp_v3_usb3phy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= qmp_v3_usb3_serdes_tbl,
> @@ -1691,7 +1686,6 @@ static const struct qmp_phy_cfg qmp_v3_usb3phy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg sc7180_usb3phy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= qmp_v3_usb3_serdes_tbl,
> @@ -1723,7 +1717,6 @@ static const struct qmp_phy_cfg sc7180_usb3phy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg sc8280xp_usb3_uniphy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= sc8280xp_usb3_uniphy_serdes_tbl,
> @@ -1752,7 +1745,6 @@ static const struct qmp_phy_cfg sc8280xp_usb3_uniphy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg qmp_v3_usb3_uniphy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= qmp_v3_usb3_uniphy_serdes_tbl,
> @@ -1781,7 +1773,6 @@ static const struct qmp_phy_cfg qmp_v3_usb3_uniphy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg msm8998_usb3phy_cfg = {
> -	.type                   = PHY_TYPE_USB3,
>   	.nlanes                 = 1,
>   
>   	.serdes_tbl             = msm8998_usb3_serdes_tbl,
> @@ -1808,7 +1799,6 @@ static const struct qmp_phy_cfg msm8998_usb3phy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg sm8150_usb3phy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= sm8150_usb3_serdes_tbl,
> @@ -1844,7 +1834,6 @@ static const struct qmp_phy_cfg sm8150_usb3phy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg sm8150_usb3_uniphy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= sm8150_usb3_uniphy_serdes_tbl,
> @@ -1876,7 +1865,6 @@ static const struct qmp_phy_cfg sm8150_usb3_uniphy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg sm8250_usb3phy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= sm8150_usb3_serdes_tbl,
> @@ -1911,7 +1899,6 @@ static const struct qmp_phy_cfg sm8250_usb3phy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg sm8250_usb3_uniphy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= sm8150_usb3_uniphy_serdes_tbl,
> @@ -1943,7 +1930,6 @@ static const struct qmp_phy_cfg sm8250_usb3_uniphy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg sdx55_usb3_uniphy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= sm8150_usb3_uniphy_serdes_tbl,
> @@ -1975,7 +1961,6 @@ static const struct qmp_phy_cfg sdx55_usb3_uniphy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg sdx65_usb3_uniphy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= sm8150_usb3_uniphy_serdes_tbl,
> @@ -2007,7 +1992,6 @@ static const struct qmp_phy_cfg sdx65_usb3_uniphy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg sm8350_usb3phy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= sm8150_usb3_serdes_tbl,
> @@ -2042,7 +2026,6 @@ static const struct qmp_phy_cfg sm8350_usb3phy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg sm8350_usb3_uniphy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= sm8150_usb3_uniphy_serdes_tbl,
> @@ -2074,7 +2057,6 @@ static const struct qmp_phy_cfg sm8350_usb3_uniphy_cfg = {
>   };
>   
>   static const struct qmp_phy_cfg qcm2290_usb3phy_cfg = {
> -	.type			= PHY_TYPE_USB3,
>   	.nlanes			= 1,
>   
>   	.serdes_tbl		= qcm2290_usb3_serdes_tbl,
> @@ -2432,10 +2414,6 @@ static int __maybe_unused qmp_usb_runtime_suspend(struct device *dev)
>   
>   	dev_vdbg(dev, "Suspending QMP phy, mode:%d\n", qphy->mode);
>   
> -	/* Supported only for USB3 PHY and luckily USB3 is the first phy */
> -	if (cfg->type != PHY_TYPE_USB3)
> -		return 0;
> -
>   	if (!qphy->phy->init_count) {
>   		dev_vdbg(dev, "PHY not initialized, bailing out\n");
>   		return 0;
> @@ -2458,10 +2436,6 @@ static int __maybe_unused qmp_usb_runtime_resume(struct device *dev)
>   
>   	dev_vdbg(dev, "Resuming QMP phy, mode:%d\n", qphy->mode);
>   
> -	/* Supported only for USB3 PHY and luckily USB3 is the first phy */
> -	if (cfg->type != PHY_TYPE_USB3)
> -		return 0;
> -
>   	if (!qphy->phy->init_count) {
>   		dev_vdbg(dev, "PHY not initialized, bailing out\n");
>   		return 0;

Reviewed-by: Neil Armstrong <neil.armstrong@...aro.org>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ