From: Vinod Koul <vinod.koul@intel.com> To: Yuan Yao <yao.yuan@freescale.com> Cc: shawn.guo@linaro.org, dan.j.williams@intel.com, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org Subject: Re: [PATCH 1/2] dma: Add Freescale qDMA engine driver support Date: Mon, 5 Oct 2015 15:37:14 +0100 [thread overview] Message-ID: <20151005143713.GC13501@vkoul-mobl.iind.intel.com> (raw) In-Reply-To: <1441950833-27684-1-git-send-email-yao.yuan@freescale.com> On Fri, Sep 11, 2015 at 01:53:52PM +0800, Yuan Yao wrote: > +Examples: > + > + qdma: qdma@8390000 { > + compatible = "fsl,ls-qdma"; > + reg = <0x0 0x8380000 0x0 0x20000>; > + interrupts = <GIC_SPI 170 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 185 IRQ_TYPE_LEVEL_HIGH>; > + interrupt-names = "qdma-tx", "qdma-err"; > + big-endian; > + channels = <1>; > + }; Binding should be a separate patch > +FREESCALE qDMA DRIVER > +M: Yuan Yao <yao.yuan@freescale.com> > +L: linux-arm-kernel@lists.infradead.org not dmaengine ML ? > +config FSL_QDMA > + tristate "Freescale qDMA engine support" > + select DMA_ENGINE > + select DMA_VIRTUAL_CHANNELS No depends on arch, can it work on x86? > +static int fsl_qdma_alloc_chan_resources(struct dma_chan *chan) > +{ > + struct fsl_qdma_chan *fsl_chan = to_fsl_qdma_chan(chan); > + > + fsl_chan->desc = NULL; > + return 0; > +} why do you need this it seems to do nothing > +static struct fsl_qdma_desc *fsl_qdma_alloc_desc(struct fsl_qdma_chan *fsl_chan) > +{ > + struct fsl_qdma_desc *fsl_desc; > + > + fsl_desc = kzalloc(sizeof(*fsl_desc), GFP_NOWAIT); > + empty line here is not required > + if (!fsl_desc) > + return NULL; > + > + fsl_desc->qchan = fsl_chan; > + > + return fsl_desc; why not return fsl_desc->qchan ; > + dma_cap_set(DMA_PRIVATE, fsl_qdma->dma_dev.cap_mask); > + dma_cap_set(DMA_SLAVE, fsl_qdma->dma_dev.cap_mask); > + dma_cap_set(DMA_MEMCPY, fsl_qdma->dma_dev.cap_mask); > + > + fsl_qdma->dma_dev.dev = &pdev->dev; > + fsl_qdma->dma_dev.device_alloc_chan_resources > + = fsl_qdma_alloc_chan_resources; > + fsl_qdma->dma_dev.device_free_chan_resources > + = fsl_qdma_free_chan_resources; > + fsl_qdma->dma_dev.device_tx_status = fsl_qdma_tx_status; > + fsl_qdma->dma_dev.device_prep_dma_memcpy = fsl_qdma_prep_memcpy; > + fsl_qdma->dma_dev.device_issue_pending = fsl_qdma_issue_pending; You claim DMA_SLAVE but no prep_ for that? > + > +static int __init fsl_qdma_init(void) > +{ > + return platform_driver_register(&fsl_qdma_driver); > +} > +subsys_initcall(fsl_qdma_init); why subsys_init? -- ~Vinod
WARNING: multiple messages have this Message-ID (diff)
From: vinod.koul@intel.com (Vinod Koul) To: linux-arm-kernel@lists.infradead.org Subject: [PATCH 1/2] dma: Add Freescale qDMA engine driver support Date: Mon, 5 Oct 2015 15:37:14 +0100 [thread overview] Message-ID: <20151005143713.GC13501@vkoul-mobl.iind.intel.com> (raw) In-Reply-To: <1441950833-27684-1-git-send-email-yao.yuan@freescale.com> On Fri, Sep 11, 2015 at 01:53:52PM +0800, Yuan Yao wrote: > +Examples: > + > + qdma: qdma at 8390000 { > + compatible = "fsl,ls-qdma"; > + reg = <0x0 0x8380000 0x0 0x20000>; > + interrupts = <GIC_SPI 170 IRQ_TYPE_LEVEL_HIGH>, > + <GIC_SPI 185 IRQ_TYPE_LEVEL_HIGH>; > + interrupt-names = "qdma-tx", "qdma-err"; > + big-endian; > + channels = <1>; > + }; Binding should be a separate patch > +FREESCALE qDMA DRIVER > +M: Yuan Yao <yao.yuan@freescale.com> > +L: linux-arm-kernel at lists.infradead.org not dmaengine ML ? > +config FSL_QDMA > + tristate "Freescale qDMA engine support" > + select DMA_ENGINE > + select DMA_VIRTUAL_CHANNELS No depends on arch, can it work on x86? > +static int fsl_qdma_alloc_chan_resources(struct dma_chan *chan) > +{ > + struct fsl_qdma_chan *fsl_chan = to_fsl_qdma_chan(chan); > + > + fsl_chan->desc = NULL; > + return 0; > +} why do you need this it seems to do nothing > +static struct fsl_qdma_desc *fsl_qdma_alloc_desc(struct fsl_qdma_chan *fsl_chan) > +{ > + struct fsl_qdma_desc *fsl_desc; > + > + fsl_desc = kzalloc(sizeof(*fsl_desc), GFP_NOWAIT); > + empty line here is not required > + if (!fsl_desc) > + return NULL; > + > + fsl_desc->qchan = fsl_chan; > + > + return fsl_desc; why not return fsl_desc->qchan ; > + dma_cap_set(DMA_PRIVATE, fsl_qdma->dma_dev.cap_mask); > + dma_cap_set(DMA_SLAVE, fsl_qdma->dma_dev.cap_mask); > + dma_cap_set(DMA_MEMCPY, fsl_qdma->dma_dev.cap_mask); > + > + fsl_qdma->dma_dev.dev = &pdev->dev; > + fsl_qdma->dma_dev.device_alloc_chan_resources > + = fsl_qdma_alloc_chan_resources; > + fsl_qdma->dma_dev.device_free_chan_resources > + = fsl_qdma_free_chan_resources; > + fsl_qdma->dma_dev.device_tx_status = fsl_qdma_tx_status; > + fsl_qdma->dma_dev.device_prep_dma_memcpy = fsl_qdma_prep_memcpy; > + fsl_qdma->dma_dev.device_issue_pending = fsl_qdma_issue_pending; You claim DMA_SLAVE but no prep_ for that? > + > +static int __init fsl_qdma_init(void) > +{ > + return platform_driver_register(&fsl_qdma_driver); > +} > +subsys_initcall(fsl_qdma_init); why subsys_init? -- ~Vinod
next prev parent reply other threads:[~2015-10-05 14:37 UTC|newest] Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top 2015-09-11 5:53 [PATCH 1/2] dma: Add Freescale qDMA engine driver support Yuan Yao 2015-09-11 5:53 ` Yuan Yao 2015-09-11 5:53 ` Yuan Yao 2015-09-11 5:53 ` [PATCH 2/2] dma: dts: " Yuan Yao 2015-09-11 5:53 ` Yuan Yao 2015-09-11 5:53 ` Yuan Yao 2015-09-23 23:45 ` [PATCH 1/2] dma: " Li Yang 2015-09-23 23:45 ` Li Yang 2015-09-23 23:45 ` Li Yang 2015-10-05 14:37 ` Vinod Koul [this message] 2015-10-05 14:37 ` Vinod Koul 2015-10-22 7:56 ` Yao Yuan 2015-10-22 7:56 ` Yao Yuan 2015-10-22 7:56 ` Yao Yuan -- strict thread matches above, loose matches on Subject: below -- 2015-03-17 5:28 Yuan Yao 2015-03-17 5:28 ` Yuan Yao 2015-03-17 18:56 ` Paul Bolle 2015-03-17 18:56 ` Paul Bolle 2015-03-20 2:01 ` Yao Yuan 2015-03-20 2:01 ` Yao Yuan 2015-04-01 3:26 ` Vinod Koul 2015-04-01 3:26 ` Vinod Koul
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20151005143713.GC13501@vkoul-mobl.iind.intel.com \ --to=vinod.koul@intel.com \ --cc=dan.j.williams@intel.com \ --cc=devicetree@vger.kernel.org \ --cc=dmaengine@vger.kernel.org \ --cc=linux-arm-kernel@lists.infradead.org \ --cc=linux-kernel@vger.kernel.org \ --cc=shawn.guo@linaro.org \ --cc=yao.yuan@freescale.com \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.