mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
perf tools: Move conditional O_CLOEXEC to util.h
To be more generally available and get the build on centos:5 to work after we use O_CLOEXEC in the next patch, in the util/dso.c file. Cc: Adrian Hunter <[email protected]> Cc: Alexander Shishkin <[email protected]> Cc: David Ahern <[email protected]> Cc: Jiri Olsa <[email protected]> Cc: Namhyung Kim <[email protected]> Cc: Wang Nan <[email protected]> Cc: Wang YanQing <[email protected]> Link: https://lkml.kernel.org/n/[email protected] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
This commit is contained in:
parent
872523233d
commit
5c61d70e55
2 changed files with 10 additions and 10 deletions
|
|
@ -12,16 +12,6 @@
|
|||
#include "util.h"
|
||||
#include "debug.h"
|
||||
|
||||
#ifndef O_CLOEXEC
|
||||
#ifdef __sparc__
|
||||
#define O_CLOEXEC 0x400000
|
||||
#elif defined(__alpha__) || defined(__hppa__)
|
||||
#define O_CLOEXEC 010000000
|
||||
#else
|
||||
#define O_CLOEXEC 02000000
|
||||
#endif
|
||||
#endif
|
||||
|
||||
static bool check_pipe(struct perf_data *data)
|
||||
{
|
||||
struct stat st;
|
||||
|
|
|
|||
|
|
@ -68,4 +68,14 @@ extern bool perf_singlethreaded;
|
|||
void perf_set_singlethreaded(void);
|
||||
void perf_set_multithreaded(void);
|
||||
|
||||
#ifndef O_CLOEXEC
|
||||
#ifdef __sparc__
|
||||
#define O_CLOEXEC 0x400000
|
||||
#elif defined(__alpha__) || defined(__hppa__)
|
||||
#define O_CLOEXEC 010000000
|
||||
#else
|
||||
#define O_CLOEXEC 02000000
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#endif /* GIT_COMPAT_UTIL_H */
|
||||
|
|
|
|||
Loading…
Reference in a new issue