• Jon Medhurst's avatar
    ARM: kprobes: Add Thumb breakpoint support · aceb487a
    Jon Medhurst authored
    Extend the breakpoint insertion and catching functions to support Thumb
    code.
    
    As breakpoints are no longer of a fixed size, the flush_insns macro
    is modified to take a size argument instead of an instruction count.
    
    Note, we need both 16- and 32-bit Thumb breakpoints, because if we
    were to use a 16-bit breakpoint to replace a 32-bit instruction which
    was in an IT block, and the condition check failed, then the breakpoint
    may not fire (it's unpredictable behaviour) and the CPU could then try
    and execute the second half of the 32-bit Thumb instruction.
    Signed-off-by: default avatarJon Medhurst <tixy@yxit.co.uk>
    Acked-by: default avatarNicolas Pitre <nicolas.pitre@linaro.org>
    aceb487a
kprobes.h 2.02 KB