<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/dma, branch v3.16</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v3.16</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v3.16'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2014-07-01T06:53:42Z</updated>
<entry>
<title>Update imx-sdma cyclic handling to report residue</title>
<updated>2014-07-01T06:53:42Z</updated>
<author>
<name>Russell King - ARM Linux</name>
<email>linux@arm.linux.org.uk</email>
</author>
<published>2014-06-25T12:00:33Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d1a792f3b4072bfac4150bb62aa34917b77fdb6d'/>
<id>urn:sha1:d1a792f3b4072bfac4150bb62aa34917b77fdb6d</id>
<content type='text'>
I received a report this morning from one of the Novena developers that
the behaviour of the iMX6 ASoC codec driver (using imx-pcm-dma.c) was
sub-optimal under high system load.

While there are issues relating to system load remaining, upon reviewing
the ASoC imx-pcm-dma.c driver, it was noticed that it not using the
residue support, because SDMA doesn't support it.  This has the effect
that SDMA has to make multiple calls into the ASoC and ALSA code, one
for each period.

Since ALSA's snd_pcm_elapsed() does not need to be called multiple times
and it is entirely sufficient to call it once to update ALSA with the
current buffer position via the pointer method, we can do better here.
We can also avoid stopping the DMA entirely, just like real cyclic DMA
implementations behave.  While this means that we replay some old samples,
this is a nicer behaviour than having audio stop and restart.

The changes to achieve this are relatively minor - imx-sdma.c can track
where the DMA is to the nearest descriptor boundary - it does this
already when deciding how many callbacks to issue.  In doing this,
buf_tail always points at the descriptor which will complete next.

The residue is defined by the bytes remaining to the end of the buffer,
when the buffer is viewed as a single block of memory [start...end].
So, when we start out, there's a full buffer worth of residue, and this
counts down as we approach the end of the buffer, eventually becoming
zero at the end, before returning to the full buffer worth when we
wrap back to the start.

Moving the walking of the descriptors into the interrupt handler means
that we can update the BD_DONE flag at interrupt time, thus avoiding
a delayed tasklet stopping the cyclic DMA.

This means that the residue can be calculated from (total descriptors -
buf_tail) * descriptor size.  This is what the change below does.  We
update imx-pcm-dma.c to remove the NO_RESIDUE flag since we now provide
the residue.

Signed-off-by: Russell King &lt;rmk+kernel@arm.linux.org.uk&gt;
Tested-by: Shawn Guo &lt;shawn.guo@linaro.org&gt;
Signed-off-by: Vinod Koul &lt;vinod.koul@intel.com&gt;
</content>
</entry>
<entry>
<title>dma: cppi41: handle 0-length packets</title>
<updated>2014-07-01T06:45:48Z</updated>
<author>
<name>Daniel Mack</name>
<email>zonque@gmail.com</email>
</author>
<published>2014-05-26T12:52:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=13bbfb5c4eb4fc85bf977245f9b3624df0187184'/>
<id>urn:sha1:13bbfb5c4eb4fc85bf977245f9b3624df0187184</id>
<content type='text'>
When a 0-length packet is received on the bus, desc-&gt;pd0 yields 1,
which confuses the driver's users. This information is clearly wrong
and not in accordance to the datasheet, but it's been observed on an
AM335x board, very reproducible.

Fix this by looking at bit 19 in PD2 of the completed packet. This bit
will tell us if a zero-length packet was received on a queue. If it's
set, ignore the value in PD0 and report a total length of 0 instead.

Signed-off-by: Daniel Mack &lt;zonque@gmail.com&gt;
Signed-off-by: Vinod Koul &lt;vinod.koul@intel.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'for-linus' of git://git.infradead.org/users/vkoul/slave-dma</title>
<updated>2014-06-10T17:28:45Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2014-06-10T17:28:45Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=77c32bbbe0d0e963ba5723b8d1f6c42c5d56858b'/>
<id>urn:sha1:77c32bbbe0d0e963ba5723b8d1f6c42c5d56858b</id>
<content type='text'>
Pull slave-dmaengine updates from Vinod Koul:
 - new Xilixn VDMA driver from Srikanth
 - bunch of updates for edma driver by Thomas, Joel and Peter
 - fixes and updates on dw, ste_dma, freescale, mpc512x, sudmac etc

