diff options
| author | David Gow <[email protected]> | 2023-11-28 07:24:06 +0000 |
|---|---|---|
| committer | Shuah Khan <[email protected]> | 2023-12-18 20:21:14 +0000 |
| commit | e847934bb124b2ad14bf967d6682e43b0b94c78a (patch) | |
| tree | 9f9572852cbda7c173e5121fbfdd3c9b919e34e6 /lib/kunit/string-stream-test.c | |
| parent | kunit: Add a macro to wrap a deferred action function (diff) | |
| download | kernel-e847934bb124b2ad14bf967d6682e43b0b94c78a.tar.gz kernel-e847934bb124b2ad14bf967d6682e43b0b94c78a.zip | |
drm/tests: Use KUNIT_DEFINE_ACTION_WRAPPER()
In order to pass functions to kunit_add_action(), they need to be of the
kunit_action_t type. While casting the function pointer can work, it
will break control-flow integrity.
drm_kunit_helpers already defines wrappers, but we now have a macro
which does this automatically. Using this greatly reduces the
boilerplate needed.
Acked-by: Maxime Ripard <[email protected]>
Signed-off-by: David Gow <[email protected]>
Signed-off-by: Shuah Khan <[email protected]>
Diffstat (limited to 'lib/kunit/string-stream-test.c')
0 files changed, 0 insertions, 0 deletions
