Fix copy files in device-sargo.mk am: 4805da399a am: 92a183f095 am: 8f64ce8eff

Change-Id: Id97921e35b6b63e0e30225230ae99476df0e902e
diff --git a/BoardConfig-common.mk b/BoardConfig-common.mk
index 5c5d83f..0193ba0 100644
--- a/BoardConfig-common.mk
+++ b/BoardConfig-common.mk
@@ -153,6 +153,12 @@
 # Sensors
 USE_SENSOR_MULTI_HAL := true
 TARGET_SUPPORT_DIRECT_REPORT := true
+# Enable sensor Version V_2
+USE_SENSOR_HAL_VER := 2.0
+
+# CHRE
+CHRE_DAEMON_ENABLED := true
+CHRE_DAEMON_LOAD_INTO_SENSORSPD := true
 
 # wlan
 BOARD_WLAN_DEVICE := qcwcn
@@ -164,6 +170,9 @@
 BOARD_HOSTAPD_PRIVATE_LIB := lib_driver_cmd_$(BOARD_WLAN_DEVICE)
 WIFI_HIDL_FEATURE_AWARE := true
 WIFI_HIDL_FEATURE_DUAL_INTERFACE:= true
+WIFI_FEATURE_WIFI_EXT_HAL := true
+WIFI_FEATURE_IMU_DETECTION := false
+WIFI_HIDL_UNIFIED_SUPPLICANT_SERVICE_RC_ENTRY := true
 
 # Audio
 BOARD_USES_ALSA_AUDIO := true
diff --git a/CleanSpec.mk b/CleanSpec.mk
index 6d71bc6..060a347 100644
--- a/CleanSpec.mk
+++ b/CleanSpec.mk
@@ -177,3 +177,16 @@
 
 # Remove obsolete android.hardware.boot@1.0-impl-wrapper.recovery.so
 $(call add-clean-step, rm -rf $(PRODUCT_OUT)/recovery/root/system/lib64/hw/android.hardware.boot@1.0-impl-wrapper.recovery.so)
+
+# Vibrator HAL 1.2 renamed from 'bonito' to 'drv2624'
+$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/etc/init/android.hardware.vibrator@1.2-service.bonito.rc)
+$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/bin/hw/android.hardware.vibrator@1.2-service.bonito)
+
+# Vibrator HAL upgraded from 1-2 to 1-3
+$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/etc/init/android.hardware.vibrator@1.2-service.drv2624.rc)
+$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/bin/hw/android.hardware.vibrator@1.2-service.drv2624)
+$(call add-clean-step, rm -rf $(PRODUCT_OUT)/vendor/etc/vintf/manifest/android.hardware.vibrator@1.2-service.drv2624.xml)
+
+# Move android.hidl.base@1.0.so to system_ext
+$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/lib/android.hidl.base@1.0.so)
+$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/lib64/android.hidl.base@1.0.so)
diff --git a/audio_policy_volumes.xml b/audio_policy_volumes.xml
index 635f721..f119317 100644
--- a/audio_policy_volumes.xml
+++ b/audio_policy_volumes.xml
@@ -44,7 +44,7 @@
     <volume stream="AUDIO_STREAM_VOICE_CALL" deviceCategory="DEVICE_CATEGORY_EXT_MEDIA"
                                              ref="DEFAULT_MEDIA_VOLUME_CURVE"/>
     <volume stream="AUDIO_STREAM_VOICE_CALL" deviceCategory="DEVICE_CATEGORY_HEARING_AID"
-                                             ref="DEFAULT_HEARING_AID_VOLUME_CURVE"/>
+                                             ref="DEFAULT_NON_MUTABLE_HEARING_AID_VOLUME_CURVE"/>
     <volume stream="AUDIO_STREAM_SYSTEM" deviceCategory="DEVICE_CATEGORY_HEADSET">
         <point>1,-3000</point>
         <point>33,-2600</point>
diff --git a/bonito/overlay/frameworks/base/core/res/res/values/config.xml b/bonito/overlay/frameworks/base/core/res/res/values/config.xml
index 0c28a5a..bba3286 100755
--- a/bonito/overlay/frameworks/base/core/res/res/values/config.xml
+++ b/bonito/overlay/frameworks/base/core/res/res/values/config.xml
@@ -134,22 +134,21 @@
          backlight values -->
     <bool name="config_displayBrightnessBucketsInDoze">true</bool>
 
+    <!-- Minimum screen brightness setting allowed by power manager.
+         The user is forbidden from setting the brightness below this level.
+         Equivalent to 1/255. -->
+    <item name="config_screenBrightnessSettingMinimumFloat" format="float" type="dimen">0.0</item>
+
+    <!-- Maximum screen brightness allowed by the power manager.
+         The user is forbidden from setting the brightness above this level.
+         This value is a fraction between 3.5% and 100%. -->
+    <item name="config_screenBrightnessSettingMaximumFloat" format="float" type="dimen">1.0</item>
+
     <!-- Default screen brightness setting.
-         Must be in the range specified by minimum and maximum. -->
-    <integer name="config_screenBrightnessSettingDefault">98</integer>
-
-    <!-- Default screen brightness for VR setting. Default value: 0x1F => 127. -->
-    <integer name="config_screenBrightnessForVrSettingDefault">127</integer>
-
-    <integer name="config_screenBrightnessForVrSettingMinimum">127</integer>
-
-    <!-- Minimum screen brightness setting allowed by the power manager.
-         The user is forbidden from setting the brightness below this level. -->
-    <integer name="config_screenBrightnessSettingMinimum">1</integer>
-
-    <!-- Maximum screen brightness setting allowed by the power manager.
-         The user is forbidden from setting the brightness above this level. -->
-    <integer name="config_screenBrightnessSettingMaximum">255</integer>
+         Must be in the range specified by minimum and maximum.
+         This value is a fraction between 3.5% and 100%.
+         Equivalent to 98/255 (default for this device)    -->
+    <item name="config_screenBrightnessSettingDefaultFloat" format="float" type="dimen">0.38188976378</item>
 
     <!-- An array describing the screen's backlight values corresponding to the brightness
          values in the config_screenBrightnessNits array.
diff --git a/component-overrides.xml b/component-overrides.xml
new file mode 100644
index 0000000..bb3419d
--- /dev/null
+++ b/component-overrides.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2019 The Android Open Source Project
+
+     Licensed under the Apache License, Version 2.0 (the "License");
+     you may not use this file except in compliance with the License.
+     You may obtain a copy of the License at
+
+          http://www.apache.org/licenses/LICENSE-2.0
+
+     Unless required by applicable law or agreed to in writing, software
+     distributed under the License is distributed on an "AS IS" BASIS,
+     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+     See the License for the specific language governing permissions and
+     limitations under the License.
+-->
+<config>
+    <component-override package="com.android.bluetooth" >
+        <component class=".sap.SapService" enabled="true" />
+    </component-override>
+</config>
\ No newline at end of file
diff --git a/default-permissions.xml b/default-permissions.xml
index 733b272..1fcf7ee 100644
--- a/default-permissions.xml
+++ b/default-permissions.xml
@@ -79,17 +79,6 @@
     </exception>
 
     <exception
-            package="com.google.android.apps.restore"
-            sha256-cert-digest="56:BE:13:2B:78:06:56:FE:24:44:CD:34:32:6E:B5:D7:AA:C9:1D:20:96:AB:F0:FE:67:3A:99:27:06:22:EC:87">
-        <!-- External storage -->
-        <permission name="android.permission.READ_EXTERNAL_STORAGE" fixed="false"/>
-        <permission name="android.permission.WRITE_EXTERNAL_STORAGE" fixed="false"/>
-        <!-- Contacts -->
-        <permission name="android.permission.READ_CONTACTS" fixed="false"/>
-        <permission name="android.permission.WRITE_CONTACTS" fixed="false"/>
-    </exception>
-
-    <exception
             package="com.verizon.mips.services">
         <!-- Call -->
         <permission name="android.permission.PROCESS_OUTGOING_CALLS" fixed="false"/>
diff --git a/device-bonito.mk b/device-bonito.mk
index f3d69a0..01830dd 100644
--- a/device-bonito.mk
+++ b/device-bonito.mk
@@ -27,8 +27,12 @@
     device/google/bonito/nfc/libnfc-nxp.bonito.uicc.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-nxp-G020C.conf \
     device/google/bonito/nfc/libnfc-nxp.bonito.ese.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-nxp-G020D.conf
 
+PRODUCT_PACKAGES += \
+    TelephonyOverlay2018MidyearBonito
+
 # Vibrator HAL
 PRODUCT_PRODUCT_PROPERTIES +=\
+    ro.vibrator.hal.config.dynamic=1 \
     ro.vibrator.hal.click.duration=8 \
     ro.vibrator.hal.tick.duration=5 \
     ro.vibrator.hal.heavyclick.duration=12 \
diff --git a/device-sargo.mk b/device-sargo.mk
index 8021f40..01cf584 100644
--- a/device-sargo.mk
+++ b/device-sargo.mk
@@ -20,6 +20,9 @@
 
 DEVICE_PACKAGE_OVERLAYS += device/google/bonito/sargo/overlay
 
+PRODUCT_PACKAGES += \
+    TelephonyOverlay2018MidyearSargo
+
 PRODUCT_COPY_FILES += \
     device/google/bonito/nfc/libnfc-nxp.sargo.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-nxp.conf \
     device/google/bonito/nfc/libnfc-nxp.sargo.uicc.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-nxp-G020E.conf \
@@ -31,6 +34,7 @@
 
 # Vibrator HAL
 PRODUCT_PRODUCT_PROPERTIES +=\
+    ro.vibrator.hal.config.dynamic=1 \
     ro.vibrator.hal.click.duration=8 \
     ro.vibrator.hal.tick.duration=5 \
     ro.vibrator.hal.heavyclick.duration=12 \
diff --git a/device.mk b/device.mk
index 660550b..0623097 100644
--- a/device.mk
+++ b/device.mk
@@ -19,6 +19,7 @@
 PRODUCT_SOONG_NAMESPACES += \
     device/google/bonito \
     hardware/google/av \
+    hardware/google/camera \
     hardware/google/interfaces \
     hardware/google/pixel \
     hardware/qcom/sdm845 \
@@ -29,6 +30,8 @@
 PRODUCT_PROPERTY_OVERRIDES += \
     keyguard.no_require_sim=true
 
+PRODUCT_PROPERTY_OVERRIDES += ro.crypto.volume.filenames_mode=aes-256-cts
+
 # enable cal by default on accel sensor
 PRODUCT_PRODUCT_PROPERTIES += \
     persist.debug.sensors.accel_cal=1
@@ -40,6 +43,7 @@
 
 PRODUCT_COPY_FILES += \
     device/google/bonito/default-permissions.xml:$(TARGET_COPY_OUT_VENDOR)/etc/default-permissions/default-permissions.xml \
+    device/google/bonito/component-overrides.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sysconfig/component-overrides.xml \
     frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml \
     frameworks/native/data/etc/android.software.verified_boot.xml:$(TARGET_COPY_OUT_PRODUCT)/etc/permissions/android.software.verified_boot.xml
 
@@ -54,6 +58,10 @@
 PRODUCT_PACKAGES += \
     messaging
 
+ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
+PRODUCT_PACKAGES += chre_test_client
+endif
+
 LOCAL_PATH := device/google/bonito
 
 TARGET_PRODUCT_PROP := $(LOCAL_PATH)/product.prop
@@ -136,6 +144,10 @@
     update_engine \
     update_verifier
 
+# Resume on Reboot support
+PRODUCT_PACKAGES += \
+    android.hardware.rebootescrow-service.default
+
 # Use Sdcardfs
 PRODUCT_PRODUCT_PROPERTIES += \
     ro.sys.sdcardfs=1
@@ -166,7 +178,8 @@
 PRODUCT_PACKAGES += \
     update_engine_sideload \
     sg_write_buffer \
-    f2fs_io
+    f2fs_io \
+    check_f2fs
 
 # The following modules are included in debuggable builds only.
 PRODUCT_PACKAGES_DEBUG += \
@@ -184,6 +197,7 @@
     frameworks/native/data/etc/android.hardware.camera.raw.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.raw.xml\
     frameworks/native/data/etc/android.hardware.bluetooth.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.bluetooth.xml \
     frameworks/native/data/etc/android.hardware.bluetooth_le.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.bluetooth_le.xml \
+    frameworks/native/data/etc/android.hardware.reboot_escrow.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.reboot_escrow.xml \
     frameworks/native/data/etc/android.hardware.sensor.accelerometer.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.accelerometer.xml \
     frameworks/native/data/etc/android.hardware.sensor.assist.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.assist.xml \
     frameworks/native/data/etc/android.hardware.sensor.compass.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.compass.xml \
@@ -194,6 +208,7 @@
     frameworks/native/data/etc/android.hardware.sensor.stepcounter.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.stepcounter.xml \
     frameworks/native/data/etc/android.hardware.sensor.stepdetector.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.stepdetector.xml \
     frameworks/native/data/etc/android.hardware.sensor.hifi_sensors.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.hifi_sensors.xml \
+    frameworks/native/data/etc/android.hardware.context_hub.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.context_hub.xml \
     frameworks/native/data/etc/android.hardware.location.gps.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.location.gps.xml \
     frameworks/native/data/etc/android.hardware.telephony.gsm.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.telephony.gsm.xml \
     frameworks/native/data/etc/android.hardware.telephony.cdma.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.telephony.cdma.xml \
@@ -215,6 +230,7 @@
     frameworks/native/data/etc/android.hardware.vulkan.level-1.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.level.xml \
     frameworks/native/data/etc/android.hardware.vulkan.compute-0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.compute.xml \
     frameworks/native/data/etc/android.hardware.vulkan.version-1_1.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.version.xml \
+    frameworks/native/data/etc/android.software.vulkan.deqp.level-2020-03-01.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.vulkan.deqp.level.xml \
     frameworks/native/data/etc/android.hardware.telephony.carrierlock.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.telephony.carrierlock.xml \
     frameworks/native/data/etc/android.hardware.se.omapi.uicc.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.se.omapi.uicc.xml \
     frameworks/native/data/etc/android.hardware.strongbox_keystore.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.strongbox_keystore.xml \
@@ -319,6 +335,10 @@
     ro.zram.first_wb_delay_mins=180 \
     ro.zram.periodic_wb_delay_hours=24 \
 
+PRODUCT_PRODUCT_PROPERTIES += \
+    ro.telephony.max.active.modems=2 \
+    persist.radio.reboot_on_modem_change=false
+
 # Disable snapshot timer
 PRODUCT_PROPERTY_OVERRIDES += \
     persist.vendor.radio.snapshot_enabled=0 \
@@ -379,10 +399,6 @@
 PRODUCT_PROPERTY_OVERRIDES += \
     ro.vendor.bt.bdaddr_path=/proc/device-tree/chosen/cdt/cdb2/bt_addr
 
-# Enable Perfetto traced
-PRODUCT_PRODUCT_PROPERTIES += \
-    persist.traced.enable=1
-
 # Bluetooth WiPower
 PRODUCT_PROPERTY_OVERRIDES += \
     ro.vendor.bluetooth.emb_wp_mode=false \
@@ -392,8 +408,8 @@
 PRODUCT_PACKAGES += \
     android.hardware.drm@1.0-impl \
     android.hardware.drm@1.0-service \
-    android.hardware.drm@1.2-service.clearkey \
-    android.hardware.drm@1.2-service.widevine
+    android.hardware.drm@1.3-service.clearkey \
+    android.hardware.drm@1.3-service.widevine
 
 # NFC and Secure Element packages
 PRODUCT_PACKAGES += \
