Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 121259
b: refs/heads/master
c: faec2ec
h: refs/heads/master
i:
  121257: f77ed0c
  121255: 5793eb9
v: v3
  • Loading branch information
Liming Wang authored and Ingo Molnar committed Dec 4, 2008
1 parent cb9e650 commit f909b55
Show file tree
Hide file tree
Showing 2 changed files with 9 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: 6b2539302bee8e88c99e3c7d80c16a04dbe5e2ad
refs/heads/master: faec2ec505d397e9426754722b6e80d519c4938f
10 changes: 8 additions & 2 deletions trunk/kernel/trace/ftrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -1425,7 +1425,7 @@ ftrace_set_func(unsigned long *array, int idx, char *buffer)
struct dyn_ftrace *rec;
struct ftrace_page *pg;
int found = 0;
int i;
int i, j;

if (ftrace_disabled)
return -ENODEV;
Expand All @@ -1443,7 +1443,13 @@ ftrace_set_func(unsigned long *array, int idx, char *buffer)
kallsyms_lookup(rec->ip, NULL, NULL, NULL, str);
if (strcmp(str, buffer) == 0) {
found = 1;
array[idx] = rec->ip;
for (j = 0; j < idx; j++)
if (array[j] == rec->ip) {
found = 0;
break;
}
if (found)
array[idx] = rec->ip;
break;
}
}
Expand Down

0 comments on commit f909b55

Please sign in to comment.