• Heiko Carstens's avatar
    s390/kprobes: move insn_page to text segment · b61e1f32
    Heiko Carstens authored
    Move the in-kernel kprobes insn page to text segment. Rationale:
    having that page in rw data segment is suboptimal, since as soon as a
    kprobe is set, this will split the 1:1 kernel mapping for a single
    page which get new permissions.
    
    Note: there is always at least one kprobe present for the kretprobe
    trampoline; so the mapping will always be split into smaller 4k
    mappings because of this.
    
    Moving the kprobes insn page into text segment makes sure that the
    page is mapped RO/X in any case, and avoids that the 1:1 mapping is
    split.
    
    The kprobe insn_page is defined as a dummy function which is filled
    with "br %r14" instructions.
    Signed-off-by: default avatarHeiko Carstens <hca@linux.ibm.com>
    Signed-off-by: default avatarVasily Gorbik <gor@linux.ibm.com>
    b61e1f32
Makefile 2.59 KB