Article View: linux.kernel.netdev
Article #20516Re: [PATCH net 4/4] ptp: ocp: correct the DCF output frequency
From: netdev-bot+sashiko
Date: Sun, 22 Nov 2026 20:41
Date: Sun, 22 Nov 2026 20:41
85 lines
11049 bytes
11049 bytes
Thank you for your contribution! Sashiko AI review found 1 potential
issue(s) to consider.
Critical: 0 ยท High: 0 ยท Medium: 1 ยท Low: 0
If you believe none of the issues are legitimate, please reply to each
issue of Medium severity or higher and explain why the AI is wrong.
If any of them are legitimate and you plan to respin, please let patchwork
know by including "pw-bot: cr" as a separate line at the end of your reply
(one such reply per series is enough).
- [Medium] The patch fixes one bad entry in a selector table from commit
09eeb3aecc6c, the one named in its Fixes: tag.
--
ptp: ocp: correct the DCF output frequency
The patch changes the DCF entry in the ptp_ocp_sma_out[] selector table
from 77000 Hz to 77500 Hz. That brings it in line with the input table
and the DPLL supported frequency list, so the advertised DCF77 frequency
can be set and read back on an output pin.
Link: https://lore.kernel.org/r/179502617840.3136.12704245716223038161@kernel.org
> diff --git a/drivers/ptp/ptp_ocp.c b/drivers/ptp/ptp_ocp.c
> index 650047581fd41..aa950cae68f46 100644
> --- a/drivers/ptp/ptp_ocp.c
> +++ b/drivers/ptp/ptp_ocp.c
> @@ -1376,7 +1376,7 @@ static const struct ocp_selector ptp_ocp_sma_out[] = {
> { .name = "GNSS1", .value = 0x0004, .frequency = 1 },
> { .name = "GNSS2", .value = 0x0008, .frequency = 1 },
> { .name = "IRIG", .value = 0x0010, .frequency = 10000 },
> - { .name = "DCF", .value = 0x0020, .frequency = 77000 },
> + { .name = "DCF", .value = 0x0020, .frequency = 77500 },
[Severity: Medium]
Should the ART input table get the same kind of fix? Commit 09eeb3aecc6c,
the one in the Fixes: tag, also added this entry to ptp_ocp_art_sma_in[]:
drivers/ptp/ptp_ocp.c:
static const struct ocp_selector ptp_ocp_art_sma_in[] = {
{ .name = "PPS1", .value = 0x0001, .frequency = 1 },
{ .name = "10Mhz", .value = 0x0008, .frequency = 1000000 },
{ }
};
The entry is named "10Mhz" but has a frequency of 1 MHz. The "10Mhz"
entry in ptp_ocp_art_sma_out[] uses 10000000.
ptp_ocp_art_sma_init() registers the ART pins with ptp_ocp_sma_freq
as their supported list:
.freq_supported_num = ARRAY_SIZE(ptp_ocp_sma_freq),
.freq_supported = ptp_ocp_sma_freq,
That list contains DPLL_PIN_FREQUENCY_10MHZ but not 1 MHz.
This seems to give the same two symptoms the commit message describes
for DCF, but on ART input pins.
On set, a DPLL netlink request for 10000000 passes
dpll_pin_is_freq_supported() in the core. It then reaches the
exact-match loop in ptp_ocp_dpll_frequency_set():
for (i = 0; tbl[i].name; i++)
if (tbl[i].frequency == frequency)
return ptp_ocp_sma_store_val(bp, tbl[i].value,
sma->mode, sma_nr + 1);
return -EINVAL;
Nothing in the table matches, so the call returns -EINVAL.
On get, ptp_ocp_dpll_frequency_get() reports 1000000 for an ART input
that selects 0x08. That value is not in the pin's advertised set. Fixed
pins hit this too, because sma[0].default_fcn is 0x08 ("IN: 10Mhz").
Would it make sense to change that entry to 10000000 in this patch, or
in a follow-up?
[ ... ]
--
Sashiko AI review ยท https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261118-timecard-common-301f823ddd-0-ahmadexp%40gmail.com
Technical Details
Message-ID:
<179538007070.3135.8275620503580456948@kernel.org>Path:
mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-368816-linux-kernel-netdev=dewy.ruReferences:
<20261118-timecard-common-301f823ddd-4-ahmadexp@gmail.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-368816-linux-kernel-netdev=dewy.ru From: netdev-bot+sashiko@kernel.org Newsgroups: linux.kernel.netdev Subject: Re: [PATCH net 4/4] ptp: ocp: correct the DCF output frequency Date: Sun, 22 Nov 2026 20:41:10 +0000 Organization: Usenet Network Message-ID: <179538007070.3135.8275620503580456948@kernel.org> References: <20261118-timecard-common-301f823ddd-4-ahmadexp@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Injection-Info: usenet.network; logging-data="3719776"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:j7d8t5gkYdIOn8qhBEM5r5JXj60= sha256:O1hNr1V3XxVZA8gwKp4S8YTYrr9ddRD8InM2X5go3nU= sha1:R3fygvmwj7BbXSHa9hsx59hhKCQ= sha256:AHevbTmdYQrrwHVvLrrzwwsnYi8Ie+ydp8/LjrojKio= List-ID: <netdev.vger.kernel.org> X-Mailpost-Empty-Hdrs: X-Spam-Level X-Received: from localhost (localhost [127.0.0.1]) by mail.dewy.ru (Postfix) with ESMTP id E2D1A125D84; Sun, 22 Nov 2026 23:41:33 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.4 X-Spam-Status: No, score=-3.4 tagged_above=-9999 required=6.31 tests=[DCC_REPUT_70_89=0.1, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key) header.d=kernel.org X-Received: from mail.dewy.ru ([127.0.0.1]) by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Ce7lVvsvLAkW; Sun, 22 Nov 2026 23:41:30 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-368816-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=pass (p=quarantine dis=none) header.from=kernel.org X-Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10]) by mail.dewy.ru (Postfix) with ESMTPS id 9B22D125D86; Sun, 22 Nov 2026 23:41:21 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by sea.lore.kernel.org (Postfix) with ESMTP id 14FC92CB28; Sun, 22 Nov 2026 20:41:14 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1795380073; b=ZL/K1iefRMc8ENPKNFfgguPsOHkzqHlf4H8tHDetC1tzmr6aZY287uyF9j9fe/7ofvl2 M4f49ZOLkQGURieZvY62+ELDurIaWpU22Yf+XSPmKWh3bEUaU9lFU2Jo65/lT0e541kfG M69Q4DIa4WwVFX5XaqW7ar8ddhPVmIC2wmXFUiBwiP5/mlANaHaOmkmcFiUd567gyDO3L K1KgUmgH2b0+6u5faTUHkbLyYRZSvQtH6edIEQGyxcjH1tFdI+Ft9cvDIDrLbj0oZh0BB sueRMr8OOgAQesrknQ5+BWWcUclv9R+7tOUR8vzHlE57BkAEqBGeWHgqdnle3JnSPBQ== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795380073; h=X-Original-To:Received:Received:DKIM-Signature:Subject:From:To:Cc: Date:Message-ID:In-Reply-To:References:X-sashiko-severity: Content-Type:Content-Transfer-Encoding:X-Mailing-List:List-Id: List-Post:List-Help:List-Subscribe:List-Unsubscribe:List-Owner: Precedence:MIME-Version; bh=636q6jaM7rA0Po/eBymCLEAcqrcFwRC63tZr1LwICak=; b=wZgFzEvB44WmYb/aYYpBZL2b7cMjZaiBsvW/vFC0CMzn52LjqpK6VtnueoZvkN0LkUQC Agx0XsSUhVpaYfsnpDd1aD/FNIRTXyTx0FiY+i5vp5vJ2/kVS0UEDMzV7TcWVqijGTvXh l8D5wy40TuozBQNl+R9Z4jRvhBGhOI1R1GylQsi2lsjgEwYCTC6j/BbPpYvq9Vg0VV/ws oDCQO21XtbVK/YHdL9h8cEBphufgC9sFPvYKltuo+oEVKcZAy6iEUm/oO4INjWlqYoUzD jCxoFXy7lEdLjBbW65E/BeBHkbgnWnu/Ut2S9AjocOLOkwP+XgSxDi5zrX/2OUaQj2A== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=OYHMYAq1; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-Received: from localhost.localdomain (localhost [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id EDBF9606A688; Sun, 22 Nov 2026 20:41:12 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=OYHMYAq1 X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1795380072; b=JbGa1hPVNdAoW4I2i/oBhVW3V77ck7RGEeoDkQTipDqDmMT8TXE3N1jE+beQS6jezPyY PdYxbSmI5HwAEx3H3YZYl5iSGHx2MUGtryAEhXRcY8QLyPhRfvc9Vl5B1JXFx7lP1jKOL jONUvMEaAdlUYrefjQrIX/kDH88/c1Z1BCiFlLQOokPkvacFJsVKATzUo1tzScTlTjvfD Q1mJcksm0f27wHxxuGjkqODS/iSoisfOV/EoJnck01icxxrZ5D2zFuTbamYya0Gkhh/LA Qw3Z+93YQC3gqpdTn/TkEmeL4Xcgr0GYS+AJyjfnpPLuq395SKAzVol9pWZeHn7iMcQ== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795380072; h=Received:DKIM-Signature:Subject:From:To:Cc:Date:Message-ID: In-Reply-To:References:X-sashiko-severity:Content-Type: Content-Transfer-Encoding:MIME-Version; bh=636q6jaM7rA0Po/eBymCLEAcqrcFwRC63tZr1LwICak=; b=fDqEr1Tk/UGzqWqg+RfHOHsj+9uD+wjVJbCqJse2dV2zl/ZcNQHKIJa7xguQcjEZT2ng hy+ocbFm3fJrGFsU4w3zed0Shl55hE1Zfr96QQpn43udQlnlM/X9GJUEnbrRoGXzhZMO1 9f4qZkNNKueZhzbVuQEJb+pJBsvA175nKPwsyXHh0H6ZOZ/G6lOZ23W6jsk0TdQhHaZZP Oax0Q4EqHyjlT6TGcp2MbcrOBxE4itDT/MBF7abJ7LEpO1C1lhWPAeJM/6V9EXmZvdULk UEF56BiSn4lC9VUJo9tt3h+tuXCKysYi6S1e+5qiblnfpdkub2R33XRjS8UC1awSvwA== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=OYHMYAq1; arc=none smtp.remote-ip=100.103.45.18 X-Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1D1B0606A683; Sun, 22 Nov 2026 20:41:11 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2081B1F000D1; Sun, 22 Nov 2026 20:41:11 +0000 (UTC) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1795380071; bh=636q6jaM7rA0Po/eBymCLEAcqrcFwRC63tZr1LwICak=; h=Subject:From:To:Cc:Date:In-Reply-To:References; b=OYHMYAq1FzhUzEKyGNNA0mjs+OH548HJdp8oOXqfDG6VNXjo0s/GhLuMt6XMBstYU ePoL6/SJdW+bsbjRbSIPN4ugeK8kYJoPKdeISQLM2w3r4LMK6rRywsrqs74D0dbszx cNEQR/GwZdOfg7jSBKmTKbRyWULweLgA+4isqCgTxPgjuovqmn45KnItLe4e9BiSk2 RuEATIezj3rDGHttqE+xxLK3dX5FBvgVKlLPecPSBZoIqj8ErQs78fIBBpmmmfCXF7 i8NsTRriRx8u0ZPfMtK//E+ddBvbqJpzZWeUXbrKCr/UCrJ3CNIjqyElnRJYfxuqeE Idfsx9M4/RBLA== X-Cc: netdev@vger.kernel.org, vadim.fedorenko@linux.dev, richardcochran@gmail.com, andrew+netdev@lunn.ch, arkadiusz.kubalewski@intel.com, davem@davemloft.net, edumazet@kernel.org, jiri@resnulli.us, kuba@kernel.org, linux-kernel@vger.kernel.org, pabeni@redhat.com X-In-Reply-To: <20261118-timecard-common-301f823ddd-4-ahmadexp@gmail.com> X-sashiko-severity: Medium X-Mailing-List: netdev@vger.kernel.org X-List-Post: <mailto:netdev@vger.kernel.org> X-List-Help: <mailto:netdev+help@vger.kernel.org> X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org> X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org> X-List-Owner: <mailto:netdev+owner@vger.kernel.org> X-Precedence: list