This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux: EDMA_XBAR Still unable to work

Part Number: AM3354

Tool/software: Linux

I want to use XDMA_EVENT_INTR0 to trigger  a DMA to read GPMC data .In the 3.2 kernel I have easy to achieve and good use, but in the latest RT-LINUX 4.4.12 try to use a variety of methods are unable to achieve this function.I do not quite understand the new kernel, can you help me? thank you very much

Here is my code..

&gpmc {
	status = "okay";
	ranges = <0 0 0x08000000 0x10000000>,	/* CS0: 16MB for NAND */
		 <1 0 0x18000000 0x08000000>,
		 <2 0 0x20000000 0x08000000>,
		 <3 0 0x28000000 0x08000000>,
		 <4 0 0x30000000 0x08000000>,
		 <5 0 0x38000000 0x04000000>,
		 <6 0 0x3c000000 0x04000000>;
	nand@0,0 {
		compatible = "ti,omap2-nand";
		....
	};
	fpga@1,0 {
		compatible = "fpga";
		pinctrl-names = "default";
		pinctrl-0 = <&fpga_pins>;
		status = "okay";
		reg = <1 0 0x01000000>; /* CS1, offset 0, IO size 4 */
		
		bank-width = <2>;		/* GPMC_CONFIG1_DEVICESIZE(1) */

		/*gpmc,burst-write;*/
		/*gpmc,burst-read;*/
		/*gpmc,burst-wrap;*/
		......
.......
/* these are on the crossbar and are outlined in the xbar-event-map element */ dmas = <&edma_xbar 20 0 28>; /*XDMA_EVENT_INTR0*/ dma-names = "fpga"; interrupt-parent = <&gpio0>; interrupts = <19 IRQ_TYPE_LEVEL_HIGH>; /* reset */ reset-gpio = <&gpio0 20 GPIO_ACTIVE_HIGH>; }; };

In the driver C file, I use "dma_request_chan (& pdev-> dev," fpga ");" Request DMA interrupt, the results can not be used to trigger this event through XDMA_EVENT_INTR0, I try to use "dma_request_channel (mask, NULL, NULL); "I can start DMA but I did not expect results

  • Part Number: AM3354

    Tool/software: Linux

    I want to use XDMA_EVENT_INTR0 to trigger  a DMA to read GPMC data .In the 3.2 kernel I have easy to achieve and good use, but in the latest RT-LINUX 4.4.12 try to use a variety of methods are unable to achieve this function.I do not quite understand the new kernel, can you help me? thank you very much

    Here is my code..

    &gpmc {
        status = "okay";
        ranges = <0 0 0x08000000 0x10000000>, /* CS0: 16MB for NAND */
             <1 0 0x18000000 0x08000000>,
             <2 0 0x20000000 0x08000000>,
             <3 0 0x28000000 0x08000000>,
             <4 0 0x30000000 0x08000000>,
             <5 0 0x38000000 0x04000000>,
             <6 0 0x3c000000 0x04000000>;
        nand@0,0 {
            compatible = "ti,omap2-nand";
            ....
        };
        fpga@1,0 {
            compatible = "fpga";
            pinctrl-names = "default";
            pinctrl-0 = <&fpga_pins>;
            status = "okay";
            reg = <1 0 0x01000000>; /* CS1, offset 0, IO size 4 */
            
            bank-width = <2>;     /* GPMC_CONFIG1_DEVICESIZE(1) */
    
            /*gpmc,burst-write;*/
            /*gpmc,burst-read;*/
            /*gpmc,burst-wrap;*/
            ......                .......
    
            /* these are on the crossbar and are outlined in the
                xbar-event-map element */
            dmas = <&edma_xbar 20 0 28>;  /*XDMA_EVENT_INTR0*/
            dma-names = "fpga";
    
            interrupt-parent = <&gpio0>;
            interrupts = <19 IRQ_TYPE_LEVEL_HIGH>;
            
    
            /* reset */
            reset-gpio = <&gpio0 20 GPIO_ACTIVE_HIGH>;
        };
    };

    In the driver C file, I use "dma_request_chan (& pdev-> dev," fpga ");" Request DMA interrupt, the results can not be used to trigger this event through XDMA_EVENT_INTR0, I try to use "dma_request_channel (mask, NULL, NULL); "I can start DMA but I did not expect results

  • Hi user4052087,

    From what I understand you are using AM335x custom board with PSDK-Linux-RT-AM335x 03.00.00.04. This RT PSDK support AM335x TI EVM and AM335x ICE, so your custom board should be based on these.

    Make sure xdma_event_intr0 signal is muxed on the XDMA_EVENT_INTR0 pin. Check also with scope that external FPGA is generating the DMA/IRQ request on that XDMA_EVENT_INTR0 pin.

    See also if the below e2e threads will be in help:

    e2e.ti.com/.../2040536
    e2e.ti.com/.../309254
    e2e.ti.com/.../552280
    e2e.ti.com/.../431021
    e2e.ti.com/.../297029
    e2e.ti.com/.../233424
    e2e.ti.com/.../188447

    Regards,
    Pavel