From 6a11f92ef449bfb87f93e7cc14cb2a717afc7aa3 Mon Sep 17 00:00:00 2001 From: Jiri Olsa Date: Wed, 16 May 2012 08:59:04 +0200 Subject: perf tools: Add union u64_swap type for swapping u64 data The following union: union { u64 val64; u32 val32[2]; } u; is used on more than one place in perf code and will be used more in upcomming patches. Adding union u64_swap to have it defined globaly so we dont need to redefine it all the time. Signed-off-by: Jiri Olsa Reviewed-by: David Ahern Tested-by: David Ahern Cc: Corey Ashford Cc: David Ahern Cc: Frederic Weisbecker Cc: Ingo Molnar Cc: Paul Mackerras Cc: Peter Zijlstra Link: http://lkml.kernel.org/r/1337151548-2396-4-git-send-email-jolsa@redhat.com Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/util/types.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'tools/perf/util/types.h') diff --git a/tools/perf/util/types.h b/tools/perf/util/types.h index 5f3689a3d08..c51fa6b70a2 100644 --- a/tools/perf/util/types.h +++ b/tools/perf/util/types.h @@ -16,4 +16,9 @@ typedef signed short s16; typedef unsigned char u8; typedef signed char s8; +union u64_swap { + u64 val64; + u32 val32[2]; +}; + #endif /* __PERF_TYPES_H */ -- cgit v1.2.3