lkml.org 
[lkml]   [2017]   [Nov]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] perf/core: Enable the bp only if the .disable field is 0.
Date
Signed-off-by: Milind Chabbi <chabbi.milind@gmail.com>
---
kernel/events/core.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/kernel/events/core.c b/kernel/events/core.c
index 35747a58ffb4..1b8eae85e9de 100644
--- a/kernel/events/core.c
+++ b/kernel/events/core.c
@@ -2659,7 +2659,8 @@ static int perf_event_modify_breakpoint(struct perf_event *bp,
return err;
}

- _perf_event_enable(bp);
+ if (!attr->disabled)
+ _perf_event_enable(bp);
return 0;
}

--
2.14.1
\
 
 \ /
  Last update: 2017-11-27 07:46    [W:0.039 / U:1.624 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site