Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 117985
b: refs/heads/master
c: c513867
h: refs/heads/master
i:
  117983: 7caff22
v: v3
  • Loading branch information
Steven Rostedt authored and Ingo Molnar committed Oct 20, 2008
1 parent 7998493 commit f7d1f5a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 3e10e879a8c334a5927d800a3663a24d562cfa31
refs/heads/master: c513867561eeb07d24a0bdda1a18a8f91921a301
6 changes: 4 additions & 2 deletions trunk/arch/x86/kernel/ftrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ ftrace_modify_code(unsigned long ip, unsigned char *old_code,
unsigned char *new_code)
{
unsigned char replaced[MCOUNT_INSN_SIZE];
int ret;

/*
* Note: Due to modules and __init, code can
Expand All @@ -77,8 +78,9 @@ ftrace_modify_code(unsigned long ip, unsigned char *old_code,
if (memcmp(replaced, old_code, MCOUNT_INSN_SIZE) != 0)
return 2;

WARN_ON_ONCE(__copy_to_user_inatomic((char __user *)ip, new_code,
MCOUNT_INSN_SIZE));
ret = __copy_to_user_inatomic((char __user *)ip, new_code,
MCOUNT_INSN_SIZE);
WARN_ON_ONCE(ret);

sync_core();

Expand Down

0 comments on commit f7d1f5a

Please sign in to comment.