mirror of
https://kernel.googlesource.com/pub/scm/linux/kernel/git/stable/linux-stable.git
synced 2025-09-13 11:07:46 +10:00
kunit: Fix wrong parameter to kunit_deactivate_static_stub()
[ Upstream commit772e50a76e
] kunit_deactivate_static_stub() accepts real_fn_addr instead of replacement_addr. In the case, it always passes NULL to kunit_deactivate_static_stub(). Fix it. Link: https://lore.kernel.org/r/20250520082050.2254875-1-tzungbi@kernel.org Fixes:e047c5eaa7
("kunit: Expose 'static stub' API to redirect functions") Signed-off-by: Tzung-Bi Shih <tzungbi@kernel.org> Reviewed-by: David Gow <davidgow@google.com> Signed-off-by: Shuah Khan <skhan@linuxfoundation.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
5810e9d402
commit
f6941e72d3
@ -96,7 +96,7 @@ void __kunit_activate_static_stub(struct kunit *test,
|
||||
|
||||
/* If the replacement address is NULL, deactivate the stub. */
|
||||
if (!replacement_addr) {
|
||||
kunit_deactivate_static_stub(test, replacement_addr);
|
||||
kunit_deactivate_static_stub(test, real_fn_addr);
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user