6a11f92ef4
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 <jolsa@redhat.com> Reviewed-by: David Ahern <dsahern@gmail.com> Tested-by: David Ahern <dsahern@gmail.com> Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1337151548-2396-4-git-send-email-jolsa@redhat.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
25 lines
494 B
C
25 lines
494 B
C
#ifndef __PERF_TYPES_H
|
|
#define __PERF_TYPES_H
|
|
|
|
#include <stdint.h>
|
|
|
|
/*
|
|
* We define u64 as uint64_t for every architecture
|
|
* so that we can print it with "%"PRIx64 without getting warnings.
|
|
*/
|
|
typedef uint64_t u64;
|
|
typedef int64_t s64;
|
|
typedef unsigned int u32;
|
|
typedef signed int s32;
|
|
typedef unsigned short u16;
|
|
typedef signed short s16;
|
|
typedef unsigned char u8;
|
|
typedef signed char s8;
|
|
|
|
union u64_swap {
|
|
u64 val64;
|
|
u32 val32[2];
|
|
};
|
|
|
|
#endif /* __PERF_TYPES_H */
|