From: Krzysztof Kozlowski <krzk@kernel.org>
To: iuncuim <iuncuim@gmail.com>, Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>, Chen-Yu Tsai <wens@csie.org>,
Jernej Skrabec <jernej.skrabec@gmail.com>,
Samuel Holland <samuel@sholland.org>,
Andre Przywara <andre.przywara@arm.com>,
Michael Turquette <mturquette@baylibre.com>,
Stephen Boyd <sboyd@kernel.org>, Vinod Koul <vkoul@kernel.org>,
Kishon Vijay Abraham I <kishon@kernel.org>,
Philipp Zabel <p.zabel@pengutronix.de>
Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-phy@lists.infradead.org, linux-clk@vger.kernel.org,
linux-sunxi@lists.linux.dev
Subject: Re: [PATCH 4/7] phy: allwinner: a523: add USB3/PCIe PHY driver
Date: Sat, 16 Aug 2025 11:33:07 +0200 [thread overview]
Message-ID: <484e4ff2-c7b2-4087-8850-5a972e7c82b4@kernel.org> (raw)
In-Reply-To: <20250816084700.569524-5-iuncuim@gmail.com>
On 16/08/2025 10:46, iuncuim wrote:
> +
> + phy->reset = devm_reset_control_get(dev, NULL);
> + if (IS_ERR(phy->reset)) {
> + dev_err(dev, "failed to get reset control\n");
> + return PTR_ERR(phy->reset);
Syntax is return dev_err_probe.
> + }
> +
> + phy->regs = devm_platform_ioremap_resource(pdev, 0);
> + if (IS_ERR(phy->regs))
> + return PTR_ERR(phy->regs);
> +
> + phy->regs_clk = phy->regs + PHY_CLK_OFFSET;
> + if (IS_ERR(phy->regs_clk))
> + return PTR_ERR(phy->regs_clk);
> +
> + phy->phy = devm_phy_create(dev, NULL, &sun55i_usb3_pcie_phy_ops);
> + if (IS_ERR(phy->phy)) {
> + dev_err(dev, "failed to create PHY\n");
> + return PTR_ERR(phy->phy);
> + }
> +
> + phy_set_drvdata(phy->phy, phy);
> + phy_provider = devm_of_phy_provider_register(dev, of_phy_simple_xlate);
> +
> + ret = sun55i_usb3_pcie_clk_init(phy);
> + if (ret)
> + return ret;
> + dev_info(phy->dev, "phy version is: 0x%x\n", readl(phy->regs));
This should be rather dev_dbg. See coding style.
> +
> + return PTR_ERR_OR_ZERO(phy_provider);
> +}
> +
> +static const struct of_device_id sun55i_usb3_pcie_phy_of_match[] = {
> + { .compatible = "allwinner,sun55i-a523-usb3-pcie-phy" },
Please run scripts/checkpatch.pl on the patches and fix reported
warnings. After that, run also 'scripts/checkpatch.pl --strict' on the
patches and (probably) fix more warnings. Some warnings can be ignored,
especially from --strict run, but the code here looks like it needs a
fix. Feel free to get in touch if the warning is not clear.
> + { },
> +};
> +MODULE_DEVICE_TABLE(of, sun55i_usb3_pcie_phy_of_match);
> +
> +static struct platform_driver sun55i_usb3_pcie_phy_driver = {
> + .probe = sun55i_usb3_pcie_phy_probe,
> + .driver = {
> + .of_match_table = sun55i_usb3_pcie_phy_of_match,
> + .name = "sun55i-usb3-pcie-phy",
> + }
> +};
> +module_platform_driver(sun55i_usb3_pcie_phy_driver);
> +
> +MODULE_DESCRIPTION("Allwinner A523 USB3/PCIe phy driver");
> +MODULE_AUTHOR("Mikhail Kalashnikov <iuncuim@gmail.com>");
> +MODULE_LICENSE("GPL");
Best regards,
Krzysztof
WARNING: multiple messages have this Message-ID (diff)
From: Krzysztof Kozlowski <krzk@kernel.org>
To: iuncuim <iuncuim@gmail.com>, Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>, Chen-Yu Tsai <wens@csie.org>,
Jernej Skrabec <jernej.skrabec@gmail.com>,
Samuel Holland <samuel@sholland.org>,
Andre Przywara <andre.przywara@arm.com>,
Michael Turquette <mturquette@baylibre.com>,
Stephen Boyd <sboyd@kernel.org>, Vinod Koul <vkoul@kernel.org>,
Kishon Vijay Abraham I <kishon@kernel.org>,
Philipp Zabel <p.zabel@pengutronix.de>
Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-phy@lists.infradead.org, linux-clk@vger.kernel.org,
linux-sunxi@lists.linux.dev
Subject: Re: [PATCH 4/7] phy: allwinner: a523: add USB3/PCIe PHY driver
Date: Sat, 16 Aug 2025 11:33:07 +0200 [thread overview]
Message-ID: <484e4ff2-c7b2-4087-8850-5a972e7c82b4@kernel.org> (raw)
In-Reply-To: <20250816084700.569524-5-iuncuim@gmail.com>
On 16/08/2025 10:46, iuncuim wrote:
> +
> + phy->reset = devm_reset_control_get(dev, NULL);
> + if (IS_ERR(phy->reset)) {
> + dev_err(dev, "failed to get reset control\n");
> + return PTR_ERR(phy->reset);
Syntax is return dev_err_probe.
> + }
> +
> + phy->regs = devm_platform_ioremap_resource(pdev, 0);
> + if (IS_ERR(phy->regs))
> + return PTR_ERR(phy->regs);
> +
> + phy->regs_clk = phy->regs + PHY_CLK_OFFSET;
> + if (IS_ERR(phy->regs_clk))
> + return PTR_ERR(phy->regs_clk);
> +
> + phy->phy = devm_phy_create(dev, NULL, &sun55i_usb3_pcie_phy_ops);
> + if (IS_ERR(phy->phy)) {
> + dev_err(dev, "failed to create PHY\n");
> + return PTR_ERR(phy->phy);
> + }
> +
> + phy_set_drvdata(phy->phy, phy);
> + phy_provider = devm_of_phy_provider_register(dev, of_phy_simple_xlate);
> +
> + ret = sun55i_usb3_pcie_clk_init(phy);
> + if (ret)
> + return ret;
> + dev_info(phy->dev, "phy version is: 0x%x\n", readl(phy->regs));
This should be rather dev_dbg. See coding style.
> +
> + return PTR_ERR_OR_ZERO(phy_provider);
> +}
> +
> +static const struct of_device_id sun55i_usb3_pcie_phy_of_match[] = {
> + { .compatible = "allwinner,sun55i-a523-usb3-pcie-phy" },
Please run scripts/checkpatch.pl on the patches and fix reported
warnings. After that, run also 'scripts/checkpatch.pl --strict' on the
patches and (probably) fix more warnings. Some warnings can be ignored,
especially from --strict run, but the code here looks like it needs a
fix. Feel free to get in touch if the warning is not clear.
> + { },
> +};
> +MODULE_DEVICE_TABLE(of, sun55i_usb3_pcie_phy_of_match);
> +
> +static struct platform_driver sun55i_usb3_pcie_phy_driver = {
> + .probe = sun55i_usb3_pcie_phy_probe,
> + .driver = {
> + .of_match_table = sun55i_usb3_pcie_phy_of_match,
> + .name = "sun55i-usb3-pcie-phy",
> + }
> +};
> +module_platform_driver(sun55i_usb3_pcie_phy_driver);
> +
> +MODULE_DESCRIPTION("Allwinner A523 USB3/PCIe phy driver");
> +MODULE_AUTHOR("Mikhail Kalashnikov <iuncuim@gmail.com>");
> +MODULE_LICENSE("GPL");
Best regards,
Krzysztof
--
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy
next prev parent reply other threads:[~2025-08-16 9:43 UTC|newest]
Thread overview: 40+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-16 8:46 [PATCH 0/7] arm64: allwinner: a523: add USB3.0 support iuncuim
2025-08-16 8:46 ` iuncuim
2025-08-16 8:46 ` [PATCH 1/7] clk: sunxi-ng: a523: add missing usb related clocks iuncuim
2025-08-16 8:46 ` iuncuim
2025-08-16 9:30 ` Krzysztof Kozlowski
2025-08-16 9:30 ` Krzysztof Kozlowski
2025-08-16 8:46 ` [PATCH 2/7] arm64: dts: allwinner: a523: add third usb2 phy iuncuim
2025-08-16 8:46 ` iuncuim
2025-08-16 9:31 ` Krzysztof Kozlowski
2025-08-16 9:31 ` Krzysztof Kozlowski
2025-08-16 13:38 ` Andre Przywara
2025-08-16 13:38 ` Andre Przywara
2025-08-16 8:46 ` [PATCH 3/7] phy: sun4i-usb: a523: add support for the USB2 PHY iuncuim
2025-08-16 8:46 ` iuncuim
2025-08-16 13:31 ` Andre Przywara
2025-08-16 13:31 ` Andre Przywara
2025-08-16 8:46 ` [PATCH 4/7] phy: allwinner: a523: add USB3/PCIe PHY driver iuncuim
2025-08-16 8:46 ` iuncuim
2025-08-16 9:33 ` Krzysztof Kozlowski [this message]
2025-08-16 9:33 ` Krzysztof Kozlowski
2025-08-25 9:42 ` Philipp Zabel
2025-08-25 9:42 ` Philipp Zabel
2025-08-27 6:40 ` Chukun Pan
2025-08-27 6:40 ` Chukun Pan
2025-08-16 8:46 ` [PATCH 5/7] arm64: dts: allwinner: a523: add USB3.0 phy node iuncuim
2025-08-16 8:46 ` iuncuim
2025-08-16 9:32 ` Krzysztof Kozlowski
2025-08-16 9:32 ` Krzysztof Kozlowski
2025-08-16 13:49 ` Andre Przywara
2025-08-16 13:49 ` Andre Przywara
2025-08-25 15:41 ` Chen-Yu Tsai
2025-08-25 15:41 ` Chen-Yu Tsai
2025-08-16 8:46 ` [PATCH 6/7] arm64: dts: allwinner: a523: add DWC3 USB3.0 node iuncuim
2025-08-16 8:46 ` iuncuim
2025-08-16 14:10 ` Andre Przywara
2025-08-16 14:10 ` Andre Przywara
2025-08-16 8:47 ` [PATCH 7/7] arm64: dts: allwinner: a523: activate USB3 for all boards iuncuim
2025-08-16 8:47 ` iuncuim
2025-08-18 18:24 ` [PATCH 0/7] arm64: allwinner: a523: add USB3.0 support Rob Herring (Arm)
2025-08-18 18:24 ` Rob Herring (Arm)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=484e4ff2-c7b2-4087-8850-5a972e7c82b4@kernel.org \
--to=krzk@kernel.org \
--cc=andre.przywara@arm.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=iuncuim@gmail.com \
--cc=jernej.skrabec@gmail.com \
--cc=kishon@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-clk@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-phy@lists.infradead.org \
--cc=linux-sunxi@lists.linux.dev \
--cc=mturquette@baylibre.com \
--cc=p.zabel@pengutronix.de \
--cc=robh@kernel.org \
--cc=samuel@sholland.org \
--cc=sboyd@kernel.org \
--cc=vkoul@kernel.org \
--cc=wens@csie.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.