* 'for-linus' of git://git.infradead.org/users/vkoul/slave-dma: (45 commits)
  dmaengine: sh: don't use dynamic static allocation
  dmaengine: sh: fix print specifier warnings
  dmaengine: sh: make shdma_prep_dma_cyclic static
  dmaengine: Kconfig: Update MXS_DMA help text to include MX6Q/MX6DL
  of: dma: Grammar s/requests/request/, s/used required/required/
  dmaengine: shdma: Enable driver compilation with COMPILE_TEST
  dmaengine: rcar-hpbdma: Include linux/err.h
  dmaengine: sudmac: Include linux/err.h
  dmaengine: sudmac: Keep #include sorted alphabetically
  dmaengine: shdmac: Include linux/err.h
  dmaengine: shdmac: Keep #include sorted alphabetically
  dmaengine: s3c24xx-dma: Add cyclic transfer support
  dmaengine: s3c24xx-dma: Process whole SG chain
  dmaengine: imx: correct sdmac-&gt;status for cyclic dma tx
  dmaengine: pch: fix compilation for alpha target
  dmaengine: dw: check return code of dma_async_device_register()
  dmaengine: dw: fix regression in dw_probe() function
  dmaengine: dw: enable clock before access
  dma: pch_dma: Fix Kconfig dependencies
  dmaengine: mpc512x: add support for peripheral transfers
  ...
</content>
</entry>
<entry>
<title>Merge branch 'topic/xilinx' into for-linus</title>
<updated>2014-06-09T16:26:29Z</updated>
<author>
<name>Vinod Koul</name>
<email>vinod.koul@intel.com</email>
</author>
<published>2014-06-09T16:26:29Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=06822788faa21529a9a97965e266d77a596dc921'/>
<id>urn:sha1:06822788faa21529a9a97965e266d77a596dc921</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Merge branch 'topic/dw' into for-linus</title>
<updated>2014-06-09T16:25:40Z</updated>
<author>
<name>Vinod Koul</name>
<email>vinod.koul@intel.com</email>
</author>
<published>2014-06-09T16:25:40Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=3c814be9712f1a9f22009fb56bf96cf6de2ec663'/>
<id>urn:sha1:3c814be9712f1a9f22009fb56bf96cf6de2ec663</id>
<content type='text'>
</content>
</entry>
<entry>
<title>dmaengine: sh: don't use dynamic static allocation</title>
<updated>2014-06-03T06:05:33Z</updated>
<author>
<name>Vinod Koul</name>
<email>vinod.koul@intel.com</email>
</author>
<published>2014-06-02T04:10:00Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=877d8425072b50965f6f04ea3a127928f66db72f'/>
<id>urn:sha1:877d8425072b50965f6f04ea3a127928f66db72f</id>
<content type='text'>
dynamic stack allocation in kernel is considered bad as kernel stack is low and
we get warns on few archs as reported by kbuild test robot

&gt;&gt; drivers/dma/sh/shdma-base.c:671:32: sparse: Variable length array is used.
&gt;&gt; drivers/dma/sh/shdma-base.c:701:1: warning: 'shdma_prep_dma_cyclic' uses
&gt;&gt; dynamic stack allocation [enabled by default]

Fix this by making a static array of 32 which should be sufficient for
shdma_prep_dma_cyclic which only user in kernel is audio and 32 periods for
audio seems quite sufficient atm

Reported-by: kbuild test robot &lt;fengguang.wu@intel.com&gt;
Signed-off-by: Vinod Koul &lt;vinod.koul@intel.com&gt;
</content>
</entry>
<entry>
<title>dmaengine: sh: fix print specifier warnings</title>
<updated>2014-06-03T06:05:24Z</updated>
<author>
<name>Vinod Koul</name>
<email>vinod.koul@intel.com</email>
</author>
<published>2014-06-02T04:02:59Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=9d9f71a804314e7d50e2fa9e6e61bc77e2d6ae1c'/>
<id>urn:sha1:9d9f71a804314e7d50e2fa9e6e61bc77e2d6ae1c</id>
<content type='text'>
As documented in Documentation/printk-formats.txt we should use %zu/%zx
specifiers for size_t type variables for the code to compile on different
architectures. This is uncovered as COMPILE_TEST has been enabled recently for
this driver

   drivers/dma/sh/shdma-base.c: In function 'shdma_prep_dma_cyclic':
&gt;&gt; drivers/dma/sh/shdma-base.c:683:4: warning: format '%d' expects argument of
&gt;&gt; type 'int', but argument 4 has type 'size_t' [-Wformat=]
       __func__, buf_len, period_len, slave_id);
&gt;&gt; drivers/dma/sh/shdma-base.c:683:4: warning: format '%d' expects argument of
&gt;&gt; type 'int', but argument 5 has type 'size_t' [-Wformat=]

