Using AXI GPIO instead of ZynqMP GPIO in ADRV9009 reference design

Hi,

I need to use AXI GPIO instead of ZynqMP GPIO and AXI quad SPI instead of ZynqMP SPI_0 in ADRV9009 reference design,

I succeeded to use the AXI SPI but I got problems with the AXI GPIO.

My base project is analog devices ADRV9009 reference design(branch 2018_R1) with Petalinux 2017.4.

The only device I can see in /sys/bus/iio/devices is "ad9528-1"

Here my device tree (where I made changes) :

PL.dtsi:

axi_gpio_0: gpio@80010000 {
            #gpio-cells = <2>;
            #interrupt-cells = <2>;
            compatible = "xlnx,xps-gpio-1.00.a";
            gpio-controller ;
            interrupt-controller ;
            interrupt-parent = <&gic>;
            interrupts = <0 111 4>;
            reg = <0x0 0x80010000 0x0 0x1000>;
            xlnx,all-inputs = <0x0>;
            xlnx,all-inputs-2 = <0x0>;
            xlnx,all-outputs = <0x0>;
            xlnx,all-outputs-2 = <0x0>;
            xlnx,dout-default = <0x00000000>;
            xlnx,dout-default-2 = <0x00000000>;
            xlnx,gpio-width = <0x20>;
            xlnx,gpio2-width = <0x20>;
            xlnx,interrupt-present = <0x1>;
            xlnx,is-dual = <0x1>;
            xlnx,tri-default = <0xFFFFFFFF>;
            xlnx,tri-default-2 = <0xFFFFFFFF>;
        };
        axi_quad_spi_0: axi_quad_spi@80000000 {
            bits-per-word = <8>;
            compatible = "xlnx,xps-spi-2.00.a";
            fifo-size = <16>;
            interrupt-parent = <&gic>;
            interrupts = <0 110 1>;
            num-cs = <0x3>;
            reg = <0x0 0x80000000 0x0 0x10000>;
            xlnx,num-ss-bits = <0x3>;
            xlnx,spi-mode = <0>;
        };

zynqmp-zcu102-rev10-adrv9009.dts:

&axi_quad_spi_0 {
    status = "okay";
};

&trx0_adrv9009 {
    reset-gpios = <&axi_gpio_0 52 8>;
    test-gpios = <&axi_gpio_0 53 8>;
    sysref-req-gpios = <&axi_gpio_0 58 8>;
    rx2-enable-gpios = <&axi_gpio_0 54 8>;
    rx1-enable-gpios = <&axi_gpio_0 55 8>;
    tx2-enable-gpios = <&axi_gpio_0 56 8>;
    tx1-enable-gpios = <&axi_gpio_0 57 8>;
};
&clk0_ad9528 {
    reset-gpios = <&axi_gpio_0 59 8>;
};
&axi_adrv9009_core_tx {
    plddrbypass-gpios = <&axi_gpio_0 60 8>;
};

adi-adrv9009.dtsi:

Inside "trx0_adrv9009: adrv9009-phy@1" I changed this lines only:

interrupt-parent = <&axi_gpio_0>;
interrupts = <51 1>;

If I need to do any more changes in the device tree please guide me where.

Thanks for the help,

Amit

Parents Reply Children