diff mbox

[v2,1/1] allow to enable all tracepoints via alias all

Message ID 1446570199-29893-1-git-send-email-den@openvz.org
State New
Headers show

Commit Message

Denis V. Lunev Nov. 3, 2015, 5:03 p.m. UTC
From: Olga Krishtal <okrishtal@parallels.com>

This will produce a lot of noise but could be usefull when we do this
for a shot perioud of time on customer side to examine unclear problem.

Signed-off-by: Olga Krishtal <okrishtal@parallels.com>
Signed-off-by: Denis V. Lunev <den@openvz.org>
CC: Paolo Bonzini <pbonzini@redhat.com>
CC: Stefan Hajnoczi <stefanha@redhat.com>
---
Changes from v1:
- proper mailing list targeted

 trace/control.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

Markus Armbruster Nov. 3, 2015, 6:40 p.m. UTC | #1
"Denis V. Lunev" <den@openvz.org> writes:

> From: Olga Krishtal <okrishtal@parallels.com>
>
> This will produce a lot of noise but could be usefull when we do this
> for a shot perioud of time on customer side to examine unclear problem.
>
> Signed-off-by: Olga Krishtal <okrishtal@parallels.com>
> Signed-off-by: Denis V. Lunev <den@openvz.org>
> CC: Paolo Bonzini <pbonzini@redhat.com>
> CC: Stefan Hajnoczi <stefanha@redhat.com>
> ---
> Changes from v1:
> - proper mailing list targeted
>
>  trace/control.c | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/trace/control.c b/trace/control.c
> index 9a1e381..75085f6 100644
> --- a/trace/control.c
> +++ b/trace/control.c
> @@ -35,6 +35,9 @@ TraceEvent *trace_event_name(const char *name)
>  
>  static bool pattern_glob(const char *pat, const char *ev)
>  {
> +    if (!(g_strcmp0(pat, "all"))) {
> +        return true;
> +    }
>      while (*pat != '\0' && *ev != '\0') {
>          if (*pat == *ev) {
>              pat++;

What's wrong with '*'?
Denis V. Lunev Nov. 3, 2015, 6:45 p.m. UTC | #2
On 11/03/2015 09:40 PM, Markus Armbruster wrote:
> "Denis V. Lunev" <den@openvz.org> writes:
>
>> From: Olga Krishtal <okrishtal@parallels.com>
>>
>> This will produce a lot of noise but could be usefull when we do this
>> for a shot perioud of time on customer side to examine unclear problem.
>>
>> Signed-off-by: Olga Krishtal <okrishtal@parallels.com>
>> Signed-off-by: Denis V. Lunev <den@openvz.org>
>> CC: Paolo Bonzini <pbonzini@redhat.com>
>> CC: Stefan Hajnoczi <stefanha@redhat.com>
>> ---
>> Changes from v1:
>> - proper mailing list targeted
>>
>>   trace/control.c | 3 +++
>>   1 file changed, 3 insertions(+)
>>
>> diff --git a/trace/control.c b/trace/control.c
>> index 9a1e381..75085f6 100644
>> --- a/trace/control.c
>> +++ b/trace/control.c
>> @@ -35,6 +35,9 @@ TraceEvent *trace_event_name(const char *name)
>>   
>>   static bool pattern_glob(const char *pat, const char *ev)
>>   {
>> +    if (!(g_strcmp0(pat, "all"))) {
>> +        return true;
>> +    }
>>       while (*pat != '\0' && *ev != '\0') {
>>           if (*pat == *ev) {
>>               pat++;
> What's wrong with '*'?
according to our tests plain '*' is not accepted.
It accepts 'bdrv*' or 'qcow2*' but not single '*'.
may be we are doing something wrong.

Den
Denis V. Lunev Nov. 3, 2015, 7:02 p.m. UTC | #3
On 11/03/2015 09:40 PM, Markus Armbruster wrote:
> "Denis V. Lunev" <den@openvz.org> writes:
>
>> From: Olga Krishtal <okrishtal@parallels.com>
>>
>> This will produce a lot of noise but could be usefull when we do this
>> for a shot perioud of time on customer side to examine unclear problem.
>>
>> Signed-off-by: Olga Krishtal <okrishtal@parallels.com>
>> Signed-off-by: Denis V. Lunev <den@openvz.org>
>> CC: Paolo Bonzini <pbonzini@redhat.com>
>> CC: Stefan Hajnoczi <stefanha@redhat.com>
>> ---
>> Changes from v1:
>> - proper mailing list targeted
>>
>>   trace/control.c | 3 +++
>>   1 file changed, 3 insertions(+)
>>
>> diff --git a/trace/control.c b/trace/control.c
>> index 9a1e381..75085f6 100644
>> --- a/trace/control.c
>> +++ b/trace/control.c
>> @@ -35,6 +35,9 @@ TraceEvent *trace_event_name(const char *name)
>>   
>>   static bool pattern_glob(const char *pat, const char *ev)
>>   {
>> +    if (!(g_strcmp0(pat, "all"))) {
>> +        return true;
>> +    }
>>       while (*pat != '\0' && *ev != '\0') {
>>           if (*pat == *ev) {
>>               pat++;
> What's wrong with '*'?
you are right. I have done things wrong. This patch is not needed at all.
diff mbox

Patch

diff --git a/trace/control.c b/trace/control.c
index 9a1e381..75085f6 100644
--- a/trace/control.c
+++ b/trace/control.c
@@ -35,6 +35,9 @@  TraceEvent *trace_event_name(const char *name)
 
 static bool pattern_glob(const char *pat, const char *ev)
 {
+    if (!(g_strcmp0(pat, "all"))) {
+        return true;
+    }
     while (*pat != '\0' && *ev != '\0') {
         if (*pat == *ev) {
             pat++;