Merge "Clean up reading and writing in init."
diff --git a/fs_mgr/fs_mgr.c b/fs_mgr/fs_mgr.c
index fa52d16..a1391e0 100644
--- a/fs_mgr/fs_mgr.c
+++ b/fs_mgr/fs_mgr.c
@@ -119,7 +119,17 @@
         ret = mount(blk_device, target, fs_type, tmpmnt_flags, tmpmnt_opts);
         INFO("%s(): mount(%s,%s,%s)=%d\n", __func__, blk_device, target, fs_type, ret);
         if (!ret) {
-            umount(target);
+            int i;
+            for (i = 0; i < 5; i++) {
+                // Try to umount 5 times before continuing on.
+                // Should we try rebooting if all attempts fail?
+                int result = umount(target);
+                if (result == 0) {
+                    break;
+                }
+                ERROR("%s(): umount(%s)=%d: %s\n", __func__, target, result, strerror(errno));
+                sleep(1);
+            }
         }
 
         /*
@@ -488,8 +498,8 @@
                         encryptable = FS_MGR_MNTALL_DEV_MIGHT_BE_ENCRYPTED;
                     }
                 } else {
-                    INFO("Could not umount %s - allow continue unencrypted\n",
-                         fstab->recs[attempted_idx].mount_point);
+                    WARNING("Could not umount %s (%s) - allow continue unencrypted\n",
+                            fstab->recs[attempted_idx].mount_point, strerror(errno));
                     continue;
                 }
             }
diff --git a/fs_mgr/fs_mgr_priv.h b/fs_mgr/fs_mgr_priv.h
index 34938fa..4ba6f92 100644
--- a/fs_mgr/fs_mgr_priv.h
+++ b/fs_mgr/fs_mgr_priv.h
@@ -21,6 +21,7 @@
 #include <fs_mgr.h>
 
 #define INFO(x...)    KLOG_INFO("fs_mgr", x)
+#define WARNING(x...) KLOG_WARNING("fs_mgr", x)
 #define ERROR(x...)   KLOG_ERROR("fs_mgr", x)
 
 #define CRYPTO_TMPFS_OPTIONS "size=256m,mode=0771,uid=1000,gid=1000"
diff --git a/libbacktrace/Android.mk b/libbacktrace/Android.mk
index ca1e4bf..f3b28dd 100755
--- a/libbacktrace/Android.mk
+++ b/libbacktrace/Android.mk
@@ -44,7 +44,6 @@
 
 libbacktrace_shared_libraries_target := \
 	libcutils \
-	libgccdemangle \
 
 libbacktrace_src_files += \
 	UnwindCurrent.cpp \
diff --git a/rootdir/init.rc b/rootdir/init.rc
index 2ae7409..bf70708 100644
--- a/rootdir/init.rc
+++ b/rootdir/init.rc
@@ -160,6 +160,9 @@
     chown system log /sys/fs/pstore/pmsg-ramoops-0
     chmod 0440 /sys/fs/pstore/pmsg-ramoops-0
 
+    # enable armv8_deprecated instruction hooks
+    write /proc/sys/abi/swp 1
+
 # Healthd can trigger a full boot from charger mode by signaling this
 # property when the power button is held.
 on property:sys.boot_from_charger_mode=1