@@ -453,17 +469,21 @@
     android.hardware.camera.provider@2.4-service_64 \
     camera.device@3.2-impl \
     camera.sdm710 \
-    libgooglecamerahal \
-    libgoogle_camera_hal_tests \
     libqomx_core \
     libmmjpeg_interface \
     libmmcamera_interface \
     libcameradepthcalibrator
 
+# Google Camera HAL test libraries in debug builds
+PRODUCT_PACKAGES_DEBUG += \
+    libgoogle_camera_hal_proprietary_tests \
+    libgoogle_camera_hal_tests.vendor
+
 PRODUCT_PACKAGES += \
     sensors.$(PRODUCT_HARDWARE) \
-    android.hardware.sensors@1.0-impl \
-    android.hardware.sensors@1.0-service
+    android.hardware.sensors@2.0-impl \
+    android.hardware.sensors@2.0-service \
+    android.hardware.sensors@2.0-service.rc
 
 PRODUCT_COPY_FILES += \
     $(LOCAL_PATH)/sensors/hals.conf:vendor/etc/sensors/hals.conf
@@ -478,8 +498,7 @@
 
 # Context hub HAL
 PRODUCT_PACKAGES += \
-    android.hardware.contexthub@1.0-impl.generic \
-    android.hardware.contexthub@1.0-service
+    android.hardware.contexthub@1.1-service.generic
 
 # Boot control HAL
 PRODUCT_PACKAGES += \
@@ -489,12 +508,17 @@
 
 # Vibrator HAL
 PRODUCT_PACKAGES += \
-    android.hardware.vibrator@1.2-service.bonito \
+    android.hardware.vibrator@1.3-service.drv2624
 
 # Thermal HAL
 PRODUCT_PACKAGES += \
     android.hardware.thermal@2.0-service.pixel
 
+ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
+PRODUCT_PACKAGES += \
+    thermal_logd
+endif
+
 PRODUCT_COPY_FILES += \
     $(LOCAL_PATH)/thermal_info_config_$(PRODUCT_HARDWARE).json:$(TARGET_COPY_OUT_VENDOR)/etc/thermal_info_config.json
 
@@ -534,10 +558,6 @@
 LIB_NL := libnl_2
 PRODUCT_PACKAGES += $(LIB_NL)
 
-# Factory OTA
-PRODUCT_PACKAGES += \
-    FactoryOta
-
 # Audio effects
 PRODUCT_PACKAGES += \
     libvolumelistener \
@@ -556,9 +576,8 @@
     audio.bluetooth.default
 
 PRODUCT_PACKAGES += \
-    android.hardware.audio@5.0-impl:32 \
-    android.hardware.audio.effect@5.0-impl:32 \
-    android.hardware.broadcastradio@1.0-impl \
+    android.hardware.audio@6.0-impl:32 \
+    android.hardware.audio.effect@6.0-impl:32 \
     android.hardware.soundtrigger@2.2-impl \
     android.hardware.bluetooth.audio@2.0-impl \
     android.hardware.audio@2.0-service
@@ -611,13 +630,6 @@
     $(LOCAL_PATH)/media_profiles_V1_0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_profiles_V1_0.xml \
     $(LOCAL_PATH)/media_codecs_omx.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_omx.xml
 
-# configures both aac and xaac decoders
-PRODUCT_COPY_FILES += \
-    device/google/bonito/media_codecs_google_audio.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_audio.xml \
-# and ensure that the xaac decoder is built
-PRODUCT_PACKAGES += \
-    libstagefright_soft_xaacdec.vendor
-
 PRODUCT_PROPERTY_OVERRIDES += \
     audio.snd_card.open.retries=50
 
@@ -643,6 +655,13 @@
 PRODUCT_PROPERTY_OVERRIDES += \
     persist.vendor.sys.ssr.restart_level=modem,slpi,adsp
 
+ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
+# Sensor debug flag
+PRODUCT_PROPERTY_OVERRIDES += \
+    persist.vendor.debug.ash.logger=0 \
+    persist.vendor.debug.ash.logger.time=0
+endif
+
 # setup dalvik vm configs
 $(call inherit-product, frameworks/native/build/phone-xhdpi-4096-dalvik-heap.mk)
 
@@ -654,15 +673,19 @@
 PRODUCT_PACKAGES += \
     charger_res_images
 
-# b/36703476
-# Set default log size on userdebug/eng build to 1M
 ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
-PRODUCT_PROPERTY_OVERRIDES += ro.logd.size=1M
+# b/36703476: Set default log size to 1M
+PRODUCT_PROPERTY_OVERRIDES += \
+  ro.logd.size=1M
+# b/114766334: persist all logs by default rotating on 30 files of 1MiB
+PRODUCT_PROPERTY_OVERRIDES += \
+  logd.logpersistd=logcatd \
+  logd.logpersistd.size=30
 endif
 
 # Dumpstate HAL
 PRODUCT_PACKAGES += \
-    android.hardware.dumpstate@1.0-service.bonito
+    android.hardware.dumpstate@1.1-service.bonito
 
 # Citadel
 PRODUCT_PACKAGES += \
@@ -690,8 +713,8 @@
     dalvik.vm.heapgrowthlimit=256m
 
 PRODUCT_COPY_FILES += \
-    device/google/bonito/hidl/android.hidl.base@1.0.so-32:system/lib/android.hidl.base@1.0.so \
-    device/google/bonito/hidl/android.hidl.base@1.0.so-64:system/lib64/android.hidl.base@1.0.so \
+    device/google/bonito/hidl/android.hidl.base@1.0.so-32:system_ext/lib/android.hidl.base@1.0.so \
+    device/google/bonito/hidl/android.hidl.base@1.0.so-64:system_ext/lib64/android.hidl.base@1.0.so \
     device/google/bonito/hidl/android.hidl.base@1.0.so-32:vendor/lib/android.hidl.base@1.0.so \
     device/google/bonito/hidl/android.hidl.base@1.0.so-64:vendor/lib64/android.hidl.base@1.0.so \
 
@@ -803,10 +826,13 @@
 # Enable modem logging for debug
 ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
 PRODUCT_PROPERTY_OVERRIDES += \
-    persist.vendor.sys.modem.diag.mdlog=true \
-    persist.vendor.sys.modem.diag.mdlog_br_num=5
+    persist.vendor.sys.modem.diag.mdlog=true
 else
+PRODUCT_PROPERTY_OVERRIDES += \
+    persist.vendor.sys.modem.diag.mdlog=false
 endif
+PRODUCT_PROPERTY_OVERRIDES += \
+    persist.vendor.sys.modem.diag.mdlog_br_num=5
 
 # Enable tcpdump_logger on userdebug and eng
 ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
@@ -870,3 +896,15 @@
 # Increment the SVN for any official public releases
 PRODUCT_PROPERTY_OVERRIDES += \
 	ro.vendor.build.svn=19
+
+# Vendor verbose logging default property
+ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
+PRODUCT_PROPERTY_OVERRIDES += \
+    persist.vendor.verbose_logging_enabled=true
+else
+PRODUCT_PROPERTY_OVERRIDES += \
+    persist.vendor.verbose_logging_enabled=false
+endif
+
+# Factory OTA
+-include vendor/google/factoryota/client/factoryota.mk
diff --git a/device_framework_matrix.xml b/device_framework_matrix.xml
index 036a645..720b125 100644
--- a/device_framework_matrix.xml
+++ b/device_framework_matrix.xml
@@ -172,7 +172,7 @@
     <hal format="hidl" optional="true">
         <name>vendor.google.wifi_ext</name>
         <transport>hwbinder</transport>
-        <version>1.0</version>
+        <version>1.1</version>
         <interface>
             <name>IWifiExt</name>
             <instance>default</instance>
diff --git a/dumpstate/Android.mk b/dumpstate/Android.mk
index 0981477..76c889b 100644
--- a/dumpstate/Android.mk
+++ b/dumpstate/Android.mk
@@ -16,8 +16,8 @@
 
 LOCAL_PATH:= $(call my-dir)
 include $(CLEAR_VARS)
-LOCAL_MODULE := android.hardware.dumpstate@1.0-service.bonito
-LOCAL_INIT_RC := android.hardware.dumpstate@1.0-service.bonito.rc
+LOCAL_MODULE := android.hardware.dumpstate@1.1-service.bonito
+LOCAL_INIT_RC := android.hardware.dumpstate@1.1-service.bonito.rc
 LOCAL_MODULE_RELATIVE_PATH := hw
 
 LOCAL_SRC_FILES := \
@@ -26,12 +26,11 @@
 
 LOCAL_SHARED_LIBRARIES := \
     android.hardware.dumpstate@1.0 \
+    android.hardware.dumpstate@1.1 \
     libbase \
     libcutils \
     libdumpstateutil \
     libhidlbase \
-    libhidltransport \
-    libhwbinder \
     liblog \
     libutils
 
diff --git a/dumpstate/DumpstateDevice.cpp b/dumpstate/DumpstateDevice.cpp
index 90a6221..2a19f1d 100755
--- a/dumpstate/DumpstateDevice.cpp
+++ b/dumpstate/DumpstateDevice.cpp
@@ -46,6 +46,8 @@
 
 #define MODEM_EFS_DUMP_PROPERTY "vendor.sys.modem.diag.efsdump"
 
+#define VENDOR_VERBOSE_LOGGING_ENABLED_PROPERTY "persist.vendor.verbose_logging_enabled"
+
 using android::os::dumpstate::CommandOptions;
 using android::os::dumpstate::DumpFileToFd;
 using android::os::dumpstate::PropertiesHelper;
@@ -54,7 +56,7 @@
 namespace android {
 namespace hardware {
 namespace dumpstate {
-namespace V1_0 {
+namespace V1_1 {
 namespace implementation {
 
 #define DIAG_LOG_PREFIX "diag_log_"
@@ -127,17 +129,47 @@
 
     RunCommandToFd(fd, "MKDIR MODEM LOG", {"/vendor/bin/mkdir", "-p", modemLogAllDir.c_str()}, CommandOptions::WithTimeout(2).Build());
 
+    const std::string diagLogDir = "/data/vendor/radio/diag_logs/logs";
+    const std::string diagPoweronLogPath = "/data/vendor/radio/diag_logs/logs/diag_poweron_log.qmdl";
+
+    bool diagLogEnabled = android::base::GetBoolProperty(DIAG_MDLOG_PERSIST_PROPERTY, false);
+
+    if (diagLogEnabled) {
+        bool diagLogStarted = android::base::GetBoolProperty( DIAG_MDLOG_STATUS_PROPERTY, false);
+
+        if (diagLogStarted) {
+            android::base::SetProperty(DIAG_MDLOG_PROPERTY, "false");
+            ALOGD("Stopping diag_mdlog...\n");
+            if (android::base::WaitForProperty(DIAG_MDLOG_STATUS_PROPERTY, "false", std::chrono::seconds(20))) {
+                ALOGD("diag_mdlog exited");
+            } else {
+                ALOGE("Waited mdlog timeout after 20 second");
+            }
+        } else {
+            ALOGD("diag_mdlog is not running");
+        }
+
+        dumpLogs(fd, diagLogDir, modemLogAllDir, android::base::GetIntProperty(DIAG_MDLOG_NUMBER_BUGREPORT, 100), DIAG_LOG_PREFIX);
+
+        if (diagLogStarted) {
+            ALOGD("Restarting diag_mdlog...");
+            android::base::SetProperty(DIAG_MDLOG_PROPERTY, "true");
+        }
+    }
+    RunCommandToFd(fd, "CP MODEM POWERON LOG", {"/vendor/bin/cp", diagPoweronLogPath.c_str(), modemLogAllDir.c_str()}, CommandOptions::WithTimeout(2).Build());
+
     if (!PropertiesHelper::IsUserBuild()) {
         RunCommandToFd(fd, "MODEM RFS INFO", {"/vendor/bin/find /data/vendor/rfs/mpss/OEMFI/"}, CommandOptions::WithTimeout(2).Build());
         RunCommandToFd(fd, "MODEM DIAG SYSTEM PROPERTIES", {"/vendor/bin/getprop | grep vendor.sys.modem.diag"}, CommandOptions::WithTimeout(2).Build());
 
         android::base::SetProperty(MODEM_EFS_DUMP_PROPERTY, "true");
 
-        const std::string diagLogDir = "/data/vendor/radio/diag_logs/logs";
         const std::string tcpdumpLogDir = "/data/vendor/tcpdump_logger/logs";
         const std::string extendedLogDir = "/data/vendor/radio/extended_logs";
         const std::vector <std::string> rilAndNetmgrLogs
             {
+              "/data/vendor/radio/haldebug_ril0",
+              "/data/vendor/radio/haldebug_ril1",
               "/data/vendor/radio/ril_log0",
               "/data/vendor/radio/ril_log0_old",
               "/data/vendor/radio/ril_log1",
@@ -148,50 +180,17 @@
               "/data/vendor/radio/imsdatadaemon_log_old",
               "/data/vendor/netmgr/netmgr_log",
               "/data/vendor/netmgr/netmgr_log_old",
+              "/data/vendor/radio/omadm_logs.txt",
               "/data/vendor/radio/power_anomaly_data.txt",
               "/data/vendor/radio/diag_logs/diag_trace.txt",
               "/data/vendor/radio/diag_logs/diag_trace_old.txt",
-              "/data/vendor/radio/diag_logs/logs/diag_poweron_log.qmdl",
               "/data/vendor/radio/metrics_data",
               "/data/vendor/ssrlog/ssr_log.txt",
               "/data/vendor/ssrlog/ssr_log_old.txt",
               "/data/vendor/rfs/mpss/modem_efs"
             };
 
-        bool smlogEnabled = android::base::GetBoolProperty(MODEM_LOGGING_SWITCH, false) && !access("/vendor/bin/smlog_dump", X_OK);
-        bool diagLogEnabled = android::base::GetBoolProperty(DIAG_MDLOG_PERSIST_PROPERTY, false);
         bool tcpdumpEnabled = android::base::GetBoolProperty(TCPDUMP_PERSIST_PROPERTY, false);
-
-        if (smlogEnabled) {
-            RunCommandToFd(fd, "SMLOG DUMP", {"smlog_dump", "-d", "-o", modemLogAllDir.c_str()}, CommandOptions::WithTimeout(10).Build());
-        } else if (diagLogEnabled) {
-            bool diagLogStarted = android::base::GetBoolProperty(DIAG_MDLOG_STATUS_PROPERTY, false);
-
-            if (diagLogStarted) {
-                android::base::SetProperty(DIAG_MDLOG_PROPERTY, "false");
-                ALOGD("Stopping diag_mdlog...\n");
-            } else {
-                ALOGD("diag_mdlog is not running\n");
-            }
-
-            for (int i = 0; i < 30; i++) {
-                if (!android::base::GetBoolProperty(DIAG_MDLOG_STATUS_PROPERTY, false)) {
-                    ALOGD("diag_mdlog exited\n");
-                    sleep(1);
-                    break;
-                }
-
-                sleep(1);
-            }
-
-            dumpLogs(fd, diagLogDir, modemLogAllDir, android::base::GetIntProperty(DIAG_MDLOG_NUMBER_BUGREPORT, 100), DIAG_LOG_PREFIX);
-
-            if (diagLogStarted) {
-                ALOGD("Restarting diag_mdlog...\n");
-                android::base::SetProperty(DIAG_MDLOG_PROPERTY, "true");
-            }
-        }
-
         if (tcpdumpEnabled) {
             dumpLogs(fd, tcpdumpLogDir, modemLogAllDir, android::base::GetIntProperty(TCPDUMP_NUMBER_BUGREPORT, 5), TCPDUMP_LOG_PREFIX);
         }
@@ -276,6 +275,18 @@
     }
 }
 
+static void DumpSensorLog(int fd) {
+    const std::string logPath = "/data/vendor/sensors/log/sensor_log.txt";
+    const std::string lastlogPath = "/data/vendor/sensors/log/sensor_lastlog.txt";
+
+    if (!access(logPath.c_str(), R_OK)) {
+        DumpFileToFd(fd, "sensor log", logPath);
+    }
+    if (!access(lastlogPath.c_str(), R_OK)) {
+        DumpFileToFd(fd, "sensor lastlog", lastlogPath);
+    }
+}
+
 static void DumpF2FS(int fd) {
     DumpFileToFd(fd, "F2FS", "/sys/kernel/debug/f2fs/status");
     DumpFileToFd(fd, "F2FS - fragmentation", "/proc/fs/f2fs/dm-6/segment_info");
@@ -317,15 +328,36 @@
 
 // Methods from ::android::hardware::dumpstate::V1_0::IDumpstateDevice follow.
 Return<void> DumpstateDevice::dumpstateBoard(const hidl_handle& handle) {
+    // Ignore return value, just return an empty status.
+    dumpstateBoard_1_1(handle, DumpstateMode::DEFAULT, 30 * 1000 /* timeoutMillis */);
+    return Void();
+}
+
+// Methods from ::android::hardware::dumpstate::V1_1::IDumpstateDevice follow.
+Return<DumpstateStatus> DumpstateDevice::dumpstateBoard_1_1(const hidl_handle& handle,
+                                                            const DumpstateMode mode,
+                                                            const uint64_t timeoutMillis) {
+    // Unused arguments.
+    (void) timeoutMillis;
+
     if (handle == nullptr || handle->numFds < 1) {
         ALOGE("no FDs\n");
-        return Void();
+        return DumpstateStatus::ILLEGAL_ARGUMENT;
     }
 
     int fd = handle->data[0];
     if (fd < 0) {
         ALOGE("invalid FD: %d\n", handle->data[0]);
-        return Void();
+        return DumpstateStatus::ILLEGAL_ARGUMENT;
+    }
+
+    if (mode == DumpstateMode::WEAR) {
+        // We aren't a Wear device.
+        ALOGE("Unsupported mode: %d\n", mode);
+        return DumpstateStatus::UNSUPPORTED_MODE;
+    } else if (mode < DumpstateMode::FULL || mode > DumpstateMode::DEFAULT) {
+        ALOGE("Invalid mode: %d\n", mode);
+        return DumpstateStatus::ILLEGAL_ARGUMENT;
     }
 
     RunCommandToFd(fd, "Notify modem", {"/vendor/bin/modem_svc", "-s"}, CommandOptions::WithTimeout(1).Build());
@@ -341,11 +373,16 @@
     DumpF2FS(fd);
     DumpeMMC(fd);
 
+    DumpSensorLog(fd);
+
     DumpFileToFd(fd, "INTERRUPTS", "/proc/interrupts");
 
     DumpPower(fd);
 
     DumpFileToFd(fd, "LL-Stats", "/d/wlan0/ll_stats");
+    DumpFileToFd(fd, "WLAN Connect Info", "/d/wlan0/connect_info");
+    DumpFileToFd(fd, "WLAN Offload Info", "/d/wlan0/offload_info");
+    DumpFileToFd(fd, "WLAN Roaming Stats", "/d/wlan0/roam_stats");
     DumpFileToFd(fd, "ICNSS Stats", "/d/icnss/stats");
     DumpFileToFd(fd, "SMD Log", "/d/ipc_logging/smd/log");
     RunCommandToFd(fd, "ION HEAPS", {"/vendor/bin/sh", "-c", "for d in $(ls -d /d/ion/*); do for f in $(ls $d); do echo --- $d/$f; cat $d/$f; done; done"});
@@ -398,14 +435,26 @@
     RunCommandToFd(fd, "Citadel STATS", {"/vendor/bin/hw/citadel_updater", "--stats"});
     RunCommandToFd(fd, "Citadel BOARDID", {"/vendor/bin/hw/citadel_updater", "--board_id"});
 
+    // Dump various events in WiFi data path
+    DumpFileToFd(fd, "WLAN DP Trace", "/d/wlan/dpt_stats/dump_set_dpt_logs");
+
     // Keep this at the end as very long on not for humans
     DumpFileToFd(fd, "WLAN FW Log Symbol Table", "/vendor/firmware/Data.msc");
 
+    return DumpstateStatus::OK;
+}
+
+Return<void> DumpstateDevice::setVerboseLoggingEnabled(const bool enable) {
+    android::base::SetProperty(VENDOR_VERBOSE_LOGGING_ENABLED_PROPERTY, enable ? "true" : "false");
     return Void();
 }
 
+Return<bool> DumpstateDevice::getVerboseLoggingEnabled() {
+    return android::base::GetBoolProperty(VENDOR_VERBOSE_LOGGING_ENABLED_PROPERTY, false);
+}
+
 }  // namespace implementation
-}  // namespace V1_0
+}  // namespace V1_1
 }  // namespace dumpstate
 }  // namespace hardware
 }  // namespace android
