On Tue, 2017-04-25 at 21:12 +0300, Andy Shevchenko wrote: > On Tue, 2017-04-25 at 15:16 +0000, Eugeniy Paltsev wrote: > > On Mon, 2017-04-24 at 19:56 +0300, Andy Shevchenko wrote: > > > On Mon, 2017-04-24 at 15:55 +0000, Eugeniy Paltsev wrote: > > > > Hi, > > > > On Fri, 2017-04-21 at 18:13 +0300, Andy Shevchenko wrote: > > > > > On Fri, 2017-04-21 at 14:29 +0000, Eugeniy Paltsev wrote: > > > > > > On Tue, 2017-04-18 at 15:31 +0300, Andy Shevchenko wrote: > > > > > > > On Fri, 2017-04-07 at 17:04 +0300, Eugeniy Paltsev wrote: > > > > This IP can be (ans is) configured with small block size. > > > > (note, that I am not saying about runtime HW configuration) > > > > > > > > And there is opportunity what we can't use sg_list directly and > > > > need > > > > to > > > > split sg_list to a smaller chunks. > > > > > > That's what I have referred quite ago. The driver should provide > > > an > > > interface to tell potential caller what maximum block (number of > > > items > > > with given bus width) it supports. > > > > > > We have struct dma_parms in struct device, but what we actually > > > need > > > is > > > to support similar on per channel basis in DMAengine framework. > > > > > > So, instead of working around this I recommend either to > > > implement > > > it > > > properly or rely on the fact that in the future someone > > > eventually > > > does that for you. > > > > > > Each driver which has this re-splitting mechanism should be > > > cleaned > > > up and refactored. > > > > I still can't see any pros of this implementation. > > There is no performance profit: we anyway need to re-splitt sg_list > > (but now in dma-user driver instead of dma driver) --->--- > > If we want to use same descriptors several times we just can use > > DMA_CTRL_REUSE option - the descriptors will be created one time > > and re-splitting will be ?ompleted only one time. > > There are two type of descriptors: SW and HW. That flag about SW > descriptor, so, it in most cases has nothing to do with the actual > entry size. Hmm, I checked all virt-dma code attentively and I don't see this limitation. The only existing limitation I can see is that we can use DMA_CTRL_REUSE only for channels supporting slave transfers. (But it is irrelevant to our discussion) So, we can use DMA_CTRL_REUSE for both HW/SW descriptor types. -- ?Eugeniy Paltsev