Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id C4E08E00CCE; Fri, 8 Sep 2017 09:00:51 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on yocto-www.yoctoproject.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,HTML_MESSAGE autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] * 0.0 HTML_MESSAGE BODY: HTML included in message Received: from webmail.sgl.com (mail1.sgl.com [209.87.231.69]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id A9186E00970 for ; Fri, 8 Sep 2017 09:00:50 -0700 (PDT) Received: from [10.1.20.15] (unknown [10.1.20.15]) by webmail.sgl.com (Postfix) with ESMTP id B9EC91D20B5E8 for ; Fri, 8 Sep 2017 11:58:54 -0400 (EDT) To: yocto@yoctoproject.org From: Fan Zhang Message-ID: Date: Fri, 8 Sep 2017 12:00:49 -0400 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 Subject: [meta-xilinx] How to include Xilinx DMA driver X-BeenThere: yocto@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Discussion of all things Yocto Project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Sep 2017 16:00:51 -0000 X-Groupsio-MsgNum: 37743 Content-Type: multipart/mixed; boundary="------------9CFB9260314A02BA14F3D4B7" Content-Language: en-US --------------9CFB9260314A02BA14F3D4B7 Content-Type: multipart/alternative; boundary="------------715AD911ADACF73EAB366CF4" --------------715AD911ADACF73EAB366CF4 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Hi All, I have a design on Zynq that uses DMA, and I need to setup a driver to program the DMA controller, setup the data transfer and supply data to user space. I searched around in the Xilinx forum, and found an dma_proxy driver. Xilinx also provides an xilinx_dma.c driver for the DMA. It is unclear to me how these all fit together. I have a few questions and I appreciate anyone to give me some pointer to moving things forward. 1. How to include xilinx_dma.c driver in to the poky image build? Xilinx wiki says enable these options: CONFIG_DMADEVICES, CONFIG_XILINX_DMA. I did a search on my bitbake folder, and they are enabled in a number of cfg files. But checking the environment with bitbake -e , and these options didn't show up. I can't find any xilinx_dma.ko in the build either. So what am I missing, and how can I include the xilinx driver into my build? Xilinx wiki page is here: http://www.wiki.xilinx.com/DMA+Drivers+-+Soft+IPs 2. I found a set of character device based dma driver, and it's user space application example. A number of people refer to this solution as an starting point for driver development. It's unclear to me whether this driver is built on top of the Xilinx_dma driver. When I tried this driver, it fails at requesting DMA channel. Anyone has experience with this driver, could you share your experience? Thank you so much. Driver can be found here: https://bitbucket.org/Schnegg/pa/src/b8f430a3ebd756f231e88e5dc8523737ed5db034/petalinux_project/components/modules/dma_proxy/dma_proxy.c?at=master&fileviewer=file-view-default Best Regards, Fan --------------715AD911ADACF73EAB366CF4 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 7bit

Hi All,

I have a design on Zynq that uses DMA, and I need to setup a driver to program the DMA controller, setup the data transfer and supply data to user space.

I searched around in the Xilinx forum, and found an dma_proxy driver. Xilinx also provides an xilinx_dma.c driver for the DMA. It is unclear to me how these all fit together. I have a few questions and I appreciate anyone to give me some pointer to moving things forward.

1. How to include xilinx_dma.c driver in to the poky image build?

Xilinx wiki says enable these options: CONFIG_DMADEVICES, CONFIG_XILINX_DMA. I did a search on my bitbake folder, and they are enabled in a number of cfg files. But checking the environment with bitbake -e , and these options didn't show up. I can't find any xilinx_dma.ko in the build either. So what am I missing, and how can I include the xilinx driver into my build? Xilinx wiki page is here: http://www.wiki.xilinx.com/DMA+Drivers+-+Soft+IPs

2. I found a set of character device based dma driver, and it's user space application example. A number of people refer to this solution as an starting point for driver development. It's unclear to me whether this driver is built on top of the Xilinx_dma driver. When I tried this driver, it fails at requesting DMA channel. Anyone has experience with this driver, could you share your experience? Thank you so much.

Driver can be found here: https://bitbucket.org/Schnegg/pa/src/b8f430a3ebd756f231e88e5dc8523737ed5db034/petalinux_project/components/modules/dma_proxy/dma_proxy.c?at=master&fileviewer=file-view-default
Best Regards,

Fan





--------------715AD911ADACF73EAB366CF4-- --------------9CFB9260314A02BA14F3D4B7 Content-Type: text/x-vcard; charset=utf-8; name="fzhang.vcf" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="fzhang.vcf" begin:vcard fn:Fan Zhang n:Zhang;Fan org:Sander Geophysics Ltd. email;internet:fzhang@sgl.com title:Electronics Design Engineer tel;work:(613)521-9626 version:2.1 end:vcard --------------9CFB9260314A02BA14F3D4B7--