Skip to content

Commit 26a3b01

Browse files
committed
Merge tag 'trace-v5.1-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace
Pull tracing fixes from Steven Rostedt: "Three small fixes: - A fix to a double free in the histogram code - Uninitialized variable fix - Use NULL instead of zero fix and spelling fixes" * tag 'trace-v5.1-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: ftrace: Fix warning using plain integer as NULL & spelling corrections tracing: initialize variable in create_dyn_event() tracing: Remove unnecessary var_ref destroy in track_data_destroy()
2 parents 9798a22 + 9efb85c commit 26a3b01

3 files changed

Lines changed: 7 additions & 8 deletions

File tree

kernel/trace/ftrace.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1992,7 +1992,7 @@ static void print_bug_type(void)
19921992
* modifying the code. @failed should be one of either:
19931993
* EFAULT - if the problem happens on reading the @ip address
19941994
* EINVAL - if what is read at @ip is not what was expected
1995-
* EPERM - if the problem happens on writting to the @ip address
1995+
* EPERM - if the problem happens on writing to the @ip address
19961996
*/
19971997
void ftrace_bug(int failed, struct dyn_ftrace *rec)
19981998
{
@@ -2391,7 +2391,7 @@ __ftrace_replace_code(struct dyn_ftrace *rec, int enable)
23912391
return ftrace_modify_call(rec, ftrace_old_addr, ftrace_addr);
23922392
}
23932393

2394-
return -1; /* unknow ftrace bug */
2394+
return -1; /* unknown ftrace bug */
23952395
}
23962396

23972397
void __weak ftrace_replace_code(int mod_flags)
@@ -3004,7 +3004,7 @@ ftrace_allocate_pages(unsigned long num_to_init)
30043004
int cnt;
30053005

30063006
if (!num_to_init)
3007-
return 0;
3007+
return NULL;
30083008

30093009
start_pg = pg = kzalloc(sizeof(*pg), GFP_KERNEL);
30103010
if (!pg)
@@ -4755,7 +4755,7 @@ static int
47554755
ftrace_set_addr(struct ftrace_ops *ops, unsigned long ip, int remove,
47564756
int reset, int enable)
47574757
{
4758-
return ftrace_set_hash(ops, 0, 0, ip, remove, reset, enable);
4758+
return ftrace_set_hash(ops, NULL, 0, ip, remove, reset, enable);
47594759
}
47604760

47614761
/**
@@ -5463,7 +5463,7 @@ void ftrace_create_filter_files(struct ftrace_ops *ops,
54635463

54645464
/*
54655465
* The name "destroy_filter_files" is really a misnomer. Although
5466-
* in the future, it may actualy delete the files, but this is
5466+
* in the future, it may actually delete the files, but this is
54675467
* really intended to make sure the ops passed in are disabled
54685468
* and that when this function returns, the caller is free to
54695469
* free the ops.
@@ -5786,7 +5786,7 @@ void ftrace_module_enable(struct module *mod)
57865786
/*
57875787
* If the tracing is enabled, go ahead and enable the record.
57885788
*
5789-
* The reason not to enable the record immediatelly is the
5789+
* The reason not to enable the record immediately is the
57905790
* inherent check of ftrace_make_nop/ftrace_make_call for
57915791
* correct previous instructions. Making first the NOP
57925792
* conversion puts the module to the correct state, thus

kernel/trace/trace_dynevent.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ int dyn_event_release(int argc, char **argv, struct dyn_event_operations *type)
7474
static int create_dyn_event(int argc, char **argv)
7575
{
7676
struct dyn_event_operations *ops;
77-
int ret;
77+
int ret = -ENODEV;
7878

7979
if (argv[0][0] == '-' || argv[0][0] == '!')
8080
return dyn_event_release(argc, argv, NULL);

kernel/trace/trace_events_hist.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3713,7 +3713,6 @@ static void track_data_destroy(struct hist_trigger_data *hist_data,
37133713
struct trace_event_file *file = hist_data->event_file;
37143714

37153715
destroy_hist_field(data->track_data.track_var, 0);
3716-
destroy_hist_field(data->track_data.var_ref, 0);
37173716

37183717
if (data->action == ACTION_SNAPSHOT) {
37193718
struct track_data *track_data;

0 commit comments

Comments
 (0)