summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/parallel-perf.py
diff options
context:
space:
mode:
authorDanilo Krummrich <dakr@kernel.org>2026-06-28 16:53:33 +0200
committerDanilo Krummrich <dakr@kernel.org>2026-07-12 15:59:28 +0200
commit478da53e5b682f0c39a4c6c3eeb09c0131342e8a (patch)
treee03dbefe6d3fa8987b525abd3075e77f63714b18 /tools/perf/scripts/python/parallel-perf.py
parent2455d5f2d5e879b42fe6ab3207b7e3f4b9c78383 (diff)
rust: drm: Wrap ioctl dispatch in RegistrationGuard
Make Ioctl handlers receive a &Device<T, Registered> reference, proving at the type level that the device is registered and its parent bus device is bound. This is achieved by calling registration_guard() on the Device<T, Ioctl> obtained in ioctl dispatch context. If the device has been unplugged, the ioctl returns -ENODEV without calling the handler. To resolve the driver type parameter T for type inference, which the compiler cannot propagate through method resolution and associated-type projections alone, a dead-code closure and a helper function are used as a type-inference anchor. Reviewed-by: Lyude Paul <lyude@redhat.com> Reviewed-by: Alexandre Courbot <acourbot@nvidia.com> Tested-by: Deborah Brouwer <deborah.brouwer@collabora.com> Link: https://patch.msgid.link/20260628145406.2107056-14-dakr@kernel.org [ Use imperative mood in commit message; clarify __dev_ctx_cast() doc comment to reflect Ioctl-to-Registered cast. - Danilo ] Signed-off-by: Danilo Krummrich <dakr@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/parallel-perf.py')
0 files changed, 0 insertions, 0 deletions