aboutsummaryrefslogtreecommitdiff
path: root/scripts/gdb/linux/utils.py
diff options
context:
space:
mode:
authorChristophe Leroy <[email protected]>2022-02-15 13:41:07 +0100
committerMichael Ellerman <[email protected]>2022-02-16 23:25:12 +1100
commit72a86433049dcfe918886645ac3d19c1eaaa67ab (patch)
tree0f3d48d5d295ef2d4a98f86929e088e0426b6c2b /scripts/gdb/linux/utils.py
parentb64913394f123e819bffabc79a0e48f98e78dc5d (diff)
lkdtm: Fix execute_[user]_location()
execute_location() and execute_user_location() intent to copy do_nothing() text and execute it at a new location. However, at the time being it doesn't copy do_nothing() function but do_nothing() function descriptor which still points to the original text. So at the end it still executes do_nothing() at its original location allthough using a copied function descriptor. So, fix that by really copying do_nothing() text and build a new function descriptor by copying do_nothing() function descriptor and updating the target address with the new location. Also fix the displayed addresses by dereferencing do_nothing() function descriptor. Signed-off-by: Christophe Leroy <[email protected]> Acked-by: Kees Cook <[email protected]> Signed-off-by: Michael Ellerman <[email protected]> Link: https://lore.kernel.org/r/4055839683d8d643cd99be121f4767c7c611b970.1644928018.git.christophe.leroy@csgroup.eu
Diffstat (limited to 'scripts/gdb/linux/utils.py')
0 files changed, 0 insertions, 0 deletions