Compare commits

..

1 commit

Author SHA1 Message Date
Darshan Manjrekar
7e69d37960 Revert "msm8937-common: Don't clean vendor by default"
This reverts commit c55bf49604.

Change-Id: Ifcd1259ae1abd850135142385d6ce75b5fda85b7
2018-11-01 18:23:07 +05:30
26 changed files with 95 additions and 134 deletions

View file

@ -26,7 +26,7 @@
LOCAL_PATH := $(call my-dir) LOCAL_PATH := $(call my-dir)
ifneq ($(filter karate,$(TARGET_DEVICE)),) ifneq ($(filter land santoni,$(TARGET_DEVICE)),)
include $(call all-makefiles-under,$(LOCAL_PATH)) include $(call all-makefiles-under,$(LOCAL_PATH))

View file

@ -15,7 +15,7 @@
# limitations under the License. # limitations under the License.
# #
VENDOR_PATH := device/lenovo/msm8937-common VENDOR_PATH := device/xiaomi/msm8937-common
# Bootloader # Bootloader
TARGET_BOOTLOADER_BOARD_NAME := MSM8937 TARGET_BOOTLOADER_BOARD_NAME := MSM8937
@ -32,7 +32,7 @@ TARGET_CPU_ABI2 :=
TARGET_CPU_VARIANT := generic TARGET_CPU_VARIANT := generic
TARGET_2ND_ARCH := arm TARGET_2ND_ARCH := arm
TARGET_2ND_ARCH_VARIANT := armv8-a TARGET_2ND_ARCH_VARIANT := armv7-a-neon
TARGET_2ND_CPU_ABI := armeabi-v7a TARGET_2ND_CPU_ABI := armeabi-v7a
TARGET_2ND_CPU_ABI2 := armeabi TARGET_2ND_CPU_ABI2 := armeabi
TARGET_2ND_CPU_VARIANT := cortex-a53 TARGET_2ND_CPU_VARIANT := cortex-a53
@ -75,10 +75,6 @@ BOARD_BLUETOOTH_BDROID_BUILDCFG_INCLUDE_DIR := $(VENDOR_PATH)/bluetooth
BLUETOOTH_HCI_USE_MCT := true BLUETOOTH_HCI_USE_MCT := true
QCOM_BT_USE_SMD_TTY := true QCOM_BT_USE_SMD_TTY := true
# Camera
TARGET_PROCESS_SDK_VERSION_OVERRIDE := \
/vendor/bin/mm-qcamera-daemon=23
# Charger # Charger
BOARD_CHARGER_DISABLE_INIT_BLANK := true BOARD_CHARGER_DISABLE_INIT_BLANK := true
BOARD_CHARGER_ENABLE_SUSPEND := true BOARD_CHARGER_ENABLE_SUSPEND := true
@ -131,7 +127,7 @@ TARGET_KERNEL_SOURCE := kernel/xiaomi/msm8937
TARGET_PROVIDES_LIBLIGHT := true TARGET_PROVIDES_LIBLIGHT := true
# Lineage Hardware # Lineage Hardware
JAVA_SOURCE_OVERLAYS := org.lineageos.hardware|$(VENDOR_PATH)/lineagehw|**/*.java BOARD_HARDWARE_CLASS += $(VENDOR_PATH)/lineagehw
# Malloc # Malloc
MALLOC_SVELTE := true MALLOC_SVELTE := true
@ -155,7 +151,7 @@ TARGET_USERIMAGES_USE_F2FS := true
TARGET_USES_MKE2FS := true TARGET_USES_MKE2FS := true
# Power # Power
TARGET_HAS_NO_WLAN_STATS := true TARGET_HAS_NO_WIFI_STATS := true
TARGET_USES_INTERACTION_BOOST := true TARGET_USES_INTERACTION_BOOST := true
# Qualcomm support # Qualcomm support
@ -175,6 +171,7 @@ BOARD_PLAT_PRIVATE_SEPOLICY_DIR += $(VENDOR_PATH)/sepolicy/private
# Treble # Treble
BOARD_PROPERTY_OVERRIDES_SPLIT_ENABLED := true BOARD_PROPERTY_OVERRIDES_SPLIT_ENABLED := true
PRODUCT_COMPATIBILITY_MATRIX_LEVEL_OVERRIDE := 27
PRODUCT_FULL_TREBLE_OVERRIDE := true PRODUCT_FULL_TREBLE_OVERRIDE := true
# WiFi # WiFi
@ -189,4 +186,4 @@ WIFI_DRIVER_FW_PATH_STA := "sta"
WPA_SUPPLICANT_VERSION := VER_0_8_X WPA_SUPPLICANT_VERSION := VER_0_8_X
# Inherit the common proprietary files # Inherit the common proprietary files
-include vendor/lenovo/msm8937-common/BoardConfigVendor.mk -include vendor/xiaomi/msm8937-common/BoardConfigVendor.mk

View file

@ -1,4 +1,4 @@
# Common device configuration for Lenovo MSM8937 # Common device configuration for Xiaomi MSM8937
## Copyright ## Copyright

View file

@ -1,8 +1,8 @@
LOCAL_PATH := $(call my-dir) LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS) include $(CLEAR_VARS)
LOCAL_MODULE := android.hardware.biometrics.fingerprint@2.1-service.lenovo_msm8937 LOCAL_MODULE := android.hardware.biometrics.fingerprint@2.1-service.xiaomi_msm8937
LOCAL_INIT_RC := android.hardware.biometrics.fingerprint@2.1-service.lenovo_msm8937.rc LOCAL_INIT_RC := android.hardware.biometrics.fingerprint@2.1-service.xiaomi_msm8937.rc
LOCAL_PROPRIETARY_MODULE := true LOCAL_PROPRIETARY_MODULE := true
LOCAL_MODULE_RELATIVE_PATH := hw LOCAL_MODULE_RELATIVE_PATH := hw
LOCAL_SRC_FILES := \ LOCAL_SRC_FILES := \

View file

@ -1,4 +1,4 @@
service fps_hal /vendor/bin/hw/android.hardware.biometrics.fingerprint@2.1-service.lenovo_msm8937 service fps_hal /vendor/bin/hw/android.hardware.biometrics.fingerprint@2.1-service.xiaomi_msm8937
# "class hal" causes a race condition on some devices due to files created # "class hal" causes a race condition on some devices due to files created
# in /data. As a workaround, postpone startup until later in boot once # in /data. As a workaround, postpone startup until later in boot once
# /data is mounted. # /data is mounted.

View file

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
#define LOG_TAG "android.hardware.biometrics.fingerprint@2.1-service.lenovo_msm8937" #define LOG_TAG "android.hardware.biometrics.fingerprint@2.1-service.xiaomi_msm8937"
#include <binder/IPCThreadState.h> #include <binder/IPCThreadState.h>
#include <binder/IServiceManager.h> #include <binder/IServiceManager.h>

View file

@ -1,10 +1,10 @@
[AID_VENDOR_QTI_DIAG] [AID_QTI_DIAG]
value:2901 value:2901
[AID_VENDOR_RFS] [AID_RFS]
value:2903 value:2903
[AID_VENDOR_RFS_SHARED] [AID_RFS_SHARED]
value:2904 value:2904
[vendor/bin/wcnss_filter] [vendor/bin/wcnss_filter]

View file

@ -5,9 +5,9 @@ LOCAL_MODULE_TAGS := optional
LOCAL_SRC_FILES := $(call all-java-files-under, src) LOCAL_SRC_FILES := $(call all-java-files-under, src)
LOCAL_PACKAGE_NAME := LenovoDoze LOCAL_PACKAGE_NAME := XiaomiDoze
LOCAL_CERTIFICATE := platform LOCAL_CERTIFICATE := platform
LOCAL_PRIVATE_PLATFORM_APIS := true LOCAL_PRIVILEGED_MODULE := true
LOCAL_USE_AAPT2 := true LOCAL_USE_AAPT2 := true
@ -17,7 +17,10 @@ LOCAL_STATIC_ANDROID_LIBRARIES := \
android-support-v7-recyclerview \ android-support-v7-recyclerview \
android-support-v7-preference \ android-support-v7-preference \
android-support-v7-appcompat \ android-support-v7-appcompat \
android-support-v14-preference android-support-v14-preference \
LOCAL_STATIC_JAVA_LIBRARIES := \
org.lineageos.platform.internal
LOCAL_RESOURCE_DIR := \ LOCAL_RESOURCE_DIR := \
$(LOCAL_PATH)/res \ $(LOCAL_PATH)/res \

View file

@ -42,7 +42,7 @@
</receiver> </receiver>
<service android:name=".DozeService" <service android:name=".DozeService"
android:permission="LenovoDozeService"> android:permission="XiaomiDozeService">
</service> </service>
<activity <activity

View file

@ -25,7 +25,7 @@ import android.util.Log;
public class BootCompletedReceiver extends BroadcastReceiver { public class BootCompletedReceiver extends BroadcastReceiver {
private static final boolean DEBUG = false; private static final boolean DEBUG = false;
private static final String TAG = "LenovoDoze"; private static final String TAG = "XiaomiDoze";
@Override @Override
public void onReceive(final Context context, Intent intent) { public void onReceive(final Context context, Intent intent) {

View file

@ -1,6 +1,6 @@
/* /*
* Copyright (C) 2015 The CyanogenMod Project * Copyright (c) 2015 The CyanogenMod Project
* 2017-2018 The LineageOS Project * 2017 The LineageOS Project
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -65,22 +65,22 @@ public class DozeService extends Service {
private void onDisplayOn() { private void onDisplayOn() {
if (DEBUG) Log.d(TAG, "Display on"); if (DEBUG) Log.d(TAG, "Display on");
if (Utils.isPickUpEnabled(this)) { if (Utils.pickUpEnabled(this)) {
mTiltSensor.disable(); mTiltSensor.disable();
} }
if (Utils.isHandwaveGestureEnabled(this) || if (Utils.handwaveGestureEnabled(this) ||
Utils.isPocketGestureEnabled(this)) { Utils.pocketGestureEnabled(this)) {
mProximitySensor.disable(); mProximitySensor.disable();
} }
} }
private void onDisplayOff() { private void onDisplayOff() {
if (DEBUG) Log.d(TAG, "Display off"); if (DEBUG) Log.d(TAG, "Display off");
if (Utils.isPickUpEnabled(this)) { if (Utils.pickUpEnabled(this)) {
mTiltSensor.enable(); mTiltSensor.enable();
} }
if (Utils.isHandwaveGestureEnabled(this) || if (Utils.handwaveGestureEnabled(this) ||
Utils.isPocketGestureEnabled(this)) { Utils.pocketGestureEnabled(this)) {
mProximitySensor.enable(); mProximitySensor.enable();
} }
} }

View file

@ -67,15 +67,12 @@ public class DozeSettingsFragment extends PreferenceFragment implements OnPrefer
mPickUpPreference = (SwitchPreference) findPreference(Utils.GESTURE_PICK_UP_KEY); mPickUpPreference = (SwitchPreference) findPreference(Utils.GESTURE_PICK_UP_KEY);
mPickUpPreference.setEnabled(dozeEnabled); mPickUpPreference.setEnabled(dozeEnabled);
mPickUpPreference.setOnPreferenceChangeListener(this);
mHandwavePreference = (SwitchPreference) findPreference(Utils.GESTURE_HAND_WAVE_KEY); mHandwavePreference = (SwitchPreference) findPreference(Utils.GESTURE_HAND_WAVE_KEY);
mHandwavePreference.setEnabled(dozeEnabled); mHandwavePreference.setEnabled(dozeEnabled);
mHandwavePreference.setOnPreferenceChangeListener(this);
mPocketPreference = (SwitchPreference) findPreference(Utils.GESTURE_POCKET_KEY); mPocketPreference = (SwitchPreference) findPreference(Utils.GESTURE_POCKET_KEY);
mPocketPreference.setEnabled(dozeEnabled); mPocketPreference.setEnabled(dozeEnabled);
mPocketPreference.setOnPreferenceChangeListener(this);
// Hide proximity sensor related features if the device doesn't support them // Hide proximity sensor related features if the device doesn't support them
if (!Utils.getProxCheckBeforePulse(getActivity())) { if (!Utils.getProxCheckBeforePulse(getActivity())) {
@ -110,21 +107,20 @@ public class DozeSettingsFragment extends PreferenceFragment implements OnPrefer
@Override @Override
public boolean onPreferenceChange(Preference preference, Object newValue) { public boolean onPreferenceChange(Preference preference, Object newValue) {
Utils.enableGesture(getActivity(), preference.getKey(), (Boolean) newValue);
Utils.checkDozeService(getActivity()); Utils.checkDozeService(getActivity());
return true; return true;
} }
@Override @Override
public void onCheckedChanged(CompoundButton compoundButton, boolean isChecked) { public void onCheckedChanged(CompoundButton compoundButton, boolean b) {
Utils.enableDoze(getActivity(), isChecked); Utils.enableDoze(b, getActivity());
Utils.checkDozeService(getActivity()); Utils.checkDozeService(getActivity());
mTextView.setText(getString(isChecked ? R.string.switch_bar_on : R.string.switch_bar_off)); mTextView.setText(getString(b ? R.string.switch_bar_on : R.string.switch_bar_off));
mPickUpPreference.setEnabled(isChecked); mPickUpPreference.setEnabled(b);
mHandwavePreference.setEnabled(isChecked); mHandwavePreference.setEnabled(b);
mPocketPreference.setEnabled(isChecked); mPocketPreference.setEnabled(b);
} }
@Override @Override

View file

@ -74,11 +74,11 @@ public class ProximitySensor implements SensorEventListener {
private boolean shouldPulse(long timestamp) { private boolean shouldPulse(long timestamp) {
long delta = timestamp - mInPocketTime; long delta = timestamp - mInPocketTime;
if (Utils.isHandwaveGestureEnabled(mContext) && Utils.isPocketGestureEnabled(mContext)) { if (Utils.handwaveGestureEnabled(mContext) && Utils.pocketGestureEnabled(mContext)) {
return true; return true;
} else if (Utils.isHandwaveGestureEnabled(mContext)) { } else if (Utils.handwaveGestureEnabled(mContext)) {
return delta < HANDWAVE_MAX_DELTA_NS; return delta < HANDWAVE_MAX_DELTA_NS;
} else if (Utils.isPocketGestureEnabled(mContext)) { } else if (Utils.pocketGestureEnabled(mContext)) {
return delta >= POCKET_MIN_DELTA_NS; return delta >= POCKET_MIN_DELTA_NS;
} }
return false; return false;

View file

@ -1,6 +1,6 @@
/* /*
* Copyright (C) 2015 The CyanogenMod Project * Copyright (c) 2015 The CyanogenMod Project
* 2017-2018 The LineageOS Project * 2017 The LineageOS Project
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -76,7 +76,7 @@ public final class Utils {
DOZE_ENABLED, 1) != 0; DOZE_ENABLED, 1) != 0;
} }
protected static boolean enableDoze(Context context, boolean enable) { protected static boolean enableDoze(boolean enable, Context context) {
return Settings.Secure.putInt(context.getContentResolver(), return Settings.Secure.putInt(context.getContentResolver(),
DOZE_ENABLED, enable ? 1 : 0); DOZE_ENABLED, enable ? 1 : 0);
} }
@ -87,30 +87,23 @@ public final class Utils {
new UserHandle(UserHandle.USER_CURRENT)); new UserHandle(UserHandle.USER_CURRENT));
} }
protected static void enableGesture(Context context, String gesture, boolean enable) { protected static boolean pickUpEnabled(Context context) {
PreferenceManager.getDefaultSharedPreferences(context).edit()
.putBoolean(gesture, enable).apply();
}
protected static boolean isGestureEnabled(Context context, String gesture) {
return PreferenceManager.getDefaultSharedPreferences(context) return PreferenceManager.getDefaultSharedPreferences(context)
.getBoolean(gesture, false); .getBoolean(GESTURE_PICK_UP_KEY, false);
} }
protected static boolean isPickUpEnabled(Context context) { protected static boolean handwaveGestureEnabled(Context context) {
return isGestureEnabled(context, GESTURE_PICK_UP_KEY); return PreferenceManager.getDefaultSharedPreferences(context)
.getBoolean(GESTURE_HAND_WAVE_KEY, false);
} }
protected static boolean isHandwaveGestureEnabled(Context context) { protected static boolean pocketGestureEnabled(Context context) {
return isGestureEnabled(context, GESTURE_HAND_WAVE_KEY); return PreferenceManager.getDefaultSharedPreferences(context)
} .getBoolean(GESTURE_POCKET_KEY, false);
protected static boolean isPocketGestureEnabled(Context context) {
return isGestureEnabled(context, GESTURE_POCKET_KEY);
} }
protected static boolean sensorsEnabled(Context context) { protected static boolean sensorsEnabled(Context context) {
return isPickUpEnabled(context) || isHandwaveGestureEnabled(context) return pickUpEnabled(context) || handwaveGestureEnabled(context)
|| isPocketGestureEnabled(context); || pocketGestureEnabled(context);
} }
} }

View file

@ -19,7 +19,7 @@
set -e set -e
DEVICE_COMMON=msm8937-common DEVICE_COMMON=msm8937-common
VENDOR=lenovo VENDOR=xiaomi
# Load extract_utils and do some sanity checks # Load extract_utils and do some sanity checks
MY_DIR="${BASH_SOURCE%/*}" MY_DIR="${BASH_SOURCE%/*}"
@ -34,8 +34,8 @@ if [ ! -f "$HELPER" ]; then
fi fi
. "$HELPER" . "$HELPER"
# Default not to sanitizing the vendor folder before extraction # Default to sanitizing the vendor folder before extraction
CLEAN_VENDOR=false CLEAN_VENDOR=true
while [ "$1" != "" ]; do while [ "$1" != "" ]; do
case $1 in case $1 in

View file

@ -5,6 +5,6 @@
}, },
{ {
"repository": "android_kernel_xiaomi_msm8937", "repository": "android_kernel_xiaomi_msm8937",
"target_path": "kernel/lenovo/msm8937" "target_path": "kernel/xiaomi/msm8937"
} }
] ]

View file

@ -11,7 +11,7 @@
is removed from the manifest file and written by assemble_vintf is removed from the manifest file and written by assemble_vintf
at build time. at build time.
--> -->
<manifest version="1.0" type="device" target-level="1"> <manifest version="1.0" type="device">
<hal format="hidl"> <hal format="hidl">
<name>android.hardware.audio</name> <name>android.hardware.audio</name>
<transport>hwbinder</transport> <transport>hwbinder</transport>
@ -74,7 +74,7 @@
<hal format="hidl"> <hal format="hidl">
<name>android.hardware.configstore</name> <name>android.hardware.configstore</name>
<transport>hwbinder</transport> <transport>hwbinder</transport>
<version>1.1</version> <version>1.0</version>
<interface> <interface>
<name>ISurfaceFlingerConfigs</name> <name>ISurfaceFlingerConfigs</name>
<instance>default</instance> <instance>default</instance>
@ -144,7 +144,7 @@
<hal format="hidl"> <hal format="hidl">
<name>android.hardware.health</name> <name>android.hardware.health</name>
<transport>hwbinder</transport> <transport>hwbinder</transport>
<version>2.0</version> <version>1.0</version>
<interface> <interface>
<name>IHealth</name> <name>IHealth</name>
<instance>default</instance> <instance>default</instance>
@ -202,7 +202,7 @@
<hal format="hidl"> <hal format="hidl">
<name>android.hardware.power</name> <name>android.hardware.power</name>
<transport>hwbinder</transport> <transport>hwbinder</transport>
<version>1.1</version> <version>1.0</version>
<interface> <interface>
<name>IPower</name> <name>IPower</name>
<instance>default</instance> <instance>default</instance>
@ -250,21 +250,12 @@
<hal format="hidl"> <hal format="hidl">
<name>android.hardware.soundtrigger</name> <name>android.hardware.soundtrigger</name>
<transport>hwbinder</transport> <transport>hwbinder</transport>
<version>2.1</version> <version>2.0</version>
<interface> <interface>
<name>ISoundTriggerHw</name> <name>ISoundTriggerHw</name>
<instance>default</instance> <instance>default</instance>
</interface> </interface>
</hal> </hal>
<hal format="hidl">
<name>android.hardware.usb</name>
<transport>hwbinder</transport>
<version>1.0</version>
<interface>
<name>IUsb</name>
<instance>default</instance>
</interface>
</hal>
<hal format="hidl"> <hal format="hidl">
<name>android.hardware.vibrator</name> <name>android.hardware.vibrator</name>
<transport>hwbinder</transport> <transport>hwbinder</transport>
@ -277,25 +268,16 @@
<hal format="hidl"> <hal format="hidl">
<name>android.hardware.wifi</name> <name>android.hardware.wifi</name>
<transport>hwbinder</transport> <transport>hwbinder</transport>
<version>1.2</version> <version>1.1</version>
<interface> <interface>
<name>IWifi</name> <name>IWifi</name>
<instance>default</instance> <instance>default</instance>
</interface> </interface>
</hal> </hal>
<hal format="hidl">
<name>android.hardware.wifi.hostapd</name>
<transport>hwbinder</transport>
<version>1.0</version>
<interface>
<name>IHostapd</name>
<instance>default</instance>
</interface>
</hal>
<hal format="hidl"> <hal format="hidl">
<name>android.hardware.wifi.supplicant</name> <name>android.hardware.wifi.supplicant</name>
<transport>hwbinder</transport> <transport>hwbinder</transport>
<version>1.1</version> <version>1.0</version>
<interface> <interface>
<name>ISupplicant</name> <name>ISupplicant</name>
<instance>default</instance> <instance>default</instance>

View file

@ -67,7 +67,7 @@ PRODUCT_PACKAGES += \
android.hardware.audio@2.0-impl \ android.hardware.audio@2.0-impl \
android.hardware.audio@2.0-service \ android.hardware.audio@2.0-service \
android.hardware.audio.effect@2.0-impl \ android.hardware.audio.effect@2.0-impl \
android.hardware.soundtrigger@2.1-impl android.hardware.soundtrigger@2.0-impl
PRODUCT_COPY_FILES += \ PRODUCT_COPY_FILES += \
frameworks/av/services/audiopolicy/config/a2dp_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/a2dp_audio_policy_configuration.xml \ frameworks/av/services/audiopolicy/config/a2dp_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/a2dp_audio_policy_configuration.xml \
@ -83,6 +83,9 @@ PRODUCT_COPY_FILES += \
$(VENDOR_PATH)/audio/sound_trigger_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_platform_info.xml $(VENDOR_PATH)/audio/sound_trigger_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_platform_info.xml
# Bluetooth # Bluetooth
PRODUCT_PACKAGES += \
libbt-vendor
PRODUCT_PACKAGES += \ PRODUCT_PACKAGES += \
android.hardware.bluetooth@1.0-service android.hardware.bluetooth@1.0-service
@ -164,8 +167,8 @@ PRODUCT_COPY_FILES += \
# Healthd # Healthd
PRODUCT_PACKAGES += \ PRODUCT_PACKAGES += \
android.hardware.health@2.0-impl \ android.hardware.health@1.0-impl \
android.hardware.health@2.0-service android.hardware.health@1.0-service
# HIDL # HIDL
PRODUCT_PACKAGES += \ PRODUCT_PACKAGES += \
@ -281,7 +284,7 @@ PRODUCT_COPY_FILES += \
# Power # Power
PRODUCT_PACKAGES += \ PRODUCT_PACKAGES += \
android.hardware.power@1.1-service-qti android.hardware.power@1.0-service-qti
PRODUCT_COPY_FILES += \ PRODUCT_COPY_FILES += \
$(VENDOR_PATH)/configs/powerhint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/powerhint.xml $(VENDOR_PATH)/configs/powerhint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/powerhint.xml
@ -346,10 +349,6 @@ PRODUCT_BOOT_JARS += \
PRODUCT_PACKAGES += \ PRODUCT_PACKAGES += \
$(VENDOR_PATH)/configs/thermal-engine.conf:$(TARGET_COPY_OUT_VENDOR)/etc/thermal-engine.conf $(VENDOR_PATH)/configs/thermal-engine.conf:$(TARGET_COPY_OUT_VENDOR)/etc/thermal-engine.conf
# USB
PRODUCT_PACKAGES += \
android.hardware.usb@1.0-service.basic
# Vibrator # Vibrator
PRODUCT_PACKAGES += \ PRODUCT_PACKAGES += \
android.hardware.vibrator@1.0-impl \ android.hardware.vibrator@1.0-impl \

View file

@ -120,6 +120,10 @@ vendor/lib64/vendor.qti.hardware.data.latency@1.0_vendor.so|9f0ccc560f84682b08e1
# Charger - from tissot 8.1.0 OPM1.171019.026 # Charger - from tissot 8.1.0 OPM1.171019.026
vendor/bin/hvdcp_opti|57e6c5bd929173d537c7003096cab430e9422aff vendor/bin/hvdcp_opti|57e6c5bd929173d537c7003096cab430e9422aff
# Consumer IR - from santoni (Redmi 4X)
lib/hw/consumerir.default.so:vendor/lib/hw/consumerir.default.so|53830d64d63d6cc405209d8d4cafea102dcd7b54
lib64/hw/consumerir.default.so:vendor/lib64/hw/consumerir.default.so|f7c90fd1d6a0c5e6cf620aa23a862e780feaaf6c
# DPM - from tissot 8.1.0 OPM1.171019.026 # DPM - from tissot 8.1.0 OPM1.171019.026
vendor/bin/dpmQmiMgr|e4c66e1111b1d1ca0ef3912730dfcca7d8654f88 vendor/bin/dpmQmiMgr|e4c66e1111b1d1ca0ef3912730dfcca7d8654f88
vendor/lib64/com.qualcomm.qti.dpm.api@1.0_vendor.so|6f55fc94e316cae982b83130dd1a9e80d86813f0 vendor/lib64/com.qualcomm.qti.dpm.api@1.0_vendor.so|6f55fc94e316cae982b83130dd1a9e80d86813f0

View file

@ -19,6 +19,7 @@
/dev/block/bootdevice/by-name/dsp /dsp ext4 ro,nosuid,nodev wait /dev/block/bootdevice/by-name/dsp /dsp ext4 ro,nosuid,nodev wait
/dev/block/bootdevice/by-name/modem /firmware vfat ro,context=u:object_r:firmware_file:s0,shortname=lower,uid=1000,gid=1000,dmask=227,fmask=337 wait /dev/block/bootdevice/by-name/modem /firmware vfat ro,context=u:object_r:firmware_file:s0,shortname=lower,uid=1000,gid=1000,dmask=227,fmask=337 wait
/dev/block/bootdevice/by-name/misc /misc emmc defaults defaults /dev/block/bootdevice/by-name/misc /misc emmc defaults defaults
/dev/block/bootdevice/by-name/config /frp emmc defaults defaults
/devices/soc/7864900.sdhci/mmc_host* auto auto nosuid,nodev wait,voldmanaged=sdcard1:auto,noemulatedsd,encryptable=footer /devices/soc/7864900.sdhci/mmc_host* auto auto nosuid,nodev wait,voldmanaged=sdcard1:auto,noemulatedsd,encryptable=footer
/devices/soc/78db000.usb/msm_hsusb_host* auto auto nosuid,nodev wait,voldmanaged=usbotg:auto /devices/soc/78db000.usb/msm_hsusb_host* auto auto nosuid,nodev wait,voldmanaged=usbotg:auto

View file

@ -175,8 +175,11 @@ on post-fs-data
# Create the directories used by the Wireless subsystem # Create the directories used by the Wireless subsystem
mkdir /data/vendor/wifi 0770 wifi wifi mkdir /data/vendor/wifi 0770 wifi wifi
mkdir /data/vendor/wifi/wpa 0770 wifi wifi mkdir /data/misc/wifi 0770 wifi wifi
mkdir /data/vendor/wifi/wpa/sockets 0770 wifi wifi mkdir /data/misc/wifi/sockets 0770 wifi wifi
mkdir /data/misc/wifi/wpa_supplicant 0770 wifi wifi
mkdir /data/misc/dhcp 0770 dhcp dhcp
chown dhcp dhcp /data/misc/dhcp
# Create netmgr log dir # Create netmgr log dir
mkdir /data/vendor/netmgr 0770 radio radio mkdir /data/vendor/netmgr 0770 radio radio
@ -349,10 +352,12 @@ on property:sys.sysctl.tcp_adv_win_scale=*
write /proc/sys/net/ipv4/tcp_adv_win_scale ${sys.sysctl.tcp_adv_win_scale} write /proc/sys/net/ipv4/tcp_adv_win_scale ${sys.sysctl.tcp_adv_win_scale}
service wpa_supplicant /vendor/bin/hw/wpa_supplicant \ service wpa_supplicant /vendor/bin/hw/wpa_supplicant \
-O/data/vendor/wifi/sockets -puse_p2p_group_interface=1 -dd \ -ip2p0 -Dnl80211 -c/data/misc/wifi/p2p_supplicant.conf \
-I/vendor/etc/wifi/p2p_supplicant_overlay.conf -N \
-iwlan0 -Dnl80211 -c/data/misc/wifi/wpa_supplicant.conf \
-I/vendor/etc/wifi/wpa_supplicant_overlay.conf \
-O/data/misc/wifi/sockets -puse_p2p_group_interface=1 -dd \
-g@android:wpa_wlan0 -g@android:wpa_wlan0
interface android.hardware.wifi.supplicant@1.0::ISupplicant default
interface android.hardware.wifi.supplicant@1.1::ISupplicant default
class main class main
socket wpa_wlan0 dgram 660 wifi wifi socket wpa_wlan0 dgram 660 wifi wifi
disabled disabled

View file

@ -1,5 +1,5 @@
# Biometric # Biometric
/(vendor|system/vendor)/bin/hw/android\.hardware\.biometrics\.fingerprint@2\.1-service\.lenovo_msm8937 u:object_r:hal_fingerprint_msm8937_exec:s0 /(vendor|system/vendor)/bin/hw/android\.hardware\.biometrics\.fingerprint@2\.1-service\.xiaomi_msm8937 u:object_r:hal_fingerprint_msm8937_exec:s0
# Bluetooth # Bluetooth
/(vendor|system/vendor)/bin/hci_qcomm_init u:object_r:bluetooth_loader_exec:s0 /(vendor|system/vendor)/bin/hci_qcomm_init u:object_r:bluetooth_loader_exec:s0

View file

@ -19,7 +19,7 @@
set -e set -e
DEVICE_COMMON=msm8937-common DEVICE_COMMON=msm8937-common
VENDOR=lenovo VENDOR=xiaomi
INITIAL_COPYRIGHT_YEAR=2018 INITIAL_COPYRIGHT_YEAR=2018
@ -40,7 +40,7 @@ fi
setup_vendor "$DEVICE_COMMON" "$VENDOR" "$LINEAGE_ROOT" true setup_vendor "$DEVICE_COMMON" "$VENDOR" "$LINEAGE_ROOT" true
# Copyright headers and guards # Copyright headers and guards
write_headers "karate" write_headers "land santoni"
# The standard common blobs # The standard common blobs
write_makefiles "$MY_DIR"/proprietary-files-qc.txt true write_makefiles "$MY_DIR"/proprietary-files-qc.txt true

View file

@ -20,7 +20,7 @@ from hashlib import sha1
import sys import sys
device='msm8937-common' device='msm8937-common'
vendor='lenovo' vendor='xiaomi'
lines = [ line for line in open('proprietary-files-qc.txt', 'r') ] lines = [ line for line in open('proprietary-files-qc.txt', 'r') ]
vendorPath = '../../../vendor/' + vendor + '/' + device + '/proprietary' vendorPath = '../../../vendor/' + vendor + '/' + device + '/proprietary'

View file

@ -1,9 +1,7 @@
VNDK_SP_LIBRARIES := \ VNDK_SP_LIBRARIES := \
android.hardware.graphics.allocator@2.0 \ android.hardware.graphics.allocator@2.0 \
android.hardware.graphics.common@1.0 \ android.hardware.graphics.common@1.0 \
android.hardware.graphics.common@1.1 \
android.hardware.graphics.mapper@2.0 \ android.hardware.graphics.mapper@2.0 \
android.hardware.graphics.mapper@2.1 \
android.hardware.renderscript@1.0 \ android.hardware.renderscript@1.0 \
android.hidl.memory@1.0 \ android.hidl.memory@1.0 \
libRSCpuRef \ libRSCpuRef \
@ -26,11 +24,8 @@ VNDK_SP_LIBRARIES := \
liblzma \ liblzma \
libpng \ libpng \
libunwind \ libunwind \
libunwindstack \
libutils \ libutils \
libz \ libz
libutilscallstack \
libdexfile
EXTRA_VENDOR_LIBRARIES := \ EXTRA_VENDOR_LIBRARIES := \
android.hidl.base@1.0 \ android.hidl.base@1.0 \
@ -39,18 +34,10 @@ EXTRA_VENDOR_LIBRARIES := \
vendor.display.config@1.0 \ vendor.display.config@1.0 \
vendor.qti.hardware.iop@1.0 vendor.qti.hardware.iop@1.0
INSTALL_IN_HW_SUBDIR := android.hidl.memory@1.0-impl
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
# VNDK Modules # VNDK Modules
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
ifdef PLATFORM_VNDK_VERSION
VNDK_SP_DIR := vndk-sp-$(PLATFORM_VNDK_VERSION)
else
VNDK_SP_DIR := vndk-sp
endif
LOCAL_PATH := $(call my-dir) LOCAL_PATH := $(call my-dir)
define define-vndk-lib define define-vndk-lib
@ -63,7 +50,7 @@ LOCAL_MULTILIB := first
LOCAL_MODULE_TAGS := optional LOCAL_MODULE_TAGS := optional
LOCAL_INSTALLED_MODULE_STEM := $1.so LOCAL_INSTALLED_MODULE_STEM := $1.so
LOCAL_MODULE_SUFFIX := .so LOCAL_MODULE_SUFFIX := .so
LOCAL_MODULE_RELATIVE_PATH := $3$(if $(filter $1,$(INSTALL_IN_HW_SUBDIR)),/hw) LOCAL_MODULE_RELATIVE_PATH := $3
LOCAL_VENDOR_MODULE := $4 LOCAL_VENDOR_MODULE := $4
include $$(BUILD_PREBUILT) include $$(BUILD_PREBUILT)
@ -78,7 +65,7 @@ LOCAL_MULTILIB := 32
LOCAL_MODULE_TAGS := optional LOCAL_MODULE_TAGS := optional
LOCAL_INSTALLED_MODULE_STEM := $1.so LOCAL_INSTALLED_MODULE_STEM := $1.so
LOCAL_MODULE_SUFFIX := .so LOCAL_MODULE_SUFFIX := .so
LOCAL_MODULE_RELATIVE_PATH := $3$(if $(filter $1,$(INSTALL_IN_HW_SUBDIR)),/hw) LOCAL_MODULE_RELATIVE_PATH := $3
LOCAL_VENDOR_MODULE := $4 LOCAL_VENDOR_MODULE := $4
include $$(BUILD_PREBUILT) include $$(BUILD_PREBUILT)
endif # TARGET_TRANSLATE_2ND_ARCH is not true endif # TARGET_TRANSLATE_2ND_ARCH is not true
@ -86,13 +73,12 @@ endif # TARGET_2ND_ARCH is not empty
endef endef
$(foreach lib,$(VNDK_SP_LIBRARIES),\ $(foreach lib,$(VNDK_SP_LIBRARIES),\
$(eval $(call define-vndk-lib,$(lib),vndk-sp-gen,$(VNDK_SP_DIR),))) $(eval $(call define-vndk-lib,$(lib),vndk-sp-gen,vndk-sp,)))
$(foreach lib,$(VNDK_SP_EXT_LIBRARIES),\ $(foreach lib,$(VNDK_SP_EXT_LIBRARIES),\
$(eval $(call define-vndk-lib,$(lib),vndk-sp-ext-gen,$(VNDK_SP_DIR),true))) $(eval $(call define-vndk-lib,$(lib),vndk-sp-ext-gen,vndk-sp,true)))
$(foreach lib,$(EXTRA_VENDOR_LIBRARIES),\ $(foreach lib,$(EXTRA_VENDOR_LIBRARIES),\
$(eval $(call define-vndk-lib,$(lib),vndk-ext-gen,,true))) $(eval $(call define-vndk-lib,$(lib),vndk-ext-gen,,true)))
VNDK_SP_DIR :=
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
# Phony Package # Phony Package
@ -106,8 +92,3 @@ LOCAL_REQUIRED_MODULES := \
$(addsuffix .vndk-sp-ext-gen,$(VNDK_SP_EXT_LIBRARIES)) \ $(addsuffix .vndk-sp-ext-gen,$(VNDK_SP_EXT_LIBRARIES)) \
$(addsuffix .vndk-ext-gen,$(EXTRA_VENDOR_LIBRARIES)) $(addsuffix .vndk-ext-gen,$(EXTRA_VENDOR_LIBRARIES))
include $(BUILD_PHONY_PACKAGE) include $(BUILD_PHONY_PACKAGE)
VNDK_SP_LIBRARIES :=
VNDK_SP_EXT_LIBRARIES :=
EXTRA_VENDOR_LIBRARIES :=
INSTALL_IN_HW_SUBDIR :=