[Intel-gfx] [PATCH] uapi/perf: Squelch compiler warning

Chris Wilson chris at chris-wilson.co.uk
Sat Jul 27 12:17:50 UTC 2019


Remove copious amounts of
./include/uapi/linux/perf_event.h:147:56: warning: cast truncates bits from constant value (8000000000000000 becomes 0)
as they are drowning out our warnings.

Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
---
 include/uapi/linux/perf_event.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/uapi/linux/perf_event.h b/include/uapi/linux/perf_event.h
index 7198ddd0c6b1..9c5f958106b0 100644
--- a/include/uapi/linux/perf_event.h
+++ b/include/uapi/linux/perf_event.h
@@ -144,8 +144,8 @@ enum perf_event_sample_format {
 
 	PERF_SAMPLE_MAX = 1U << 20,		/* non-ABI */
 
-	__PERF_SAMPLE_CALLCHAIN_EARLY		= 1ULL << 63, /* non-ABI; internal use */
 };
+#define __PERF_SAMPLE_CALLCHAIN_EARLY	(1ULL << 63) /* non-ABI; internal use */
 
 /*
  * values to program into branch_sample_type when PERF_SAMPLE_BRANCH is set
-- 
2.22.0



More information about the Intel-gfx mailing list