mirror of
https://github.com/torvalds/linux.git
synced 2024-11-01 09:41:44 +00:00
s390/kprobes: have more correct if statement in s390_get_insn_slot()
When checking the insn address wether it is a kernel image or module address it should be an if-else-if statement not two independent if statements. This doesn't really fix a bug, but matches s390_free_insn_slot(). Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
This commit is contained in:
parent
faf499dfcc
commit
fcd05b50fc
@ -252,7 +252,7 @@ static int __kprobes s390_get_insn_slot(struct kprobe *p)
|
||||
p->ainsn.insn = NULL;
|
||||
if (is_kernel_addr(p->addr))
|
||||
p->ainsn.insn = get_dmainsn_slot();
|
||||
if (is_module_addr(p->addr))
|
||||
else if (is_module_addr(p->addr))
|
||||
p->ainsn.insn = get_insn_slot();
|
||||
return p->ainsn.insn ? 0 : -ENOMEM;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user