diff options
author | Tejun Heo <tj@kernel.org> | 2009-07-03 18:13:18 -0400 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2009-07-03 18:13:18 -0400 |
commit | c43768cbb7655ea5ff782ae250f6e2ef4297cf98 (patch) | |
tree | 3982e41dde3eecaa3739a5d1a8ed18d04bd74f01 /arch/s390/kernel/kprobes.c | |
parent | 1a8dd307cc0a2119be4e578c517795464e6dabba (diff) | |
parent | 746a99a5af60ee676afa2ba469ccd1373493c7e7 (diff) |
Merge branch 'master' into for-next
Pull linus#master to merge PER_CPU_DEF_ATTRIBUTES and alpha build fix
changes. As alpha in percpu tree uses 'weak' attribute instead of
inline assembly, there's no need for __used attribute.
Conflicts:
arch/alpha/include/asm/percpu.h
arch/mn10300/kernel/vmlinux.lds.S
include/linux/percpu-defs.h
Diffstat (limited to 'arch/s390/kernel/kprobes.c')
-rw-r--r-- | arch/s390/kernel/kprobes.c | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/arch/s390/kernel/kprobes.c b/arch/s390/kernel/kprobes.c index 9bb2f6241d9f..86783efa24ee 100644 --- a/arch/s390/kernel/kprobes.c +++ b/arch/s390/kernel/kprobes.c | |||
@@ -154,39 +154,35 @@ void __kprobes get_instruction_type(struct arch_specific_insn *ainsn) | |||
154 | 154 | ||
155 | static int __kprobes swap_instruction(void *aref) | 155 | static int __kprobes swap_instruction(void *aref) |
156 | { | 156 | { |
157 | struct kprobe_ctlblk *kcb = get_kprobe_ctlblk(); | ||
158 | unsigned long status = kcb->kprobe_status; | ||
157 | struct ins_replace_args *args = aref; | 159 | struct ins_replace_args *args = aref; |
160 | int rc; | ||
158 | 161 | ||
159 | return probe_kernel_write(args->ptr, &args->new, sizeof(args->new)); | 162 | kcb->kprobe_status = KPROBE_SWAP_INST; |
163 | rc = probe_kernel_write(args->ptr, &args->new, sizeof(args->new)); | ||
164 | kcb->kprobe_status = status; | ||
165 | return rc; | ||
160 | } | 166 | } |
161 | 167 | ||
162 | void __kprobes arch_arm_kprobe(struct kprobe *p) | 168 | void __kprobes arch_arm_kprobe(struct kprobe *p) |
163 | { | 169 | { |
164 | struct kprobe_ctlblk *kcb = get_kprobe_ctlblk(); | ||
165 | unsigned long status = kcb->kprobe_status; | ||
166 | struct ins_replace_args args; | 170 | struct ins_replace_args args; |
167 | 171 | ||
168 | args.ptr = p->addr; | 172 | args.ptr = p->addr; |
169 | args.old = p->opcode; | 173 | args.old = p->opcode; |
170 | args.new = BREAKPOINT_INSTRUCTION; | 174 | args.new = BREAKPOINT_INSTRUCTION; |
171 | |||
172 | kcb->kprobe_status = KPROBE_SWAP_INST; | ||
173 | stop_machine(swap_instruction, &args, NULL); | 175 | stop_machine(swap_instruction, &args, NULL); |
174 | kcb->kprobe_status = status; | ||
175 | } | 176 | } |
176 | 177 | ||
177 | void __kprobes arch_disarm_kprobe(struct kprobe *p) | 178 | void __kprobes arch_disarm_kprobe(struct kprobe *p) |
178 | { | 179 | { |
179 | struct kprobe_ctlblk *kcb = get_kprobe_ctlblk(); | ||
180 | unsigned long status = kcb->kprobe_status; | ||
181 | struct ins_replace_args args; | 180 | struct ins_replace_args args; |
182 | 181 | ||
183 | args.ptr = p->addr; | 182 | args.ptr = p->addr; |
184 | args.old = BREAKPOINT_INSTRUCTION; | 183 | args.old = BREAKPOINT_INSTRUCTION; |
185 | args.new = p->opcode; | 184 | args.new = p->opcode; |
186 | |||
187 | kcb->kprobe_status = KPROBE_SWAP_INST; | ||
188 | stop_machine(swap_instruction, &args, NULL); | 185 | stop_machine(swap_instruction, &args, NULL); |
189 | kcb->kprobe_status = status; | ||
190 | } | 186 | } |
191 | 187 | ||
192 | void __kprobes arch_remove_kprobe(struct kprobe *p) | 188 | void __kprobes arch_remove_kprobe(struct kprobe *p) |