]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
Merge branches 'tracing/ftrace', 'tracing/kprobes', 'tracing/tasks' and 'linus' into...
authorIngo Molnar <mingo@elte.hu>
Fri, 20 Mar 2009 09:14:53 +0000 (10:14 +0100)
committerIngo Molnar <mingo@elte.hu>
Fri, 20 Mar 2009 09:14:53 +0000 (10:14 +0100)
1  2  3  4 
Makefile
kernel/module.c
kernel/trace/trace.c

diff --cc Makefile
Simple merge
diff --cc kernel/module.c
Simple merge
index a2d13e8c8fd880da0a91b179c2da6894e263cc0c,1ce6208fd727205f25850e2ed13aa63265da76f0,305c562dae2aa02bef0a8bd488db96b569bafc34,17bb88d86ac2fead9cb0bacc72a338c2d8d798c4..c95b7292be7000143edfbb0d375ecc3eacbd2f49
@@@@@ -313,9 -306,8 -306,8 -287,6 +313,9 @@@@@ static const char *trace_options[] = 
        "userstacktrace",
        "sym-userobj",
        "printk-msg-only",
   +    "context-info",
   +    "latency-format",
 +++    "global-clock",
        NULL
    };
    
@@@@@ -775,37 -767,37 -774,37 -824,33 +782,37 @@@@@ static void trace_save_cmdline(struct t
    
        memcpy(&saved_cmdlines[idx], tsk->comm, TASK_COMM_LEN);
    
   -    spin_unlock(&trace_cmdline_lock);
   +    __raw_spin_unlock(&trace_cmdline_lock);
    }
    
   -char *trace_find_cmdline(int pid)
   +void trace_find_cmdline(int pid, char comm[])
    {
   -    char *cmdline = "<...>";
        unsigned map;
    
   -    if (!pid)
   -            return "<idle>";
   +    if (!pid) {
   +            strcpy(comm, "<idle>");
   +            return;
   +    }
    
   -    if (pid > PID_MAX_DEFAULT)
   -            goto out;
   +    if (pid > PID_MAX_DEFAULT) {
   +            strcpy(comm, "<...>");
   +            return;
   +    }
    
   +    __raw_spin_lock(&trace_cmdline_lock);
        map = map_pid_to_cmdline[pid];
-- -    if (map >= SAVED_CMDLINES)
-- -            goto out;
-- -
--      strcpy(comm, saved_cmdlines[map]);
   -    cmdline = saved_cmdlines[map];
++ +    if (map != NO_CMDLINE_MAP)
++ +            strcpy(comm, saved_cmdlines[map]);
++ +    else
++ +            strcpy(comm, "<...>");
    
-- - out:
   -    return cmdline;
   +    __raw_spin_unlock(&trace_cmdline_lock);
    }
    
    void tracing_record_cmdline(struct task_struct *tsk)
    {
--      if (atomic_read(&trace_record_cmdline_disabled) || !tracing_is_on())
   -    if (atomic_read(&trace_record_cmdline_disabled))
++ +    if (atomic_read(&trace_record_cmdline_disabled) || !tracer_enabled ||
++ +        !tracing_is_on())
                return;
    
        trace_save_cmdline(tsk);