am 55b763ff: Grant sdcard_r to ril-daemon.
* commit '55b763ff7b779d7ee91f245e0887332db8782afe':
Grant sdcard_r to ril-daemon.
diff --git a/include/netutils/ifc.h b/include/netutils/ifc.h
index 67a4a45..3574f7f 100644
--- a/include/netutils/ifc.h
+++ b/include/netutils/ifc.h
@@ -34,6 +34,9 @@
extern int ifc_enable(const char *ifname);
extern int ifc_disable(const char *ifname);
+#define RESET_IPV4_ADDRESSES 0x01
+#define RESET_IPV6_ADDRESSES 0x02
+#define RESET_ALL_ADDRESSES (RESET_IPV4_ADDRESSES | RESET_IPV6_ADDRESSES)
extern int ifc_reset_connections(const char *ifname, const int reset_mask);
extern int ifc_get_addr(const char *name, in_addr_t *addr);
diff --git a/include/system/audio.h b/include/system/audio.h
index 3807317..3076914 100644
--- a/include/system/audio.h
+++ b/include/system/audio.h
@@ -152,7 +152,7 @@
AUDIO_FORMAT_PCM_SUB_8_24_BIT),
} audio_format_t;
-typedef enum {
+enum {
/* output channels */
AUDIO_CHANNEL_OUT_FRONT_LEFT = 0x1,
AUDIO_CHANNEL_OUT_FRONT_RIGHT = 0x2,
diff --git a/init/devices.c b/init/devices.c
index 125f981..2ad81ef 100644
--- a/init/devices.c
+++ b/init/devices.c
@@ -50,6 +50,7 @@
#define SYSFS_PREFIX "/sys"
#define FIRMWARE_DIR1 "/etc/firmware"
#define FIRMWARE_DIR2 "/vendor/firmware"
+#define FIRMWARE_DIR3 "/firmware/image"
#ifdef HAVE_SELINUX
static struct selabel_handle *sehandle;
@@ -725,7 +726,7 @@
static void process_firmware_event(struct uevent *uevent)
{
- char *root, *loading, *data, *file1 = NULL, *file2 = NULL;
+ char *root, *loading, *data, *file1 = NULL, *file2 = NULL, *file3 = NULL;
int l, loading_fd, data_fd, fw_fd;
int booting = is_booting();
@@ -752,6 +753,10 @@
if (l == -1)
goto data_free_out;
+ l = asprintf(&file3, FIRMWARE_DIR3"/%s", uevent->firmware);
+ if (l == -1)
+ goto data_free_out;
+
loading_fd = open(loading, O_WRONLY);
if(loading_fd < 0)
goto file_free_out;
@@ -765,17 +770,20 @@
if(fw_fd < 0) {
fw_fd = open(file2, O_RDONLY);
if (fw_fd < 0) {
- if (booting) {
- /* If we're not fully booted, we may be missing
- * filesystems needed for firmware, wait and retry.
- */
- usleep(100000);
- booting = is_booting();
- goto try_loading_again;
+ fw_fd = open(file3, O_RDONLY);
+ if (fw_fd < 0) {
+ if (booting) {
+ /* If we're not fully booted, we may be missing
+ * filesystems needed for firmware, wait and retry.
+ */
+ usleep(100000);
+ booting = is_booting();
+ goto try_loading_again;
+ }
+ INFO("firmware: could not open '%s' %d\n", uevent->firmware, errno);
+ write(loading_fd, "-1", 2);
+ goto data_close_out;
}
- INFO("firmware: could not open '%s' %d\n", uevent->firmware, errno);
- write(loading_fd, "-1", 2);
- goto data_close_out;
}
}
diff --git a/libnetutils/ifc_utils.c b/libnetutils/ifc_utils.c
index 186b98c..50095ab 100644
--- a/libnetutils/ifc_utils.c
+++ b/libnetutils/ifc_utils.c
@@ -600,10 +600,6 @@
return result;
}
-#define RESET_IPV4_ADDRESSES 0x01
-#define RESET_IPV6_ADDRESSES 0x02
-#define RESET_ALL_ADDRESSES (RESET_IPV4_ADDRESSES | RESET_IPV6_ADDRESSES)
-
int ifc_reset_connections(const char *ifname, const int reset_mask)
{
#ifdef HAVE_ANDROID_OS
diff --git a/libnl_2/Android.mk b/libnl_2/Android.mk
index 1745f5a..deac9de 100644
--- a/libnl_2/Android.mk
+++ b/libnl_2/Android.mk
@@ -1,5 +1,11 @@
+#######################################
+# * Netlink cache not implemented
+# * Library is not thread safe
+#######################################
+
LOCAL_PATH := $(call my-dir)
+
include $(CLEAR_VARS)
LOCAL_SRC_FILES := \
@@ -22,9 +28,10 @@
LOCAL_MODULE_TAGS := optional
include $(BUILD_STATIC_LIBRARY)
-#######################################
-# Shared library currently unavailiable
-# * Netlink cache not implemented
-# * Library is not thread safe
-#######################################
-
+include $(CLEAR_VARS)
+LOCAL_SRC_FILES :=
+LOCAL_WHOLE_STATIC_LIBRARIES:= libnl_2
+LOCAL_SHARED_LIBRARIES:= liblog
+LOCAL_MODULE := libnl_2
+LOCAL_MODULE_TAGS := optional
+include $(BUILD_SHARED_LIBRARY)
diff --git a/mkbootimg/mkbootimg.c b/mkbootimg/mkbootimg.c
index a94cb9c..d72e317 100644
--- a/mkbootimg/mkbootimg.c
+++ b/mkbootimg/mkbootimg.c
@@ -142,7 +142,7 @@
} else if(!strcmp(arg, "--base")) {
unsigned base = strtoul(val, 0, 16);
hdr.kernel_addr = base + 0x00008000;
- hdr.ramdisk_addr = base + 0x01000000;
+ hdr.ramdisk_addr = base + 0x01300000;
hdr.second_addr = base + 0x00F00000;
hdr.tags_addr = base + 0x00000100;
} else if(!strcmp(arg, "--board")) {