<feed xmlns='http://www.w3.org/2005/Atom'>
<title>wireguard-linux/drivers/accel/rocket, branch stable</title>
<subtitle>WireGuard for the Linux kernel</subtitle>
<id>https://git.zx2c4.com/wireguard-linux/atom/drivers/accel/rocket?h=stable</id>
<link rel='self' href='https://git.zx2c4.com/wireguard-linux/atom/drivers/accel/rocket?h=stable'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/'/>
<updated>2025-09-01T10:11:28Z</updated>
<entry>
<title>accel/rocket: Fix some error checking in rocket_core_init()</title>
<updated>2025-09-01T10:11:28Z</updated>
<author>
<name>Dan Carpenter</name>
<email>dan.carpenter@linaro.org</email>
</author>
<published>2025-08-21T12:30:19Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=09e6d39cc83b18a17857b8d4d6a8902bc87dfbc2'/>
<id>urn:sha1:09e6d39cc83b18a17857b8d4d6a8902bc87dfbc2</id>
<content type='text'>
The problem is that pm_runtime_get_sync() can return 1 on success so
checking for zero doesn't work.  Use the pm_runtime_resume_and_get()
function instead.  The pm_runtime_resume_and_get() function does
additional cleanup as well so that's a bonus as well.

Fixes: 0810d5ad88a1 ("accel/rocket: Add job submission IOCTL")
Signed-off-by: Dan Carpenter &lt;dan.carpenter@linaro.org&gt;
Signed-off-by: Tomeu Vizoso &lt;tomeu@tomeuvizoso.net&gt;
Link: https://lore.kernel.org/r/aKcRW6fsRP_o5C_y@stanley.mountain
</content>
</entry>
<entry>
<title>accel/rocket: Check the correct DMA irq status to warn about</title>
<updated>2025-09-01T10:11:28Z</updated>
<author>
<name>Heiko Stuebner</name>
<email>heiko@sntech.de</email>
</author>
<published>2025-08-18T18:56:58Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=78e399955d352a2387a4b22713385a0c5d737685'/>
<id>urn:sha1:78e399955d352a2387a4b22713385a0c5d737685</id>
<content type='text'>
Right now, the code checks the DMA_READ_ERROR state 2 times, while
I guess it was supposed to warn about both read and write errors.

Change the 2nd check to look at the write-error flag.

Fixes: 0810d5ad88a1 ("accel/rocket: Add job submission IOCTL")
Signed-off-by: Heiko Stuebner &lt;heiko@sntech.de&gt;
Signed-off-by: Tomeu Vizoso &lt;tomeu@tomeuvizoso.net&gt;
Link: https://lore.kernel.org/r/20250818185658.2585696-1-heiko@sntech.de
</content>
</entry>
<entry>
<title>accel/rocket: Fix usages of kfree() and sizeof()</title>
<updated>2025-09-01T10:11:28Z</updated>
<author>
<name>Brigham Campbell</name>
<email>me@brighamcampbell.com</email>
</author>
<published>2025-08-13T16:02:37Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=ce6b656b5d64d612e9fc1c495eba6a362051c2ca'/>
<id>urn:sha1:ce6b656b5d64d612e9fc1c495eba6a362051c2ca</id>
<content type='text'>
Replace usages of kfree() with kvfree() for pointers which were
allocated using kvmalloc(), as required by the kernel memory management
API.

Use sizeof() on the type that a pointer references instead of the
pointer itself. In this case, scheds and *scheds both happen to be
pointers, so sizeof() will expand to the same value in either case, but
using *scheds is more technically correct since scheds is an array of
drm_gpu_scheduler *.

Reported-by: kernel test robot &lt;lkp@intel.com&gt;
Reported-by: Julia Lawall &lt;julia.lawall@inria.fr&gt;
Closes: https://lore.kernel.org/r/202508120730.PLbjlKbI-lkp@intel.com/
Signed-off-by: Brigham Campbell &lt;me@brighamcampbell.com&gt;
Signed-off-by: Tomeu Vizoso &lt;tomeu@tomeuvizoso.net&gt;
Link: https://lore.kernel.org/r/20250813-rocket-free-fix-v1-1-51f00a7a1271@brighamcampbell.com
Fixes: 0810d5ad88a1 ("accel/rocket: Add job submission IOCTL")
</content>
</entry>
<entry>
<title>accel/rocket: Depend on DRM_ACCEL not just DRM</title>
<updated>2025-09-01T10:11:28Z</updated>
<author>
<name>Heiko Stuebner</name>
<email>heiko@sntech.de</email>
</author>
<published>2025-08-14T11:35:19Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=503b0ed38ca60cfb5ba101517a680beebd38d377'/>
<id>urn:sha1:503b0ed38ca60cfb5ba101517a680beebd38d377</id>
<content type='text'>
With the current dependency on only DRM, a config of

CONFIG_DRM_ACCEL_ROCKET=y

