Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f1b3b636 authored by Christopher Ferris's avatar Christopher Ferris Committed by android-build-merger
Browse files

Merge "Update for kernel headers v4.7.2." am: 73d2cc57 am: c4abab85

am: 99bb22da

Change-Id: I7f4a1e252b2eef6604fcc6f4a97ea60e1dd30238
parents 5fc94d2c 99bb22da
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -135,9 +135,14 @@ static const char* get_sigcode(int signo, int code) {
        case SEGV_ACCERR: return "SEGV_ACCERR";
#if defined(SEGV_BNDERR)
        case SEGV_BNDERR: return "SEGV_BNDERR";
#endif
#if defined(SEGV_PKUERR)
        case SEGV_PKUERR: return "SEGV_PKUERR";
#endif
      }
#if defined(SEGV_BNDERR)
#if defined(SEGV_PKUERR)
      static_assert(NSIGSEGV == SEGV_PKUERR, "missing SEGV_* si_code");
#elif defined(SEGV_BNDERR)
      static_assert(NSIGSEGV == SEGV_BNDERR, "missing SEGV_* si_code");
#else
      static_assert(NSIGSEGV == SEGV_ACCERR, "missing SEGV_* si_code");
+15 −1
Original line number Diff line number Diff line
@@ -21,13 +21,27 @@
#include <stdint.h>
#include <string.h>

#include <linux/sync.h>
#include <linux/sw_sync.h>

#include <sys/ioctl.h>
#include <sys/stat.h>
#include <sys/types.h>

#include <sync/sync.h>

// The sync code is undergoing a major change. Add enough in to get
// everything to compile wih the latest uapi headers.
struct sync_merge_data {
  int32_t fd2;
  char name[32];
  int32_t fence;
};

#define SYNC_IOC_MAGIC '>'
#define SYNC_IOC_WAIT _IOW(SYNC_IOC_MAGIC, 0, __s32)
#define SYNC_IOC_MERGE _IOWR(SYNC_IOC_MAGIC, 1, struct sync_merge_data)
#define SYNC_IOC_FENCE_INFO _IOWR(SYNC_IOC_MAGIC, 2, struct sync_fence_info_data)

int sync_wait(int fd, int timeout)
{
    __s32 to = timeout;