diff options
author | Anshuman Khandual <anshuman.khandual@arm.com> | 2022-09-07 12:19:22 +0300 |
---|---|---|
committer | Peter Zijlstra <peterz@infradead.org> | 2022-09-07 22:54:00 +0300 |
commit | f67dd218fafd9de9a13d095e775b621db76a058f (patch) | |
tree | 97e83cc21a7e6740fd7bae1d368a92115f3e256a /include/linux/perf_event.h | |
parent | 7517f08b9a5eef0fa683b976c97d6178d00e6a3d (diff) | |
download | linux-f67dd218fafd9de9a13d095e775b621db76a058f.tar.xz |
perf/core: Assert PERF_EVENT_FLAG_ARCH does not overlap with generic flags
This just ensures that PERF_EVENT_FLAG_ARCH does not overlap with generic
hardware event flags.
Signed-off-by: Anshuman Khandual <anshuman.khandual@arm.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: James Clark <james.clark@arm.com>
Link: https://lkml.kernel.org/r/20220907091924.439193-3-anshuman.khandual@arm.com
Diffstat (limited to 'include/linux/perf_event.h')
-rw-r--r-- | include/linux/perf_event.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h index 3e3c07512b75..f88cb31eaf75 100644 --- a/include/linux/perf_event.h +++ b/include/linux/perf_event.h @@ -141,6 +141,8 @@ struct hw_perf_event_extra { #define PERF_EVENT_FLAG_ARCH 0x000fffff #define PERF_EVENT_FLAG_USER_READ_CNT 0x80000000 +static_assert((PERF_EVENT_FLAG_USER_READ_CNT & PERF_EVENT_FLAG_ARCH) == 0); + /** * struct hw_perf_event - performance event hardware details: */ |