From: Paolo Abeni <pabeni@redhat.com>
To: "Niklas Söderlund" <niklas.soderlund+renesas@ragnatech.se>,
"Rob Herring" <robh@kernel.org>,
"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
"Conor Dooley" <conor+dt@kernel.org>,
"Geert Uytterhoeven" <geert+renesas@glider.be>,
"Magnus Damm" <magnus.damm@gmail.com>,
"Richard Cochran" <richardcochran@gmail.com>,
"Andrew Lunn" <andrew+netdev@lunn.ch>,
"DavidS. Miller" <davem@davemloft.net>,
"Eric Dumazet" <edumazet@google.com>,
"Jakub Kicinski" <kuba@kernel.org>,
"Vadim Fedorenko" <vadim.fedorenko@linux.dev>,
linux-renesas-soc@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org, netdev@vger.kernel.org
Subject: Re: [PATCH net-next v5 2/3] ptp: Add driver for R-Car Gen4
Date: Tue, 28 Jul 2026 13:18:59 +0200 [thread overview]
Message-ID: <1ee51bd7-3667-4184-b018-8a8cf29512c0@redhat.com> (raw)
In-Reply-To: <20260721132936.1331318-3-niklas.soderlund+renesas@ragnatech.se>
On 7/21/26 3:29 PM, Niklas Söderlund wrote:
> +static int ptp_rcar_gen4_probe(struct platform_device *pdev)
> +{
> + struct ptp_rcar_gen4_priv *priv;
> + struct device *dev = &pdev->dev;
> + unsigned long rate;
> +
> + priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL);
> + if (!priv)
> + return -ENOMEM;
> +
> + platform_set_drvdata(pdev, priv);
> +
> + priv->base = devm_platform_ioremap_resource(pdev, 0);
> + if (IS_ERR(priv->base))
> + return PTR_ERR(priv->base);
> +
> + priv->clk = devm_clk_get(dev, NULL);
> + if (IS_ERR(priv->clk))
> + return PTR_ERR(priv->clk);
> +
> + rate = clk_get_rate(priv->clk);
> + if (!rate)
> + return -ENODEV;
> +
> + spin_lock_init(&priv->lock);
> +
> + priv->info = ptp_rcar_gen4_info;
> +
> + /* Default timer increment in ns.
> + * bit[31:27] - integer
> + * bit[26:0] - decimal
> + * increment[ns] = perid[ns] * 2^27 => (1ns * 2^27) / rate[hz]
> + */
> +
> + priv->default_addend = div_s64(1000000000LL << 27, rate);
> +
> + pm_runtime_enable(dev);
> + pm_runtime_get_sync(dev);
Both sashikos agrees pm_runtime_resume_and_get() should be used instead.
This was already raised in v4, with no reply.
/P
next prev parent reply other threads:[~2026-07-28 11:19 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-21 13:29 [PATCH net-next v5 0/3] ptp: Add driver for R-Car Gen4 Niklas Söderlund
2026-07-21 13:29 ` [PATCH net-next v5 1/3] dt-bindings: ptp: renesas,rcar-gen4-gptp: Add " Niklas Söderlund
2026-07-21 13:29 ` [PATCH net-next v5 2/3] ptp: Add driver for " Niklas Söderlund
2026-07-21 14:36 ` Vadim Fedorenko
2026-07-22 13:31 ` sashiko-bot
2026-07-28 11:18 ` Paolo Abeni [this message]
2026-07-28 13:42 ` Niklas Söderlund
2026-07-21 13:29 ` [PATCH net-next v5 3/3] arm64: dts: renesas: r8a779g0: Add gPTP node Niklas Söderlund
2026-07-22 13:31 ` sashiko-bot
2026-07-28 11:12 ` Paolo Abeni
2026-07-28 13:37 ` Niklas Söderlund
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=1ee51bd7-3667-4184-b018-8a8cf29512c0@redhat.com \
--to=pabeni@redhat.com \
--cc=andrew+netdev@lunn.ch \
--cc=conor+dt@kernel.org \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=edumazet@google.com \
--cc=geert+renesas@glider.be \
--cc=krzk+dt@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-renesas-soc@vger.kernel.org \
--cc=magnus.damm@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=niklas.soderlund+renesas@ragnatech.se \
--cc=richardcochran@gmail.com \
--cc=robh@kernel.org \
--cc=vadim.fedorenko@linux.dev \
/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