-
Notifications
You must be signed in to change notification settings - Fork 894
Add support for ADA4355 #2806
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Add support for ADA4355 #2806
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,135 @@ | ||
// SPDX-License-Identifier: GPL-2.0 | ||
/* | ||
* Analog Devices ada4355 | ||
* | ||
* hdl_project: <ada4355_fmc/zed> | ||
* board_revision: <> | ||
* | ||
* Copyright (C) 2025 Analog Devices Inc. | ||
*/ | ||
/dts-v1/; | ||
|
||
#include <dt-bindings/gpio/gpio.h> | ||
|
||
#include "zynq-zed.dtsi" | ||
#include "zynq-zed-adv7511.dtsi" | ||
|
||
&fpga_axi { | ||
|
||
fmc_i2c: i2c@41620000 { | ||
compatible = "xlnx,axi-iic-1.01.b", "xlnx,xps-iic-2.00.a"; | ||
interrupt-parent = <&intc>; | ||
interrupts = <0 55 IRQ_TYPE_LEVEL_HIGH>; | ||
reg = <0x41620000 0x10000>; | ||
|
||
#size-cells = <0>; | ||
#address-cells = <1>; | ||
|
||
ad7291@2f { | ||
compatible = "adi,ad7291"; | ||
reg = <0x2f>; | ||
}; | ||
}; | ||
|
||
rx_dma: rx-dmac@44a30000 { | ||
compatible = "adi,axi-dmac-1.00.a"; | ||
reg = <0x44A30000 0x10000>; | ||
#dma-cells = <1>; | ||
interrupts = <0 57 IRQ_TYPE_LEVEL_HIGH>; | ||
clocks = <&clkc 16>; | ||
|
||
adi,channels { | ||
#size-cells = <0>; | ||
#address-cells = <1>; | ||
|
||
dma-channel@0 { | ||
reg = <0>; | ||
adi,source-bus-width = <32>; | ||
adi,source-bus-type = <2>; | ||
adi,destination-bus-width = <64>; | ||
adi,destination-bus-type = <0>; | ||
}; | ||
}; | ||
}; | ||
|
||
ada4355: ada4355@44a00000 { | ||
compatible = "adi,axi-adc-10.0.a"; | ||
reg = <0x44A00000 0x10000>; | ||
dmas = <&rx_dma 0>; | ||
dma-names = "rx"; | ||
|
||
spibus-connected = <&adc_ada4355>; | ||
}; | ||
}; | ||
|
||
&spi0 { | ||
status = "okay"; | ||
}; | ||
|
||
#define fmc_spi spi0 | ||
|
||
/ { | ||
ada4355_fixed_clock: ada4355_fixed_clock{ | ||
compatible = "fixed-clock"; | ||
#clock-cells = <0>; | ||
clock-frequency = <125000000>; | ||
}; | ||
|
||
gpio-control@0 { | ||
compatible = "adi,one-bit-adc-dac"; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
out-gpios = <&gpio0 86 GPIO_ACTIVE_HIGH>, | ||
<&gpio0 87 GPIO_ACTIVE_HIGH>, | ||
<&gpio0 88 GPIO_ACTIVE_HIGH>, | ||
<&gpio0 90 GPIO_ACTIVE_HIGH>, | ||
<&gpio0 91 GPIO_ACTIVE_HIGH>, | ||
<&gpio0 92 GPIO_ACTIVE_HIGH>, | ||
<&gpio0 93 GPIO_ACTIVE_HIGH>; | ||
|
||
channel@0 { | ||
reg = <0>; | ||
label = "GSEL0"; | ||
}; | ||
channel@1 { | ||
reg = <1>; | ||
label = "GSEL1"; | ||
}; | ||
channel@2 { | ||
reg = <2>; | ||
label = "FSEL0"; | ||
}; | ||
channel@3 { | ||
reg = <3>; | ||
label = "GSEL2"; | ||
}; | ||
channel@4 { | ||
reg = <4>; | ||
label = "GPIO_TEST"; | ||
}; | ||
channel@5 { | ||
reg = <5>; | ||
label = "GSEL3"; | ||
}; | ||
channel@6 { | ||
reg = <6>; | ||
label = "FSEL1"; | ||
}; | ||
}; | ||
}; | ||
|
||
&fmc_spi { | ||
|
||
adc_ada4355: adc_ada4355@0 { | ||
compatible = "adi,ada4355"; | ||
reg = <0>; | ||
spi-max-frequency = <100000>; | ||
gpio-vld-en-gpios = <&gpio0 89 GPIO_ACTIVE_HIGH>; | ||
|
||
clocks = <&ada4355_fixed_clock>; | ||
clock-names = "adc_clk"; | ||
num_lanes = <2>; | ||
spi-cpol; | ||
spi-cpha; | ||
}; | ||
}; |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,99 @@ | ||
// SPDX-License-Identifier: GPL-2.0 | ||
/* | ||
* Analog Devices ada4355 | ||
* | ||
* hdl_project: <ada4355_fmc/zed> | ||
* board_revision: <> | ||
* | ||
* Copyright (C) 2025 Analog Devices Inc. | ||
*/ | ||
/dts-v1/; | ||
|
||
#include <dt-bindings/gpio/gpio.h> | ||
|
||
#include "zynq-zed.dtsi" | ||
#include "zynq-zed-adv7511.dtsi" | ||
|
||
&fpga_axi { | ||
rx_dma: rx-dmac@44a30000 { | ||
compatible = "adi,axi-dmac-1.00.a"; | ||
reg = <0x44A30000 0x10000>; | ||
#dma-cells = <1>; | ||
interrupts = <0 57 IRQ_TYPE_LEVEL_HIGH>; | ||
clocks = <&clkc 16>; | ||
|
||
adi,channels { | ||
#size-cells = <0>; | ||
#address-cells = <1>; | ||
|
||
dma-channel@0 { | ||
reg = <0>; | ||
adi,source-bus-width = <32>; | ||
adi,source-bus-type = <2>; | ||
adi,destination-bus-width = <64>; | ||
adi,destination-bus-type = <0>; | ||
}; | ||
}; | ||
}; | ||
|
||
ada4355: ada4355@44a00000 { | ||
compatible = "adi,axi-adc-10.0.a"; | ||
reg = <0x44A00000 0x10000>; | ||
dmas = <&rx_dma 0>; | ||
dma-names = "rx"; | ||
|
||
spibus-connected = <&adc_ada4355>; | ||
}; | ||
}; | ||
|
||
&spi0 { | ||
status = "okay"; | ||
}; | ||
|
||
#define fmc_spi spi0 | ||
|
||
/ { | ||
ada4355_fixed_clock: ada4355_fixed_clock{ | ||
compatible = "fixed-clock"; | ||
#clock-cells = <0>; | ||
clock-frequency = <125000000>; | ||
}; | ||
|
||
gpio-control@0 { | ||
compatible = "adi,one-bit-adc-dac"; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
out-gpios = <&gpio0 86 GPIO_ACTIVE_HIGH>, | ||
<&gpio0 87 GPIO_ACTIVE_HIGH>, | ||
<&gpio0 88 GPIO_ACTIVE_HIGH>; | ||
|
||
channel@0 { | ||
reg = <0>; | ||
label = "GSEL0"; | ||
}; | ||
channel@1 { | ||
reg = <1>; | ||
label = "GSEL1"; | ||
}; | ||
channel@2 { | ||
reg = <2>; | ||
label = "FSEL"; | ||
}; | ||
}; | ||
}; | ||
|
||
&fmc_spi { | ||
|
||
adc_ada4355: adc_ada4355@0 { | ||
compatible = "adi,ada4355"; | ||
reg = <0>; | ||
spi-max-frequency = <100000>; | ||
gpio-vld-en-gpios = <&gpio0 89 GPIO_ACTIVE_HIGH>; | ||
|
||
clocks = <&ada4355_fixed_clock>; | ||
clock-names = "adc_clk"; | ||
num_lanes = <2>; | ||
spi-cpol; | ||
spi-cpha; | ||
}; | ||
}; |
Original file line number | Diff line number | Diff line change | ||||||
---|---|---|---|---|---|---|---|---|
|
@@ -461,6 +461,18 @@ config ADAQ8092 | |||||||
To compile this driver as a module, choose M here: the | ||||||||
module will be called adaq8092. | ||||||||
|
||||||||
|
||||||||
config ADA4355 | ||||||||
tristate "Analog Devices ADA4355 uModule Data Acquisition Module" | ||||||||
depends on SPI | ||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. edit: my comment looks into why it was lacking symbols, nuno suggestion is the correct solution.
Suggested change
The driver uses axiadc_write and axiadc_read, exported from cf_axi_adc_core.c, enabled with CF_AXI_ADC. For curiosity, we have now a script that resolves the tree of depends in the KConfig based on a target:
as committed, it lacks the CF_AXI_ADC symbol. |
||||||||
depends on CF_AXI_ADC | ||||||||
select REGMAP_SPI | ||||||||
help | ||||||||
Say yes here to build support for Analog Devices ADA4355 | ||||||||
14-bit, 125MSPS, high-speed dual-channel analog to digital | ||||||||
converters (ADC) that realize a complete current to bits data | ||||||||
acquisition solution. Provides direct access via sysfs. | ||||||||
|
||||||||
config ADM1177 | ||||||||
tristate "Analog Devices ADM1177 Digital Power Monitor driver" | ||||||||
depends on I2C | ||||||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, the PR description says the driver is in the process of upstreaming, but I didn't find it in the mailing list so commenting here.
For upstreaming, a dt-binding (.yaml file) will be needed.
And dt maintainers will probably ask to describe the voltage supplies.
Looks like this will have a required 3.3V VCC supply and two (VEA and VED) optional supplies.