Netdev List
 help / color / mirror / Atom feed
From: Ali Rouhi <arouhi@sitime.com>
To: "jiri@resnulli.us" <jiri@resnulli.us>
Cc: "vadim.fedorenko@linux.dev" <vadim.fedorenko@linux.dev>,
	"arkadiusz.kubalewski@intel.com" <arkadiusz.kubalewski@intel.com>,
	"robh@kernel.org" <robh@kernel.org>,
	"krzk+dt@kernel.org" <krzk+dt@kernel.org>,
	"conor+dt@kernel.org" <conor+dt@kernel.org>,
	"cjubran@nvidia.com" <cjubran@nvidia.com>,
	"Oleg.Zadorozhnyi@devoxsoftware.com"
	<Oleg.Zadorozhnyi@devoxsoftware.com>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Ali Rouhi <arouhi@sitime.com>
Subject: [PATCH net-next v7 0/3] dpll: add SiTime SiT9531x DPLL clock driver
Date: Sat, 15 Aug 2026 22:19:20 +0000	[thread overview]
Message-ID: <20260815221919.64226-1-arouhi@sitime.com> (raw)

This series adds a DPLL subsystem driver for the SiTime SiT95316 and
SiT95317 I2C clock generators. Each device integrates four PLLs with
automatic/manual reference selection and on-chip TDC phase-offset
measurement, and is used for synchronization in telecom, networking,
and data-center timing.

The series contains the device-tree binding, the driver under
drivers/dpll/sit9531x/, and the MAINTAINERS entry.

v1: https://lore.kernel.org/netdev/20260511211143.19792-1-arouhi@sitime.com/
v2: https://lore.kernel.org/netdev/20260520191943.73938-1-arouhi@sitime.com/
v3: https://lore.kernel.org/netdev/20260731180951.65725-1-arouhi@sitime.com/
v4: https://lore.kernel.org/netdev/20260806232439.27551-1-arouhi@sitime.com/
v5: https://lore.kernel.org/netdev/20260810230439.22866-1-arouhi@sitime.com/
v6: https://lore.kernel.org/netdev/20260812175337.18155-1-arouhi@sitime.com/

Changes since v6 (driver only; the bindings are unchanged):

  - Remove a conflict marker that slipped into a comment block in
    dpll.c. It sat inside /* */, so it built and checkpatch, which has
    no check for markers, did not report it.
  - Unwind DPLL registration when it fails partway. dev_start() returned
    on the first failure without unregistering the DPLLs already done,
    and the caller then freed them, leaving the subsystem with pointers
    into freed memory.
  - Report an input as selectable only for the DPLL that can select it.
    The test used the physical receiver state, which every DPLL fed from
    that lane shares. A lane in LOS no longer drops to disconnected
    either: signal quality belongs in the pin's own attributes.
  - Refuse DPLL_PIN_STATE_CONNECTED on an input instead of treating it
    as selectable. The device selects by priority and has no mode that
    pins one reference, so the request cannot be honoured.
  - Keep the rest of the priority table when one input moves. prio_set
    used to fill every lower-priority slot with the same source, which
    discarded the fallbacks the caller had not asked about.
  - Refuse to drive INTSYNC from a PLL that already selects it.
  - Drop the SYSREF/SYNCB/pulser claim from the commit message: only the
    esync default is reachable, the other modes are not exposed.

The AI review also reported a use-after-free of the pin properties. It
is a false positive: dpll_pin_alloc() calls dpll_pin_prop_dup(), which
copies freq_supported with kmemdup() and the labels with kstrdup(), so
the core owns its copies and the driver has to free its own.


Ali Rouhi (3):
  dt-bindings: vendor-prefixes: add SiTime Corporation
  dt-bindings: dpll: add SiTime SiT95316 clock generator
  dpll: add SiTime SiT9531x DPLL clock driver

 .../bindings/dpll/sitime,sit95316.yaml        |  171 +
 .../devicetree/bindings/vendor-prefixes.yaml  |    2 +
 MAINTAINERS                                   |    7 +
 drivers/dpll/Kconfig                          |    1 +
 drivers/dpll/Makefile                         |    1 +
 drivers/dpll/sit9531x/Kconfig                 |   17 +
 drivers/dpll/sit9531x/Makefile                |    4 +
 drivers/dpll/sit9531x/core.c                  | 3111 +++++++++++++++++
 drivers/dpll/sit9531x/core.h                  |  372 ++
 drivers/dpll/sit9531x/dpll.c                  | 1232 +++++++
 drivers/dpll/sit9531x/dpll.h                  |   69 +
 drivers/dpll/sit9531x/prop.c                  |  397 +++
 drivers/dpll/sit9531x/prop.h                  |   39 +
 drivers/dpll/sit9531x/regs.h                  |  371 ++
 14 files changed, 5794 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/dpll/sitime,sit95316.yaml
 create mode 100644 drivers/dpll/sit9531x/Kconfig
 create mode 100644 drivers/dpll/sit9531x/Makefile
 create mode 100644 drivers/dpll/sit9531x/core.c
 create mode 100644 drivers/dpll/sit9531x/core.h
 create mode 100644 drivers/dpll/sit9531x/dpll.c
 create mode 100644 drivers/dpll/sit9531x/dpll.h
 create mode 100644 drivers/dpll/sit9531x/prop.c
 create mode 100644 drivers/dpll/sit9531x/prop.h
 create mode 100644 drivers/dpll/sit9531x/regs.h


base-commit: 001b5d347d8ba39b2dccaefcc57967b18caec8fe
-- 
2.34.1


             reply	other threads:[~2026-08-15 22:19 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-15 22:19 Ali Rouhi [this message]
2026-08-15 22:19 ` [PATCH net-next v7 1/3] dt-bindings: vendor-prefixes: add SiTime Corporation Ali Rouhi
2026-08-15 22:19 ` [PATCH net-next v7 2/3] dt-bindings: dpll: add SiTime SiT95316 clock generator Ali Rouhi
2026-08-15 22:19 ` [PATCH net-next v7 3/3] dpll: add SiTime SiT9531x DPLL clock driver Ali Rouhi

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=20260815221919.64226-1-arouhi@sitime.com \
    --to=arouhi@sitime.com \
    --cc=Oleg.Zadorozhnyi@devoxsoftware.com \
    --cc=arkadiusz.kubalewski@intel.com \
    --cc=cjubran@nvidia.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=jiri@resnulli.us \
    --cc=krzk+dt@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --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