#include <linux/input.h>
#include <linux/if_link.h>
#include <linux/loop.h>
+#include <linux/audit.h>
#ifdef HAVE_AUDIT
#include <libaudit.h>
# elif defined __arm__
# define __NR_memfd_create 385
# elif defined _MIPS_SIM
-# warning "__NR_memfd_create not yet defined for MIPS"
-# define __NR_memfd_create 0xffffffff
+# if _MIPS_SIM == _MIPS_SIM_ABI32
+# define __NR_memfd_create 4354
+# endif
+# if _MIPS_SIM == _MIPS_SIM_NABI32
+# define __NR_memfd_create 6318
+# endif
+# if _MIPS_SIM == _MIPS_SIM_ABI64
+# define __NR_memfd_create 5314
+# endif
# else
# define __NR_memfd_create 356
# endif
#ifndef LOOPBACK_IFINDEX
#define LOOPBACK_IFINDEX 1
#endif
+
+#ifndef MAX_AUDIT_MESSAGE_LENGTH
+#define MAX_AUDIT_MESSAGE_LENGTH 8970
+#endif
+
+#ifndef AUDIT_NLGRP_MAX
+#define AUDIT_NLGRP_READLOG 1
+#endif