is possible, but of course wrong, because without DRM_ACCEL the build-
system will never even enter drivers/accel/* .

So depend on DRM_ACCEL instead of just DRM.

Fixes: ed98261b4168 ("accel/rocket: Add a new driver for Rockchip's NPU")
Signed-off-by: Heiko Stuebner &lt;heiko@sntech.de&gt;
Signed-off-by: Tomeu Vizoso &lt;tomeu@tomeuvizoso.net&gt;
Link: https://lore.kernel.org/r/20250814113519.1551855-3-heiko@sntech.de
</content>
</entry>
<entry>
<title>accel/rocket: Fix indentation of Kconfig entry</title>
<updated>2025-09-01T10:11:28Z</updated>
<author>
<name>Heiko Stuebner</name>
<email>heiko@sntech.de</email>
</author>
<published>2025-08-14T11:35:18Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=c4d24127aaf1c50753c8bcdf050ed39b7c709869'/>
<id>urn:sha1:c4d24127aaf1c50753c8bcdf050ed39b7c709869</id>
<content type='text'>
The general indentation for the Kconfig lines is one tab, so adapt the
lines accordingly.

The description is correctly indented (1 tab + 2 spaces) so doesn't need
changes.

Fixes: ed98261b4168 ("accel/rocket: Add a new driver for Rockchip's NPU")
Signed-off-by: Heiko Stuebner &lt;heiko@sntech.de&gt;
Signed-off-by: Tomeu Vizoso &lt;tomeu@tomeuvizoso.net&gt;
Link: https://lore.kernel.org/r/20250814113519.1551855-2-heiko@sntech.de
</content>
</entry>
<entry>
<title>accel/rocket: Fix undeclared const rocket_pm_ops</title>
<updated>2025-08-03T15:40:23Z</updated>
<author>
<name>Brigham Campbell</name>
<email>me@brighamcampbell.com</email>
</author>
<published>2025-08-02T19:25:47Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=d9c1b06f3553977c50017e7ab40f8cecf80a30c9'/>
<id>urn:sha1:d9c1b06f3553977c50017e7ab40f8cecf80a30c9</id>
<content type='text'>
Fix sparse warning regarding an undeclared const rocket_pm_ops, which is
used in rocket_drv.c.

Reported-by: kernel test robot &lt;lkp@intel.com&gt;
Closes: https://lore.kernel.org/oe-kbuild-all/202508030021.uwdr4P08-lkp@intel.com/
Signed-off-by: Brigham Campbell &lt;me@brighamcampbell.com&gt;
Signed-off-by: Tomeu Vizoso &lt;tomeu@tomeuvizoso.net&gt;
Link: https://lore.kernel.org/r/20250802-fix-rockchip-npu-build-v1-2-fb0f0dacb3fe@brighamcampbell.com
</content>
</entry>
<entry>
<title>accel/rocket: Fix Rockchip NPU compilation</title>
<updated>2025-08-03T15:40:23Z</updated>
<author>
<name>Brigham Campbell</name>
<email>me@brighamcampbell.com</email>
</author>
<published>2025-08-02T19:25:46Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=218b15a3e9755c9cae79941b4bec22a4e8ad8758'/>
<id>urn:sha1:218b15a3e9755c9cae79941b4bec22a4e8ad8758</id>
<content type='text'>
Replace DRM_GPU_SCHED_STAT_NOMINAL with GPU_DRM_SCHED_STAT_RESET, in
accordance with commit 0a5dc1b67ef5 ("drm/sched: Rename
DRM_GPU_SCHED_STAT_NOMINAL to DRM_GPU_SCHED_STAT_RESET")

Pass extra parameter to drm_sched_job_init, as required by commit
2956554823ce ("drm/sched: Store the drm client_id in drm_sched_fence")

Signed-off-by: Brigham Campbell &lt;me@brighamcampbell.com&gt;
Signed-off-by: Tomeu Vizoso &lt;tomeu@tomeuvizoso.net&gt;
Link: https://lore.kernel.org/r/20250802-fix-rockchip-npu-build-v1-1-fb0f0dacb3fe@brighamcampbell.com
</content>
</entry>
<entry>
<title>accel/rocket: Add IOCTLs for synchronizing memory accesses</title>
<updated>2025-07-25T16:04:46Z</updated>
<author>
<name>Tomeu Vizoso</name>
<email>tomeu@tomeuvizoso.net</email>
</author>
<published>2025-07-21T09:17:32Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=525ad89dd90434d529b76a87b1c653a69fedc416'/>
<id>urn:sha1:525ad89dd90434d529b76a87b1c653a69fedc416</id>
<content type='text'>
The NPU cores have their own access to the memory bus, and this isn't
cache coherent with the CPUs.

Add IOCTLs so userspace can mark when the caches need to be flushed, and
also when a writer job needs to be waited for before the buffer can be
accessed from the CPU.

Initially based on the same IOCTLs from the Etnaviv driver.

v2:
- Don't break UABI by reordering the IOCTL IDs (Jeff Hugo)

v3:
- Check that padding fields in IOCTLs are zero (Jeff Hugo)

v6:
- Fix conversion logic to make sure we use DMA_BIDIRECTIONAL when needed
  (Lucas Stach)

v8:
- Always sync BOs in both directions (Robin Murphy)

Reviewed-by: Jeff Hugo &lt;jeff.hugo@oss.qualcomm.com&gt;
Tested-by: Heiko Stuebner &lt;heiko@sntech.de&gt;
Signed-off-by: Tomeu Vizoso &lt;tomeu@tomeuvizoso.net&gt;
Signed-off-by: Jeff Hugo &lt;jeff.hugo@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20250721-6-10-rocket-v9-5-77ebd484941e@tomeuvizoso.net
</content>
</entry>
<entry>
<title>accel/rocket: Add job submission IOCTL</title>
<updated>2025-07-25T16:02:27Z</updated>
<author>
<name>Tomeu Vizoso</name>
<email>tomeu@tomeuvizoso.net</email>
</author>
<published>2025-07-21T09:17:31Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=0810d5ad88a18f1e6d549853a388ad0316f74e36'/>
<id>urn:sha1:0810d5ad88a18f1e6d549853a388ad0316f74e36</id>
<content type='text'>
Using the DRM GPU scheduler infrastructure, with a scheduler for each
core.

Userspace can decide for a series of tasks to be executed sequentially
in the same core, so SRAM locality can be taken advantage of.

The job submission code was initially based on Panfrost.

v2:
- Remove hardcoded number of cores
- Misc. style fixes (Jeffrey Hugo)
- Repack IOCTL struct (Jeffrey Hugo)

v3:
- Adapt to a split of the register block in the DT bindings (Nicolas
  Frattaroli)
- Make use of GPL-2.0-only for the copyright notice (Jeff Hugo)
- Use drm_* logging functions (Thomas Zimmermann)
- Rename reg i/o macros (Thomas Zimmermann)
- Add padding to ioctls and check for zero (Jeff Hugo)
- Improve error handling (Nicolas Frattaroli)

v6:
- Use mutexes guard (Markus Elfring)
- Use u64_to_user_ptr (Jeff Hugo)
- Drop rocket_fence (Rob Herring)

v7:
- Assign its own IOMMU domain to each client, for isolation (Daniel
  Stone and Robin Murphy)

v8:
- Use reset lines to reset the cores (Robin Murphy)
- Use the macros to compute the values for the bitfields (Robin Murphy)
- More descriptive name for the IRQ (Robin Murphy)
- Simplify job interrupt handing (Robin Murphy)
- Correctly acquire a reference to the IOMMU (Robin Murphy)
- Specify the size of the embedded structs in the IOCTLs for future
  extensibility (Rob Herring)
- Expose only 32 bits for the address of the regcmd BO (Robin Murphy)

Tested-by: Heiko Stuebner &lt;heiko@sntech.de&gt;
Reviewed-by: Jeff Hugo &lt;jeff.hugo@oss.qualcomm.com&gt;
Signed-off-by: Tomeu Vizoso &lt;tomeu@tomeuvizoso.net&gt;
Signed-off-by: Jeff Hugo &lt;jeff.hugo@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20250721-6-10-rocket-v9-4-77ebd484941e@tomeuvizoso.net
</content>
</entry>
<entry>
<title>accel/rocket: Add IOCTL for BO creation</title>
<updated>2025-07-25T16:00:36Z</updated>
<author>
<name>Tomeu Vizoso</name>
<email>tomeu@tomeuvizoso.net</email>
</author>
<published>2025-07-21T09:17:30Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=658ebeac33517bd3169d4b65ed801e9065d0211a'/>
<id>urn:sha1:658ebeac33517bd3169d4b65ed801e9065d0211a</id>
<content type='text'>
This uses the SHMEM DRM helpers and we map right away to the CPU and NPU
sides, as all buffers are expected to be accessed from both.

v2:
- Sync the IOMMUs for the other cores when mapping and unmapping.

v3:
- Make use of GPL-2.0-only for the copyright notice (Jeff Hugo)

v6:
- Use mutexes guard (Markus Elfring)

v7:
- Assign its own IOMMU domain to each client, for isolation (Daniel
  Stone and Robin Murphy)

v8:
- Correctly acquire a reference to the IOMMU (Robin Murphy)
- Allocate DMA address ourselves with drm_mm (Robin Murphy)
- Use refcount_read (Heiko Stuebner)
- Remove superfluous dma_sync_sgtable_for_device (Robin Murphy)

Reviewed-by: Jeffrey Hugo &lt;quic_jhugo@quicinc.com&gt;
Tested-by: Heiko Stuebner &lt;heiko@sntech.de&gt;
Signed-off-by: Tomeu Vizoso &lt;tomeu@tomeuvizoso.net&gt;
Signed-off-by: Jeff Hugo &lt;jeff.hugo@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20250721-6-10-rocket-v9-3-77ebd484941e@tomeuvizoso.net
</content>
</entry>
</feed>
