From nobody Mon Feb 9 12:26:02 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 040F930FC37; Fri, 23 Jan 2026 15:53:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769183639; cv=none; b=Nbn17z1Ggud3OwC64wa9IZsXEKN9L5UI2xdIv8rmWCor0rOVIKy0RC6Ibo8bugKoi0yEQxhd7idC/Ukfc8mlpaaWYDfAEtynKzbNPhRgNqgHRTDOpDvWVkUXaHkVO8U7BqoHgwhpWe8aj09GZG+hVtvOF5tOiNCzgyJB+9Vf8yI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769183639; c=relaxed/simple; bh=OD/SBHOngggc6K9v2EoE30z4UwEXpKaZxfIERT1it2U=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=V5kMPPgSuCP0dLjBul4C6572xAspnlNDuzkJZQLbYXbTpQf070ZeIUIr9OsBqLMrDUJWVwtkvFDW+mG4BGEa7n30RHPWpwm/j4PB3dA2mA9viSCBjLdK7uswlYBy4f02Jr4X5ihx6kx/TDXxhe7RhgQHoSOHpIjCgcSRoSDKLJ4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=R//zzBZA; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="R//zzBZA" Received: by smtp.kernel.org (Postfix) with ESMTPS id C0709C4CEF1; Fri, 23 Jan 2026 15:53:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1769183638; bh=OD/SBHOngggc6K9v2EoE30z4UwEXpKaZxfIERT1it2U=; h=From:Date:Subject:References:In-Reply-To:To:Cc:Reply-To:From; b=R//zzBZAF3y0GkAgzzdHWAI65HNGuqnz2Nvg4tdVeOogY9Hb12Kk7iLv8ju3WfPPs 0N0NOiYB+pOUww4s6bZsSbBBF7QksMTGwFJGHZN4LBgOFSrvGnmfA1qOgxBCdhFyGg uXenIhp2F2aZ9VLwq4rUnXoxx6nti9950pTx5qqlbq0Qh7KrbpMzZOc0ZF5Uo4aBCp n5sw3JcYJ06ORFrJHuENBldBSj+wjVNnCibVhqt+6nuL8GRiBA6Sa99j2cotfxCLY5 C++eZFuJVbLkVp/25/c12X0Od0lfvRYDUY9LEk3xTTuyTYz/urBjJGCHoM00fbQ2iR xiK3867Vaxo7w== Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id B8AFFD74EF6; Fri, 23 Jan 2026 15:53:58 +0000 (UTC) From: Rodrigo Alencar via B4 Relay Date: Fri, 23 Jan 2026 15:53:12 +0000 Subject: [PATCH v5 7/8] docs: iio: add documentation for adf41513 driver Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260123-adf41513-iio-driver-v5-7-2dce812a2dda@analog.com> References: <20260123-adf41513-iio-driver-v5-0-2dce812a2dda@analog.com> In-Reply-To: <20260123-adf41513-iio-driver-v5-0-2dce812a2dda@analog.com> To: linux-kernel@vger.kernel.org, linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-doc@vger.kernel.org Cc: Jonathan Cameron , David Lechner , Andy Shevchenko , Lars-Peter Clausen , Michael Hennerich , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Jonathan Corbet , Rodrigo Alencar X-Mailer: b4 0.14.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1769183636; l=9013; i=rodrigo.alencar@analog.com; s=default; h=from:subject:message-id; bh=S42BxNj0eA5QUVMELxyYhMLf88oiZrzxZfcZDBL3qXs=; b=aMxk3YGxT09WtV22CH9zOrm052tapUAdmf/QBMK2bgZZYIRZTPH1hhfWHBXtWjUw/suBkxyOi yOxRwXZ/qNuDv9wTAHVzeqAa/ld8FFAYgmgUSfBHyTMCJvj7SWu0D++ X-Developer-Key: i=rodrigo.alencar@analog.com; a=ed25519; pk=ULeHbgU/OYh/PG/4anHDfLgldFItQHAhOktYRVLMFRo= X-Endpoint-Received: by B4 Relay for rodrigo.alencar@analog.com/default with auth_id=561 X-Original-From: Rodrigo Alencar Reply-To: rodrigo.alencar@analog.com From: Rodrigo Alencar Add documentation for ADF41513 driver, which describes the device driver files and shows how userspace may consume the ABI for various tasks. Signed-off-by: Rodrigo Alencar --- Documentation/iio/adf41513.rst | 199 +++++++++++++++++++++++++++++++++++++= ++++ Documentation/iio/index.rst | 1 + MAINTAINERS | 1 + 3 files changed, 201 insertions(+) diff --git a/Documentation/iio/adf41513.rst b/Documentation/iio/adf41513.rst new file mode 100644 index 000000000000..4193c825b532 --- /dev/null +++ b/Documentation/iio/adf41513.rst @@ -0,0 +1,199 @@ +.. SPDX-License-Identifier: GPL-2.0 + +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D +ADF41513 driver +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D + +This driver supports Analog Devices' ADF41513 and similar SPI PLL frequency +synthesizers. + +1. Supported devices +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D + +* `ADF41510 `_ +* `ADF41513 `_ + +The ADF41513 is an ultralow noise frequency synthesizer that can be used to +implement local oscillators (LOs) as high as 26.5 GHz in the upconversion = and +downconversion sections of wireless receivers and transmitters. The ADF415= 10 +is a similar device that supports frequencies up to 10 GHz. + +Both devices support integer-N and fractional-N operation modes, providing +excellent phase noise performance and flexible frequency generation +capabilities. + +Key Features: + +- **ADF41510**: 1 GHz to 10 GHz frequency range +- **ADF41513**: 1 GHz to 26.5 GHz frequency range +- Integer-N and fractional-N operation modes +- Ultra-low phase noise (-235 dBc/Hz integer-N, -231 dBc/Hz fractional-N) +- High maximum PFD frequency (250 MHz integer-N, 125 MHz fractional-N) +- 25-bit fixed modulus or 49-bit variable modulus fractional modes +- Programmable charge pump currents with 16x range +- Digital lock detect functionality +- Phase resync capability for consistent output phase + +2. Device attributes +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D + +The ADF41513 driver provides the following IIO extended attributes for +frequency control and monitoring: + +Each IIO device has a device folder under ``/sys/bus/iio/devices/iio:devic= eX``, +where X is the IIO index of the device. Under these folders reside a set of +device files that provide access to the synthesizer's functionality. + +The following table shows the ADF41513 related device files: + ++----------------------+--------------------------------------------------= -----+ +| Device file | Description = | ++=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D+=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D+ +| frequency | RF output frequency control and readback (Hz) = | ++----------------------+--------------------------------------------------= -----+ +| frequency_resolution | Target frequency resolution control (Hz) = | ++----------------------+--------------------------------------------------= -----+ +| powerdown | Power management control (0=3Dactive, 1=3Dpower d= own) | ++----------------------+--------------------------------------------------= -----+ +| phase | RF output phase adjustment and readback (radians)= | ++----------------------+--------------------------------------------------= -----+ + +2.1 Frequency Control +---------------------- + +The ``frequency`` attribute controls the RF output frequency with sub-Hz +precision. The driver automatically selects between integer-N and fraction= al-N +modes to achieve the requested frequency with the best possible phase noise +performance. + +**Supported ranges:** + +- **ADF41510**: 1,000,000,000 Hz to 10,000,000,000 Hz (1 GHz to 10 GHz) +- **ADF41513**: 1,000,000,000 Hz to 26,500,000,000 Hz (1 GHz to 26.5 GHz) + +The frequency is specified in Hz, for sub-Hz precision use decimal notatio= n. +For example, 12.102 GHz would be written as "12102000000.000000". + +2.2 Frequency Resolution Control +-------------------------------- + +The ``frequency_resolution`` attribute controls the target frequency resol= ution +that the driver attempts to achieve. This affects the choice between integ= er-N +and fractional-N modes, including fixed modulus (25-bit) and variable modu= lus +(49-bit) fractional-N modes: + +- **Integer-N**: Resolution =3D f_PFD +- **Fixed modulus**: Resolution =3D f_PFD / 2^25 (~3 Hz with 100 MHz PFD) +- **Variable modulus**: Resolution =3D f_PFD / 2^49 (=C2=B5Hz resolution p= ossible) + +Default resolution is 1 Hz (1,000,000 =C2=B5Hz). + +2.3 Phase adjustment +-------------------- + +The ``phase`` attribute allows adjustment of the output phase in radians. +Setting this attribute enables phase adjustment. It can be set from 0 to 2= *pi +radians. Reading this attribute returns the current phase offset of the ou= tput +signal. To create a consistent phase relationship with the reference signa= l, +the phase resync feature needs to be enabled by setting a non-zero value t= o the +``adi,phase-resync-period-ns`` device property, which triggers a phase +resynchronization after locking is achieved. + +3. Operating modes +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D + +3.1 Integer-N Mode +------------------ + +When the requested frequency can be achieved as an integer multiple of the= PFD +frequency (within the specified resolution tolerance), the driver automati= cally +selects integer-N mode for optimal phase noise performance. + +In integer-N mode: + +- Phase noise: -235 dBc/Hz normalized floor +- Frequency resolution: f_PFD (same as PFD frequency) +- Maximum PFD frequency: 250 MHz +- Bleed current: Disabled + +3.2 Fractional-N Mode +--------------------- + +When sub-integer frequency steps are required, the driver automatically se= lects +fractional-N mode using either fixed or variable modulus. + +**Fixed Modulus (25-bit)**: + +- Used when variable modulus is not required +- Resolution: f_PFD / 2^25 +- Simpler implementation, faster settling + +**Variable Modulus (49-bit)**: + +- Used for maximum resolution requirements +- Resolution: f_PFD / 2^49 (theoretical) +- Exact frequency synthesis capability + +In fractional-N mode: + +- Phase noise: -231 dBc/Hz normalized floor +- Maximum PFD frequency: 125 MHz +- Bleed current: Automatically enabled and optimized +- Dithering: Enabled to reduce fractional spurs + +3.3 Automatic Mode Selection +---------------------------- + +The driver automatically selects the optimal operating mode based on: + +1. **Frequency accuracy requirements**: Determined by frequency_resolution= setting +2. **Phase noise optimization**: Integer-N preferred when possible +3. **PFD frequency constraints**: Different limits for integer vs fraction= al modes +4. **Prescaler selection**: Automatic 4/5 vs 8/9 prescaler selection based= on frequency + +4. Usage examples +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D + +4.1 Basic Frequency Setting +---------------------------- + +Set output frequency to 12.102 GHz: + +.. code-block:: bash + + root:/sys/bus/iio/devices/iio:device0> echo 12102000000 > out_altvolta= ge0_frequency + +Read current frequency: + +.. code-block:: bash + + root:/sys/bus/iio/devices/iio:device0> cat out_altvoltage0_frequency + 12101999999.582767 + +4.2 High Resolution Frequency Control +------------------------------------- + +Configure for sub-Hz resolution and set a precise frequency: + +.. code-block:: bash + + # Set resolution to 0.1 Hz (100,000 =C2=B5Hz) + root:/sys/bus/iio/devices/iio:device0> echo 0.1 > out_altvoltage0_freq= uency_resolution + + # Set frequency to 12.102 GHz (1 =C2=B5Hz precision) + root:/sys/bus/iio/devices/iio:device0> echo 12102000000 > out_altvolta= ge0_frequency + root:/sys/bus/iio/devices/iio:device0> cat out_altvoltage0_frequency + 12101999999.980131 + +4.3 Monitor Lock Status +----------------------- + +When lock detect GPIO is configured, check if PLL is locked: + +.. code-block:: bash + + # Read frequency - will return error if not locked + root:/sys/bus/iio/devices/iio:device0> cat out_altvoltage0_frequency + +If the PLL is not locked, the frequency read will return ``-EBUSY`` (Devic= e or +resource busy). diff --git a/Documentation/iio/index.rst b/Documentation/iio/index.rst index ba3e609c6a13..605871765c78 100644 --- a/Documentation/iio/index.rst +++ b/Documentation/iio/index.rst @@ -30,6 +30,7 @@ Industrial I/O Kernel Drivers ad7625 ad7944 ade9000 + adf41513 adis16475 adis16480 adis16550 diff --git a/MAINTAINERS b/MAINTAINERS index 88308fc780b3..b9cc8ddcd624 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -1624,6 +1624,7 @@ L: linux-iio@vger.kernel.org S: Supported W: https://ez.analog.com/linux-software-drivers F: Documentation/devicetree/bindings/iio/frequency/adi,adf41513.yaml +F: Documentation/iio/adf41513.rst F: drivers/iio/frequency/adf41513.c F: drivers/iio/test/iio-test-fixpoint-parse.c =20 --=20 2.43.0