linux/drivers/accel/rocket
Quentin Schulz 57d8ae1569 accel/rocket: factor out code with find_core_for_dev in rocket_remove
There already is a function to return the offset of the core for a given
struct device, so let's reuse that function instead of reimplementing
the same logic.

There's one change in behavior when a struct device is passed which
doesn't match any core's. Before, we would continue through
rocket_remove() but now we exit early, to match what other callers of
find_core_for_dev() (rocket_device_runtime_resume/suspend()) are doing.
This however should never happen. Aside from that, no intended change in
behavior.

Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
Reviewed-by: Tomeu Vizoso <tomeu@tomeuvizoso.net>
Signed-off-by: Tomeu Vizoso <tomeu@tomeuvizoso.net>
Link: https://patch.msgid.link/20251215-rocket-reuse-find-core-v1-1-be86a1d2734c@cherry.de
2026-01-10 17:49:14 +01:00
..
Kconfig accel/rocket: Depend on DRM_ACCEL not just DRM 2025-09-01 12:11:28 +02:00
Makefile accel/rocket: Add job submission IOCTL 2025-07-25 10:02:27 -06:00
rocket_core.c accel/rocket: fix unwinding in error path in rocket_core_init 2026-01-10 17:49:14 +01:00
rocket_core.h accel/rocket: Add job submission IOCTL 2025-07-25 10:02:27 -06:00
rocket_device.c accel/rocket: Add job submission IOCTL 2025-07-25 10:02:27 -06:00
rocket_device.h accel/rocket: Add job submission IOCTL 2025-07-25 10:02:27 -06:00
rocket_drv.c accel/rocket: factor out code with find_core_for_dev in rocket_remove 2026-01-10 17:49:14 +01:00
rocket_drv.h accel/rocket: Fix undeclared const rocket_pm_ops 2025-08-03 17:40:23 +02:00
rocket_gem.c drm: include drm_print.h where needed 2025-10-31 10:34:52 +02:00
rocket_gem.h accel/rocket: Add IOCTLs for synchronizing memory accesses 2025-07-25 10:04:46 -06:00
rocket_job.c accel/rocket: Check the correct DMA irq status to warn about 2025-09-01 12:11:28 +02:00
rocket_job.h accel/rocket: Add job submission IOCTL 2025-07-25 10:02:27 -06:00
rocket_registers.h