lkml.org 
[lkml]   [2009]   [Dec]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 06/13] function-graph: Allow writing the same val to set_graph_function
From
2009/12/7 Li Zefan <lizf@cn.fujitsu.com>:
>  # echo 'do_open' > set_graph_function
>  # echo 'do_open' >> set_graph_function
>  bash: echo: write error: Invalid argument
>
> Make it valid to write the same value to set_graph_function,
> which is consistent with set_ftrace_filter interface.
>
> Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>


Acked-by: Frederic Weisbecker <fweisbec@gmail.com>


> ---
>  kernel/trace/ftrace.c |    5 ++---
>  1 files changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
> index ff8aecd..7968762 100644
> --- a/kernel/trace/ftrace.c
> +++ b/kernel/trace/ftrace.c
> @@ -2552,10 +2552,9 @@ ftrace_set_func(unsigned long *array, int *idx, char *buffer)
>                                        exists = true;
>                                        break;
>                                }
> -                       if (!exists) {
> +                       if (!exists)
>                                array[(*idx)++] = rec->ip;
> -                               found = 1;
> -                       }
> +                       found = 1;
>                }
>        } while_for_each_ftrace_rec();
>
> --
> 1.6.3
>
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2009-12-07 15:45    [W:1.531 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site