From: Krzysztof Kozlowski <krzk@kernel.org>
To: Hui-Ping Chen <hpchen0nvt@gmail.com>,
vkoul@kernel.org, kishon@kernel.org, robh@kernel.org,
krzk+dt@kernel.org, conor+dt@kernel.org
Cc: linux-arm-kernel@lists.infradead.org,
linux-phy@lists.infradead.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 2/2] phy: nuvoton: add new driver for the Nuvoton MA35 SoC USB 2.0 PHY
Date: Thu, 1 Aug 2024 16:43:56 +0200 [thread overview]
Message-ID: <85bd5da2-312e-4d25-a4e9-afae4fedbd50@kernel.org> (raw)
In-Reply-To: <20240801053744.807884-3-hpchen0nvt@gmail.com>
On 01/08/2024 07:37, Hui-Ping Chen wrote:
> + struct regmap *sysreg;
Look here - iomem? No.
> +};
> +
> +static int ma35_usb_phy_power_on(struct phy *phy)
> +{
> + struct ma35_usb_phy *p_phy = phy_get_drvdata(phy);
> + unsigned int val;
> + int ret;
> +
> + ret = clk_prepare_enable(p_phy->clk);
> + if (ret < 0) {
> + dev_err(p_phy->dev, "Failed to enable PHY clock: %d\n", ret);
> + return ret;
> + }
> +
> + regmap_read(p_phy->sysreg, MA35_SYS_REG_USBPMISCR, &val);
> + if (val & PHY0SUSPEND) {
> + /*
> + * USB PHY0 is in operation mode already
> + * make sure USB PHY 60 MHz UTMI Interface Clock ready
> + */
> + ret = readl_poll_timeout((void __iomem *)p_phy->sysreg + MA35_SYS_REG_USBPMISCR,
Eh, I responded to v2, not here, so repeating:
sysreg is a regmap, not io address. How could it possibly work and be
tested?!? This cannot work. Test your code *before* sending it.
Best regards,
Krzysztof
next prev parent reply other threads:[~2024-08-01 14:44 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-01 5:37 [PATCH v3 0/2] Add support for nuvoton ma35 usb2 phy Hui-Ping Chen
2024-08-01 5:37 ` [PATCH v3 1/2] dt-bindings: phy: nuvoton,ma35-usb2-phy: add new bindings Hui-Ping Chen
2024-08-01 14:40 ` Krzysztof Kozlowski
2024-08-01 5:37 ` [PATCH v3 2/2] phy: nuvoton: add new driver for the Nuvoton MA35 SoC USB 2.0 PHY Hui-Ping Chen
2024-08-01 9:50 ` Markus Elfring
2024-08-02 4:57 ` Hui-Ping Chen
2024-08-01 14:43 ` Krzysztof Kozlowski [this message]
2024-08-02 5:01 ` Hui-Ping Chen
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=85bd5da2-312e-4d25-a4e9-afae4fedbd50@kernel.org \
--to=krzk@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=hpchen0nvt@gmail.com \
--cc=kishon@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-phy@lists.infradead.org \
--cc=robh@kernel.org \
--cc=vkoul@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).