| * Jump label s390 support |
| * Copyright IBM Corp. 2011 |
| * Author(s): Jan Glauber <jang@linux.vnet.ibm.com> |
| #include <linux/module.h> |
| #include <linux/uaccess.h> |
| #include <linux/stop_machine.h> |
| #include <linux/jump_label.h> |
| static int __arch_jump_label_transform(void *data) |
| struct insn_args *args = data; |
| rc = probe_kernel_write(args->target, args->insn, args->size); |
| void arch_jump_label_transform(struct jump_entry *entry, |
| enum jump_label_type type) |
| if (type == JUMP_LABEL_ENABLE) { |
| insn.offset = (entry->target - entry->code) >> 1; |
| args.target = (void *) entry->code; |
| args.size = JUMP_LABEL_NOP_SIZE; |
| stop_machine(__arch_jump_label_transform, &args, NULL); |