Reported-by: kbuild test robot &lt;fengguang.wu@intel.com&gt;
Acked-by: Laurent Pinchart &lt;laurent.pinchart@ideasonboard.com&gt;
Signed-off-by: Vinod Koul &lt;vinod.koul@intel.com&gt;
</content>
</entry>
<entry>
<title>dmaengine: sh: make shdma_prep_dma_cyclic static</title>
<updated>2014-06-03T06:04:47Z</updated>
<author>
<name>Vinod Koul</name>
<email>vinod.koul@intel.com</email>
</author>
<published>2014-06-02T03:52:03Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a68765430772fac92ad4f0dd9e33d31b4276546e'/>
<id>urn:sha1:a68765430772fac92ad4f0dd9e33d31b4276546e</id>
<content type='text'>
kbuild test robot reports that shdma_prep_dma_cyclic should be static, since
symbol is not declared, quick check revails that is the case

&gt;&gt; drivers/dma/sh/shdma-base.c:660:32: sparse: symbol 'shdma_prep_dma_cyclic'
&gt;&gt; was not declared. Should it be static?

Reported-by: kbuild test robot &lt;fengguang.wu@intel.com&gt;
Acked-by: Laurent Pinchart &lt;laurent.pinchart@ideasonboard.com&gt;
Signed-off-by: Vinod Koul &lt;vinod.koul@intel.com&gt;
</content>
</entry>
<entry>
<title>Merge tag 'drivers-for-3.16' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc into next</title>
<updated>2014-06-02T23:35:49Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2014-06-02T23:35:49Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a727eaf64ff084a50b983fc506810c7a576b7ce3'/>
<id>urn:sha1:a727eaf64ff084a50b983fc506810c7a576b7ce3</id>
<content type='text'>
Pull ARM SoC driver changes from Olof Johansson:
 "SoC-near driver changes that we're merging through our tree.  Mostly
  because they depend on other changes we have staged, but in some cases
  because the driver maintainers preferred that we did it this way.

  This contains a largeish cleanup series of the omap_l3_noc bus driver,
  cpuidle rework for Exynos, some reset driver conversions and a long
  branch of TI EDMA fixes and cleanups, with more to come next release.

  The TI EDMA cleanups is a shared branch with the dmaengine tree, with
  a handful of Davinci-specific fixes on top.

  After discussion at last year's KS (and some more on the mailing
  lists), we are here adding a drivers/soc directory.  The purpose of
  this is to keep per-vendor shared code that's needed by different
  drivers but that doesn't fit into the MFD (nor drivers/platform)
  model.  We expect to keep merging contents for this hierarchy through
  arm-soc so we can keep an eye on what the vendors keep adding here and
  not making it a free-for-all to shove in crazy stuff"

* tag 'drivers-for-3.16' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (101 commits)
  cpufreq: exynos: Fix driver compilation with ARCH_MULTIPLATFORM
  tty: serial: msm: Remove direct access to GSBI
  power: reset: keystone-reset: introduce keystone reset driver
  Documentation: dt: add bindings for keystone pll control controller
  Documentation: dt: add bindings for keystone reset driver
  soc: qcom: fix of_device_id table
  ARM: EXYNOS: Fix kernel panic when unplugging CPU1 on exynos
  ARM: EXYNOS: Move the driver to drivers/cpuidle directory
  ARM: EXYNOS: Cleanup all unneeded headers from cpuidle.c
  ARM: EXYNOS: Pass the AFTR callback to the platform_data
  ARM: EXYNOS: Move S5P_CHECK_SLEEP into pm.c
  ARM: EXYNOS: Move the power sequence call in the cpu_pm notifier
  ARM: EXYNOS: Move the AFTR state function into pm.c
  ARM: EXYNOS: Encapsulate the AFTR code into a function
  ARM: EXYNOS: Disable cpuidle for exynos5440
  ARM: EXYNOS: Encapsulate boot vector code into a function for cpuidle
  ARM: EXYNOS: Pass wakeup mask parameter to function for cpuidle
  ARM: EXYNOS: Remove ifdef for scu_enable in pm
  ARM: EXYNOS: Move scu_enable in the cpu_pm notifier
  ARM: EXYNOS: Use the cpu_pm notifier for pm
  ...
</content>
</entry>
<entry>
<title>dmaengine: Kconfig: Update MXS_DMA help text to include MX6Q/MX6DL</title>
<updated>2014-06-01T17:46:37Z</updated>
<author>
<name>Fabio Estevam</name>
<email>fabio.estevam@freescale.com</email>
</author>
<published>2014-05-26T21:08:25Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=654fa24965aafcb4bb8a1a14400c5ecea3be76b6'/>
<id>urn:sha1:654fa24965aafcb4bb8a1a14400c5ecea3be76b6</id>
<content type='text'>
The APBX-DMA block is also found on MX6Q/MX6DL chips.

Update the help text accordingly.

Signed-off-by: Fabio Estevam &lt;fabio.estevam@freescale.com&gt;
Signed-off-by: Vinod Koul &lt;vinod.koul@intel.com&gt;
</content>
</entry>
</feed>