diff --git a/dumpstate/DumpstateDevice.h b/dumpstate/DumpstateDevice.h
index ba5fcb7..55dc1f6 100644
--- a/dumpstate/DumpstateDevice.h
+++ b/dumpstate/DumpstateDevice.h
@@ -13,10 +13,10 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-#ifndef ANDROID_HARDWARE_DUMPSTATE_V1_0_DUMPSTATEDEVICE_H
-#define ANDROID_HARDWARE_DUMPSTATE_V1_0_DUMPSTATEDEVICE_H
+#ifndef ANDROID_HARDWARE_DUMPSTATE_V1_1_DUMPSTATEDEVICE_H
+#define ANDROID_HARDWARE_DUMPSTATE_V1_1_DUMPSTATEDEVICE_H
 
-#include <android/hardware/dumpstate/1.0/IDumpstateDevice.h>
+#include <android/hardware/dumpstate/1.1/IDumpstateDevice.h>
 #include <hidl/MQDescriptor.h>
 #include <hidl/Status.h>
 #include <string>
@@ -24,10 +24,12 @@
 namespace android {
 namespace hardware {
 namespace dumpstate {
-namespace V1_0 {
+namespace V1_1 {
 namespace implementation {
 
-using ::android::hardware::dumpstate::V1_0::IDumpstateDevice;
+using ::android::hardware::dumpstate::V1_1::DumpstateMode;
+using ::android::hardware::dumpstate::V1_1::DumpstateStatus;
+using ::android::hardware::dumpstate::V1_1::IDumpstateDevice;
 using ::android::hardware::hidl_array;
 using ::android::hardware::hidl_handle;
 using ::android::hardware::hidl_string;
@@ -40,15 +42,22 @@
   // Methods from ::android::hardware::dumpstate::V1_0::IDumpstateDevice follow.
   Return<void> dumpstateBoard(const hidl_handle& h) override;
 
+  // Methods from ::android::hardware::dumpstate::V1_1::IDumpstateDevice follow.
+  Return<DumpstateStatus> dumpstateBoard_1_1(const hidl_handle& h,
+                                             const DumpstateMode mode,
+                                             const uint64_t timeoutMillis) override;
+  Return<void> setVerboseLoggingEnabled(const bool enable) override;
+  Return<bool> getVerboseLoggingEnabled() override;
+
   void dumpLogs(int fd, std::string srcDir, std::string destDir, int maxFileNum,
                 const char *logPrefix);
   void dumpModem(int fd, int fdModem);
 };
 
 }  // namespace implementation
-}  // namespace V1_0
+}  // namespace V1_1
 }  // namespace dumpstate
 }  // namespace hardware
 }  // namespace android
 
-#endif  // ANDROID_HARDWARE_DUMPSTATE_V1_0_DUMPSTATEDEVICE_H
+#endif  // ANDROID_HARDWARE_DUMPSTATE_V1_1_DUMPSTATEDEVICE_H
diff --git a/dumpstate/android.hardware.dumpstate@1.0-service.bonito.rc b/dumpstate/android.hardware.dumpstate@1.0-service.bonito.rc
deleted file mode 100644
index 5f40217..0000000
--- a/dumpstate/android.hardware.dumpstate@1.0-service.bonito.rc
+++ /dev/null
@@ -1,8 +0,0 @@
-service vendor.dumpstate-1-0 /vendor/bin/hw/android.hardware.dumpstate@1.0-service.bonito
-    class hal
-    user system
-    group system vendor_rfs
-    interface android.hardware.dumpstate@1.0::IDumpstateDevice default
-
-on boot
-    chmod 0444 /sys/kernel/debug/tzdbg/qsee_log
diff --git a/dumpstate/android.hardware.dumpstate@1.1-service.bonito.rc b/dumpstate/android.hardware.dumpstate@1.1-service.bonito.rc
new file mode 100644
index 0000000..653d6cf
--- /dev/null
+++ b/dumpstate/android.hardware.dumpstate@1.1-service.bonito.rc
@@ -0,0 +1,9 @@
+service vendor.dumpstate-1-1 /vendor/bin/hw/android.hardware.dumpstate@1.1-service.bonito
+    class hal
+    user system
+    group system vendor_rfs
+    interface android.hardware.dumpstate@1.0::IDumpstateDevice default
+    interface android.hardware.dumpstate@1.1::IDumpstateDevice default
+
+on boot
+    chmod 0444 /sys/kernel/debug/tzdbg/qsee_log
diff --git a/dumpstate/service.cpp b/dumpstate/service.cpp
index 14b402f..907401f 100644
--- a/dumpstate/service.cpp
+++ b/dumpstate/service.cpp
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-#define LOG_TAG "android.hardware.dumpstate@1.0-service.bonito"
+#define LOG_TAG "android.hardware.dumpstate@1.1-service.bonito"
 
 #include <hidl/HidlSupport.h>
 #include <hidl/HidlTransportSupport.h>
@@ -21,8 +21,8 @@
 #include "DumpstateDevice.h"
 
 using ::android::hardware::configureRpcThreadpool;
-using ::android::hardware::dumpstate::V1_0::IDumpstateDevice;
-using ::android::hardware::dumpstate::V1_0::implementation::DumpstateDevice;
+using ::android::hardware::dumpstate::V1_1::IDumpstateDevice;
+using ::android::hardware::dumpstate::V1_1::implementation::DumpstateDevice;
 using ::android::hardware::joinRpcThreadpool;
 using ::android::sp;
 
diff --git a/fstab.hardware b/fstab.hardware
index 8346e91..3d41165 100644
--- a/fstab.hardware
+++ b/fstab.hardware
@@ -18,5 +18,5 @@
 # and fails if it does not find it.
 /dev/block/bootdevice/by-name/misc                      /misc                            emmc    defaults                                             defaults
 /devices/platform/soc/a600000.ssusb/a600000.dwc3/xhci-hcd.*.auto*     /storage/usbotg    vfat    nosuid,nodev    wait,voldmanaged=usbotg:auto
-/dev/block/zram0                                    none               swap        defaults                                              zramsize=2147483648,max_comp_streams=8,zram_loopback_path=/data/per_boot/zram_swap,zram_loopback_size=512M
+/dev/block/zram0                                    none               swap        defaults                                              zramsize=2147483648,max_comp_streams=8,zram_backingdev_size=512M
 /dev/block/platform/soc/7c4000.sdhci/by-name/persist    /mnt/vendor/persist              ext4    nosuid,nodev,noatime,barrier=1          wait,first_stage_mount
diff --git a/health/Android.bp b/health/Android.bp
index b06227b..9eb609f 100644
--- a/health/Android.bp
+++ b/health/Android.bp
@@ -43,8 +43,6 @@
         "libbase",
         "libcutils",
         "libhidlbase",
-        "libhidltransport",
-        "libhwbinder",
         "libpixelhealth",
         "libutils",
         "android.hardware.health@2.0",
diff --git a/health/HealthService.cpp b/health/HealthService.cpp
index 37c1c24..cfbe339 100644
--- a/health/HealthService.cpp
+++ b/health/HealthService.cpp
@@ -14,9 +14,8 @@
  * limitations under the License.
  */
 #define LOG_TAG "android.hardware.health@2.0-service.bonito"
-#include <android-base/logging.h>
-
 #include <android-base/file.h>
+#include <android-base/logging.h>
 #include <android-base/parseint.h>
 #include <android-base/strings.h>
 #include <health2/Health.h>
@@ -24,18 +23,20 @@
 #include <healthd/healthd.h>
 #include <hidl/HidlTransportSupport.h>
 #include <pixelhealth/BatteryMetricsLogger.h>
+#include <pixelhealth/BatteryThermalControl.h>
 #include <pixelhealth/CycleCountBackupRestore.h>
 #include <pixelhealth/DeviceHealth.h>
 #include <pixelhealth/LowBatteryShutdownMetrics.h>
 
-#include "BatteryRechargingControl.h"
-#include "BatteryInfoUpdate.h"
-#include "LearnedCapacityBackupRestore.h"
 #include <fstream>
 #include <iomanip>
 #include <string>
 #include <vector>
 
+#include "BatteryInfoUpdate.h"
+#include "BatteryRechargingControl.h"
+#include "LearnedCapacityBackupRestore.h"
+
 namespace {
 
 using android::hardware::health::V2_0::DiskStats;
@@ -45,6 +46,7 @@
 using ::device::google::bonito::health::BatteryInfoUpdate;
 using ::device::google::bonito::health::LearnedCapacityBackupRestore;
 using hardware::google::pixel::health::BatteryMetricsLogger;
+using hardware::google::pixel::health::BatteryThermalControl;
 using hardware::google::pixel::health::CycleCountBackupRestore;
 using hardware::google::pixel::health::DeviceHealth;
 using hardware::google::pixel::health::LowBatteryShutdownMetrics;
@@ -57,10 +59,11 @@
 
 static BatteryRechargingControl battRechargingControl;
 static BatteryInfoUpdate battInfoUpdate;
+static BatteryThermalControl battThermalControl("sys/devices/virtual/thermal/tz-by-name/soc/mode");
 static BatteryMetricsLogger battMetricsLogger(kBatteryResistance, kBatteryOCV);
 static LowBatteryShutdownMetrics shutdownMetrics(kVoltageAvg);
 static CycleCountBackupRestore ccBackupRestoreBMS(
-    8, kCycleCountsBins, "/persist/battery/qcom_cycle_counts_bins");
+    8, kCycleCountsBins, "/mnt/vendor/persist/battery/qcom_cycle_counts_bins");
 static DeviceHealth deviceHealth;
 static LearnedCapacityBackupRestore lcBackupRestore;
 
