Merge "Wrap more system calls in TEMP_FAILURE_RETRY." into jb-mr1-dev
diff --git a/charger/charger.c b/charger/charger.c
index abf5517..76be076 100644
--- a/charger/charger.c
+++ b/charger/charger.c
@@ -21,19 +21,20 @@
 #include <errno.h>
 #include <fcntl.h>
 #include <linux/input.h>
-#include <linux/netlink.h>
 #include <stdbool.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
 #include <sys/poll.h>
-#include <sys/socket.h>
 #include <sys/stat.h>
 #include <sys/types.h>
 #include <sys/un.h>
 #include <time.h>
 #include <unistd.h>
 
+#include <sys/socket.h>
+#include <linux/netlink.h>
+
 #include <cutils/android_reboot.h>
 #include <cutils/klog.h>
 #include <cutils/list.h>
diff --git a/include/private/android_filesystem_config.h b/include/private/android_filesystem_config.h
index 6521cbe..33ecd9a 100644
--- a/include/private/android_filesystem_config.h
+++ b/include/private/android_filesystem_config.h
@@ -87,6 +87,9 @@
 
 #define AID_USER        100000  /* offset for uid ranges for each user */
 
+#define AID_SHARED_GID_START 50000 /* start of gids for apps in each user to share */
+#define AID_SHARED_GID_END   59999 /* start of gids for apps in each user to share */
+
 #if !defined(EXCLUDE_FS_CONFIG_STRUCTURES)
 struct android_id_info {
     const char *name;
diff --git a/libnl_2/genl/genl.c b/libnl_2/genl/genl.c
index 05431d6..1a39c6a 100644
--- a/libnl_2/genl/genl.c
+++ b/libnl_2/genl/genl.c
@@ -20,6 +20,7 @@
 #include <unistd.h>
 #include <stdio.h>
 #include <sys/time.h>
+#include <sys/socket.h>
 #include <linux/netlink.h>
 #include <netlink/genl/ctrl.h>
 #include <netlink/genl/family.h>
diff --git a/libnl_2/msg.c b/libnl_2/msg.c
index 283da6e..1303e8a 100644
--- a/libnl_2/msg.c
+++ b/libnl_2/msg.c
@@ -18,6 +18,7 @@
 
 #include <malloc.h>
 #include <unistd.h>
+#include <sys/socket.h>
 #include <linux/netlink.h>
 #include "netlink-types.h"