<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/dma/altera-msgdma.c, branch v7.0.10</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v7.0.10</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v7.0.10'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2026-02-21T09:02:28+00:00</updated>
<entry>
<title>treewide: Replace kmalloc with kmalloc_obj for non-scalar types</title>
<updated>2026-02-21T09:02:28+00:00</updated>
<author>
<name>Kees Cook</name>
<email>kees@kernel.org</email>
</author>
<published>2026-02-21T07:49:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=69050f8d6d075dc01af7a5f2f550a8067510366f'/>
<id>urn:sha1:69050f8d6d075dc01af7a5f2f550a8067510366f</id>
<content type='text'>
This is the result of running the Coccinelle script from
scripts/coccinelle/api/kmalloc_objs.cocci. The script is designed to
avoid scalar types (which need careful case-by-case checking), and
instead replace kmalloc-family calls that allocate struct or union
object instances:

Single allocations:	kmalloc(sizeof(TYPE), ...)
are replaced with:	kmalloc_obj(TYPE, ...)

Array allocations:	kmalloc_array(COUNT, sizeof(TYPE), ...)
are replaced with:	kmalloc_objs(TYPE, COUNT, ...)

Flex array allocations:	kmalloc(struct_size(PTR, FAM, COUNT), ...)
are replaced with:	kmalloc_flex(*PTR, FAM, COUNT, ...)

(where TYPE may also be *VAR)

The resulting allocations no longer return "void *", instead returning
"TYPE *".

Signed-off-by: Kees Cook &lt;kees@kernel.org&gt;
</content>
</entry>
<entry>
<title>dmaengine: altera-msgdma: use sg_nents_for_dma() helper</title>
<updated>2026-01-09T03:06:00+00:00</updated>
<author>
<name>Andy Shevchenko</name>
<email>andriy.shevchenko@linux.intel.com</email>
</author>
<published>2026-01-08T10:50:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=47f5cb7878cc62ed95981c5d02862b253eddb590'/>
<id>urn:sha1:47f5cb7878cc62ed95981c5d02862b253eddb590</id>
<content type='text'>
Instead of open coded variant let's use recently introduced helper.