@@ -111,6 +114,7 @@
 int healthd_board_battery_update(struct android::BatteryProperties *props) {
     battRechargingControl.updateBatteryProperties(props);
     deviceHealth.update(props);
+    battThermalControl.updateThermalState(props);
     battInfoUpdate.update(props);
     battMetricsLogger.logBatteryProperties(props);
     shutdownMetrics.logShutdownVoltage(props);
diff --git a/health/LearnedCapacityBackupRestore.cpp b/health/LearnedCapacityBackupRestore.cpp
index cfea5c0..1f30707 100644
--- a/health/LearnedCapacityBackupRestore.cpp
+++ b/health/LearnedCapacityBackupRestore.cpp
@@ -23,7 +23,7 @@
 
 static constexpr char kChgFullDesignFile[] = "sys/class/power_supply/bms/charge_full_design";
 static constexpr char kChgFullFile[] = "sys/class/power_supply/bms/charge_full";
-static constexpr char kSysCFPersistFile[] = "/persist/battery/qcom_charge_full";
+static constexpr char kSysCFPersistFile[] = "/mnt/vendor/persist/battery/qcom_charge_full";
 static constexpr int kBuffSize = 256;
 
 LearnedCapacityBackupRestore::LearnedCapacityBackupRestore() {}
diff --git a/init.hardware.diag.rc.user b/init.hardware.diag.rc.user
index c24f851..f6ba93c 100644
--- a/init.hardware.diag.rc.user
+++ b/init.hardware.diag.rc.user
@@ -14,6 +14,37 @@
 # limitations under the License.
 #
 
-on property:ro.boot.mode=normal
-    rm /dev/diag
-    rm /dev/diagtest
+on init
+    chmod 666 /dev/diag
+
+on post-fs-data
+    mkdir /data/vendor/radio 0777 radio radio
+    mkdir /data/vendor/radio/diag_logs 0777 system system
+    rm /data/vendor/radio/diag_logs/logs/diag_poweron_log.qmdl
+
+service diag_mdlog_start /vendor/bin/diag_mdlog
+    class late_start
+    user shell
+    group system diag media_rw
+    disabled
+    oneshot
+
+service diag_mdlog_stop /vendor/bin/diag_mdlog -k
+    class late_start
+    user shell
+    group system diag media_rw
+    disabled
+    oneshot
+
+on boot && property:persist.vendor.sys.modem.diag.mdlog=*
+    rm /data/vendor/radio/diag_logs/diag_mdlog_pid
+    setprop vendor.sys.modem.diag.mdlog ${persist.vendor.sys.modem.diag.mdlog}
+
+on property:vendor.sys.modem.diag.mdlog=true
+    start diag_mdlog_start
+
+on property:vendor.sys.modem.diag.mdlog=false
+    start diag_mdlog_stop
+
+on property:persist.vendor.verbose_logging_enabled=*
+    setprop persist.vendor.sys.modem.diag.mdlog ${persist.vendor.verbose_logging_enabled}
diff --git a/init.hardware.diag.rc.userdebug b/init.hardware.diag.rc.userdebug
index 308535e..89ee2bf 100644
--- a/init.hardware.diag.rc.userdebug
+++ b/init.hardware.diag.rc.userdebug
@@ -110,3 +110,6 @@
 
 on property:persist.vendor.usb.usbradio.config=*
    start usbd
+
+on property:persist.vendor.verbose_logging_enabled=*
+   setprop persist.vendor.sys.modem.diag.mdlog ${persist.vendor.verbose_logging_enabled}
diff --git a/init.hardware.rc b/init.hardware.rc
index b462312..051dea1 100644
--- a/init.hardware.rc
+++ b/init.hardware.rc
@@ -148,6 +148,7 @@
     chown system system /sys/devices/virtual/thermal/tz-by-name/mb-therm-monitor/trip_point_0_hyst
     chown system system /sys/devices/virtual/thermal/tz-by-name/usbc-therm-monitor/trip_point_0_temp
     chown system system /sys/devices/virtual/thermal/tz-by-name/usbc-therm-monitor/trip_point_0_hyst
+    chown system system /sys/devices/virtual/thermal/tz-by-name/soc/mode
 
 on fs
     mount_all /vendor/etc/fstab.${ro.boot.hardware.platform} --early
@@ -304,6 +305,8 @@
 
     mkdir /data/vendor/sensors 0770
     chown system system /data/vendor/sensors
+    mkdir /data/vendor/sensors/log 0770
+    chown system system /data/vendor/sensors/log
 
     chmod 770 /mnt/vendor/persist/audio
     chmod 660 /mnt/vendor/persist/audio/audio.cal
@@ -386,7 +389,6 @@
     chown system system /sys/class/leds/green/rgb_start
     chown system system /sys/class/leds/blue/rgb_start
     chown system system /sys/class/backlight/panel0-backlight/brightness
-    chown system system /sys/class/backlight/panel0-backlight/vr_mode
 
     # Permission for Wireless charger
     chown system system /sys/devices/platform/soc/a88000.i2c/i2c-0/0-0061/rxdata
@@ -638,21 +640,6 @@
    group system
    capabilities NET_BIND_SERVICE
 
-service wpa_supplicant /vendor/bin/hw/wpa_supplicant \
-    -O/data/vendor/wifi/wpa/sockets -puse_p2p_group_interface=1 -dd \
-    -g@android:wpa_wlan0
-    #   we will start as root and wpa_supplicant will switch to user wifi
-    #   after setting up the capabilities required for WEXT
-    #   user wifi
-    #   group wifi inet keystore
-    interface android.hardware.wifi.supplicant@1.0::ISupplicant default
-    interface android.hardware.wifi.supplicant@1.1::ISupplicant default
-    interface android.hardware.wifi.supplicant@1.2::ISupplicant default
-    class main
-    socket wpa_wlan0 dgram 660 wifi wifi
-    disabled
-    oneshot
-
 service cnss-daemon /vendor/bin/cnss-daemon -n -l
    class late_start
    user system
@@ -724,20 +711,12 @@
      class core
 
 # bugreport is triggered by holding down volume down, volume up and power
-service bugreport /system/bin/dumpstate -d -p -B -z \
-        -o /data/user_de/0/com.android.shell/files/bugreports/bugreport
+service bugreport /system/bin/dumpstate -d -p -z
     class main
     disabled
     oneshot
     keycodes 114 115 116
 
-service vendor.chre /vendor/bin/chre
-    class late_start
-    user system
-    group system
-    socket chre seqpacket 0660 root system
-    shutdown critical
-
 service devstart_sh /vendor/bin/init.qcom.devstart.sh
     class main
     user root
@@ -844,10 +823,21 @@
     chown system system /sys/devices/platform/soc/a84000.i2c/i2c-2/2-0020/input/input2/suspend
 
 # DSDS feature
+# Restart 1st qcrild after SIM config changed
+on property:vendor.radio.sim_num.switch=1to2 && property:persist.radio.multisim.config=dsds
+    restart vendor.qcrild
+
+on property:vendor.radio.sim_num.switch=2to1 && property:persist.radio.multisim.config=
+    restart vendor.qcrild
+
 # Enable 2nd qcrild when the property set to dsds
 on property:persist.radio.multisim.config=dsds
     start vendor.qcrild2
 
+# Stop 2nd qcrild when the property set to empty string
+on property:persist.radio.multisim.config=
+    stop vendor.qcrild2
+
 on property:sys.boot_completed=1 && property:ro.boot.mode=firstboot
     start init-firstboot-sh
 
diff --git a/init.qcom.devstart.sh b/init.qcom.devstart.sh
index 4d5c4f9..9f67a0b 100644
--- a/init.qcom.devstart.sh
+++ b/init.qcom.devstart.sh
@@ -8,4 +8,4 @@
 version=`grep -ao "OEM_IMAGE_VERSION_STRING[ -~]*" \
               /vendor/firmware/adsp.b04 | \
          sed -e s/OEM_IMAGE_VERSION_STRING=ADSP.version.// -e s/\(.*\).//`
-setprop sys.adsp.firmware.version "$version"
+setprop vendor.sys.adsp.firmware.version "$version"
diff --git a/manifest.xml b/manifest.xml
index 8000b1d..32d35ea 100644
--- a/manifest.xml
+++ b/manifest.xml
@@ -2,7 +2,7 @@
     <hal format="hidl">
         <name>android.hardware.audio</name>
         <transport>hwbinder</transport>
-        <version>5.0</version>
+        <version>6.0</version>
         <interface>
             <name>IDevicesFactory</name>
             <instance>default</instance>
@@ -11,7 +11,7 @@
     <hal format="hidl">
         <name>android.hardware.audio.effect</name>
         <transport>hwbinder</transport>
-        <version>5.0</version>
+        <version>6.0</version>
         <interface>
             <name>IEffectsFactory</name>
             <instance>default</instance>
@@ -90,15 +90,6 @@
         </interface>
     </hal>
     <hal format="hidl">
-        <name>android.hardware.contexthub</name>
-        <transport>hwbinder</transport>
-        <version>1.0</version>
-        <interface>
-            <name>IContexthub</name>
-            <instance>default</instance>
-        </interface>
-    </hal>
-    <hal format="hidl">
         <name>android.hardware.drm</name>
         <transport>hwbinder</transport>
         <version>1.0</version>
@@ -112,13 +103,11 @@
         </interface>
         <fqname>@1.2::ICryptoFactory/clearkey</fqname>
         <fqname>@1.2::IDrmFactory/clearkey</fqname>
-        <fqname>@1.2::ICryptoFactory/widevine</fqname>
-        <fqname>@1.2::IDrmFactory/widevine</fqname>
     </hal>
     <hal format="hidl">
         <name>android.hardware.dumpstate</name>
         <transport>hwbinder</transport>
-        <version>1.0</version>
+        <version>1.1</version>
         <interface>
             <name>IDumpstateDevice</name>
             <instance>default</instance>
@@ -275,7 +264,7 @@
     <hal format="hidl">
         <name>vendor.google.radioext</name>
         <transport>hwbinder</transport>
-        <version>1.1</version>
+        <version>1.2</version>
         <interface>
             <name>IRadioExt</name>
             <instance>default</instance>
@@ -309,7 +298,7 @@
     <hal format="hidl">
         <name>android.hardware.sensors</name>
         <transport>hwbinder</transport>
-        <version>1.0</version>
+        <version>2.0</version>
         <interface>
             <name>ISensors</name>
             <instance>default</instance>
@@ -361,15 +350,6 @@
         </interface>
     </hal>
     <hal format="hidl">
-        <name>android.hardware.vibrator</name>
-        <transport>hwbinder</transport>
-        <version>1.2</version>
-        <interface>
-            <name>IVibrator</name>
-            <instance>default</instance>
-        </interface>
-    </hal>
-    <hal format="hidl">
         <name>android.hardware.weaver</name>
         <transport>hwbinder</transport>
         <version>1.0</version>
@@ -379,33 +359,6 @@
         </interface>
     </hal>
     <hal format="hidl">
-        <name>android.hardware.wifi</name>
-        <transport>hwbinder</transport>
-        <version>1.3</version>
-        <interface>
-            <name>IWifi</name>
-            <instance>default</instance>
-        </interface>
-    </hal>
-    <hal format="hidl">
-        <name>android.hardware.wifi.hostapd</name>
-        <transport>hwbinder</transport>
-        <version>1.1</version>
-        <interface>
-            <name>IHostapd</name>
-            <instance>default</instance>
-        </interface>
-    </hal>
-    <hal format="hidl">
-        <name>android.hardware.wifi.supplicant</name>
-        <transport>hwbinder</transport>
-        <version>1.2</version>
-        <interface>
-            <name>ISupplicant</name>
-            <instance>default</instance>
-        </interface>
-    </hal>
-    <hal format="hidl">
         <name>vendor.qti.hardware.radio.ims</name>
         <transport>hwbinder</transport>
         <version>1.2</version>
diff --git a/media_codecs_google_audio.xml b/media_codecs_google_audio.xml
deleted file mode 100644
index 7e586fe..0000000
--- a/media_codecs_google_audio.xml
+++ /dev/null
@@ -1,103 +0,0 @@
-<?xml version="1.0" encoding="utf-8" ?>
-<!-- Copyright (C) 2014 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
-
--->
-
-<Included>
-    <Decoders>
-        <MediaCodec name="OMX.google.mp3.decoder" type="audio/mpeg">
-            <Limit name="channel-count" max="2" />
-            <Limit name="sample-rate" ranges="8000,11025,12000,16000,22050,24000,32000,44100,48000" />
-            <Limit name="bitrate" range="8000-320000" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.amrnb.decoder" type="audio/3gpp">
-            <Limit name="channel-count" max="1" />
-            <Limit name="sample-rate" ranges="8000" />
-            <Limit name="bitrate" range="4750-12200" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.amrwb.decoder" type="audio/amr-wb">
-            <Limit name="channel-count" max="1" />
-            <Limit name="sample-rate" ranges="16000" />
-            <Limit name="bitrate" range="6600-23850" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.aac.decoder" type="audio/mp4a-latm">
-            <Limit name="channel-count" max="8" />
-            <Limit name="sample-rate" ranges="7350,8000,11025,12000,16000,22050,24000,32000,44100,48000" />
-            <Limit name="bitrate" range="8000-960000" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.xaac.decoder" type="audio/mp4a-latm">
-            <Limit name="channel-count" max="8" />
-            <Limit name="sample-rate" ranges="7350,8000,11025,12000,16000,22050,24000,32000,44100,48000" />
-            <Limit name="bitrate" range="8000-960000" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.g711.alaw.decoder" type="audio/g711-alaw">
-            <Limit name="channel-count" max="1" />
-            <Limit name="sample-rate" ranges="8000-48000" />
-            <Limit name="bitrate" range="64000" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.g711.mlaw.decoder" type="audio/g711-mlaw">
-            <Limit name="channel-count" max="1" />
-            <Limit name="sample-rate" ranges="8000-48000" />
-            <Limit name="bitrate" range="64000" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.vorbis.decoder" type="audio/vorbis">
-            <Limit name="channel-count" max="8" />
-            <Limit name="sample-rate" ranges="8000-96000" />
-            <Limit name="bitrate" range="32000-500000" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.opus.decoder" type="audio/opus">
-            <Limit name="channel-count" max="8" />
-            <Limit name="sample-rate" ranges="48000" />
-            <Limit name="bitrate" range="6000-510000" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.raw.decoder" type="audio/raw">
-            <Limit name="channel-count" max="8" />
-            <Limit name="sample-rate" ranges="8000-96000" />
-            <Limit name="bitrate" range="1-10000000" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.flac.decoder" type="audio/flac">
-            <Limit name="channel-count" max="8" />
-            <Limit name="sample-rate" ranges="1-655350" />
-            <Limit name="bitrate" range="1-21000000" />
-        </MediaCodec>
-    </Decoders>
-    <Encoders>
-        <MediaCodec name="OMX.google.aac.encoder" type="audio/mp4a-latm">
-            <Limit name="channel-count" max="6" />
-            <Limit name="sample-rate" ranges="8000,11025,12000,16000,22050,24000,32000,44100,48000" />
-            <!-- also may support 64000, 88200  and 96000 Hz -->
-            <Limit name="bitrate" range="8000-960000" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.amrnb.encoder" type="audio/3gpp">
-            <Limit name="channel-count" max="1" />
-            <Limit name="sample-rate" ranges="8000" />
-            <Limit name="bitrate" range="4750-12200" />
-            <Feature name="bitrate-modes" value="CBR" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.amrwb.encoder" type="audio/amr-wb">
-            <Limit name="channel-count" max="1" />
-            <Limit name="sample-rate" ranges="16000" />
-            <Limit name="bitrate" range="6600-23850" />
-            <Feature name="bitrate-modes" value="CBR" />
-        </MediaCodec>
-        <MediaCodec name="OMX.google.flac.encoder" type="audio/flac">
-            <Limit name="channel-count" max="2" />
-            <Limit name="sample-rate" ranges="1-655350" />
-            <Limit name="bitrate" range="1-21000000" />
-            <Limit name="complexity" range="0-8"  default="5" />
-            <Feature name="bitrate-modes" value="CQ" />
-        </MediaCodec>
-    </Encoders>
-</Included>
diff --git a/overlay/frameworks/base/core/res/res/values/config.xml b/overlay/frameworks/base/core/res/res/values/config.xml
index 89b99f5..be462e4 100644
--- a/overlay/frameworks/base/core/res/res/values/config.xml
+++ b/overlay/frameworks/base/core/res/res/values/config.xml
@@ -120,6 +120,13 @@
     </string-array>
 
     <!-- List of regexpressions describing the interface (if any) that represent tetherable
+         Wifi P2P interfaces.  If the device doesn't want to support tethering over Wifi P2p this
+         should be empty.  An example would be "p2p-p2p.*" -->
+    <string-array translatable="false" name="config_tether_wifi_p2p_regexs">
+        <item>"p2p-p2p\\d-.*"</item>
+    </string-array>
+
+    <!-- List of regexpressions describing the interface (if any) that represent tetherable
          bluetooth interfaces.  If the device doesn't want to support tethering over bluetooth this
          should be empty. -->
     <string-array translatable="false" name="config_tether_bluetooth_regexs">
@@ -182,20 +189,6 @@
         <item>"9,1"</item>
     </string-array>
 
-    <!-- Boolean indicating whether the wifi chipset has dual frequency band support -->
-    <bool translatable="false" name="config_wifi_dual_band_support">true</bool>
-
-    <!-- Boolean indicating whether the wifi chipset requires the softap band be -->
-    <!-- converted from 5GHz to ANY due to hardware restrictions -->
-    <bool translatable="false" name="config_wifi_convert_apband_5ghz_to_any">true</bool>
-
-    <!-- Boolean indicating whether 802.11r Fast BSS Transition is enabled on this platform -->
-    <bool translatable="false" name="config_wifi_fast_bss_transition_enabled">true</bool>
-
-    <!-- Boolean indicating whether the wifi chipset has background scan support -->
-    <bool translatable="false" name="config_wifi_background_scan_support">true</bool>
-
-
     <!-- Vibrator pattern for feedback about a long screen/key press -->
     <integer-array name="config_longPressVibePattern">
         <item>8</item>
@@ -204,16 +197,6 @@
     <!-- Make things go fast -->
     <bool name="config_ui_enableFadingMarquee">false</bool>
 
-    <!-- Wifi driver supports batched scan -->
-    <bool translatable="false" name="config_wifi_batched_scan_supported">true</bool>
-
-    <!-- Boolean indicating whether or not to revert to default country code when cellular
-    radio is unable to find any MCC information to infer wifi country code from -->
-    <bool translatable="false" name="config_wifi_revert_country_code_on_cellular_loss">true</bool>
-
-    <!-- Boolean indicating whether or not wifi should turn off when emergency call is made -->
-    <bool translatable="false" name="config_wifi_turn_off_during_emergency_call">true</bool>
-
    <!-- Enable doze mode
          ComponentName of a dream to show whenever the system would otherwise have gone to sleep. -->
     <string translatable="false" name="config_dozeComponent">com.android.systemui/com.android.systemui.doze.DozeService</string>
@@ -269,25 +252,6 @@
         <item>lte:524288,1048576,8388608,262144,524288,4194304</item>
     </string-array>
 
-    <!-- Configure wifi tcp buffersizes in the form:
-         rmem_min,rmem_def,rmem_max,wmem_min,wmem_def,wmem_max -->
-    <string name="config_wifi_tcp_buffers" translatable="false">524288,2097152,8388608,262144,524288,4194304</string>
-
-    <!-- Idle Receive current for wifi radio. 0 by default-->
-    <integer translatable="false" name="config_wifi_idle_receive_cur_ma">1</integer>
-
-    <!-- Rx current for wifi radio. 0 by default-->
-    <integer translatable="false" name="config_wifi_active_rx_cur_ma">100</integer>
-
-    <!-- Tx current for wifi radio. 0 by default-->
-    <integer translatable="false" name="config_wifi_tx_cur_ma">250</integer>
-
-    <!-- Operating volatage for wifi radio. 0 by default-->
-    <integer translatable="false" name="config_wifi_operating_voltage_mv">3800</integer>
-
-    <!-- Config SoftAP 2G channel list -->
-    <string  translatable="false" name="config_wifi_framework_sap_2G_channel_list">6</string>
-
     <!-- Config determines whether to update phone object when voice registration
          state changes. Voice radio tech change will always trigger an update of
          phone object irrespective of this config -->
@@ -316,11 +280,11 @@
         <item>"/system/framework/services.jar"</item>
         <item>"/system/framework/arm64/boot.oat"</item>
         <item>"/system/framework/arm64/boot-core-libart.oat"</item>
-        <item>"/apex/com.android.runtime/javalib/core-oj.jar"</item>
-        <item>"/apex/com.android.runtime/javalib/core-libart.jar"</item>
+        <item>"/apex/com.android.art/javalib/core-oj.jar"</item>
+        <item>"/apex/com.android.art/javalib/core-libart.jar"</item>
         <item>"/apex/com.android.media/javalib/updatable-media.jar"</item>
-        <item>"/product/priv-app/SystemUIGoogle/SystemUIGoogle.apk"</item>
-        <item>"/product/priv-app/SystemUIGoogle/oat/arm64/SystemUIGoogle.odex"</item>
+        <item>"/system_ext/priv-app/SystemUIGoogle/SystemUIGoogle.apk"</item>
+        <item>"/system_ext/priv-app/SystemUIGoogle/oat/arm64/SystemUIGoogle.odex"</item>
         <item>"/system/lib64/libsurfaceflinger.so"</item>
     </string-array>
 
@@ -366,20 +330,6 @@
     <!-- Whether the new Auto Selection Network UI should be shown -->
     <bool name="config_enableNewAutoSelectNetworkUI">true</bool>
 
-    <!-- Enable ACS (auto channel selection) for Wifi hotspot (SAP) -->
-    <bool translatable="false" name="config_wifi_softap_acs_supported">true</bool>
-
-    <!-- Enable 802.11ac for Wifi hotspot (SAP) -->
-    <bool translatable="false" name="config_wifi_softap_ieee80211ac_supported">true</bool>
-
-    <!-- Integer thresholds, do not connect to APs with RSSI lower than these values  -->
-    <integer translatable="false" name="config_wifi_framework_wifi_score_entry_rssi_threshold_5GHz">-77</integer>
-    <integer translatable="false" name="config_wifi_framework_wifi_score_entry_rssi_threshold_24GHz">-80</integer>
-    <!-- Integer thresholds for low network score, should be somewhat less than the entry threshholds -->
-    <integer translatable="false" name="config_wifi_framework_wifi_score_bad_rssi_threshold_5GHz">-80</integer>
-    <integer translatable="false" name="config_wifi_framework_wifi_score_bad_rssi_threshold_24GHz">-83</integer>
-
-
     <!-- The default intensity level for haptic feedback. See
          Settings.System.HAPTIC_FEEDBACK_INTENSITY more details on the constant values and
          meanings. -->
@@ -398,12 +348,6 @@
         <item>com.felicanetworks.mfc</item>
         <item>com.felicanetworks.mfm</item>
     </string-array>
-
-    <!-- True if the firmware supports Wi-Fi link probing -->
-    <bool name="config_wifi_link_probing_supported">true</bool>
-
-    <!-- True if the firmware supports connected MAC randomization -->
-    <bool name="config_wifi_connected_mac_randomization_supported">true</bool>
     <!-- Enable Zram writeback feature to allow unused pages in zram be written to flash. -->
     <bool name="config_zramWriteback">true</bool>
 </resources>
diff --git a/overlay/frameworks/base/packages/SettingsProvider/res/values/defaults.xml b/overlay/frameworks/base/packages/SettingsProvider/res/values/defaults.xml
deleted file mode 100644
index 378e34b..0000000
--- a/overlay/frameworks/base/packages/SettingsProvider/res/values/defaults.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/**
- * Copyright (c) 2018, The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
--->
-<resources>
-    <!-- Default for Settings.System.VIBRATE_WHEN_RINGING -->
-    <bool name="def_vibrate_when_ringing">true</bool>
-    <!-- Default for Settings.Global.APPLY_RAMPING_RINGER -->
-    <bool name="def_apply_ramping_ringer">false</bool>
-</resources>
diff --git a/overlay/packages/apps/Bluetooth/res/values/config.xml b/overlay/packages/apps/Bluetooth/res/values/config.xml
deleted file mode 100644
index e403105..0000000
--- a/overlay/packages/apps/Bluetooth/res/values/config.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-Copyright (c) 2017, The Linux Foundation. All rights reserved.
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions are
-met:
-    * Redistributions of source code must retain the above copyright
-      notice, this list of conditions and the following disclaimer.
-    * Redistributions in binary form must reproduce the above
-      copyright notice, this list of conditions and the following
-      disclaimer in the documentation and/or other materials provided
-      with the distribution.
-    * Neither the name of The Linux Foundation nor the names of its
-      contributors may be used to endorse or promote products derived
-      from this software without specific prior written permission.
-
-THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
-WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT
-ARE DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
-BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
-BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
-WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
-OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
-IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
--->
-<resources>
-    <bool name="profile_supported_sap">true</bool>
-    <bool name="profile_supported_hearing_aid">true</bool>
-</resources>
diff --git a/pixelstats/Android.bp b/pixelstats/Android.bp
index bb65839..dadea9d 100644
--- a/pixelstats/Android.bp
+++ b/pixelstats/Android.bp
@@ -24,7 +24,6 @@
     "libbinder",
     "libcutils",
     "libhidlbase",
-    "libhidltransport",
     "liblog",
     "libutils",
     "libpixelstats",
diff --git a/powerstats/Android.bp b/powerstats/Android.bp
index 5c4fac6..ad273df 100644
--- a/powerstats/Android.bp
+++ b/powerstats/Android.bp
@@ -28,7 +28,6 @@
         "libbase",
         "libcutils",
         "libhidlbase",
-        "libhidltransport",
         "libfmq",
         "liblog",
         "libutils",
diff --git a/rro_overlays/TelephonyOverlay/Android.bp b/rro_overlays/TelephonyOverlay/Android.bp
new file mode 100644
index 0000000..72abbfa
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Android.bp
@@ -0,0 +1,37 @@
+//
+// Copyright (C) 2020 The Android Open Source Project
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+runtime_resource_overlay {
+    name: "TelephonyOverlay2018MidyearBonito",
+    resource_dirs: ["Bonito/res","Common/res"],
+    certificate: "platform",
+    product_specific: true,
+    aaptflags: ["--auto-add-overlay"],
+    manifest: "AndroidManifest.xml",
+    theme: "TelephonyOverlay2018MidyearBonito",
+}
+
+
+runtime_resource_overlay {
+    name: "TelephonyOverlay2018MidyearSargo",
+    resource_dirs: ["Sargo/res","Common/res"],
+    certificate: "platform",
+    product_specific: true,
+    aaptflags: ["--auto-add-overlay"],
+    manifest: "AndroidManifest.xml",
+    theme: "TelephonyOverlay2018MidyearSargo",
+}
+
diff --git a/rro_overlays/TelephonyOverlay/AndroidManifest.xml b/rro_overlays/TelephonyOverlay/AndroidManifest.xml
new file mode 100644
index 0000000..e3662bc
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/AndroidManifest.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2019 The Android Open Source Project
+
+     Licensed under the Apache License, Version 2.0 (the "License");
+     you may not use this file except in compliance with the License.
+     You may obtain a copy of the License at
+
+          http://www.apache.org/licenses/LICENSE-2.0
+
+     Unless required by applicable law or agreed to in writing, software
+     distributed under the License is distributed on an "AS IS" BASIS,
+     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+     See the License for the specific language governing permissions and
+     limitations under the License.
+-->
+<!-- Pixel specific wifi overlays -->
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.android.telephony.resources.pixel"
+    android:versionCode="1"
+    android:versionName="1.0">
+    <application android:hasCode="false" />
+    <overlay
+      android:targetPackage="com.android.telephony.resources"
+      android:targetName="TelephonyCustomization"
+      android:isStatic="true"
+      android:priority="0"/>
+</manifest>
+
diff --git a/rro_overlays/TelephonyOverlay/Bonito/res/values-mcc310-mnc004/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Bonito/res/values-mcc310-mnc004/donottranslate_config.xml
new file mode 100644
index 0000000..1cdb9c9
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Bonito/res/values-mcc310-mnc004/donottranslate_config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+ * Copyright (C) 2019 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+-->
+<resources>
+    <!-- MMS user agent string -->
+    <string name="config_mms_user_agent" translatable="false">g020a</string>
+    <!-- MMS user agent prolfile url -->
+    <string name="config_mms_user_agent_profile_url" translatable="false">http://uaprof.vtext.com/google/g020a/g020a.xml</string>
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Bonito/res/values-mcc311-mnc230/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Bonito/res/values-mcc311-mnc230/donottranslate_config.xml
new file mode 100644
index 0000000..6edf16c
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Bonito/res/values-mcc311-mnc230/donottranslate_config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2018, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+<resources>
+
+    <!-- MMS user agent string -->
+    <string name="config_mms_user_agent" translatable="false">g020c</string>
+    <!-- MMS user agent profile url -->
+    <string name="config_mms_user_agent_profile_url" translatable="false">http://pix.cspire.com/UA/profile/google/g020c/g020c.xml</string>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Bonito/res/values-mcc311-mnc480/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Bonito/res/values-mcc311-mnc480/donottranslate_config.xml
new file mode 100644
index 0000000..949b85d
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Bonito/res/values-mcc311-mnc480/donottranslate_config.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2018, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<resources>
+
+    <!-- MMS user agent string -->
+    <string name="config_mms_user_agent" translatable="false">g020a</string>
+    <!-- MMS user agent profile url -->
+    <string name="config_mms_user_agent_profile_url" translatable="false">http://uaprof.vtext.com/google/g020a/g020a.xml</string>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Bonito/res/values/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Bonito/res/values/donottranslate_config.xml
new file mode 100644
index 0000000..2457827
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Bonito/res/values/donottranslate_config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+ * Copyright (C) 2019 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+-->
+<resources>
+    <!-- MMS user agent string -->
+    <string name="config_mms_user_agent" translatable="false">g020c</string>
+    <!-- MMS user agent profile url -->
+    <string name="config_mms_user_agent_profile_url" translatable="false">http://www.gstatic.com/android/sms/G020C.xml</string>
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc204-mnc04/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc204-mnc04/donottranslate_config.xml
new file mode 100644
index 0000000..4eef2d0
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc204-mnc04/donottranslate_config.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+
+    <!-- Use ERI text for network name on CDMA LTE -->
+    <bool name="config_LTE_eri_for_network_name">false</bool>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc004/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc004/donottranslate_config.xml
new file mode 100644
index 0000000..4eef2d0
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc004/donottranslate_config.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+
+    <!-- Use ERI text for network name on CDMA LTE -->
+    <bool name="config_LTE_eri_for_network_name">false</bool>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc120/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc120/donottranslate_config.xml
new file mode 100644
index 0000000..b16c85d
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc120/donottranslate_config.xml
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+
+    <!-- Do not translate. Defines the slots is Two Digit Number for dialing normally not USSD -->
+    <string-array translatable="false" name="config_twoDigitNumberPattern">
+        <item>"*2"</item>
+    </string-array>
+
+    <!-- Sometimes, PDU has garbages. So, need to use valid index -->
+    <integer name="config_valid_wappush_index">4</integer>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc260/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc260/donottranslate_config.xml
new file mode 100644
index 0000000..4cb6c79
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc260/donottranslate_config.xml
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+    <!-- Configure mobile tcp buffer sizes in the form:
+         rat-name:rmem_min,rmem_def,rmem_max,wmem_min,wmem_def,wmem_max
+         If no value is found for the rat-name in use, the system default will be applied.
+    -->
+    <string-array name="config_mobile_tcp_buffers">
+        <item>umts:21135,131070,1056768,6144,24576,165312</item>
+        <item>hspa:18300,131070,1056768,6144,24576,393216</item>
+        <item>hsdpa:18300,131070,1056768,6144,24576,393216</item>
+        <item>hsupa:6141,131070,1056768,6144,24576,393216</item>
+        <item>hspap:31455,131070,1830912,6144,24576,1830912</item>
+        <item>edge:8192,26280,704512,4096,16384,110208</item>
+        <item>gprs:8192,8760,704512,4096,8760,110208</item>
+        <item>lte:2097152,4194304,8388608,262144,524288,1048576</item>
+    </string-array>
+
+
+</resources>
+
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc410/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc410/donottranslate_config.xml
new file mode 100644
index 0000000..4d0762e
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc310-mnc410/donottranslate_config.xml
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+    <!-- Configure mobile tcp buffer sizes in the form:
+         rat-name:rmem_min,rmem_def,rmem_max,wmem_min,wmem_def,wmem_max
+         If no value is found for the rat-name in use, the system default will be applied.
+    -->
+    <string-array name="config_mobile_tcp_buffers">
+        <item>umts:131072,262144,1452032,4096,16384,399360</item>
+        <item>hspa:131072,262144,1452032,4096,16384,399360</item>
+        <item>hsdpa:131072,262144,1452032,4096,16384,399360</item>
+        <item>hsupa:131072,262144,1452032,4096,16384,399360</item>
+        <item>hspap:131072,262144,1452032,4096,16384,399360</item>
+        <item>edge:4093,26280,35040,4096,16384,35040</item>
+        <item>gprs:4092,8760,11680,4096,8760,11680</item>
+        <item>evdo:4094,87380,262144,4096,16384,262144</item>
+        <item>lte:524288,1048576,8388608,262144,524288,4194304</item>
+    </string-array>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc311-mnc480/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc311-mnc480/donottranslate_config.xml
new file mode 100644
index 0000000..4eef2d0
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc311-mnc480/donottranslate_config.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+
+    <!-- Use ERI text for network name on CDMA LTE -->
+    <bool name="config_LTE_eri_for_network_name">false</bool>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc312-mnc530/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc312-mnc530/donottranslate_config.xml
new file mode 100644
index 0000000..b16c85d
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc312-mnc530/donottranslate_config.xml
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+
+    <!-- Do not translate. Defines the slots is Two Digit Number for dialing normally not USSD -->
+    <string-array translatable="false" name="config_twoDigitNumberPattern">
+        <item>"*2"</item>
+    </string-array>
+
+    <!-- Sometimes, PDU has garbages. So, need to use valid index -->
+    <integer name="config_valid_wappush_index">4</integer>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc01/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc01/donottranslate_config.xml
new file mode 100644
index 0000000..8c0c020
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc01/donottranslate_config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+    <bool name="config_auto_attach_data_on_creation">false</bool>
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc02/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc02/donottranslate_config.xml
new file mode 100644
index 0000000..8c0c020
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc02/donottranslate_config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+    <bool name="config_auto_attach_data_on_creation">false</bool>
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc03/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc03/donottranslate_config.xml
new file mode 100644
index 0000000..8c0c020
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc03/donottranslate_config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+    <bool name="config_auto_attach_data_on_creation">false</bool>
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc07/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc07/donottranslate_config.xml
new file mode 100644
index 0000000..8c0c020
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc07/donottranslate_config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+    <bool name="config_auto_attach_data_on_creation">false</bool>
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc11/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc11/donottranslate_config.xml
new file mode 100644
index 0000000..8c0c020
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc11/donottranslate_config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+    <bool name="config_auto_attach_data_on_creation">false</bool>
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc71/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc71/donottranslate_config.xml
new file mode 100644
index 0000000..8c0c020
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc71/donottranslate_config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+    <bool name="config_auto_attach_data_on_creation">false</bool>
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc72/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc72/donottranslate_config.xml
new file mode 100644
index 0000000..8c0c020
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc72/donottranslate_config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+    <bool name="config_auto_attach_data_on_creation">false</bool>
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc90/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc90/donottranslate_config.xml
new file mode 100644
index 0000000..8c0c020
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values-mcc505-mnc90/donottranslate_config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2016, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+    <bool name="config_auto_attach_data_on_creation">false</bool>
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values/donottranslate_arrays.xml b/rro_overlays/TelephonyOverlay/Common/res/values/donottranslate_arrays.xml
new file mode 100644
index 0000000..41dc40a
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values/donottranslate_arrays.xml
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2019 The Android Open Source Project
+
+     Licensed under the Apache License, Version 2.0 (the "License");
+     you may not use this file except in compliance with the License.
+     You may obtain a copy of the License at
+
+          http://www.apache.org/licenses/LICENSE-2.0
+
+     Unless required by applicable law or agreed to in writing, software
+     distributed under the License is distributed on an "AS IS" BASIS,
+     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+     See the License for the specific language governing permissions and
+     limitations under the License.
+-->
+
+<resources>
+    <!-- Device-specific array of SIM slot indexes which are are embedded eUICCs.
+         e.g. If a device has two physical slots with indexes 0, 1, and slot 1 is an
+         eUICC, then the value of this array should be:
+             <integer-array name="non_removable_euicc_slots">
+                 <item>1</item>
+             </integer-array>
+         If a device has three physical slots and slot 1 and 2 are eUICCs, then the value of
+         this array should be:
+             <integer-array name="non_removable_euicc_slots">
+                <item>1</item>
+                <item>2</item>
+             </integer-array>
+         This is used to differentiate between removable eUICCs and built in eUICCs, and should
+         be set by OEMs for devices which use eUICCs. -->
+    <integer-array name="non_removable_euicc_slots">
+        <item>1</item>
+    </integer-array>
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Common/res/values/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Common/res/values/donottranslate_config.xml
new file mode 100644
index 0000000..110ad49
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Common/res/values/donottranslate_config.xml
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+ * Copyright (C) 2019 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+-->
+<resources>
+    <!-- Config determines whether to update phone object when voice registration
+         state changes. Voice radio tech change will always trigger an update of
+         phone object irrespective of this config -->
+    <bool name="config_switch_phone_on_voice_reg_state_change">false</bool>
+
+    <!-- Boolean indicating if restoring network selection should be skipped -->
+    <!-- The restoring is handled by modem if it is true -->
+    <bool translatable="false" name="skip_restoring_network_selection">true</bool>
+
+    <!-- Number of physical SIM slots on the device. This includes both eSIM and pSIM slots, and
+         is not necessarily the same as the number of phones/logical modems supported by the device.
+         For example, a multi-sim device can have 2 phones/logical modems, but 3 physical slots,
+         or a single SIM device can have 1 phones/logical modems, but 2 physical slots (one eSIM
+         and one pSIM) -->
+    <integer name="config_num_physical_slots">2</integer>
+
+    <!-- Is the device capable of hot swapping an UICC Card -->
+    <bool name="config_hotswapCapable">true</bool>
+
+    <!-- An array of device capabilities defined by GSMA SGP.22 v2.0, and their corresponding major
+         version. -->
+    <string-array translatable="false" name="config_telephonyEuiccDeviceCapabilities">
+        <item>"gsm,11"</item>
+        <item>"utran,11"</item>
+        <item>"cdma1x,1"</item>
+        <item>"hrpd,3"</item>
+        <item>"ehrpd,12"</item>
+        <item>"eutran,11"</item>
+    </string-array>
+
+    <!-- Configure mobile tcp buffer sizes in the form:
+         rat-name:rmem_min,rmem_def,rmem_max,wmem_min,wmem_def,wmem_max
+         If no value is found for the rat-name in use, the system default will be applied.
+    -->
+    <string-array name="config_mobile_tcp_buffers">
+        <item>umts:131072,262144,1452032,4096,16384,399360</item>
+        <item>hspa:131072,262144,2441216,4096,16384,399360</item>
+        <item>hsupa:131072,262144,2441216,4096,16384,399360</item>
+        <item>hsdpa:131072,262144,2441216,4096,16384,399360</item>
+        <item>hspap:131072,262144,2441216,4096,16384,399360</item>
+        <item>edge:16384,32768,131072,4096,16384,65536</item>
+        <item>gprs:4096,8192,24576,4096,8192,24576</item>
+        <item>1xrtt:16384,32768,131070,4096,16384,102400</item>
+        <item>evdo:131072,262144,1048576,4096,16384,524288</item>
+        <item>lte:524288,1048576,8388608,262144,524288,4194304</item>
+    </string-array>
+
+    <!-- ImsService package name to bind to by default, if config_dynamic_bind_ims is true -->
+    <string name="config_ims_package" translatable="false">org.codeaurora.ims</string>
+
+    <!-- Flag specifying whether or not IMS will use the ImsResolver dynamically -->
+    <bool name="config_dynamic_bind_ims">true</bool>
+
+    <!-- Flag specifying whether VoLTE is availasble on device -->
+    <bool name="config_device_volte_available">true</bool>
+
+    <!-- Flag specifying whether VoLTE is available on device -->
+    <bool name="config_device_vt_available">true</bool>
+
+    <!-- Flag specifying whether WFC over IMS is availasble on device -->
+    <bool name="config_device_wfc_ims_available">true</bool>
+
+    <!-- Enable video pause workaround when enabling/disabling the camera. -->
+    <bool name="config_useVideoPauseWorkaround">true</bool>
+
+    <!-- Use ERI text for network name on CDMA LTE -->
+    <bool name="config_LTE_eri_for_network_name">true</bool>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Sargo/res/values-mcc310-mnc004/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Sargo/res/values-mcc310-mnc004/donottranslate_config.xml
new file mode 100644
index 0000000..edf7060
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Sargo/res/values-mcc310-mnc004/donottranslate_config.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2018, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+
+    <!-- MMS user agent string -->
+    <string name="config_mms_user_agent" translatable="false">g020e</string>
+    <!-- MMS user agent profile url -->
+    <string name="config_mms_user_agent_profile_url" translatable="false">http://uaprof.vtext.com/google/g020e/g020e.xml</string>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Sargo/res/values-mcc311-mnc230/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Sargo/res/values-mcc311-mnc230/donottranslate_config.xml
new file mode 100644
index 0000000..1a69fc6
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Sargo/res/values-mcc311-mnc230/donottranslate_config.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2018, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+
+    <!-- MMS user agent string -->
+    <string name="config_mms_user_agent" translatable="false">g020g</string>
+    <!-- MMS user agent profile url -->
+    <string name="config_mms_user_agent_profile_url" translatable="false">http://pix.cspire.com/UA/profile/google/g020g/g020g.xml</string>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Sargo/res/values-mcc311-mnc480/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Sargo/res/values-mcc311-mnc480/donottranslate_config.xml
new file mode 100644
index 0000000..edf7060
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Sargo/res/values-mcc311-mnc480/donottranslate_config.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2018, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources>
+
+    <!-- MMS user agent string -->
+    <string name="config_mms_user_agent" translatable="false">g020e</string>
+    <!-- MMS user agent profile url -->
+    <string name="config_mms_user_agent_profile_url" translatable="false">http://uaprof.vtext.com/google/g020e/g020e.xml</string>
+
+</resources>
diff --git a/rro_overlays/TelephonyOverlay/Sargo/res/values/donottranslate_config.xml b/rro_overlays/TelephonyOverlay/Sargo/res/values/donottranslate_config.xml
new file mode 100644
index 0000000..d302c73
--- /dev/null
+++ b/rro_overlays/TelephonyOverlay/Sargo/res/values/donottranslate_config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+ * Copyright (C) 2019 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+-->
+<resources>
+    <!-- MMS user agent string -->
+    <string name="config_mms_user_agent" translatable="false">g020g</string>
+    <!-- MMS user agent profile url -->
+    <string name="config_mms_user_agent_profile_url" translatable="false">http://www.gstatic.com/android/sms/G020G.xml</string>
+</resources>
diff --git a/sargo/overlay/frameworks/base/core/res/res/values/config.xml b/sargo/overlay/frameworks/base/core/res/res/values/config.xml
index f798762..fb1fc7e 100755
--- a/sargo/overlay/frameworks/base/core/res/res/values/config.xml
+++ b/sargo/overlay/frameworks/base/core/res/res/values/config.xml
@@ -134,22 +134,22 @@
          backlight values -->
     <bool name="config_displayBrightnessBucketsInDoze">true</bool>
 
-    <!-- Default screen brightness setting.
-         Must be in the range specified by minimum and maximum. -->
-    <integer name="config_screenBrightnessSettingDefault">98</integer>
+    <!-- Minimum screen brightness setting allowed by power manager.
+         The user is forbidden from setting the brightness below this level.
+         Equivalent to 1/255. -->
+    <item name="config_screenBrightnessSettingMinimumFloat" format="float" type="dimen">0.0</item>
 
-    <!-- Default screen brightness for VR setting. Default value: 0x7F => 127. -->
-    <integer name="config_screenBrightnessForVrSettingDefault">127</integer>
+    <!-- Maximum screen brightness allowed by the power manager.
+         The user is forbidden from setting the brightness above this level.
+         This value is a fraction between 3.5% and 100%. -->
+    <item name="config_screenBrightnessSettingMaximumFloat" format="float" type="dimen">1.0</item>
 
-    <integer name="config_screenBrightnessForVrSettingMinimum">127</integer>
 
-    <!-- Minimum screen brightness setting allowed by the power manager.
-         The user is forbidden from setting the brightness below this level. -->
-    <integer name="config_screenBrightnessSettingMinimum">1</integer>
-
-    <!-- Maximum screen brightness setting allowed by the power manager.
-         The user is forbidden from setting the brightness above this level. -->
-    <integer name="config_screenBrightnessSettingMaximum">255</integer>
+    <!-- Default screen brightness setting
+         Must be in the range specified by minimum and maximum.
+         This value is a fraction between 3.5% and 100
+         Equivalent to 98/255 (default for this device)    -->
+    <item name="config_screenBrightnessSettingDefaultFloat" format="float" type="dimen">0.38188976378</item>
 
     <!-- An array describing the screen's backlight values corresponding to the brightness
          values in the config_screenBrightnessNits array.
diff --git a/ueventd.hardware.rc b/ueventd.hardware.rc
index e928969..027d7e9 100644
--- a/ueventd.hardware.rc
+++ b/ueventd.hardware.rc
@@ -121,3 +121,6 @@
 
 # Storage: for factory reset protection feature
 /dev/block/platform/soc/7c4000.sdhci/by-name/frp       0660   system     system
+
+# Resume-on-Reboot
+/dev/access-kregistry     0660   system system
diff --git a/usb/Android.bp b/usb/Android.bp
index 449b067..124f468 100644
--- a/usb/Android.bp
+++ b/usb/Android.bp
@@ -20,7 +20,6 @@
     shared_libs: [
         "libbase",
         "libhidlbase",
-        "libhidltransport",
         "liblog",
         "libutils",
         "libhardware",
diff --git a/usb/UsbGadget.cpp b/usb/UsbGadget.cpp
index 82916a2..661669f 100644
--- a/usb/UsbGadget.cpp
+++ b/usb/UsbGadget.cpp
@@ -527,6 +527,8 @@
   if ((functions & GadgetFunction::ADB) != 0) {
     ffsEnabled = true;
     ALOGI("setCurrentUsbFunctions Adb");
+    if (!WriteStringToFile("1", DESC_USE_PATH))
+      return Status::ERROR;
     if (inotify_add_watch(inotifyFd, "/dev/usb-ffs/adb/", IN_ALL_EVENTS) == -1)
       return Status::ERROR;
 
diff --git a/vibrator/Android.bp b/vibrator/Android.bp
deleted file mode 100644
index 2462082..0000000
--- a/vibrator/Android.bp
+++ /dev/null
@@ -1,34 +0,0 @@
-//
-// Copyright (C) 2017 The Android Open Source Project
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//      http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-cc_binary {
-    name: "android.hardware.vibrator@1.2-service.bonito",
-    relative_install_path: "hw",
-    init_rc: ["android.hardware.vibrator@1.2-service.bonito.rc"],
-    srcs: ["service.cpp", "Vibrator.cpp"],
-    cflags: ["-Wall", "-Werror"],
-    shared_libs: [
-        "libhidlbase",
-        "libcutils",
-        "libhidltransport",
-        "liblog",
-        "libhwbinder",
-        "libutils",
-        "libhardware",
-        "android.hardware.vibrator@1.0",
-        "android.hardware.vibrator@1.1",
-        "android.hardware.vibrator@1.2"
-    ],
-    proprietary: true,
-}
diff --git a/vibrator/OWNERS b/vibrator/OWNERS
deleted file mode 100644
index 2ce9955..0000000
--- a/vibrator/OWNERS
+++ /dev/null
@@ -1,3 +0,0 @@
-eliptus@google.com
-michaelwr@google.com
-chasewu@google.com
diff --git a/vibrator/Vibrator.cpp b/vibrator/Vibrator.cpp
deleted file mode 100644
index 509d739..0000000
--- a/vibrator/Vibrator.cpp
+++ /dev/null
@@ -1,231 +0,0 @@
-/*
- * Copyright (C) 2017 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "VibratorService"
-
-#include <log/log.h>
-
-#include <cutils/properties.h>
-#include <hardware/hardware.h>
-#include <hardware/vibrator.h>
-
-#include "Vibrator.h"
-
-#include <cinttypes>
-#include <cmath>
-#include <fstream>
-#include <iostream>
-
-namespace android {
-namespace hardware {
-namespace vibrator {
-namespace V1_2 {
-namespace implementation {
-
-static constexpr int8_t MAX_RTP_INPUT = 127;
-static constexpr int8_t MIN_RTP_INPUT = 0;
-
-static constexpr char RTP_MODE[] = "rtp";
-static constexpr char WAVEFORM_MODE[] = "waveform";
-
-static constexpr uint32_t LOOP_MODE_OPEN = 1;
-static constexpr uint32_t SINE_WAVE = 1;
-static constexpr uint32_t SQUARE_WAVE = 0;
-
-// Default max voltage 2.15V
-static constexpr uint32_t VOLTAGE_MAX = 107;
-
-// Use effect #1 in the waveform library for CLICK effect
-static constexpr char WAVEFORM_CLICK_EFFECT_SEQ[] = "1 0";
-static constexpr int32_t WAVEFORM_CLICK_EFFECT_MS = 6;
-
-// Use effect #2 in the waveform library for TICK effect
-static constexpr char WAVEFORM_TICK_EFFECT_SEQ[] = "2 0";
-static constexpr int32_t WAVEFORM_TICK_EFFECT_MS = 2;
-
-// Use effect #3 in the waveform library for DOUBLE_CLICK effect
-static constexpr char WAVEFORM_DOUBLE_CLICK_EFFECT_SEQ[] = "3 0";
-static constexpr uint32_t WAVEFORM_DOUBLE_CLICK_EFFECT_MS = 182;
-
-// Use effect #4 in the waveform library for HEAVY_CLICK effect
-static constexpr char WAVEFORM_HEAVY_CLICK_EFFECT_SEQ[] = "4 0";
-static constexpr uint32_t WAVEFORM_HEAVY_CLICK_EFFECT_MS = 8;
-
-using Status = ::android::hardware::vibrator::V1_0::Status;
-using EffectStrength = ::android::hardware::vibrator::V1_0::EffectStrength;
-
-Vibrator::Vibrator(HwApi &&hwapi, std::uint32_t short_lra_period, std::uint32_t long_lra_period)
-    : mHwApi(std::move(hwapi)), mShortLraPeriod(short_lra_period), mLongLraPeriod(long_lra_period) {
-    mClickDuration = property_get_int32("ro.vibrator.hal.click.duration", WAVEFORM_CLICK_EFFECT_MS);
-    mTickDuration = property_get_int32("ro.vibrator.hal.tick.duration", WAVEFORM_TICK_EFFECT_MS);
-    mHeavyClickDuration =
-        property_get_int32("ro.vibrator.hal.heavyclick.duration", WAVEFORM_HEAVY_CLICK_EFFECT_MS);
-    mShortVoltageMax = property_get_int32("ro.vibrator.hal.short.voltage", VOLTAGE_MAX);
-    mLongVoltageMax = property_get_int32("ro.vibrator.hal.long.voltage", VOLTAGE_MAX);
-
-    // This enables effect #1 from the waveform library to be triggered by SLPI
-    // while the AP is in suspend mode
-    mHwApi.lpTriggerEffect << 1 << std::endl;
-    if (!mHwApi.lpTriggerEffect) {
-        ALOGW("Failed to set LP trigger mode (%d): %s", errno, strerror(errno));
-    }
-}
-
-Return<Status> Vibrator::on(uint32_t timeoutMs, bool isWaveform) {
-    // Bonito / Sargo only support open-loop mode
-    mHwApi.ctrlLoop << LOOP_MODE_OPEN << std::endl;
-    mHwApi.duration << timeoutMs << std::endl;
-    if (!mHwApi.duration) {
-        ALOGE("Failed to set duration (%d): %s", errno, strerror(errno));
-        return Status::UNKNOWN_ERROR;
-    }
-
-    if (isWaveform) {
-        mHwApi.mode << WAVEFORM_MODE << std::endl;
-        mHwApi.lraWaveShape << SINE_WAVE << std::endl;
-        mHwApi.odClamp << mShortVoltageMax << std::endl;
-        mHwApi.olLraPeriod << mShortLraPeriod << std::endl;
-    } else {
-        mHwApi.mode << RTP_MODE << std::endl;
-        mHwApi.lraWaveShape << SQUARE_WAVE << std::endl;
-        mHwApi.odClamp << mLongVoltageMax << std::endl;
-        mHwApi.olLraPeriod << mLongLraPeriod << std::endl;
-    }
-
-    mHwApi.activate << 1 << std::endl;
-    if (!mHwApi.activate) {
-        ALOGE("Failed to activate (%d): %s", errno, strerror(errno));
-        return Status::UNKNOWN_ERROR;
-    }
-
-    return Status::OK;
-}
-
-// Methods from ::android::hardware::vibrator::V1_2::IVibrator follow.
-Return<Status> Vibrator::on(uint32_t timeoutMs) {
-    return on(timeoutMs, false /* isWaveform */);
-}
-
-Return<Status> Vibrator::off()  {
-    mHwApi.activate << 0 << std::endl;
-    if (!mHwApi.activate) {
-        ALOGE("Failed to turn vibrator off (%d): %s", errno, strerror(errno));
-        return Status::UNKNOWN_ERROR;
-    }
-    return Status::OK;
-}
-
-Return<bool> Vibrator::supportsAmplitudeControl() {
-    return (mHwApi.rtpInput ? true : false);
-}
-
-Return<Status> Vibrator::setAmplitude(uint8_t amplitude) {
-    if (amplitude == 0) {
-        return Status::BAD_VALUE;
-    }
-
-    int32_t rtp_input =
-        std::round((amplitude - 1) / 254.0 * (MAX_RTP_INPUT - MIN_RTP_INPUT) + MIN_RTP_INPUT);
-
-    mHwApi.rtpInput << rtp_input << std::endl;
-    if (!mHwApi.rtpInput) {
-        ALOGE("Failed to set amplitude (%d): %s", errno, strerror(errno));
-        return Status::UNKNOWN_ERROR;
-    }
-
-    return Status::OK;
-}
-
-static uint8_t convertEffectStrength(EffectStrength strength) {
-    uint8_t scale;
-
-    switch (strength) {
-        case EffectStrength::LIGHT:
-            scale = 2;  // 50%
-            break;
-        case EffectStrength::MEDIUM:
-        case EffectStrength::STRONG:
-            scale = 0;  // 100%
-            break;
-    }
-
-    return scale;
-}
-
-Return<void> Vibrator::perform(V1_0::Effect effect, EffectStrength strength, perform_cb _hidl_cb) {
-    return performWrapper(effect, strength, _hidl_cb);
-}
-
-Return<void> Vibrator::perform_1_1(V1_1::Effect_1_1 effect, EffectStrength strength,
-                                   perform_cb _hidl_cb) {
-    return performWrapper(effect, strength, _hidl_cb);
-}
-
-Return<void> Vibrator::perform_1_2(Effect effect, EffectStrength strength, perform_cb _hidl_cb) {
-    return performWrapper(effect, strength, _hidl_cb);
-}
-
-template <typename T>
-Return<void> Vibrator::performWrapper(T effect, EffectStrength strength, perform_cb _hidl_cb) {
-    auto validEffectRange = hidl_enum_range<T>();
-    if (effect < *validEffectRange.begin() || effect > *std::prev(validEffectRange.end())) {
-        _hidl_cb(Status::UNSUPPORTED_OPERATION, 0);
-        return Void();
-    }
-    auto validStrengthRange = hidl_enum_range<EffectStrength>();
-    if (strength < *validStrengthRange.begin() || strength > *std::prev(validStrengthRange.end())) {
-        _hidl_cb(Status::UNSUPPORTED_OPERATION, 0);
-        return Void();
-    }
-    return performEffect(static_cast<Effect>(effect), strength, _hidl_cb);
-}
-
-Return<void> Vibrator::performEffect(Effect effect, EffectStrength strength, perform_cb _hidl_cb) {
-    Status status = Status::OK;
-    uint32_t timeMS;
-
-    switch (effect) {
-        case Effect::CLICK:
-            mHwApi.sequencer << WAVEFORM_CLICK_EFFECT_SEQ << std::endl;
-            timeMS = mClickDuration;
-            break;
-        case Effect::DOUBLE_CLICK:
-            mHwApi.sequencer << WAVEFORM_DOUBLE_CLICK_EFFECT_SEQ << std::endl;
-            timeMS = WAVEFORM_DOUBLE_CLICK_EFFECT_MS;
-            break;
-        case Effect::TICK:
-            mHwApi.sequencer << WAVEFORM_TICK_EFFECT_SEQ << std::endl;
-            timeMS = mTickDuration;
-            break;
-        case Effect::HEAVY_CLICK:
-            mHwApi.sequencer << WAVEFORM_HEAVY_CLICK_EFFECT_SEQ << std::endl;
-            timeMS = mHeavyClickDuration;
-            break;
-        default:
-            _hidl_cb(Status::UNSUPPORTED_OPERATION, 0);
-            return Void();
-    }
-    mHwApi.scale << convertEffectStrength(strength) << std::endl;
-    on(timeMS, true /* isWaveform */);
-    _hidl_cb(status, timeMS);
-    return Void();
-}
-
-}  // namespace implementation
-}  // namespace V1_2
-}  // namespace vibrator
-}  // namespace hardware
-}  // namespace android
diff --git a/vibrator/Vibrator.h b/vibrator/Vibrator.h
deleted file mode 100644
index 08635cf..0000000
--- a/vibrator/Vibrator.h
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Copyright (C) 2017 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#ifndef ANDROID_HARDWARE_VIBRATOR_V1_2_VIBRATOR_H
-#define ANDROID_HARDWARE_VIBRATOR_V1_2_VIBRATOR_H
-
-#include <android/hardware/vibrator/1.2/IVibrator.h>
-#include <hidl/Status.h>
-
-#include <fstream>
-
-namespace android {
-namespace hardware {
-namespace vibrator {
-namespace V1_2 {
-namespace implementation {
-
-class Vibrator : public IVibrator {
-  public:
-    typedef struct {
-        std::ofstream activate;
-        std::ofstream ctrlLoop;
-        std::ofstream duration;
-        std::ofstream lpTriggerEffect;
-        std::ofstream lraWaveShape;
-        std::ofstream mode;
-        std::ofstream odClamp;
-        std::ofstream olLraPeriod;
-        std::ofstream rtpInput;
-        std::ofstream scale;
-        std::ofstream sequencer;
-        std::ofstream state;
-    } HwApi;
-
-  public:
-    Vibrator(HwApi &&hwapi, std::uint32_t short_lra_period, std::uint32_t long_lra_period);
-
-    // Methods from ::android::hardware::vibrator::V1_0::IVibrator follow.
-    using Status = ::android::hardware::vibrator::V1_0::Status;
-    Return<Status> on(uint32_t timeoutMs) override;
-    Return<Status> off() override;
-    Return<bool> supportsAmplitudeControl() override;
-    Return<Status> setAmplitude(uint8_t amplitude) override;
-
-    using EffectStrength = ::android::hardware::vibrator::V1_0::EffectStrength;
-    Return<void> perform(V1_0::Effect effect, EffectStrength strength,
-                         perform_cb _hidl_cb) override;
-    Return<void> perform_1_1(V1_1::Effect_1_1 effect, EffectStrength strength,
-                             perform_cb _hidl_cb) override;
-    Return<void> perform_1_2(Effect effect, EffectStrength strength, perform_cb _hidl_cb) override;
-
-  private:
-    Return<Status> on(uint32_t timeoutMs, bool isWaveform);
-    template <typename T>
-    Return<void> performWrapper(T effect, EffectStrength strength, perform_cb _hidl_cb);
-    Return<void> performEffect(Effect effect, EffectStrength strength, perform_cb _hidl_cb);
-    HwApi mHwApi;
-    std::uint32_t mShortLraPeriod;
-    std::uint32_t mLongLraPeriod;
-    int32_t mClickDuration;
-    int32_t mTickDuration;
-    int32_t mHeavyClickDuration;
-    int32_t mShortVoltageMax;
-    int32_t mLongVoltageMax;
-};
-}  // namespace implementation
-}  // namespace V1_2
-}  // namespace vibrator
-}  // namespace hardware
-}  // namespace android
-
-#endif  // ANDROID_HARDWARE_VIBRATOR_V1_2_VIBRATOR_H
diff --git a/vibrator/android.hardware.vibrator@1.2-service.bonito.rc b/vibrator/android.hardware.vibrator@1.2-service.bonito.rc
deleted file mode 100644
index b47bee8..0000000
--- a/vibrator/android.hardware.vibrator@1.2-service.bonito.rc
+++ /dev/null
@@ -1,4 +0,0 @@
-service vendor.vibrator-1-2 /vendor/bin/hw/android.hardware.vibrator@1.2-service.bonito
-    class hal
-    user system
-    group system
diff --git a/vibrator/service.cpp b/vibrator/service.cpp
deleted file mode 100644
index b090420..0000000
--- a/vibrator/service.cpp
+++ /dev/null
@@ -1,247 +0,0 @@
-/*
- * Copyright (C) 2017 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#define LOG_TAG "android.hardware.vibrator@1.2-service.bonito"
-
-#include <android/hardware/vibrator/1.2/IVibrator.h>
-#include <cutils/properties.h>
-#include <hidl/HidlSupport.h>
-#include <hidl/HidlTransportSupport.h>
-#include <utils/Errors.h>
-#include <utils/StrongPointer.h>
-
-#include "Vibrator.h"
-
-using android::hardware::configureRpcThreadpool;
-using android::hardware::joinRpcThreadpool;
-using android::hardware::vibrator::V1_2::IVibrator;
-using android::hardware::vibrator::V1_2::implementation::Vibrator;
-using namespace android;
-
-// Refer to Documentation/ABI/testing/sysfs-class-led-driver-drv2624
-// kernel documentation on the detail usages for ABIs below
-static constexpr char ACTIVATE_PATH[] = "/sys/class/leds/vibrator/activate";
-static constexpr char DURATION_PATH[] = "/sys/class/leds/vibrator/duration";
-static constexpr char STATE_PATH[] = "/sys/class/leds/vibrator/state";
-static constexpr char RTP_INPUT_PATH[] = "/sys/class/leds/vibrator/device/rtp_input";
-static constexpr char MODE_PATH[] = "/sys/class/leds/vibrator/device/mode";
-static constexpr char SEQUENCER_PATH[] = "/sys/class/leds/vibrator/device/set_sequencer";
-static constexpr char SCALE_PATH[] = "/sys/class/leds/vibrator/device/scale";
-static constexpr char CTRL_LOOP_PATH[] = "/sys/class/leds/vibrator/device/ctrl_loop";
-static constexpr char LP_TRIGGER_PATH[] = "/sys/class/leds/vibrator/device/lp_trigger_effect";
-static constexpr char LRA_WAVE_SHAPE_PATH[] = "/sys/class/leds/vibrator/device/lra_wave_shape";
-static constexpr char OD_CLAMP_PATH[] = "/sys/class/leds/vibrator/device/od_clamp";
-
-// File path to the calibration file
-static constexpr char CALIBRATION_FILEPATH[] = "/persist/haptics/drv2624.cal";
-
-// Kernel ABIs for updating the calibration data
-static constexpr char AUTOCAL_CONFIG[] = "autocal";
-static constexpr char LRA_PERIOD_CONFIG[] = "lra_period";
-static constexpr char AUTOCAL_FILEPATH[] = "/sys/class/leds/vibrator/device/autocal";
-static constexpr char OL_LRA_PERIOD_FILEPATH[] = "/sys/class/leds/vibrator/device/ol_lra_period";
-
-// Set a default lra period in case there is no calibration file
-static constexpr uint32_t DEFAULT_LRA_PERIOD = 262;
-static constexpr uint32_t DEFAULT_FREQUENCY_SHIFT = 10;
-
-static std::uint32_t freqPeriodFormula(std::uint32_t in) {
-    return 1000000000 / (24615 * in);
-}
-
-static std::string trim(const std::string &str, const std::string &whitespace = " \t") {
-    const auto str_begin = str.find_first_not_of(whitespace);
-    if (str_begin == std::string::npos) {
-        return "";
-    }
-
-    const auto str_end = str.find_last_not_of(whitespace);
-    const auto str_range = str_end - str_begin + 1;
-
-    return str.substr(str_begin, str_range);
-}
-
-static bool loadCalibrationData(std::uint32_t &short_lra_period, std::uint32_t &long_lra_period) {
-    std::map<std::string, std::string> config_data;
-
-    std::ofstream autocal{AUTOCAL_FILEPATH};
-    if (!autocal) {
-        int error = errno;
-        ALOGE("Failed to open %s (%d): %s", AUTOCAL_FILEPATH, error, strerror(error));
-        return false;
-    }
-
-    std::ofstream ol_lra_period{OL_LRA_PERIOD_FILEPATH};
-    if (!ol_lra_period) {
-        int error = errno;
-        ALOGE("Failed to open %s (%d): %s", OL_LRA_PERIOD_FILEPATH, error, strerror(error));
-        return false;
-    }
-
-    std::ifstream cal_data{CALIBRATION_FILEPATH};
-    if (!cal_data) {
-        int error = errno;
-        ALOGE("Failed to open %s (%d): %s", CALIBRATION_FILEPATH, error, strerror(error));
-        return false;
-    }
-
-    std::string line;
-
-    while (std::getline(cal_data, line)) {
-        if (line.empty() || line[0] == '#') {
-            continue;
-        }
-        std::istringstream is_line(line);
-        std::string key;
-        if (std::getline(is_line, key, ':')) {
-            std::string value;
-
-            if (std::getline(is_line, value)) {
-                config_data[trim(key)] = trim(value);
-            }
-        }
-    }
-
-    if (config_data.find(AUTOCAL_CONFIG) != config_data.end()) {
-        autocal << config_data[AUTOCAL_CONFIG] << std::endl;
-    }
-
-    if (config_data.find(LRA_PERIOD_CONFIG) != config_data.end()) {
-        uint32_t thisFrequency;
-        uint32_t thisPeriod;
-        ol_lra_period << config_data[LRA_PERIOD_CONFIG] << std::endl;
-        thisPeriod = std::stoul(config_data[LRA_PERIOD_CONFIG]);
-        short_lra_period = thisPeriod;
-        // 1. Change long lra period to frequency
-        // 2. Get frequency': subtract the frequency shift from the frequency
-        // 3. Get final long lra period after put the frequency' to formula
-        thisFrequency =
-            freqPeriodFormula(thisPeriod) -
-            property_get_int32("ro.vibrator.hal.long.frequency.shift", DEFAULT_FREQUENCY_SHIFT);
-        long_lra_period = freqPeriodFormula(thisFrequency);
-    }
-
-    return true;
-}
-
-status_t registerVibratorService() {
-    // Calibration data: lra period 262(i.e. 155Hz)
-    std::uint32_t short_lra_period(DEFAULT_LRA_PERIOD);
-    std::uint32_t long_lra_period(DEFAULT_LRA_PERIOD);
-    Vibrator::HwApi hwapi;
-
-    // ostreams below are required
-    hwapi.activate.open(ACTIVATE_PATH);
-    if (!hwapi.activate) {
-        int error = errno;
-        ALOGE("Failed to open %s (%d): %s", ACTIVATE_PATH, error, strerror(error));
-        return -error;
-    }
-
-    hwapi.duration.open(DURATION_PATH);
-    if (!hwapi.duration) {
-        int error = errno;
-        ALOGE("Failed to open %s (%d): %s", DURATION_PATH, error, strerror(error));
-        return -error;
-    }
-
-    hwapi.state.open(STATE_PATH);
-    if (!hwapi.state) {
-        int error = errno;
-        ALOGE("Failed to open %s (%d): %s", STATE_PATH, error, strerror(error));
-        return -error;
-    }
-
-    hwapi.state << 1 << std::endl;
-    if (!hwapi.state) {
-        int error = errno;
-        ALOGE("Failed to set state (%d): %s", errno, strerror(errno));
-        return -error;
-    }
-
-    // ostreams below are optional
-    hwapi.rtpInput.open(RTP_INPUT_PATH);
-    if (!hwapi.rtpInput) {
-        int error = errno;
-        ALOGW("Failed to open %s (%d): %s", RTP_INPUT_PATH, error, strerror(error));
-    }
-
-    hwapi.mode.open(MODE_PATH);
-    if (!hwapi.mode) {
-        int error = errno;
-        ALOGW("Failed to open %s (%d): %s", MODE_PATH, error, strerror(error));
-    }
-
-    hwapi.sequencer.open(SEQUENCER_PATH);
-    if (!hwapi.sequencer) {
-        int error = errno;
-        ALOGW("Failed to open %s (%d): %s", SEQUENCER_PATH, error, strerror(error));
-    }
-
-    hwapi.scale.open(SCALE_PATH);
-    if (!hwapi.scale) {
-        int error = errno;
-        ALOGW("Failed to open %s (%d): %s", SCALE_PATH, error, strerror(error));
-    }
-
-    hwapi.ctrlLoop.open(CTRL_LOOP_PATH);
-    if (!hwapi.ctrlLoop) {
-        int error = errno;
-        ALOGW("Failed to open %s (%d): %s", CTRL_LOOP_PATH, error, strerror(error));
-    }
-
-    hwapi.lpTriggerEffect.open(LP_TRIGGER_PATH);
-    if (!hwapi.lpTriggerEffect) {
-        int error = errno;
-        ALOGW("Failed to open %s (%d): %s", LP_TRIGGER_PATH, error, strerror(error));
-    }
-
-    hwapi.lraWaveShape.open(LRA_WAVE_SHAPE_PATH);
-    if (!hwapi.lraWaveShape) {
-        int error = errno;
-        ALOGW("Failed to open %s (%d): %s", LRA_WAVE_SHAPE_PATH, error, strerror(error));
-    }
-
-    hwapi.odClamp.open(OD_CLAMP_PATH);
-    if (!hwapi.odClamp) {
-        int error = errno;
-        ALOGW("Failed to open %s (%d): %s", OD_CLAMP_PATH, error, strerror(error));
-    }
-
-    hwapi.olLraPeriod.open(OL_LRA_PERIOD_FILEPATH);
-    if (!hwapi.olLraPeriod) {
-        int error = errno;
-        ALOGW("Failed to open %s (%d): %s", OL_LRA_PERIOD_FILEPATH, error, strerror(error));
-    }
-
-    if (!loadCalibrationData(short_lra_period, long_lra_period)) {
-        ALOGW("Failed load calibration data");
-    }
-
-    sp<IVibrator> vibrator = new Vibrator(std::move(hwapi), short_lra_period, long_lra_period);
-
-    return vibrator->registerAsService();
-}
-
-int main() {
-    configureRpcThreadpool(1, true);
-    status_t status = registerVibratorService();
-
-    if (status != OK) {
-        return status;
-    }
-
-    joinRpcThreadpool();
-}
diff --git a/vr/Android.bp b/vr/Android.bp
deleted file mode 100644
index 952338e..0000000
--- a/vr/Android.bp
+++ /dev/null
@@ -1,30 +0,0 @@
-//
-// Copyright (C) 2017 The Android Open Source Project
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//      http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-cc_binary {
-    name: "android.hardware.vr@1.0-service.bonito",
-    relative_install_path: "hw",
-    init_rc: ["android.hardware.vr@1.0-service.bonito.rc"],
-    srcs: ["service.cpp", "VrDevice.cpp"],
-    cflags: ["-Werror", "-Wall"],
-    shared_libs: [
-        "libbase",
-        "libhidlbase",
-        "libhidltransport",
-        "liblog",
-        "libutils",
-        "android.hardware.vr@1.0",
-    ],
-    proprietary: true,
-}
diff --git a/vr/NOTICE b/vr/NOTICE
deleted file mode 100644
index 667db97..0000000
--- a/vr/NOTICE
+++ /dev/null
@@ -1,10 +0,0 @@
-Copyright (C) 2017 The Android Open Source Project
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
diff --git a/vr/VrDevice.cpp b/vr/VrDevice.cpp
deleted file mode 100644
index dc8f3d7..0000000
--- a/vr/VrDevice.cpp
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (C) 2017 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "VrDevice"
-
-#include <android-base/file.h>
-#include <android-base/logging.h>
-#include <android-base/properties.h>
-#include <android-base/stringprintf.h>
-
-#include "VrDevice.h"
-
-namespace android {
-namespace hardware {
-namespace vr {
-namespace V1_0 {
-namespace implementation {
-
-VrDevice::VrDevice() : mVRmode(false) {}
-
-Return<void> VrDevice::init() {
-    // NOOP
-    return Void();
-}
-
-Return<void> VrDevice::setVrMode(bool enabled) {
-    std::string hwProp = android::base::GetProperty("ro.hardware", "default");
-    std::string vrMode = enabled ? "-vr" : "";
-    std::string thermalConf = "/vendor/etc/thermal-engine-" + hwProp + vrMode + ".conf";
-    mVRmode = enabled;
-
-    if (!android::base::SetProperty("vendor.sys.qcom.thermalcfg", thermalConf)) {
-        LOG(ERROR) << "Couldn't set vendor.sys.qcom.thermalcfg to " << thermalConf;
-        return Void();
-    }
-    if (!android::base::SetProperty("ctl.restart", "vendor.thermal-engine")) {
-        LOG(ERROR) << "Couldn't set thermal_engine restart property";
-    }
-    return Void();
-}
-
-Return<void> VrDevice::debug(const hidl_handle& handle, const hidl_vec<hidl_string>&) {
-    if (handle != nullptr && handle->numFds >= 1) {
-        int fd = handle->data[0];
-        std::string buf(android::base::StringPrintf("VRMode: %s\n",
-                                                    (mVRmode ? "true" : "false")));
-        if (!android::base::WriteStringToFd(buf, fd)) {
-            PLOG(ERROR) << "Failed to dump state to fd";
-        }
-        fsync(fd);
-    }
-    return Void();
-}
-
-}  // namespace implementation
-}  // namespace V1_0
-}  // namespace vr
-}  // namespace hardware
-}  // namespace android
diff --git a/vr/VrDevice.h b/vr/VrDevice.h
deleted file mode 100644
index f5f1210..0000000
--- a/vr/VrDevice.h
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2017 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#ifndef ANDROID_HARDWARE_VR_V1_0_VR_H
-#define ANDROID_HARDWARE_VR_V1_0_VR_H
-
-#include <android/hardware/vr/1.0/IVr.h>
-
-namespace android {
-namespace hardware {
-namespace vr {
-namespace V1_0 {
-namespace implementation {
-
-using ::android::hardware::vr::V1_0::IVr;
-using ::android::hardware::Return;
-
-class VrDevice : public IVr {
-  public:
-    VrDevice();
-
-    Return<void> init()  override;
-    Return<void> setVrMode(bool enabled)  override;
-    Return<void> debug(const hidl_handle& handle, const hidl_vec<hidl_string>&)  override;
-
-  private:
-    bool mVRmode;
-};
-
-}  // namespace implementation
-}  // namespace V1_0
-}  // namespace vr
-}  // namespace hardware
-}  // namespace android
-
-#endif  // ANDROID_HARDWARE_VR_V1_0_VR_H
diff --git a/vr/android.hardware.vr@1.0-service.bonito.rc b/vr/android.hardware.vr@1.0-service.bonito.rc
deleted file mode 100644
index c546021..0000000
--- a/vr/android.hardware.vr@1.0-service.bonito.rc
+++ /dev/null
@@ -1,9 +0,0 @@
-service vendor.vr-bonito-1-0 /vendor/bin/hw/android.hardware.vr@1.0-service.bonito
-    class hal
-    user system
-    group system
-
-# reset thermal-engine when framework died and thermal-engine is in VR mode
-on property:init.svc.zygote=restarting && property:vendor.sys.qcom.thermalcfg=/vendor/etc/thermal-engine-${ro.hardware}-vr.conf
-   setprop vendor.sys.qcom.thermalcfg /vendor/etc/thermal-engine-${ro.hardware}.conf
-   restart vendor.thermal-engine
diff --git a/vr/service.cpp b/vr/service.cpp
deleted file mode 100644
index 1ff9cdf..0000000
--- a/vr/service.cpp
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (C) 2017 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#define LOG_TAG "android.hardware.vr@1.0-service.bonito"
-
-#include <android-base/logging.h>
-#include <hidl/HidlSupport.h>
-#include <hidl/HidlTransportSupport.h>
-#include <utils/StrongPointer.h>
-
-#include "VrDevice.h"
-
-using ::android::hardware::configureRpcThreadpool;
-using ::android::hardware::joinRpcThreadpool;
-using ::android::hardware::vr::V1_0::implementation::VrDevice;
-using ::android::hardware::vr::V1_0::IVr;
-using ::android::sp;
-
-int main(int /* argc */, char* /* argv */ []) {
-    sp<IVr> vr = new VrDevice;
-    configureRpcThreadpool(1, true);
-    CHECK_EQ(vr->registerAsService(), android::NO_ERROR)
-            << "Failed to register vr HAL";
-    joinRpcThreadpool();
-    return 0;
-}
diff --git a/wpa_supplicant_overlay.conf b/wpa_supplicant_overlay.conf
index 3ac13d1..e63a4bb 100644
--- a/wpa_supplicant_overlay.conf
+++ b/wpa_supplicant_overlay.conf
@@ -4,3 +4,4 @@
 wowlan_triggers=magic_pkt
 bss_max_count=512
 bss_no_flush_when_down=1
+driver_param=use_p2p_group_interface=1