merge from open-source master
diff --git a/fastboot/fastboot.c b/fastboot/fastboot.c
index 1a0183f..050f406 100644
--- a/fastboot/fastboot.c
+++ b/fastboot/fastboot.c
@@ -149,8 +149,8 @@
     if(!(vendor_id && (info->dev_vendor == vendor_id)) &&
        (info->dev_vendor != 0x18d1) &&  // Google
        (info->dev_vendor != 0x0451) &&
-       (info->dev_vendor != 0x22b8) &&  // Motorola
        (info->dev_vendor != 0x0502) &&
+       (info->dev_vendor != 0x22b8) &&  // Motorola
        (info->dev_vendor != 0x0bb4))    // HTC
             return -1;
     if(info->ifc_class != 0xff) return -1;
diff --git a/logcat/event-log-tags b/logcat/event-log-tags
index 2140b37..a51e2fa 100644
--- a/logcat/event-log-tags
+++ b/logcat/event-log-tags
@@ -282,6 +282,8 @@
 30035 am_schedule_service_restart (Component Name|3),(Time|2|3)
 # A client was waiting for a content provider, but its process was lost
 30036 am_provider_lost_process (Package Name|3),(UID|1|5),(Name|3)
+# The activity manager gave up on a new process taking too long to start
+30037 am_process_start_timeout (PID|1|5),(UID|1|5),(Process Name|3)
 
 # Out of memory for surfaces.
 31000 wm_no_surface_memory (Window|3),(PID|1|5),(Operation|3)
@@ -373,9 +375,13 @@
 #//device/dalvik/libcore/luni/src/main/native/org_apache_harmony_luni_platform_OSNetworkSystem.c
 51000 socket_stats (send|1|2),(recv|1|2),(ip|1|5),(port|1|5),(close|1|5)
 
-# db stats.  0 is query, 1 is write (may become more fine grained in the
-# future)
-52000 db_operation (name|3),(op_type|1|5),(time|2|3)
+# Database operation samples.
+# db: the filename of the database
+# sql: the executed query (without query args)
+# time: cpu time millis (not wall time), including lock acquisition
+# blocking_package: if this is on a main thread, the package name, otherwise ""
+# sample_percent: the percent likelihood this query was logged
+52000 db_operation (db|3),(sql|3),(time|1|3),(blocking_package|3),(sample_percent|1|6)
 
 # http request/response stats
 52001 http_stats (useragent|3),(response|2|3),(processing|2|3),(tx|1|2),(rx|1|2)
diff --git a/rootdir/init.rc b/rootdir/init.rc
index f62d1d8..cd3fd9e 100644
--- a/rootdir/init.rc
+++ b/rootdir/init.rc
@@ -97,7 +97,7 @@
     chmod 0770 /cache
 
     # This may have been created by the recovery system with odd permissions
-    chown system system /cache/recovery
+    chown system cache /cache/recovery
     chmod 0770 /cache/recovery
 
     #change permissions on vmallocinfo so we can grab it from bugreports