Reviewed-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Link: https://patch.msgid.link/20260108105619.3513561-3-andriy.shevchenko@linux.intel.com
Signed-off-by: Vinod Koul &lt;vkoul@kernel.org&gt;
</content>
</entry>
<entry>
<title>dmaengine: Switch back to struct platform_driver::remove()</title>
<updated>2024-10-14T18:20:34+00:00</updated>
<author>
<name>Uwe Kleine-König</name>
<email>u.kleine-koenig@baylibre.com</email>
</author>
<published>2024-10-04T06:22:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=76355c25e4f71ee4667ebaadd9faf8ec29d18f23'/>
<id>urn:sha1:76355c25e4f71ee4667ebaadd9faf8ec29d18f23</id>
<content type='text'>
After commit 0edb555a65d1 ("platform: Make platform_driver::remove()
return void") .remove() is (again) the right callback to implement for
platform drivers.

Convert all platform drivers below drivers/dma after the previous
conversion commits apart from the wireless drivers to use .remove(),
with the eventual goal to drop struct platform_driver::remove_new(). As
.remove() and .remove_new() have the same prototypes, conversion is done
by just changing the structure member name in the driver initializer.

Signed-off-by: Uwe Kleine-König &lt;u.kleine-koenig@baylibre.com&gt;
Link: https://lore.kernel.org/r/20241004062227.187726-2-u.kleine-koenig@baylibre.com
Signed-off-by: Vinod Koul &lt;vkoul@kernel.org&gt;
</content>
</entry>
<entry>
<title>dmaengine: Fix spelling mistakes</title>
<updated>2024-09-02T08:26:01+00:00</updated>
<author>
<name>Amit Vadhavana</name>
<email>av2082000@gmail.com</email>
</author>
<published>2024-08-31T17:29:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=a688efea0f2a084aee372e5b7b12d4d2d172f99a'/>
<id>urn:sha1:a688efea0f2a084aee372e5b7b12d4d2d172f99a</id>
<content type='text'>
Correct spelling mistakes in the DMA engine to improve readability
and clarity without altering functionality.

Signed-off-by: Amit Vadhavana &lt;av2082000@gmail.com&gt;
Reviewed-by: Kees Cook &lt;kees@kernel.org&gt;
Reviewed-by: Dave Jiang &lt;dave.jiang@intel.com&gt;
Reviewed-by: Fenghua Yu &lt;fenghua.yu@intel.com&gt;
Link: https://lore.kernel.org/r/20240831172949.13189-1-av2082000@gmail.com
Signed-off-by: Vinod Koul &lt;vkoul@kernel.org&gt;
</content>
</entry>
<entry>
<title>dmaengine: altera-msgdma: properly free descriptor in msgdma_free_descriptor</title>
<updated>2024-06-11T16:20:55+00:00</updated>
<author>
<name>Olivier Dautricourt</name>
<email>olivierdautricourt@gmail.com</email>
</author>
<published>2024-06-08T21:31:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=54e4ada1a4206f878e345ae01cf37347d803d1b1'/>
<id>urn:sha1:54e4ada1a4206f878e345ae01cf37347d803d1b1</id>
<content type='text'>
Remove list_del call in msgdma_chan_desc_cleanup, this should be the role
of msgdma_free_descriptor. In consequence replace list_add_tail with
list_move_tail in msgdma_free_descriptor.

This fixes the path:
   msgdma_free_chan_resources -&gt; msgdma_free_descriptors -&gt;
   msgdma_free_desc_list -&gt; msgdma_free_descriptor

which does not correctly free the descriptors as first nodes were not
removed from the list.

Signed-off-by: Olivier Dautricourt &lt;olivierdautricourt@gmail.com&gt;
Tested-by: Olivier Dautricourt &lt;olivierdautricourt@gmail.com&gt;
Link: https://lore.kernel.org/r/20240608213216.25087-3-olivierdautricourt@gmail.com
Signed-off-by: Vinod Koul &lt;vkoul@kernel.org&gt;
</content>
</entry>
<entry>
<title>dmaengine: altera-msgdma: cleanup after completing all descriptors</title>
<updated>2024-06-11T16:20:55+00:00</updated>
<author>
<name>Olivier Dautricourt</name>
<email>olivierdautricourt@gmail.com</email>
</author>
<published>2024-06-08T21:31:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=d3ddfab0969b19a7dee3753010bb3ea94a0cccd1'/>
<id>urn:sha1:d3ddfab0969b19a7dee3753010bb3ea94a0cccd1</id>
<content type='text'>
msgdma_chan_desc_cleanup iterates the done list for each completed
descriptor while we need to do it once after all descriptors are
completed.

This fixes a Sparse warning because we first take the lock in
msgdma_tasklet.
- Move locking to msgdma_chan_desc_cleanup.
- Move call to msgdma_chan_desc_cleanup outside of the critical section of
msgdma_tasklet.

Inspired by: commit 16ed0ef3e931 ("dmaengine: zynqmp_dma: cleanup after
                                   completing all descriptors")

Signed-off-by: Olivier Dautricourt &lt;olivierdautricourt@gmail.com&gt;
Tested-by: Olivier Dautricourt &lt;olivierdautricourt@gmail.com&gt;
Suggested-by: Eric Schwarz &lt;eas@sw-optimization.com&gt;
Link: https://lore.kernel.org/r/20240608213216.25087-2-olivierdautricourt@gmail.com
Signed-off-by: Vinod Koul &lt;vkoul@kernel.org&gt;
</content>
</entry>
<entry>
<title>dmaengine: altera-msgdma: use irq variant of spin_lock/unlock while invoking callbacks</title>
<updated>2024-06-11T16:20:55+00:00</updated>
<author>
<name>Olivier Dautricourt</name>
<email>olivierdautricourt@gmail.com</email>
</author>
<published>2024-06-08T21:31:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=261d3a85d959841821ca0d69f9d7b0d4087661c4'/>
<id>urn:sha1:261d3a85d959841821ca0d69f9d7b0d4087661c4</id>
<content type='text'>
As we first take the lock with spin_lock_irqsave in msgdma_tasklet, Lockdep
might complain about this. Inspired by commit 9558cf4ad07e
("dmaengine: zynqmp_dma: fix lockdep warning in tasklet")

Signed-off-by: Olivier Dautricourt &lt;olivierdautricourt@gmail.com&gt;
Tested-by: Olivier Dautricourt &lt;olivierdautricourt@gmail.com&gt;
Suggested-by: Eric Schwarz &lt;eas@sw-optimization.com&gt;
Link: https://lore.kernel.org/r/20240608213216.25087-1-olivierdautricourt@gmail.com
Signed-off-by: Vinod Koul &lt;vkoul@kernel.org&gt;
</content>
</entry>
<entry>
<title>dmaengine: altera-msgdma: Convert to platform remove callback returning void</title>
<updated>2023-09-28T07:40:45+00:00</updated>
<author>
<name>Uwe Kleine-König</name>
<email>u.kleine-koenig@pengutronix.de</email>
</author>
<published>2023-09-19T13:31:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=8876762f285fff08b1aefeba52c7157a2c9beec1'/>
<id>urn:sha1:8876762f285fff08b1aefeba52c7157a2c9beec1</id>
<content type='text'>
The .remove() callback for a platform driver returns an int which makes
many driver authors wrongly assume it's possible to do error handling by
returning an error code. However the value returned is ignored (apart
from emitting a warning) and this typically results in resource leaks.
To improve here there is a quest to make the remove callback return
void. In the first step of this quest all drivers are converted to
.remove_new() which already returns void. Eventually after all drivers
are converted, .remove_new() is renamed to .remove().

Trivially convert this driver from always returning zero in the remove
callback to the void returning variant.

Signed-off-by: Uwe Kleine-König &lt;u.kleine-koenig@pengutronix.de&gt;
Acked-by: Olivier Dautricourt &lt;olivierdautricourt@gmail.com&gt;
Link: https://lore.kernel.org/r/20230919133207.1400430-2-u.kleine-koenig@pengutronix.de
Signed-off-by: Vinod Koul &lt;vkoul@kernel.org&gt;
</content>
</entry>
<entry>
<title>dmaengine: altera-msgdma: Fixed some inconsistent function name descriptions</title>
<updated>2022-07-06T16:30:06+00:00</updated>
<author>
<name>Jiapeng Chong</name>
<email>jiapeng.chong@linux.alibaba.com</email>
</author>
<published>2022-07-06T08:26:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=4348d99efa01fe030eb625495de8b9f3578b5c7d'/>
<id>urn:sha1:4348d99efa01fe030eb625495de8b9f3578b5c7d</id>
<content type='text'>
Inconsistent function names describing msgdma_chan_remove() and
msgdma_dma_remove are modified to msgdma_dev_remove() and msgdma_remove().

Remove some warnings found by running scripts/kernel-doc, which is caused
by using 'make W=1'.

drivers/dma/altera-msgdma.c:927: warning: expecting prototype for msgdma_dma_remove(). Prototype was for msgdma_remove() instead.
drivers/dma/altera-msgdma.c:758: warning: expecting prototype for msgdma_chan_remove(). Prototype was for msgdma_dev_remove() instead.

Signed-off-by: Jiapeng Chong &lt;jiapeng.chong@linux.alibaba.com&gt;
Reviewed-by: Stefan Roese &lt;sr@denx.de&gt;
Link: https://lore.kernel.org/r/20220706082605.114907-1-jiapeng.chong@linux.alibaba.com
Signed-off-by: Vinod Koul &lt;vkoul@kernel.org&gt;
</content>
</entry>
<entry>
<title>dmaengine: altera-msgdma: Remove useless DMA-32 fallback configuration</title>
<updated>2022-02-15T11:23:11+00:00</updated>
<author>
<name>Christophe JAILLET</name>
<email>christophe.jaillet@wanadoo.fr</email>
</author>
<published>2022-01-15T07:40:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=7326bf800a47e5dabf574abe48dc7d6aa95ee7a2'/>
<id>urn:sha1:7326bf800a47e5dabf574abe48dc7d6aa95ee7a2</id>
<content type='text'>
As stated in [1], dma_set_mask() with a 64-bit mask never fails if
dev-&gt;dma_mask is non-NULL.
So, if it fails, the 32 bits case will also fail for the same reason.

Simplify code and remove some dead code accordingly.

[1]: https://lore.kernel.org/linux-kernel/YL3vSPK5DXTNvgdx@infradead.org/#t

Signed-off-by: Christophe JAILLET &lt;christophe.jaillet@wanadoo.fr&gt;
Reviewed-by: Stefan Roese &lt;sr@denx.de&gt;
Acked-by: Olivier Dautricourt &lt;olivier.dautricourt@orolia.com&gt;
Link: https://lore.kernel.org/r/01058ada3a0dea207212182ca7525060a204f1e1.1642232423.git.christophe.jaillet@wanadoo.fr
Signed-off-by: Vinod Koul &lt;vkoul@kernel.org&gt;
</content>
</entry>
</feed>
