* dmatest no longer works on ARC SDP with DW DMAC
@ 2016-08-10 11:06 ` Eugeniy Paltsev
0 siblings, 0 replies; 8+ messages in thread
From: Eugeniy Paltsev @ 2016-08-10 11:06 UTC (permalink / raw)
To: linux-snps-arc
dmatest on ARC SDP with DW DMAC became broken after df5c7386
("dmaengine: dw: some Intel devices has no memcpy support") and
30cb2639 ("dmaengine: dw: don't override platform data with autocfg")
commits.
* After df5c7386 commit "DMA_MEMCPY" capability option doesn't
get set correctly in platform driver version.
* After 30cb2639 commit
"data_width" and "nollp" parameters don't get set correctly in platform
driver version.
This happens because in old driver version there are three sources?
of parameters: pdata, device tree and autoconfig hardware registers.?
Some parameters were read from pdata and others from autoconfig
hardware registers. If pdata was absent some pdata structure?
fields were filled with parameters from device tree. But 30cb2639
commit disabled overriding pdata with autocfg, so if we use platform
driver version without pdata some parameters will not be set.
I'm wondering what would be the best way to fix this situation?
Should we strictly read parameters from only one source (pdata/device
tree/autoconfig) or we may mix some of them (for example getting
missing data from autoconf regs)?
^ permalink raw reply [flat|nested] 8+ messages in thread* dmatest no longer works on ARC SDP with DW DMAC @ 2016-08-10 11:06 ` Eugeniy Paltsev 0 siblings, 0 replies; 8+ messages in thread From: Eugeniy Paltsev @ 2016-08-10 11:06 UTC (permalink / raw) To: dmaengine@vger.kernel.org Cc: vinod.koul@intel.com, linux-kernel@vger.kernel.org, Vlad Zakharov, linux-snps-arc@lists.infradead.org, Eugeniy Paltsev, Alexey Brodkin, Nelson Pereira, viresh.kumar@linaro.org, andriy.shevchenko@linux.intel.com dmatest on ARC SDP with DW DMAC became broken after df5c7386 ("dmaengine: dw: some Intel devices has no memcpy support") and 30cb2639 ("dmaengine: dw: don't override platform data with autocfg") commits. * After df5c7386 commit "DMA_MEMCPY" capability option doesn't get set correctly in platform driver version. * After 30cb2639 commit "data_width" and "nollp" parameters don't get set correctly in platform driver version. This happens because in old driver version there are three sources of parameters: pdata, device tree and autoconfig hardware registers. Some parameters were read from pdata and others from autoconfig hardware registers. If pdata was absent some pdata structure fields were filled with parameters from device tree. But 30cb2639 commit disabled overriding pdata with autocfg, so if we use platform driver version without pdata some parameters will not be set. I'm wondering what would be the best way to fix this situation? Should we strictly read parameters from only one source (pdata/device tree/autoconfig) or we may mix some of them (for example getting missing data from autoconf regs)? ^ permalink raw reply [flat|nested] 8+ messages in thread
* dmatest no longer works on ARC SDP with DW DMAC 2016-08-10 11:06 ` Eugeniy Paltsev @ 2016-08-10 12:15 ` Andy Shevchenko -1 siblings, 0 replies; 8+ messages in thread From: Andy Shevchenko @ 2016-08-10 12:15 UTC (permalink / raw) To: linux-snps-arc On Wed, 2016-08-10@11:06 +0000, Eugeniy Paltsev wrote: > dmatest on ARC SDP with DW DMAC became broken after df5c7386 > ("dmaengine: dw: some Intel devices has no memcpy support") and > 30cb2639 ("dmaengine: dw: don't override platform data with autocfg") > commits. > * After df5c7386 commit "DMA_MEMCPY" capability option doesn't > get set correctly in platform driver version. > * After 30cb2639 commit > "data_width" and "nollp" parameters don't get set correctly in > platform > driver version. > > This happens because in old driver version there are three sources? > of parameters: pdata, device tree and autoconfig hardware registers.? > Some parameters were read from pdata and others from autoconfig > hardware registers. If pdata was absent some pdata structure? > fields were filled with parameters from device tree. But 30cb2639 > commit disabled overriding pdata with autocfg, so if we use platform > driver version without pdata some parameters will not be set. Yes, that's correct behaviour right now. You have to provide platform code which registers device with all platform data provided. > I'm wondering what would be the best way to fix this situation? Ideally we have to switch to use built-in device properties (drivers/base/property.c) and platform code in your case has to provide properties. > Should we strictly read parameters from only one source (pdata/device > tree/autoconfig) or we may mix some of them (for example getting > missing data from autoconf regs)? See above. -- Andy Shevchenko <andriy.shevchenko at linux.intel.com> Intel Finland Oy ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: dmatest no longer works on ARC SDP with DW DMAC @ 2016-08-10 12:15 ` Andy Shevchenko 0 siblings, 0 replies; 8+ messages in thread From: Andy Shevchenko @ 2016-08-10 12:15 UTC (permalink / raw) To: Eugeniy Paltsev, dmaengine@vger.kernel.org Cc: vinod.koul@intel.com, linux-kernel@vger.kernel.org, Vlad Zakharov, linux-snps-arc@lists.infradead.org, Alexey Brodkin, Nelson Pereira, viresh.kumar@linaro.org On Wed, 2016-08-10 at 11:06 +0000, Eugeniy Paltsev wrote: > dmatest on ARC SDP with DW DMAC became broken after df5c7386 > ("dmaengine: dw: some Intel devices has no memcpy support") and > 30cb2639 ("dmaengine: dw: don't override platform data with autocfg") > commits. > * After df5c7386 commit "DMA_MEMCPY" capability option doesn't > get set correctly in platform driver version. > * After 30cb2639 commit > "data_width" and "nollp" parameters don't get set correctly in > platform > driver version. > > This happens because in old driver version there are three sources > of parameters: pdata, device tree and autoconfig hardware registers. > Some parameters were read from pdata and others from autoconfig > hardware registers. If pdata was absent some pdata structure > fields were filled with parameters from device tree. But 30cb2639 > commit disabled overriding pdata with autocfg, so if we use platform > driver version without pdata some parameters will not be set. Yes, that's correct behaviour right now. You have to provide platform code which registers device with all platform data provided. > I'm wondering what would be the best way to fix this situation? Ideally we have to switch to use built-in device properties (drivers/base/property.c) and platform code in your case has to provide properties. > Should we strictly read parameters from only one source (pdata/device > tree/autoconfig) or we may mix some of them (for example getting > missing data from autoconf regs)? See above. -- Andy Shevchenko <andriy.shevchenko@linux.intel.com> Intel Finland Oy ^ permalink raw reply [flat|nested] 8+ messages in thread
* dmatest no longer works on ARC SDP with DW DMAC 2016-08-10 12:15 ` Andy Shevchenko @ 2016-08-10 12:22 ` Alexey Brodkin -1 siblings, 0 replies; 8+ messages in thread From: Alexey Brodkin @ 2016-08-10 12:22 UTC (permalink / raw) To: linux-snps-arc Hi Andy, On Wed, 2016-08-10@15:15 +0300, Andy Shevchenko wrote: > On Wed, 2016-08-10@11:06 +0000, Eugeniy Paltsev wrote: > > > > dmatest on ARC SDP with DW DMAC became broken after df5c7386 > > ("dmaengine: dw: some Intel devices has no memcpy support") and > > 30cb2639 ("dmaengine: dw: don't override platform data with autocfg") > > commits. > > * After df5c7386 commit "DMA_MEMCPY" capability option doesn't > > get set correctly in platform driver version. > > * After 30cb2639 commit > > "data_width" and "nollp" parameters don't get set correctly in > > platform > > driver version. > > > > This happens because in old driver version there are three sources? > > of parameters: pdata, device tree and autoconfig hardware registers.? > > Some parameters were read from pdata and others from autoconfig > > hardware registers. If pdata was absent some pdata structure? > > fields were filled with parameters from device tree. But 30cb2639 > > commit disabled overriding pdata with autocfg, so if we use platform > > driver version without pdata some parameters will not be set. > > Yes, that's correct behaviour right now. You have to provide platform > code which registers device with all platform data provided. But given autocfg registers exist in HW why don't we rely on their contents? > > I'm wondering what would be the best way to fix this situation? > > Ideally we have to switch to use built-in device properties > (drivers/base/property.c) and platform code in your case has to provide > properties. What do you mean saying "built-in device properties"? Setting pdata structure? In our particular case we use device tree for DW DMAC setup. -Alexey ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: dmatest no longer works on ARC SDP with DW DMAC @ 2016-08-10 12:22 ` Alexey Brodkin 0 siblings, 0 replies; 8+ messages in thread From: Alexey Brodkin @ 2016-08-10 12:22 UTC (permalink / raw) To: andriy.shevchenko@linux.intel.com Cc: vinod.koul@intel.com, linux-kernel@vger.kernel.org, Alexey.Brodkin@synopsys.com, Eugeniy.Paltsev@synopsys.com, Nelson.Pereira@synopsys.com, linux-snps-arc@lists.infradead.org, viresh.kumar@linaro.org, dmaengine@vger.kernel.org Hi Andy, On Wed, 2016-08-10 at 15:15 +0300, Andy Shevchenko wrote: > On Wed, 2016-08-10 at 11:06 +0000, Eugeniy Paltsev wrote: > > > > dmatest on ARC SDP with DW DMAC became broken after df5c7386 > > ("dmaengine: dw: some Intel devices has no memcpy support") and > > 30cb2639 ("dmaengine: dw: don't override platform data with autocfg") > > commits. > > * After df5c7386 commit "DMA_MEMCPY" capability option doesn't > > get set correctly in platform driver version. > > * After 30cb2639 commit > > "data_width" and "nollp" parameters don't get set correctly in > > platform > > driver version. > > > > This happens because in old driver version there are three sources > > of parameters: pdata, device tree and autoconfig hardware registers. > > Some parameters were read from pdata and others from autoconfig > > hardware registers. If pdata was absent some pdata structure > > fields were filled with parameters from device tree. But 30cb2639 > > commit disabled overriding pdata with autocfg, so if we use platform > > driver version without pdata some parameters will not be set. > > Yes, that's correct behaviour right now. You have to provide platform > code which registers device with all platform data provided. But given autocfg registers exist in HW why don't we rely on their contents? > > I'm wondering what would be the best way to fix this situation? > > Ideally we have to switch to use built-in device properties > (drivers/base/property.c) and platform code in your case has to provide > properties. What do you mean saying "built-in device properties"? Setting pdata structure? In our particular case we use device tree for DW DMAC setup. -Alexey ^ permalink raw reply [flat|nested] 8+ messages in thread
* dmatest no longer works on ARC SDP with DW DMAC 2016-08-10 12:22 ` Alexey Brodkin @ 2016-08-10 12:46 ` Andy Shevchenko -1 siblings, 0 replies; 8+ messages in thread From: Andy Shevchenko @ 2016-08-10 12:46 UTC (permalink / raw) To: linux-snps-arc On Wed, 2016-08-10@12:22 +0000, Alexey Brodkin wrote: > Hi Andy, > > On Wed, 2016-08-10@15:15 +0300, Andy Shevchenko wrote: > > > > On Wed, 2016-08-10@11:06 +0000, Eugeniy Paltsev wrote: > > > > > > > > > dmatest on ARC SDP with DW DMAC became broken after df5c7386 > > > ("dmaengine: dw: some Intel devices has no memcpy support") and > > > 30cb2639 ("dmaengine: dw: don't override platform data with > > > autocfg") > > > commits. > > > * After df5c7386 commit "DMA_MEMCPY" capability option doesn't > > > get set correctly in platform driver version. > > > * After 30cb2639 commit > > > "data_width" and "nollp" parameters don't get set correctly in > > > platform > > > driver version. > > > > > > This happens because in old driver version there are three > > > sources? > > > of parameters: pdata, device tree and autoconfig hardware > > > registers.? > > > Some parameters were read from pdata and others from autoconfig > > > hardware registers. If pdata was absent some pdata structure? > > > fields were filled with parameters from device tree. But 30cb2639 > > > commit disabled overriding pdata with autocfg, so if we use > > > platform > > > driver version without pdata some parameters will not be set. > > > > Yes, that's correct behaviour right now. You have to provide > > platform > > code which registers device with all platform data provided. > > But given autocfg registers exist in HW why don't we rely on their > contents? And how exactly we can get that mem2mem support is absent / broken by some reason? All those quirks (bool is_*) kinda semi-hardware related. What we can do is to have two categories of properties: a) genuine hardware properties, and b) quirks. So, refactor the ->probe() function in a way that will still copy quirks and other non-hardware properties from platform data, if provided, to the driver internals. > > > > > > > > > I'm wondering what would be the best way to fix this situation? > > > > Ideally we have to switch to use built-in device properties > > (drivers/base/property.c) and platform code in your case has to > > provide > > properties. > > What do you mean saying "built-in device properties"? > Setting pdata structure? In our particular case we use device tree > for DW DMAC setup. Providing device properties instead of platform data. Again see above. -- Andy Shevchenko <andriy.shevchenko at linux.intel.com> Intel Finland Oy ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: dmatest no longer works on ARC SDP with DW DMAC @ 2016-08-10 12:46 ` Andy Shevchenko 0 siblings, 0 replies; 8+ messages in thread From: Andy Shevchenko @ 2016-08-10 12:46 UTC (permalink / raw) To: Alexey Brodkin Cc: vinod.koul@intel.com, linux-kernel@vger.kernel.org, Eugeniy.Paltsev@synopsys.com, Nelson.Pereira@synopsys.com, linux-snps-arc@lists.infradead.org, viresh.kumar@linaro.org, dmaengine@vger.kernel.org On Wed, 2016-08-10 at 12:22 +0000, Alexey Brodkin wrote: > Hi Andy, > > On Wed, 2016-08-10 at 15:15 +0300, Andy Shevchenko wrote: > > > > On Wed, 2016-08-10 at 11:06 +0000, Eugeniy Paltsev wrote: > > > > > > > > > dmatest on ARC SDP with DW DMAC became broken after df5c7386 > > > ("dmaengine: dw: some Intel devices has no memcpy support") and > > > 30cb2639 ("dmaengine: dw: don't override platform data with > > > autocfg") > > > commits. > > > * After df5c7386 commit "DMA_MEMCPY" capability option doesn't > > > get set correctly in platform driver version. > > > * After 30cb2639 commit > > > "data_width" and "nollp" parameters don't get set correctly in > > > platform > > > driver version. > > > > > > This happens because in old driver version there are three > > > sources > > > of parameters: pdata, device tree and autoconfig hardware > > > registers. > > > Some parameters were read from pdata and others from autoconfig > > > hardware registers. If pdata was absent some pdata structure > > > fields were filled with parameters from device tree. But 30cb2639 > > > commit disabled overriding pdata with autocfg, so if we use > > > platform > > > driver version without pdata some parameters will not be set. > > > > Yes, that's correct behaviour right now. You have to provide > > platform > > code which registers device with all platform data provided. > > But given autocfg registers exist in HW why don't we rely on their > contents? And how exactly we can get that mem2mem support is absent / broken by some reason? All those quirks (bool is_*) kinda semi-hardware related. What we can do is to have two categories of properties: a) genuine hardware properties, and b) quirks. So, refactor the ->probe() function in a way that will still copy quirks and other non-hardware properties from platform data, if provided, to the driver internals. > > > > > > > > > I'm wondering what would be the best way to fix this situation? > > > > Ideally we have to switch to use built-in device properties > > (drivers/base/property.c) and platform code in your case has to > > provide > > properties. > > What do you mean saying "built-in device properties"? > Setting pdata structure? In our particular case we use device tree > for DW DMAC setup. Providing device properties instead of platform data. Again see above. -- Andy Shevchenko <andriy.shevchenko@linux.intel.com> Intel Finland Oy ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2016-08-10 20:39 UTC | newest] Thread overview: 8+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2016-08-10 11:06 dmatest no longer works on ARC SDP with DW DMAC Eugeniy Paltsev 2016-08-10 11:06 ` Eugeniy Paltsev 2016-08-10 12:15 ` Andy Shevchenko 2016-08-10 12:15 ` Andy Shevchenko 2016-08-10 12:22 ` Alexey Brodkin 2016-08-10 12:22 ` Alexey Brodkin 2016-08-10 12:46 ` Andy Shevchenko 2016-08-10 12:46 ` Andy Shevchenko
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.