Compare commits
72 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
969921c9d2 | ||
|
|
95fdf78d7d | ||
|
|
4b1f11bea1 | ||
|
|
b25e8937af | ||
|
|
ffcc869f3d | ||
|
|
17bbae1937 | ||
|
|
520dca561f | ||
|
|
df9fd5317b | ||
|
|
3feddf5d83 | ||
|
|
70228d4c82 | ||
|
|
76908973eb | ||
|
|
9fe63005df | ||
|
|
af615d958f | ||
|
|
424f353e21 | ||
|
|
4c3d4e054d | ||
|
|
e36c418d6d | ||
|
|
d684b42dea | ||
|
|
a943c0952f | ||
|
|
59a1085565 | ||
|
|
26be72933f | ||
|
|
e7fee7ec72 | ||
|
|
ea80c1a56a | ||
|
|
79459db5bb | ||
|
|
e26a736193 | ||
|
|
77c5c9ebeb | ||
|
|
52abf8d743 | ||
|
|
7367815f38 | ||
|
|
aa79a946d0 | ||
|
|
69deaaf71c | ||
|
|
b979314f49 | ||
|
|
0874c784fc | ||
|
|
a921879ab9 | ||
|
|
09325e4649 | ||
|
|
40b5607fbf | ||
|
|
34e0542d15 | ||
|
|
c4783ebc14 | ||
|
|
495f16aa62 | ||
|
|
1ae4321dfd | ||
|
|
d066e06f8d | ||
|
|
9ae0c766fb | ||
|
|
1ed8330a0d | ||
|
|
d197f49f27 | ||
|
|
e408e7ed19 | ||
|
|
c3465ccb28 | ||
|
|
1dd446cc35 | ||
|
|
57c3a2e49c | ||
|
|
1f6ac4d356 | ||
|
|
2dc7641e68 | ||
|
|
83051e2180 | ||
|
|
9acdd2ce8a | ||
|
|
7ba3a1ccbc | ||
|
|
953fadb597 | ||
|
|
c1cb4e49e6 | ||
|
|
94e87c52b1 | ||
|
|
0c7136e49c | ||
|
|
d2876b5715 | ||
|
|
64f8efa983 | ||
|
|
7039fa836d | ||
|
|
ed7d89fd47 | ||
|
|
fa1a9c4d07 | ||
|
|
97a3520e15 | ||
|
|
6acdaac083 | ||
|
|
dc9dcce222 | ||
|
|
09b2f4ed8b | ||
|
|
f3e94320a5 | ||
|
|
f4eca49db6 | ||
|
|
1404e74c74 | ||
|
|
f267f97373 | ||
|
|
5e4999467e | ||
|
|
721bf8f908 | ||
|
|
55e59d11d9 | ||
|
|
6f4a750de1 |
@@ -1,3 +1,8 @@
|
||||
//
|
||||
// Copyright (C) 2024-2025 The LineageOS Project
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
//
|
||||
|
||||
soong_namespace {
|
||||
}
|
||||
|
||||
|
||||
@@ -18,8 +18,6 @@ LOCAL_PATH := $(call my-dir)
|
||||
|
||||
ifneq ($(filter a52sxq m52xq a73xq,$(TARGET_DEVICE)),)
|
||||
|
||||
include $(call all-makefiles-under,$(LOCAL_PATH))
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
FIRMWARE_MODEM_MOUNT_POINT := $(TARGET_OUT_VENDOR)/firmware-modem
|
||||
|
||||
@@ -139,14 +139,15 @@ USE_XML_AUDIO_POLICY_CONF := 1
|
||||
AUDIOSERVER_MULTILIB := 32
|
||||
|
||||
# Audio
|
||||
AUDIO_FEATURE_ENABLED_AHAL_EXT := false
|
||||
AUDIO_FEATURE_ENABLED_AHAL_EXT := true
|
||||
AUDIO_FEATURE_ENABLED_COMPRESS_VOIP := false
|
||||
AUDIO_FEATURE_ENABLED_DLKM := true
|
||||
AUDIO_FEATURE_ENABLED_DS2_DOLBY_DAP := false
|
||||
AUDIO_FEATURE_ENABLED_DS2_DOLBY_DAP := true
|
||||
AUDIO_FEATURE_ENABLED_DTS_EAGLE := false
|
||||
AUDIO_FEATURE_ENABLED_DYNAMIC_LOG := false
|
||||
AUDIO_FEATURE_ENABLED_DYNAMIC_LOG := true
|
||||
AUDIO_FEATURE_ENABLED_EXT_AMPLIFIER := false
|
||||
AUDIO_FEATURE_ENABLED_EXTENDED_COMPRESS_FORMAT := true
|
||||
AUDIO_FEATURE_ENABLED_GEF_SUPPORT := true
|
||||
AUDIO_FEATURE_ENABLED_GEF_SUPPORT := false
|
||||
AUDIO_FEATURE_ENABLED_GKI := true
|
||||
AUDIO_FEATURE_ENABLED_HW_ACCELERATED_EFFECTS := false
|
||||
AUDIO_FEATURE_ENABLED_INSTANCE_ID := true
|
||||
@@ -154,43 +155,19 @@ AUDIO_FEATURE_ENABLED_PROXY_DEVICE := true
|
||||
AUDIO_FEATURE_ENABLED_SSR := false
|
||||
AUDIO_FEATURE_ENABLED_SVA_MULTI_STAGE := true
|
||||
BOARD_SUPPORTS_SOUND_TRIGGER := true
|
||||
|
||||
# Camera
|
||||
SOONG_CONFIG_NAMESPACES += samsungCameraVars
|
||||
SOONG_CONFIG_samsungCameraVars += \
|
||||
extra_ids \
|
||||
needs_sec_reserved_field
|
||||
|
||||
# ID=54 is macro
|
||||
SOONG_CONFIG_samsungCameraVars_extra_ids := 54
|
||||
|
||||
SOONG_CONFIG_samsungCameraVars_needs_sec_reserved_field := true
|
||||
|
||||
# Init
|
||||
TARGET_INIT_VENDOR_LIB := //$(COMMON_PATH):libinit_samsung_sm7325
|
||||
TARGET_PROVIDES_AUDIO_EXTNS := true
|
||||
|
||||
# HIDL manifests
|
||||
DEVICE_MANIFEST_SKUS := yupik
|
||||
DEVICE_MANIFEST_YUPIK_FILES += $(COMMON_PATH)/configs/manifest_yupik.xml
|
||||
DEVICE_MANIFEST_FILE += $(COMMON_PATH)/configs/manifest_lahaina.xml
|
||||
DEVICE_MATRIX_FILE := hardware/qcom-caf/common/compatibility_matrix.xml
|
||||
DEVICE_FRAMEWORK_COMPATIBILITY_MATRIX_FILE := \
|
||||
DEVICE_FRAMEWORK_COMPATIBILITY_MATRIX_FILE += \
|
||||
$(COMMON_PATH)/configs/framework_compatibility_matrix.xml \
|
||||
hardware/samsung/vintf/samsung_framework_compatibility_matrix.xml \
|
||||
hardware/qcom-caf/common/vendor_framework_compatibility_matrix.xml \
|
||||
vendor/lineage/config/device_framework_matrix.xml
|
||||
hardware/qcom-caf/common/vendor_framework_compatibility_matrix.xml
|
||||
|
||||
# QCOM
|
||||
BOARD_USES_QCOM_HARDWARE := true
|
||||
|
||||
# Samsung
|
||||
BOARD_VENDOR := samsung
|
||||
|
||||
# Lineage Health
|
||||
TARGET_HEALTH_CHARGING_CONTROL_CHARGING_PATH := /sys/class/power_supply/battery/batt_slate_mode
|
||||
TARGET_HEALTH_CHARGING_CONTROL_CHARGING_ENABLED := 0
|
||||
TARGET_HEALTH_CHARGING_CONTROL_CHARGING_DISABLED := 1
|
||||
TARGET_HEALTH_CHARGING_CONTROL_SUPPORTS_BYPASS := false
|
||||
|
||||
# DRM
|
||||
TARGET_ENABLE_MEDIADRM_64 := true
|
||||
|
||||
@@ -213,25 +190,24 @@ ENABLE_VENDOR_RIL_SERVICE := true
|
||||
# Recovery
|
||||
BOARD_HAS_DOWNLOAD_MODE := true
|
||||
BOARD_INCLUDE_RECOVERY_DTBO := true
|
||||
TARGET_RECOVERY_FSTAB := $(COMMON_PATH)/init/fstab.qcom
|
||||
TARGET_RECOVERY_PIXEL_FORMAT := RGBX_8888
|
||||
BOARD_RECOVERY_MKBOOTIMG_ARGS += --header_version 2
|
||||
TARGET_USES_MKE2FS := true
|
||||
BOARD_USES_FULL_RECOVERY_IMAGE := true
|
||||
TARGET_RECOVERY_FSTAB := $(COMMON_PATH)/recovery/root/fstab.qcom
|
||||
|
||||
# Releasetools
|
||||
TARGET_RECOVERY_UPDATER_LIBS := librecovery_updater_samsung_sm7325
|
||||
TARGET_RELEASETOOLS_EXTENSIONS := $(COMMON_PATH)/releasetools
|
||||
|
||||
# SePolicy
|
||||
include device/lineage/sepolicy/libperfmgr/sepolicy.mk
|
||||
include device/qcom/sepolicy_vndr/SEPolicy.mk
|
||||
include hardware/samsung-ext/interfaces/sepolicy/SEPolicy.mk
|
||||
BOARD_VENDOR_SEPOLICY_DIRS += $(COMMON_PATH)/sepolicy/vendor
|
||||
PRODUCT_PRIVATE_SEPOLICY_DIRS += $(COMMON_PATH)/sepolicy/private
|
||||
PRODUCT_PUBLIC_SEPOLICY_DIRS += $(COMMON_PATH)/sepolicy/public
|
||||
|
||||
# Vibrator
|
||||
$(call soong_config_set,samsungVibratorVars,duration_amplitude,true)
|
||||
|
||||
# WiFi
|
||||
BOARD_WLAN_DEVICE := qcwcn
|
||||
BOARD_HOSTAPD_DRIVER := NL80211
|
||||
|
||||
@@ -41,6 +41,19 @@
|
||||
<library name="volume_listener" path="libvolumelistener.so"/>
|
||||
<library name="audiosphere" path="libasphere.so"/>
|
||||
<library name="shoebox" path="libshoebox.so"/>
|
||||
<!--DOLBY DAP-->
|
||||
<library name="dap" path="libswdap.so"/>
|
||||
<library name="dvl" path="libdlbvol.so"/>
|
||||
<!--DOLBY END-->
|
||||
<!--DOLBY GAME-->
|
||||
<library name="gamedap" path="libswgamedap.so"/>
|
||||
<!--DOLBY END-->
|
||||
<!--DOLBY VQE-->
|
||||
<library name="vqe" path="libswvqe.so"/>
|
||||
<!--DOLBY END-->
|
||||
<!--Spatial Audio-->
|
||||
<library name="spatializer" path="libspatialaudio.so"/>
|
||||
<!--Spatial Audio-->
|
||||
</libraries>
|
||||
<effects>
|
||||
<effectProxy name="bassboost" library="proxy" uuid="14804144-a5ee-4d24-aa88-0002a5d5c51b">
|
||||
@@ -77,7 +90,6 @@
|
||||
<libhw library="visualizer_hw" uuid="7a8044a0-1a71-11e3-a184-0002a5d5c51b"/>
|
||||
</effectProxy>
|
||||
<effect name="downmix" library="downmix" uuid="93f04452-e4fe-41cc-91f9-e475b6d1d69f"/>
|
||||
<effect name="hw_acc" library="offload_bundle" uuid="7d1580bd-297f-4683-9239-e475b6d1d69f"/>
|
||||
<effect name="loudness_enhancer" library="loudness_enhancer" uuid="fa415329-2034-4bea-b5dc-5b381c8d1e2c"/>
|
||||
<effect name="dynamics_processing" library="dynamics_processing" uuid="e0e6539b-1781-7261-676f-6d7573696340"/>
|
||||
<effect name="aec" library="audio_pre_processing" uuid="0f8d0d2a-59e5-45fe-b6e4-248c8a799109"/>
|
||||
@@ -89,23 +101,29 @@
|
||||
<effect name="notification_helper" library="volume_listener" uuid="0b776dde-0590-11e5-81ba-0025b32654a0"/>
|
||||
<effect name="audiosphere" library="audiosphere" uuid="184e62ab-2d19-4364-9d1b-c0a40733866c"/>
|
||||
<effect name="shoebox" library="shoebox" uuid="1eab784c-1a36-4b2a-b7fc-e34c44cab89e"/>
|
||||
<!--DOLBY DAP-->
|
||||
<effect name="dap" library="dap" uuid="9d4921da-8225-4f29-aefa-39537a04bcaa"/>
|
||||
<effect name="dlb_music_listener" library="dvl" uuid="40f66c8b-5aa5-4345-8919-53ec431aaa98"/>
|
||||
<effect name="dlb_ring_listener" library="dvl" uuid="21d14087-558a-4f21-94a9-5002dce64bce"/>
|
||||
<effect name="dlb_alarm_listener" library="dvl" uuid="6aff229c-30c6-4cc8-9957-dbfe5c1bd7f6"/>
|
||||
<effect name="dlb_system_listener" library="dvl" uuid="874db4d8-051d-4b7b-bd95-a3bebc837e9e"/>
|
||||
<effect name="dlb_notification_listener" library="dvl" uuid="1f0091e3-6ad8-40fe-9b09-5948f9a26e7e"/>
|
||||
<effect name="dlb_voice_call_listener" library="dvl" uuid="58d13383-b41d-05df-d94e-bb23db293260"/>
|
||||
<!--DOLBY END-->
|
||||
<!--DOLBY GAME-->
|
||||
<effect name="gamedap" library="gamedap" uuid="3783c334-d3a0-4d13-874f-0032e5fb80e2"/>
|
||||
<!--DOLBY END-->
|
||||
<!--DOLBY VQE-->
|
||||
<effect name="vqe" library="vqe" uuid="64a0f614-7fa4-48b8-b081-d59dc954616f"/>
|
||||
<!--DOLBY END-->
|
||||
<!--Spatial Audio-->
|
||||
<effect name="spatializer" library="spatializer" uuid="cc4677de-ff72-11eb-9a03-0242ac130003"/>
|
||||
<!--Spatial Audio-->
|
||||
</effects>
|
||||
<postprocess>
|
||||
<stream type="music">
|
||||
<apply effect="music_helper"/>
|
||||
</stream>
|
||||
<stream type="ring">
|
||||
<apply effect="ring_helper"/>
|
||||
</stream>
|
||||
<stream type="alarm">
|
||||
<apply effect="alarm_helper"/>
|
||||
</stream>
|
||||
<stream type="voice_call">
|
||||
<apply effect="voice_helper"/>
|
||||
</stream>
|
||||
<stream type="notification">
|
||||
<apply effect="notification_helper"/>
|
||||
</stream>
|
||||
</stream>
|
||||
</postprocess>
|
||||
<preprocess>
|
||||
<stream type="voice_communication">
|
||||
|
||||
@@ -145,25 +145,10 @@ inputs {
|
||||
bit_width 16
|
||||
app_type 69938
|
||||
}
|
||||
record_24bit {
|
||||
formats AUDIO_FORMAT_PCM_8_24_BIT|AUDIO_FORMAT_PCM_24_BIT_PACKED|AUDIO_FORMAT_PCM_24_BIT
|
||||
sampling_rates 44100|48000|88200|96000|176400|192000
|
||||
bit_width 24
|
||||
# [[ SEC_AUDIO
|
||||
app_type 69944
|
||||
# SEC_AUDIO ]]
|
||||
#app_type 69948
|
||||
}
|
||||
#record_32bit {
|
||||
# formats AUDIO_FORMAT_PCM_32_BIT|AUDIO_FORMAT_PCM_FLOAT
|
||||
# sampling_rates 44100|48000|88200|96000|176400|192000
|
||||
# bit_width 32
|
||||
# app_type 69949
|
||||
#}
|
||||
record_compress_16 {
|
||||
flags AUDIO_INPUT_FLAG_COMPRESS
|
||||
formats AUDIO_FORMAT_PCM_16_BIT
|
||||
sampling_rates 8000|16000|32000|44100|48000|88200|96000|176400|192000
|
||||
sampling_rates 48000|96000
|
||||
bit_width 16
|
||||
app_type 69938
|
||||
}
|
||||
|
||||
@@ -111,6 +111,12 @@
|
||||
</mixPort>
|
||||
<mixPort name="hifi_playback" role="source" />
|
||||
<mixPort name="hifi_input" role="sink" />
|
||||
<!--Spatial Audio-->
|
||||
<mixPort name="immersive_out" role="source" flags="AUDIO_OUTPUT_FLAG_SPATIALIZER">
|
||||
<profile name="" format="AUDIO_FORMAT_PCM_FLOAT"
|
||||
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
|
||||
<!--Spatial Audio-->
|
||||
</mixPort>
|
||||
</mixPorts>
|
||||
<devicePorts>
|
||||
<!-- Output devices declaration, i.e. Sink DEVICE PORT -->
|
||||
@@ -205,25 +211,25 @@
|
||||
<route type="mix" sink="Earpiece"
|
||||
sources="primary output,deep_buffer,fast,compressed_offload"/>
|
||||
<route type="mix" sink="Speaker"
|
||||
sources="primary output,deep_buffer,fast,compressed_offload,mmap_no_irq_out"/>
|
||||
sources="primary output,deep_buffer,fast,compressed_offload,mmap_no_irq_out,immersive_out"/>
|
||||
<route type="mix" sink="Wired Headset"
|
||||
sources="primary output,deep_buffer,fast,compressed_offload,mmap_no_irq_out"/>
|
||||
sources="primary output,deep_buffer,fast,compressed_offload,mmap_no_irq_out,immersive_out"/>
|
||||
<route type="mix" sink="Wired Headphones"
|
||||
sources="primary output,deep_buffer,fast,compressed_offload,mmap_no_irq_out"/>
|
||||
sources="primary output,deep_buffer,fast,compressed_offload,mmap_no_irq_out,immersive_out"/>
|
||||
<route type="mix" sink="USB Device Out"
|
||||
sources="primary output,deep_buffer,fast,direct_pcm,compressed_offload,mmap_no_irq_out,hifi_playback"/>
|
||||
sources="primary output,deep_buffer,fast,direct_pcm,compressed_offload,mmap_no_irq_out,hifi_playback,immersive_out"/>
|
||||
<route type="mix" sink="USB Headset Out"
|
||||
sources="primary output,deep_buffer,fast,direct_pcm,compressed_offload,mmap_no_irq_out,hifi_playback"/>
|
||||
sources="primary output,deep_buffer,fast,direct_pcm,compressed_offload,mmap_no_irq_out,hifi_playback,immersive_out"/>
|
||||
<route type="mix" sink="usb_surround_sound"
|
||||
sources="USB Device In,USB Headset In"/>
|
||||
<route type="mix" sink="hifi_input"
|
||||
sources="USB Device In,USB Headset In"/>
|
||||
<route type="mix" sink="BT SCO"
|
||||
sources="primary output,deep_buffer,fast,voip_rx"/>
|
||||
sources="primary output,deep_buffer,fast,voip_rx,immersive_out"/>
|
||||
<route type="mix" sink="BT SCO Headset"
|
||||
sources="primary output,deep_buffer,fast,voip_rx"/>
|
||||
sources="primary output,deep_buffer,fast,voip_rx,immersive_out"/>
|
||||
<route type="mix" sink="BT SCO Car Kit"
|
||||
sources="primary output,deep_buffer,fast,voip_rx"/>
|
||||
sources="primary output,deep_buffer,fast,voip_rx,immersive_out"/>
|
||||
<route type="mix" sink="Telephony Tx"
|
||||
sources="voice_tx,incall_music_uplink"/>
|
||||
<route type="mix" sink="voice_rx"
|
||||
|
||||
39
common.mk
39
common.mk
@@ -37,6 +37,7 @@ PRODUCT_ENABLE_UFFD_GC := false
|
||||
|
||||
# Init files and fstab
|
||||
PRODUCT_PACKAGES += \
|
||||
fstab.qcom \
|
||||
fstab.ramplus \
|
||||
init.audio.samsung.rc \
|
||||
init.fingerprint.rc \
|
||||
@@ -58,6 +59,8 @@ PRODUCT_PACKAGES += \
|
||||
wifi_qcom_wcn6750.rc \
|
||||
wifi_sec.rc
|
||||
|
||||
$(call soong_config_set,libinit,vendor_init_lib,//$(LOCAL_PATH):libinit_samsung_sm7325)
|
||||
|
||||
# Vendor scripts
|
||||
PRODUCT_PACKAGES += \
|
||||
init.class_main.sh \
|
||||
@@ -74,8 +77,7 @@ PRODUCT_PACKAGES += \
|
||||
init.qti.qcv.sh
|
||||
|
||||
PRODUCT_COPY_FILES += \
|
||||
$(LOCAL_PATH)/rootdir/etc/fstab.qcom:$(TARGET_COPY_OUT_VENDOR_RAMDISK)/first_stage_ramdisk/fstab.qcom \
|
||||
$(LOCAL_PATH)/rootdir/etc/fstab.qcom:$(TARGET_COPY_OUT_VENDOR)/etc/fstab.qcom
|
||||
$(LOCAL_PATH)/init/fstab.qcom:$(TARGET_COPY_OUT_VENDOR_RAMDISK)/first_stage_ramdisk/fstab.qcom
|
||||
|
||||
# Audio
|
||||
PRODUCT_PACKAGES += \
|
||||
@@ -121,6 +123,9 @@ PRODUCT_PACKAGES += \
|
||||
vendor.qti.hardware.camera.device@1.0.vendor \
|
||||
libui_shim.vendor
|
||||
|
||||
$(call soong_config_set_bool,samsungCameraVars,needs_sec_reserved_field,true)
|
||||
$(call soong_config_set,samsungCameraVars,extra_ids,54)
|
||||
|
||||
# CAS
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.cas@1.2-service
|
||||
@@ -168,6 +173,9 @@ PRODUCT_PACKAGES += \
|
||||
PRODUCT_PACKAGES += \
|
||||
SamsungDoze
|
||||
|
||||
# Dolby
|
||||
$(call inherit-product, hardware/dolby/dolby.mk)
|
||||
|
||||
# DRM
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.drm-service.clearkey \
|
||||
@@ -179,14 +187,18 @@ PRODUCT_PACKAGES += \
|
||||
PRODUCT_PACKAGES += \
|
||||
fastbootd
|
||||
|
||||
# FastCharge
|
||||
PRODUCT_PACKAGES += \
|
||||
vendor.lineage.fastcharge@1.0-service.samsung
|
||||
|
||||
# Lineage Health
|
||||
PRODUCT_PACKAGES += \
|
||||
vendor.lineage.health-service.default
|
||||
|
||||
$(call soong_config_set,lineage_health,charging_control_charging_path,/sys/class/power_supply/battery/batt_slate_mode)
|
||||
$(call soong_config_set,lineage_health,charging_control_charging_enabled,0)
|
||||
$(call soong_config_set,lineage_health,charging_control_charging_disabled,1)
|
||||
$(call soong_config_set_bool,lineage_health,charging_control_supports_bypass,false)
|
||||
$(call soong_config_set,lineage_health,fast_charge_node,/sys/class/sec/switch/afc_disable)
|
||||
$(call soong_config_set,lineage_health,fast_charge_value_none,1)
|
||||
$(call soong_config_set,lineage_health,fast_charge_value_fast_charge,0)
|
||||
|
||||
# Fingerprint
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.biometrics.fingerprint-service.samsung
|
||||
@@ -232,7 +244,7 @@ $(call soong_config_set,samsungVars,target_keymaster4_library,//vendor/samsung/s
|
||||
|
||||
# LiveDisplay
|
||||
PRODUCT_PACKAGES += \
|
||||
vendor.lineage.livedisplay@2.0-service.samsung-qcom.sm7325
|
||||
vendor.lineage.livedisplay-service.samsung-qcom
|
||||
|
||||
# Media
|
||||
PRODUCT_PACKAGES += \
|
||||
@@ -274,7 +286,7 @@ PRODUCT_PACKAGES += \
|
||||
|
||||
ifeq ($(TARGET_HAVE_SEC_NFC),true)
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.nfc@1.2-service.samsung
|
||||
android.hardware.nfc-service.sec
|
||||
|
||||
PRODUCT_COPY_FILES += \
|
||||
$(LOCAL_PATH)/configs/nfc/libnfc-sec-vendor.conf:$(TARGET_COPY_OUT_VENDOR)/etc/libnfc-sec-vendor.conf
|
||||
@@ -301,7 +313,6 @@ PRODUCT_COPY_FILES += \
|
||||
frameworks/native/data/etc/android.hardware.camera.full.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.full.xml \
|
||||
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.fingerprint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.fingerprint.xml \
|
||||
frameworks/native/data/etc/android.hardware.biometrics.face.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.biometrics.face.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.nfc.hcef.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hcef.xml \
|
||||
frameworks/native/data/etc/android.hardware.nfc.hce.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.nfc.hce.xml \
|
||||
@@ -380,7 +391,7 @@ PRODUCT_PACKAGES += \
|
||||
|
||||
# Touch features
|
||||
PRODUCT_PACKAGES += \
|
||||
vendor.lineage.touch@1.0-service.samsung_sm7325
|
||||
vendor.lineage.touch-service.samsung
|
||||
|
||||
# Vendor service manager
|
||||
PRODUCT_PACKAGES += \
|
||||
@@ -397,10 +408,17 @@ PRODUCT_PACKAGES += \
|
||||
|
||||
PRODUCT_SOONG_NAMESPACES += vendor/qcom/opensource/usb/etc
|
||||
|
||||
# Samsung Ext Flash
|
||||
PRODUCT_PACKAGES += \
|
||||
vendor.samsung_ext.hardware.camera.flashlight-service \
|
||||
FlashControl
|
||||
|
||||
# Vibrator
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.vibrator-service.samsung
|
||||
|
||||
$(call soong_config_set_bool,samsungVibratorVars,duration_amplitude,true)
|
||||
|
||||
# Tether
|
||||
PRODUCT_PACKAGES += \
|
||||
ipacm \
|
||||
@@ -447,6 +465,7 @@ PRODUCT_SOONG_NAMESPACES += \
|
||||
$(LOCAL_PATH) \
|
||||
hardware/google/interfaces \
|
||||
hardware/google/pixel \
|
||||
hardware/samsung-ext/interfaces \
|
||||
hardware/samsung
|
||||
|
||||
# Inherit proprietary blobs
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
<manifest version="2.0" type="device" target-level="5">
|
||||
<manifest version="2.0" type="device" target-level="6">
|
||||
<kernel target-level="5"/>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.audio</name>
|
||||
<transport>hwbinder</transport>
|
||||
@@ -7,7 +8,6 @@
|
||||
<name>IDevicesFactory</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@7.0::IDevicesFactory/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.audio.effect</name>
|
||||
@@ -17,17 +17,6 @@
|
||||
<name>IEffectsFactory</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@7.0::IEffectsFactory/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.biometrics.face</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IBiometricsFace</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.0::IBiometricsFace/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.bluetooth</name>
|
||||
@@ -37,7 +26,6 @@
|
||||
<name>IBluetoothHci</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.0::IBluetoothHci/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>android.hardware.gatekeeper</name>
|
||||
@@ -47,7 +35,6 @@
|
||||
<name>IGatekeeper</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.0::IGatekeeper/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>android.hardware.keymaster</name>
|
||||
@@ -57,7 +44,6 @@
|
||||
<name>IKeymasterDevice</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@4.0::IKeymasterDevice/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.media.c2</name>
|
||||
@@ -88,11 +74,6 @@
|
||||
<name>IRadioConfig</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.1::IRadioConfig/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>android.hardware.radio.deprecated</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.soundtrigger</name>
|
||||
@@ -102,7 +83,6 @@
|
||||
<name>ISoundTriggerHw</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@2.3::ISoundTriggerHw/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.tetheroffload.config</name>
|
||||
@@ -112,7 +92,6 @@
|
||||
<name>IOffloadConfig</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.0::IOffloadConfig/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.tetheroffload.control</name>
|
||||
@@ -122,23 +101,6 @@
|
||||
<name>IOffloadControl</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.1::IOffloadControl/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>com.qualcomm.qti.dpm.api</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>com.qualcomm.qti.imscmservice</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>com.qualcomm.qti.uceservice</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.data.factory</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.qti.hardware.cacert</name>
|
||||
@@ -148,7 +110,6 @@
|
||||
<name>IService</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.0::IService/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.qti.hardware.capabilityconfigstore</name>
|
||||
@@ -158,15 +119,6 @@
|
||||
<name>ICapabilityConfigStore</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.0::ICapabilityConfigStore/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.data.connection</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.data.latency</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.qti.hardware.dsp</name>
|
||||
@@ -176,16 +128,6 @@
|
||||
<name>IDspService</name>
|
||||
<instance>dspservice</instance>
|
||||
</interface>
|
||||
<fqname>@1.0::IDspService/dspservice</fqname>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.embmssl</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.factory</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.1</version>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.qti.hardware.iop</name>
|
||||
@@ -195,21 +137,6 @@
|
||||
<name>IIop</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@2.0::IIop/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.mwqemadapter</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.qti.hardware.perf</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>2.2</version>
|
||||
<interface>
|
||||
<name>IPerf</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@2.2::IPerf/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.qti.hardware.qseecom</name>
|
||||
@@ -219,43 +146,6 @@
|
||||
<name>IQSEECom</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.0::IQSEECom/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.radio.am</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.radio.ims</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.radio.internal.deviceinfo</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.radio.lpa</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.radio.qcrilhook</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.radio.qtiradio</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.radio.uim</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.radio.uim_remote_client</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.hardware.radio.uim_remote_server</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.qti.hardware.trustedui</name>
|
||||
@@ -273,20 +163,6 @@
|
||||
<name>IWifiStats</name>
|
||||
<instance>wifiStats</instance>
|
||||
</interface>
|
||||
<fqname>@1.0::IWifiStats/wifiStats</fqname>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.ims.callinfo</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.imsrtpservice</name>
|
||||
<transport>hwbinder</transport>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>vendor.qti.power.pasrmanager</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.samsung.hardware.bluetooth</name>
|
||||
@@ -296,7 +172,6 @@
|
||||
<name>ISehBluetooth</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@2.0::ISehBluetooth/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.samsung.hardware.bluetooth.a2dp</name>
|
||||
@@ -306,7 +181,6 @@
|
||||
<name>ISehBluetoothAudioOffload</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.0::ISehBluetoothAudioOffload/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.samsung.hardware.gnss</name>
|
||||
@@ -316,7 +190,6 @@
|
||||
<name>ISehGnss</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@2.0::ISehGnss/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.samsung.hardware.radio</name>
|
||||
@@ -327,8 +200,6 @@
|
||||
<instance>slot1</instance>
|
||||
<instance>slot2</instance>
|
||||
</interface>
|
||||
<fqname>@2.2::ISehRadio/slot1</fqname>
|
||||
<fqname>@2.2::ISehRadio/slot2</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.samsung.hardware.radio.bridge</name>
|
||||
@@ -339,8 +210,6 @@
|
||||
<instance>slot1</instance>
|
||||
<instance>slot2</instance>
|
||||
</interface>
|
||||
<fqname>@2.0::ISehBridge/slot1</fqname>
|
||||
<fqname>@2.0::ISehBridge/slot2</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.samsung.hardware.radio.channel</name>
|
||||
@@ -353,15 +222,10 @@
|
||||
<instance>imsd</instance>
|
||||
<instance>imsd2</instance>
|
||||
</interface>
|
||||
<fqname>@2.0::ISehChannel/epdgd</fqname>
|
||||
<fqname>@2.0::ISehChannel/epdgd2</fqname>
|
||||
<fqname>@2.0::ISehChannel/imsd</fqname>
|
||||
<fqname>@2.0::ISehChannel/imsd2</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<hal format="aidl">
|
||||
<name>vendor.lineage.livedisplay</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>2.0</version>
|
||||
<version>1</version>
|
||||
<interface>
|
||||
<name>IAdaptiveBacklight</name>
|
||||
<instance>default</instance>
|
||||
@@ -370,22 +234,26 @@
|
||||
<name>IDisplayColorCalibration</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<interface>
|
||||
<name>IDisplayModes</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<interface>
|
||||
<name>ISunlightEnhancement</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@2.0::IAdaptiveBacklight/default</fqname>
|
||||
<fqname>@2.0::IDisplayColorCalibration/default</fqname>
|
||||
<fqname>@2.0::ISunlightEnhancement/default</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<hal format="aidl">
|
||||
<name>vendor.lineage.touch</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
<version>1</version>
|
||||
<interface>
|
||||
<name>IGloveMode</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<interface>
|
||||
<name>IHighTouchPollingRate</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<interface>
|
||||
<name>ITouchscreenGesture</name>
|
||||
<instance>default</instance>
|
||||
@@ -290,4 +290,5 @@
|
||||
</MediaCodec>
|
||||
</Encoders>
|
||||
<Include href="media_codecs_google_c2.xml" />
|
||||
<Include href="media_codecs_dolby_audio.xml" />
|
||||
</MediaCodecs>
|
||||
|
||||
@@ -37,11 +37,11 @@ FW_FILE_NAME="sec_s3nrn4v_firmware.bin"
|
||||
## RF Register for S3NRN4V
|
||||
#RFREG_FILE="/vendor/etc/nfc/sec_s3nrn4v_hwreg.bin"
|
||||
|
||||
RF_DIR_PATH="/vendor/etc/nfc/"
|
||||
RF_FILE_NAME="sec_s3nrn4v_hwreg.bin"
|
||||
RF_HW_DIR_PATH="/vendor/etc/nfc/"
|
||||
RF_HW_FILE_NAME="sec_s3nrn4v_hwreg.bin"
|
||||
|
||||
SW_OPT_DIR_PATH="/vendor/etc/nfc/"
|
||||
SW_OPT_FILE_NAME="sec_s3nrn4v_swreg.bin"
|
||||
RF_SW_DIR_PATH="/vendor/etc/nfc/"
|
||||
RF_SW_FILE_NAME="sec_s3nrn4v_swreg.bin"
|
||||
## --------------- Part-III : Configuration for MW --------------------------------##
|
||||
####################################################################################
|
||||
# III-1) Driver path
|
||||
|
||||
35
evolution.dependencies
Normal file
35
evolution.dependencies
Normal file
@@ -0,0 +1,35 @@
|
||||
[
|
||||
{
|
||||
"repository": "kernel_samsung_sm7325",
|
||||
"target_path": "kernel/samsung/sm7325",
|
||||
"branch": "bka"
|
||||
},
|
||||
{
|
||||
"remote": "github-non-los",
|
||||
"repository": "LineageOS/android_hardware_samsung",
|
||||
"target_path": "hardware/samsung",
|
||||
"branch": "lineage-23.1"
|
||||
},
|
||||
{
|
||||
"remote": "github-non-los",
|
||||
"repository": "LineageOS/android_hardware_samsung_slsi_nfc",
|
||||
"target_path": "hardware/samsung_slsi/nfc",
|
||||
"branch": "lineage-23.1"
|
||||
},
|
||||
{
|
||||
"repository": "vendor_samsung_sm7325-common",
|
||||
"target_path": "vendor/samsung/sm7325-common",
|
||||
"branch": "bka"
|
||||
},
|
||||
{
|
||||
"remote": "github-non-los",
|
||||
"repository": "anhdat1024/android_hardware_dolby",
|
||||
"target_path": "hardware/dolby",
|
||||
"branch": "16.0"
|
||||
},
|
||||
{
|
||||
"repository": "hardware_samsung-extra_interfaces",
|
||||
"target_path": "hardware/samsung-ext/interfaces",
|
||||
"branch": "bka"
|
||||
}
|
||||
]
|
||||
242
init/Android.bp
242
init/Android.bp
@@ -1,29 +1,221 @@
|
||||
//
|
||||
// Copyright (C) 2023 The LineageOS 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.
|
||||
// Copyright (C) 2025 The LineageOS Project
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
//
|
||||
|
||||
cc_library_static {
|
||||
name: "libinit_samsung_sm7325",
|
||||
recovery_available: true,
|
||||
srcs: ["init_sm7325.cpp"],
|
||||
whole_static_libs: ["libbase"],
|
||||
include_dirs: [
|
||||
"system/libbase/include",
|
||||
"system/core/init"
|
||||
],
|
||||
shared_libs: [
|
||||
"libbase",
|
||||
],
|
||||
prebuilt_etc {
|
||||
name: "fstab.qcom",
|
||||
src: "fstab.qcom",
|
||||
soc_specific: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "fstab.ramplus",
|
||||
src: "fstab.ramplus",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.audio.samsung.rc",
|
||||
src: "init.audio.samsung.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.fingerprint.rc",
|
||||
src: "init.fingerprint.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.nfc.samsung.rc",
|
||||
src: "init.nfc.samsung.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.qcom.rc",
|
||||
src: "init.qcom.rc",
|
||||
sub_dir: "init/hw",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.qti.kernel.rc",
|
||||
src: "init.qti.kernel.rc",
|
||||
sub_dir: "init/hw",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.qti.media.rc",
|
||||
src: "init.qti.media.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.ramplus.rc",
|
||||
src: "init.ramplus.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.samsung.bsp.rc",
|
||||
src: "init.samsung.bsp.rc",
|
||||
sub_dir: "init/hw",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.samsung.display.rc",
|
||||
src: "init.samsung.display.rc",
|
||||
sub_dir: "init/hw",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.samsung.rc",
|
||||
src: "init.samsung.rc",
|
||||
sub_dir: "init/hw",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.target.rc",
|
||||
src: "init.target.rc",
|
||||
sub_dir: "init/hw",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.vendor.onebinary.rc",
|
||||
src: "init.vendor.onebinary.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "vendor.samsung.rilchip.qcom.rc",
|
||||
src: "vendor.samsung.rilchip.qcom.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.vendor.rilcommon.rc",
|
||||
src: "init.vendor.rilcommon.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.vendor.sensors.rc",
|
||||
src: "init.vendor.sensors.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "wifi_firmware.rc",
|
||||
src: "wifi_firmware.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "ueventd.qcom.rc",
|
||||
src: "ueventd.qcom.rc",
|
||||
filename: "ueventd.rc",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "wifi_qcom_wcn6750.rc",
|
||||
src: "wifi_qcom_wcn6750.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "wifi_sec.rc",
|
||||
src: "wifi_sec.rc",
|
||||
sub_dir: "init",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "init.class_main.sh",
|
||||
src: "init.class_main.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "init.kernel.post_boot.sh",
|
||||
src: "init.kernel.post_boot.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "init.kernel.post_boot-yupik.sh",
|
||||
src: "init.kernel.post_boot-yupik.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "init.qcom.class_core.sh",
|
||||
src: "init.qcom.class_core.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "init.qcom.early_boot.sh",
|
||||
src: "init.qcom.early_boot.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "init.qcom.post_boot.sh",
|
||||
src: "init.qcom.post_boot.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "init.qcom.sh",
|
||||
src: "init.qcom.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "init.qti.chg_policy.sh",
|
||||
src: "init.qti.chg_policy.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "init.qti.kernel.sh",
|
||||
src: "init.qti.kernel.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "init.qti.media.sh",
|
||||
src: "init.qti.media.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "init.qti.qcv.sh",
|
||||
src: "init.qti.qcv.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "vendor_modprobe.sh",
|
||||
src: "vendor_modprobe.sh",
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@ odm /odm ext4 ro wait,logical,first_stage_mount
|
||||
/dev/block/by-name/metadata /metadata ext4 noatime,nosuid,nodev,noauto_da_alloc,discard,journal_checksum,data=ordered,errors=panic,sync wait,formattable,first_stage_mount,check
|
||||
/dev/block/bootdevice/by-name/cache /cache ext4 noatime,nosuid,nodev,noauto_da_alloc,discard,journal_checksum,data=ordered,errors=panic wait,check
|
||||
/dev/block/bootdevice/by-name/persist /mnt/vendor/persist ext4 noatime,nosuid,nodev,noauto_da_alloc,discard,journal_checksum,data=ordered,errors=panic wait,check
|
||||
/dev/block/bootdevice/by-name/userdata /data f2fs noatime,nosuid,nodev,discard,usrquota,grpquota,fsync_mode=nobarrier,reserve_root=32768,resgid=5678,inlinecrypt latemount,wait,check,fileencryption=aes-256-xts:aes-256-cts:v2+inlinecrypt_optimized,quota,reservedsize=128M,sysfs_path=/sys/devices/platform/soc/1d84000.ufshc,checkpoint=fs
|
||||
/dev/block/bootdevice/by-name/userdata /data f2fs noatime,nosuid,nodev,discard,usrquota,grpquota,fsync_mode=nobarrier,reserve_root=32768,resgid=5678,inlinecrypt latemount,wait,check,formattable,fileencryption=aes-256-xts:aes-256-cts:v2+inlinecrypt_optimized,quota,reservedsize=128M,sysfs_path=/sys/devices/platform/soc/1d84000.ufshc,checkpoint=fs,keydirectory=/metadata/vold/metadata_encryption
|
||||
/dev/block/bootdevice/by-name/apnhlos /vendor/firmware_mnt vfat ro,shortname=lower,uid=0,gid=1000,dmask=227,fmask=337,context=u:object_r:firmware_file:s0 wait
|
||||
/dev/block/bootdevice/by-name/modem /vendor/firmware-modem vfat ro,shortname=lower,uid=0,gid=1000,dmask=227,fmask=337,context=u:object_r:firmware_file:s0 wait
|
||||
/dev/block/bootdevice/by-name/efs /mnt/vendor/efs ext4 noatime,nosuid,nodev,noauto_da_alloc,discard,journal_checksum,data=ordered,errors=panic wait,check
|
||||
@@ -1,7 +1,3 @@
|
||||
on early-init
|
||||
chmod 0660 /dev/goodix_fp
|
||||
chown system system /dev/goodix_fp
|
||||
|
||||
on init
|
||||
write /sys/class/sec/tsp/cmd "fod_enable,1,1,0"
|
||||
write /sys/class/sec/tsp/cmd "set_fod_rect,421,2018,659,2256"
|
||||
@@ -11,6 +7,9 @@ on boot
|
||||
chmod 0660 /dev/esfp0
|
||||
chown system system /dev/esfp0
|
||||
|
||||
chmod 0660 /dev/goodix_fp
|
||||
chown system system /dev/goodix_fp
|
||||
|
||||
chmod 0660 /dev/qbt2000_fd
|
||||
chmod 0660 /dev/qbt2000_ipc
|
||||
chmod 0660 /dev/qbtspi
|
||||
@@ -66,6 +66,9 @@ on early-init
|
||||
|
||||
on init
|
||||
|
||||
# AFC permissions for fast charge
|
||||
chown system radio /sys/class/sec/switch/afc_disable
|
||||
|
||||
# Support legacy paths
|
||||
symlink /sdcard /mnt/sdcard
|
||||
symlink /sdcard /storage/sdcard0
|
||||
@@ -570,6 +573,11 @@ on property:vold.decrypt=trigger_restart_framework
|
||||
start qcom-c_main-sh
|
||||
start wcnss-service
|
||||
|
||||
on post-fs-data
|
||||
# Charge Bypass
|
||||
chown system system /sys/class/power_supply/battery
|
||||
chmod 0660 /sys/class/power_supply/battery
|
||||
|
||||
service vendor.qrtr-ns /vendor/bin/qrtr-ns -f
|
||||
class core
|
||||
user vendor_qrtr
|
||||
@@ -908,8 +916,10 @@ service vendor.audio-hal /vendor/bin/hw/android.hardware.audio.service
|
||||
class hal
|
||||
user audioserver
|
||||
# media gid needed for /dev/fm (radio) and for /data/misc/media (tee)
|
||||
group audio camera drmrpc inet media mediadrm net_bt net_bt_admin net_bw_acct oem_2901 wakelock
|
||||
capabilities BLOCK_SUSPEND
|
||||
group audio camera drmrpc inet media mediadrm net_bt net_bt_admin net_bw_acct oem_2901 wakelock context_hub
|
||||
capabilities BLOCK_SUSPEND SYS_NICE
|
||||
# setting RLIMIT_RTPRIO allows binder RT priority inheritance
|
||||
rlimit rtprio 10 10
|
||||
ioprio rt 4
|
||||
writepid /dev/cpuset/foreground/tasks /dev/stune/foreground/tasks
|
||||
onrestart restart audioserver
|
||||
@@ -111,6 +111,10 @@ on post-fs-data
|
||||
on early-boot
|
||||
start vendor.sensors
|
||||
|
||||
# Dolby
|
||||
mkdir /data/vendor/dolby 0770 media media
|
||||
mkdir /data/vendor/multimedia 0775 system system
|
||||
|
||||
on boot
|
||||
setprop vendor.powerhal.init 1
|
||||
|
||||
@@ -79,6 +79,18 @@ on fs && property:ro.boot.rp=6 && property:ro.boot.em.model=SM-A528N
|
||||
mount none /vendor/firmware/wlan/a528n/rev6/wpss.b07 /vendor/firmware/wpss.b07 bind
|
||||
mount none /vendor/firmware/wlan/a528n/rev6/wpss.mdt /vendor/firmware/wpss.mdt bind
|
||||
|
||||
# bootloader revision 7, A528N (asia)
|
||||
on fs && property:ro.boot.rp=7 && property:ro.boot.em.model=SM-A528N
|
||||
mount none /vendor/firmware/wlan/a528n/rev7/wpss.b00 /vendor/firmware/wpss.b00 bind
|
||||
mount none /vendor/firmware/wlan/a528n/rev7/wpss.b01 /vendor/firmware/wpss.b01 bind
|
||||
mount none /vendor/firmware/wlan/a528n/rev7/wpss.b02 /vendor/firmware/wpss.b02 bind
|
||||
mount none /vendor/firmware/wlan/a528n/rev7/wpss.b03 /vendor/firmware/wpss.b03 bind
|
||||
mount none /vendor/firmware/wlan/a528n/rev7/wpss.b04 /vendor/firmware/wpss.b04 bind
|
||||
mount none /vendor/firmware/wlan/a528n/rev7/wpss.b05 /vendor/firmware/wpss.b05 bind
|
||||
mount none /vendor/firmware/wlan/a528n/rev7/wpss.b06 /vendor/firmware/wpss.b06 bind
|
||||
mount none /vendor/firmware/wlan/a528n/rev7/wpss.b07 /vendor/firmware/wpss.b07 bind
|
||||
mount none /vendor/firmware/wlan/a528n/rev7/wpss.mdt /vendor/firmware/wpss.mdt bind
|
||||
|
||||
# bootloader revision 3, A528B (international)
|
||||
on fs && property:ro.boot.rp=3 && property:ro.boot.em.model=SM-A528B
|
||||
mount none /vendor/firmware/wlan/a528b/rev3/wpss.b01 /vendor/firmware/wpss.b01 bind
|
||||
@@ -317,6 +329,30 @@ on fs && property:ro.boot.rp=6 && property:ro.boot.em.model=SM-M526B
|
||||
mount none /vendor/firmware/wlan/m526b/rev6/wpss.b07 /vendor/firmware/wpss.b07 bind
|
||||
mount none /vendor/firmware/wlan/m526b/rev6/wpss.mdt /vendor/firmware/wpss.mdt bind
|
||||
|
||||
# bootloader revision 7, M526BR (international)
|
||||
on fs && property:ro.boot.rp=7 && property:ro.boot.em.model=SM-M526BR
|
||||
mount none /vendor/firmware/wlan/m526br/rev7/wpss.b00 /vendor/firmware/wpss.b00 bind
|
||||
mount none /vendor/firmware/wlan/m526br/rev7/wpss.b01 /vendor/firmware/wpss.b01 bind
|
||||
mount none /vendor/firmware/wlan/m526br/rev7/wpss.b02 /vendor/firmware/wpss.b02 bind
|
||||
mount none /vendor/firmware/wlan/m526br/rev7/wpss.b03 /vendor/firmware/wpss.b03 bind
|
||||
mount none /vendor/firmware/wlan/m526br/rev7/wpss.b04 /vendor/firmware/wpss.b04 bind
|
||||
mount none /vendor/firmware/wlan/m526br/rev7/wpss.b05 /vendor/firmware/wpss.b05 bind
|
||||
mount none /vendor/firmware/wlan/m526br/rev7/wpss.b06 /vendor/firmware/wpss.b06 bind
|
||||
mount none /vendor/firmware/wlan/m526br/rev7/wpss.b07 /vendor/firmware/wpss.b07 bind
|
||||
mount none /vendor/firmware/wlan/m526br/rev7/wpss.mdt /vendor/firmware/wpss.mdt bind
|
||||
|
||||
# bootloader revision 7, M526B (america)
|
||||
on fs && property:ro.boot.rp=7 && property:ro.boot.em.model=SM-M526B
|
||||
mount none /vendor/firmware/wlan/m526b/rev7/wpss.b00 /vendor/firmware/wpss.b00 bind
|
||||
mount none /vendor/firmware/wlan/m526b/rev7/wpss.b01 /vendor/firmware/wpss.b01 bind
|
||||
mount none /vendor/firmware/wlan/m526b/rev7/wpss.b02 /vendor/firmware/wpss.b02 bind
|
||||
mount none /vendor/firmware/wlan/m526b/rev7/wpss.b03 /vendor/firmware/wpss.b03 bind
|
||||
mount none /vendor/firmware/wlan/m526b/rev7/wpss.b04 /vendor/firmware/wpss.b04 bind
|
||||
mount none /vendor/firmware/wlan/m526b/rev7/wpss.b05 /vendor/firmware/wpss.b05 bind
|
||||
mount none /vendor/firmware/wlan/m526b/rev7/wpss.b06 /vendor/firmware/wpss.b06 bind
|
||||
mount none /vendor/firmware/wlan/m526b/rev7/wpss.b07 /vendor/firmware/wpss.b07 bind
|
||||
mount none /vendor/firmware/wlan/m526b/rev7/wpss.mdt /vendor/firmware/wpss.mdt bind
|
||||
|
||||
# bootloader revision 3, A736B
|
||||
on fs && property:ro.boot.rp=3 && property:ro.boot.em.model=SM-A736B
|
||||
mount none /vendor/firmware/wlan/rev3/wpss.b01 /vendor/firmware/wpss.b01 bind
|
||||
29
libinit/Android.bp
Normal file
29
libinit/Android.bp
Normal file
@@ -0,0 +1,29 @@
|
||||
//
|
||||
// Copyright (C) 2023 The LineageOS 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_library_static {
|
||||
name: "libinit_samsung_sm7325",
|
||||
recovery_available: true,
|
||||
srcs: ["init_sm7325.cpp"],
|
||||
whole_static_libs: ["libbase"],
|
||||
include_dirs: [
|
||||
"system/libbase/include",
|
||||
"system/core/init"
|
||||
],
|
||||
shared_libs: [
|
||||
"libbase",
|
||||
],
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
[
|
||||
{
|
||||
"repository": "android_kernel_samsung_sm7325",
|
||||
"target_path": "kernel/samsung/sm7325"
|
||||
},
|
||||
{
|
||||
"repository": "android_hardware_samsung",
|
||||
"target_path": "hardware/samsung"
|
||||
}
|
||||
]
|
||||
@@ -1,61 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2023 The LineageOS 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.
|
||||
*/
|
||||
|
||||
#include <android-base/file.h>
|
||||
#include <android-base/strings.h>
|
||||
|
||||
#include <fstream>
|
||||
|
||||
#include "AdaptiveBacklight.h"
|
||||
|
||||
using android::base::ReadFileToString;
|
||||
using android::base::Trim;
|
||||
using android::base::WriteStringToFile;
|
||||
|
||||
namespace vendor {
|
||||
namespace lineage {
|
||||
namespace livedisplay {
|
||||
namespace V2_0 {
|
||||
namespace samsung {
|
||||
|
||||
static constexpr const char* kBacklightPath = "/sys/class/lcd/panel/alpm";
|
||||
|
||||
bool AdaptiveBacklight::isSupported() {
|
||||
std::fstream backlight(kBacklightPath, backlight.in | backlight.out);
|
||||
return backlight.good();
|
||||
}
|
||||
|
||||
// Methods from ::vendor::lineage::livedisplay::V2_0::IAdaptiveBacklight follow.
|
||||
Return<bool> AdaptiveBacklight::isEnabled() {
|
||||
std::string tmp;
|
||||
int32_t contents = 0;
|
||||
|
||||
if (ReadFileToString(kBacklightPath, &tmp)) {
|
||||
contents = std::stoi(Trim(tmp));
|
||||
}
|
||||
|
||||
return contents > 0;
|
||||
}
|
||||
|
||||
Return<bool> AdaptiveBacklight::setEnabled(bool enabled) {
|
||||
return WriteStringToFile(enabled ? "2" : "0", kBacklightPath, true);
|
||||
}
|
||||
|
||||
} // namespace samsung
|
||||
} // namespace V2_0
|
||||
} // namespace livedisplay
|
||||
} // namespace lineage
|
||||
} // namespace vendor
|
||||
@@ -1,55 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2023 The LineageOS 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 VENDOR_LINEAGE_LIVEDISPLAY_V2_0_ADAPTIVEBACKLIGHT_H
|
||||
#define VENDOR_LINEAGE_LIVEDISPLAY_V2_0_ADAPTIVEBACKLIGHT_H
|
||||
|
||||
#include <hidl/MQDescriptor.h>
|
||||
#include <hidl/Status.h>
|
||||
#include <vendor/lineage/livedisplay/2.0/IAdaptiveBacklight.h>
|
||||
|
||||
namespace vendor {
|
||||
namespace lineage {
|
||||
namespace livedisplay {
|
||||
namespace V2_0 {
|
||||
namespace samsung {
|
||||
|
||||
using ::android::hardware::hidl_array;
|
||||
using ::android::hardware::hidl_memory;
|
||||
using ::android::hardware::hidl_string;
|
||||
using ::android::hardware::hidl_vec;
|
||||
using ::android::hardware::Return;
|
||||
using ::android::hardware::Void;
|
||||
using ::android::sp;
|
||||
|
||||
class AdaptiveBacklight : public IAdaptiveBacklight {
|
||||
public:
|
||||
bool isSupported();
|
||||
|
||||
// Methods from ::vendor::lineage::livedisplay::V2_0::IAdaptiveBacklight follow.
|
||||
Return<bool> isEnabled() override;
|
||||
Return<bool> setEnabled(bool enabled) override;
|
||||
|
||||
// Methods from ::android::hidl::base::V1_0::IBase follow.
|
||||
};
|
||||
|
||||
} // namespace samsung
|
||||
} // namespace V2_0
|
||||
} // namespace livedisplay
|
||||
} // namespace lineage
|
||||
} // namespace vendor
|
||||
|
||||
#endif // VENDOR_LINEAGE_LIVEDISPLAY_V2_0_ADAPTIVEBACKLIGHT_H
|
||||
@@ -1,34 +0,0 @@
|
||||
// Copyright (C) 2019-2023 The LineageOS 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: "vendor.lineage.livedisplay@2.0-service.samsung-qcom.sm7325",
|
||||
defaults: ["hidl_defaults"],
|
||||
init_rc: ["vendor.lineage.livedisplay@2.0-service.samsung-qcom.sm7325.rc"],
|
||||
relative_install_path: "hw",
|
||||
srcs: [
|
||||
"AdaptiveBacklight.cpp",
|
||||
"SunlightEnhancement.cpp",
|
||||
"DisplayColorCalibration.cpp",
|
||||
"service.cpp",
|
||||
],
|
||||
shared_libs: [
|
||||
"libbase",
|
||||
"libbinder",
|
||||
"libhidlbase",
|
||||
"libutils",
|
||||
"vendor.lineage.livedisplay@2.0",
|
||||
],
|
||||
vendor: true,
|
||||
}
|
||||
@@ -1,77 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2023 The LineageOS 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.
|
||||
*/
|
||||
|
||||
#include <android-base/file.h>
|
||||
#include <android-base/strings.h>
|
||||
|
||||
#include <fstream>
|
||||
|
||||
#include "DisplayColorCalibration.h"
|
||||
|
||||
using android::base::ReadFileToString;
|
||||
using android::base::Split;
|
||||
using android::base::Trim;
|
||||
using android::base::WriteStringToFile;
|
||||
|
||||
namespace vendor {
|
||||
namespace lineage {
|
||||
namespace livedisplay {
|
||||
namespace V2_0 {
|
||||
namespace samsung {
|
||||
|
||||
static constexpr const char* kColorPath = "/sys/class/mdnie/mdnie/sensorRGB";
|
||||
|
||||
bool DisplayColorCalibration::isSupported() {
|
||||
std::fstream rgb(kColorPath, rgb.in | rgb.out);
|
||||
return rgb.good();
|
||||
}
|
||||
|
||||
Return<int32_t> DisplayColorCalibration::getMaxValue() {
|
||||
return 255;
|
||||
}
|
||||
|
||||
Return<int32_t> DisplayColorCalibration::getMinValue() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
Return<void> DisplayColorCalibration::getCalibration(getCalibration_cb resultCb) {
|
||||
std::vector<int32_t> rgb;
|
||||
std::string tmp;
|
||||
|
||||
if (ReadFileToString(kColorPath, &tmp)) {
|
||||
std::vector<std::string> colors = Split(Trim(tmp), " ");
|
||||
for (const std::string& color : colors) {
|
||||
rgb.push_back(std::stoi(color));
|
||||
}
|
||||
}
|
||||
|
||||
resultCb(rgb);
|
||||
return Void();
|
||||
}
|
||||
|
||||
Return<bool> DisplayColorCalibration::setCalibration(const hidl_vec<int32_t>& rgb) {
|
||||
std::string contents;
|
||||
for (const int32_t& color : rgb) {
|
||||
contents += std::to_string(color) + " ";
|
||||
}
|
||||
return WriteStringToFile(Trim(contents), kColorPath, true);
|
||||
}
|
||||
|
||||
} // namespace samsung
|
||||
} // namespace V2_0
|
||||
} // namespace livedisplay
|
||||
} // namespace lineage
|
||||
} // namespace vendor
|
||||
@@ -1,54 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2023 The LineageOS 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.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <hidl/MQDescriptor.h>
|
||||
#include <hidl/Status.h>
|
||||
#include <vendor/lineage/livedisplay/2.0/IDisplayColorCalibration.h>
|
||||
|
||||
namespace vendor {
|
||||
namespace lineage {
|
||||
namespace livedisplay {
|
||||
namespace V2_0 {
|
||||
namespace samsung {
|
||||
|
||||
using ::android::hardware::hidl_array;
|
||||
using ::android::hardware::hidl_memory;
|
||||
using ::android::hardware::hidl_string;
|
||||
using ::android::hardware::hidl_vec;
|
||||
using ::android::hardware::Return;
|
||||
using ::android::hardware::Void;
|
||||
using ::android::sp;
|
||||
|
||||
class DisplayColorCalibration : public IDisplayColorCalibration {
|
||||
public:
|
||||
bool isSupported();
|
||||
|
||||
// Methods from ::vendor::lineage::livedisplay::V2_0::IDisplayColorCalibration follow.
|
||||
Return<int32_t> getMaxValue() override;
|
||||
Return<int32_t> getMinValue() override;
|
||||
Return<void> getCalibration(getCalibration_cb resultCb) override;
|
||||
Return<bool> setCalibration(const hidl_vec<int32_t>& rgb) override;
|
||||
|
||||
// Methods from ::android::hidl::base::V1_0::IBase follow.
|
||||
};
|
||||
|
||||
} // namespace samsung
|
||||
} // namespace V2_0
|
||||
} // namespace livedisplay
|
||||
} // namespace lineage
|
||||
} // namespace vendor
|
||||
@@ -1,62 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2023 The LineageOS 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.
|
||||
*/
|
||||
|
||||
#include <android-base/file.h>
|
||||
#include <android-base/strings.h>
|
||||
|
||||
#include <fstream>
|
||||
|
||||
#include "SunlightEnhancement.h"
|
||||
|
||||
using android::base::ReadFileToString;
|
||||
using android::base::Trim;
|
||||
using android::base::WriteStringToFile;
|
||||
|
||||
namespace vendor {
|
||||
namespace lineage {
|
||||
namespace livedisplay {
|
||||
namespace V2_0 {
|
||||
namespace samsung {
|
||||
|
||||
static constexpr const char* kSREPath = "/sys/class/mdnie/mdnie/outdoor";
|
||||
|
||||
// Methods from ::vendor::lineage::livedisplay::V2_0::ISunlightEnhancement follow.
|
||||
bool SunlightEnhancement::isSupported() {
|
||||
std::fstream sre(kSREPath, sre.in | sre.out);
|
||||
|
||||
return sre.good();
|
||||
}
|
||||
|
||||
// Methods from ::vendor::lineage::livedisplay::V2_0::IAdaptiveBacklight follow.
|
||||
Return<bool> SunlightEnhancement::isEnabled() {
|
||||
std::string tmp;
|
||||
int32_t statusSRE = 0;
|
||||
if (ReadFileToString(kSREPath, &tmp)) {
|
||||
statusSRE = std::stoi(Trim(tmp));
|
||||
}
|
||||
|
||||
return statusSRE == 1;
|
||||
}
|
||||
|
||||
Return<bool> SunlightEnhancement::setEnabled(bool enabled) {
|
||||
return WriteStringToFile(enabled ? "1" : "0", kSREPath, true);
|
||||
}
|
||||
|
||||
} // namespace samsung
|
||||
} // namespace V2_0
|
||||
} // namespace livedisplay
|
||||
} // namespace lineage
|
||||
} // namespace vendor
|
||||
@@ -1,50 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2023 The LineageOS 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.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <hidl/MQDescriptor.h>
|
||||
#include <hidl/Status.h>
|
||||
#include <vendor/lineage/livedisplay/2.0/ISunlightEnhancement.h>
|
||||
|
||||
namespace vendor {
|
||||
namespace lineage {
|
||||
namespace livedisplay {
|
||||
namespace V2_0 {
|
||||
namespace samsung {
|
||||
|
||||
using ::android::hardware::hidl_array;
|
||||
using ::android::hardware::hidl_memory;
|
||||
using ::android::hardware::hidl_string;
|
||||
using ::android::hardware::hidl_vec;
|
||||
using ::android::hardware::Return;
|
||||
using ::android::hardware::Void;
|
||||
using ::android::sp;
|
||||
|
||||
class SunlightEnhancement : public ISunlightEnhancement {
|
||||
public:
|
||||
bool isSupported();
|
||||
|
||||
// Methods from ::vendor::lineage::livedisplay::V2_0::ISunlightEnhancement follow.
|
||||
Return<bool> isEnabled() override;
|
||||
Return<bool> setEnabled(bool enabled) override;
|
||||
};
|
||||
|
||||
} // namespace samsung
|
||||
} // namespace V2_0
|
||||
} // namespace livedisplay
|
||||
} // namespace lineage
|
||||
} // namespace vendor
|
||||
@@ -1,109 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2023 The LineageOS 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.
|
||||
*/
|
||||
|
||||
#ifdef LIVES_IN_SYSTEM
|
||||
#define LOG_TAG "lineage.livedisplay@2.0-service.samsung-qcom.sm7325"
|
||||
#else
|
||||
#define LOG_TAG "vendor.lineage.livedisplay@2.0-service.samsung-qcom.sm7325"
|
||||
#endif
|
||||
|
||||
#include <android-base/logging.h>
|
||||
#include <binder/ProcessState.h>
|
||||
#include <hidl/HidlTransportSupport.h>
|
||||
|
||||
#include "AdaptiveBacklight.h"
|
||||
#include "SunlightEnhancement.h"
|
||||
#include "DisplayColorCalibration.h"
|
||||
|
||||
using android::hardware::configureRpcThreadpool;
|
||||
using android::hardware::joinRpcThreadpool;
|
||||
using android::sp;
|
||||
using android::status_t;
|
||||
using android::OK;
|
||||
|
||||
using vendor::lineage::livedisplay::V2_0::samsung::AdaptiveBacklight;
|
||||
using vendor::lineage::livedisplay::V2_0::samsung::SunlightEnhancement;
|
||||
using vendor::lineage::livedisplay::V2_0::samsung::DisplayColorCalibration;
|
||||
|
||||
int main() {
|
||||
sp<AdaptiveBacklight> adaptiveBacklight;
|
||||
sp<SunlightEnhancement> sunlightEnhancement;
|
||||
sp<DisplayColorCalibration> displayColorCalibration;
|
||||
status_t status;
|
||||
|
||||
LOG(INFO) << "LiveDisplay HAL service is starting.";
|
||||
|
||||
adaptiveBacklight = new AdaptiveBacklight();
|
||||
if (adaptiveBacklight == nullptr) {
|
||||
LOG(ERROR)
|
||||
<< "Can not create an instance of LiveDisplay HAL AdaptiveBacklight Iface, exiting.";
|
||||
goto shutdown;
|
||||
}
|
||||
|
||||
sunlightEnhancement = new SunlightEnhancement();
|
||||
if (sunlightEnhancement == nullptr) {
|
||||
LOG(ERROR)
|
||||
<< "Can not create an instance of LiveDisplay HAL SunlightEnhancement Iface, exiting.";
|
||||
goto shutdown;
|
||||
}
|
||||
|
||||
displayColorCalibration = new DisplayColorCalibration();
|
||||
if (displayColorCalibration == nullptr) {
|
||||
LOG(ERROR) << "Can not create an instance of LiveDisplay HAL DisplayColorCalibration "
|
||||
"Iface, exiting.";
|
||||
goto shutdown;
|
||||
}
|
||||
|
||||
configureRpcThreadpool(1, true /*callerWillJoin*/);
|
||||
|
||||
if (adaptiveBacklight->isSupported()) {
|
||||
status = adaptiveBacklight->registerAsService();
|
||||
if (status != OK) {
|
||||
LOG(ERROR) << "Could not register service for LiveDisplay HAL AdaptiveBacklight Iface ("
|
||||
<< status << ")";
|
||||
goto shutdown;
|
||||
}
|
||||
}
|
||||
|
||||
if (sunlightEnhancement->isSupported()) {
|
||||
status = sunlightEnhancement->registerAsService();
|
||||
if (status != OK) {
|
||||
LOG(ERROR)
|
||||
<< "Could not register service for LiveDisplay HAL SunlightEnhancement Iface ("
|
||||
<< status << ")";
|
||||
goto shutdown;
|
||||
}
|
||||
}
|
||||
|
||||
if (displayColorCalibration->isSupported()) {
|
||||
status = displayColorCalibration->registerAsService();
|
||||
if (status != OK) {
|
||||
LOG(ERROR)
|
||||
<< "Could not register service for LiveDisplay HAL DisplayColorCalibration Iface ("
|
||||
<< status << ")";
|
||||
goto shutdown;
|
||||
}
|
||||
}
|
||||
|
||||
LOG(INFO) << "LiveDisplay HAL service is ready.";
|
||||
joinRpcThreadpool();
|
||||
// Should not pass this line
|
||||
|
||||
shutdown:
|
||||
// In normal operation, we don't expect the thread pool to shutdown
|
||||
LOG(ERROR) << "LiveDisplay HAL service is shutting down.";
|
||||
return 1;
|
||||
}
|
||||
@@ -1,7 +0,0 @@
|
||||
on post-fs-data
|
||||
mkdir /data/vendor/display 0770 system system
|
||||
|
||||
service vendor.livedisplay-hal-2-0-samsung-qcom.sm7325 /vendor/bin/hw/vendor.lineage.livedisplay@2.0-service.samsung-qcom.sm7325
|
||||
class late_start
|
||||
user system
|
||||
group system
|
||||
@@ -119,10 +119,8 @@
|
||||
|
||||
<!-- List supported color modes. -->
|
||||
<integer-array name="config_availableColorModes">
|
||||
<item>0</item> <!-- COLOR_MODE_NATURAL -->
|
||||
<item>1</item> <!-- COLOR_MODE_BOOSTED -->
|
||||
<item>2</item> <!-- COLOR_MODE_SATURATED -->
|
||||
<item>3</item> <!-- COLOR_MODE_AUTOMATIC -->
|
||||
<item>0</item> <!-- COLOR_MODE_NATURAL -->
|
||||
<item>256</item> <!-- COLOR_MODE_VENDOR -->
|
||||
</integer-array>
|
||||
|
||||
<!-- Screen brightness used to dim the screen while dozing in a very low power state.
|
||||
@@ -1347,4 +1345,11 @@
|
||||
|
||||
<!-- Whether the new Auto Selection Network UI should be shown -->
|
||||
<bool name="config_enableNewAutoSelectNetworkUI">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>
|
||||
</resources>
|
||||
|
||||
47
overlay/frameworks/base/core/res/res/values/dimens.xml
Normal file
47
overlay/frameworks/base/core/res/res/values/dimens.xml
Normal file
@@ -0,0 +1,47 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
/*
|
||||
** Copyright 2023, 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>
|
||||
|
||||
<!-- The default height of the status bar used in {@link SystemBarUtils#getStatusBarHeight} to
|
||||
calculate the status bar height. -->
|
||||
<dimen name="status_bar_height_default">100px</dimen>
|
||||
|
||||
<!-- Height of the status bar.
|
||||
Do not read this dimen directly. Use {@link SystemBarUtils#getStatusBarHeight} instead.
|
||||
-->
|
||||
<dimen name="status_bar_height">100px</dimen>
|
||||
|
||||
<!-- Height of the status bar in portrait.
|
||||
Do not read this dimen directly. Use {@link SystemBarUtils#getStatusBarHeight} instead.
|
||||
-->
|
||||
<dimen name="status_bar_height_portrait">100px</dimen>
|
||||
|
||||
<!-- Height of the status bar in landscape.
|
||||
Do not read this dimen directly. Use {@link SystemBarUtils#getStatusBarHeight} instead.
|
||||
-->
|
||||
<dimen name="status_bar_height_landscape">100px</dimen>
|
||||
|
||||
<!-- Default radius of the software rounded corners. -->
|
||||
<dimen name="rounded_corner_radius">70px</dimen>
|
||||
|
||||
<!-- Default paddings for content around the corners. -->
|
||||
<dimen name="rounded_corner_content_padding">50px</dimen>
|
||||
|
||||
</resources>
|
||||
@@ -24,5 +24,11 @@
|
||||
<bool name="doze_display_state_supported">true</bool>
|
||||
|
||||
<!-- the padding on the top of the statusbar (usually 0) -->
|
||||
<dimen name="status_bar_padding_top">6dp</dimen>
|
||||
<dimen name="status_bar_padding_top">7dp</dimen>
|
||||
|
||||
<!-- If not zero, limits the internal screen recorder's framerate to the set value. -->
|
||||
<integer name="config_screenRecorderMaxFramerate">60</integer>
|
||||
|
||||
<!-- Preferred max refresh rate at AOD & Ambient Display, if supported by the display. -->
|
||||
<integer name="config_aodMaxRefreshRate">60</integer>
|
||||
</resources>
|
||||
|
||||
@@ -21,5 +21,16 @@
|
||||
default that should be overridden by device-specific overlays. -->
|
||||
<dimen name="physical_power_button_center_screen_location_y">980px</dimen>
|
||||
|
||||
<dimen name="rounded_corner_content_padding">8dp</dimen>
|
||||
<!-- the padding on the start of the statusbar -->
|
||||
<dimen name="status_bar_padding_start">-1dp</dimen>
|
||||
|
||||
<!-- the padding on the end of the statusbar -->
|
||||
<dimen name="status_bar_padding_end">0dp</dimen>
|
||||
|
||||
<!-- QS padding controllers-->
|
||||
<dimen name="qs_panel_padding_top">100dp</dimen>
|
||||
|
||||
<!-- Margin on the left side of the carrier text on Keyguard -->
|
||||
<dimen name="keyguard_carrier_text_margin">12dp</dimen>
|
||||
|
||||
</resources>
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
<!-- Defines the actions shown in advanced reboot submenu -->
|
||||
<string-array name="config_restartActionsList">
|
||||
<item>restart</item>
|
||||
<item>restart_systemui</item>
|
||||
<item>restart_recovery</item>
|
||||
<item>restart_download</item>
|
||||
</string-array>
|
||||
|
||||
@@ -37,4 +37,20 @@
|
||||
|
||||
<!-- Max network scan search time in seconds -->
|
||||
<integer name="config_network_scan_helper_max_search_time_sec">254</integer>
|
||||
|
||||
<!-- Display settings screen, Color mode options. Must be the same length and order as
|
||||
config_color_mode_options_values below. Only the values that also appear in
|
||||
frameworks/base/core/res/res/values/config.xml's config_availableColorModes are shown. -->
|
||||
<string-array name="config_color_mode_options_strings" translatable="false">
|
||||
<item>Natural</item>
|
||||
<item>Vivid</item>
|
||||
</string-array>
|
||||
|
||||
<!-- Display settings screen, Color mode options. Must be the same length and order as
|
||||
config_color_mode_options_strings above. Only the values that also appear in
|
||||
frameworks/base/core/res/res/values/config.xml's config_availableColorModes are shown. -->
|
||||
<integer-array name="config_color_mode_options_values" translatable="false">
|
||||
<item>0</item>
|
||||
<item>256</item>
|
||||
</integer-array>
|
||||
</resources>
|
||||
|
||||
@@ -58,20 +58,20 @@ vendor/lib/lib_soundaliveresampler.so
|
||||
vendor/lib/lib_SoundAlive_SRC384_ver320.so
|
||||
vendor/lib/librecordalive.so
|
||||
vendor/lib/lib_SamsungRec_07010.so
|
||||
vendor/lib/libexthwplugin.so;MODULE_SUFFIX=_vendor
|
||||
vendor/lib/libsndmonitor.so;MODULE_SUFFIX=_vendor
|
||||
vendor/lib/libbatterylistener.so;MODULE_SUFFIX=_vendor
|
||||
vendor/lib/liba2dpoffload.so;MODULE_SUFFIX=_vendor
|
||||
vendor/lib/libexthwplugin.so
|
||||
vendor/lib/libsndmonitor.so
|
||||
vendor/lib/libbatterylistener.so
|
||||
vendor/lib/liba2dpoffload.so
|
||||
vendor/lib/libadm.so
|
||||
vendor/lib/libcomprcapture.so;MODULE_SUFFIX=_vendor
|
||||
vendor/lib/libhdmiedid.so;MODULE_SUFFIX=_vendor
|
||||
vendor/lib/libhdmipassthru.so;MODULE_SUFFIX=_vendor
|
||||
vendor/lib/libhfp.so;MODULE_SUFFIX=_vendor
|
||||
vendor/lib/libcomprcapture.so
|
||||
vendor/lib/libhdmiedid.so
|
||||
vendor/lib/libhdmipassthru.so
|
||||
vendor/lib/libhfp.so
|
||||
vendor/lib/libqtigef.so
|
||||
vendor/lib/libcirrusspkrprot.so;MODULE_SUFFIX=_vendor
|
||||
vendor/lib/libcirrusspkrprot.so
|
||||
vendor/lib/libsurround_3mic_proc.so
|
||||
vendor/lib/libdrc.so
|
||||
vendor/lib/libspkrprot.so;MODULE_SUFFIX=_vendor
|
||||
vendor/lib/libspkrprot.so
|
||||
vendor/lib/libprofileparamstorage.so
|
||||
vendor/lib/libspatializerparamstorage.so
|
||||
vendor/lib/spatializer-aidl-V1-cpp.so
|
||||
|
||||
@@ -18,7 +18,7 @@ import common
|
||||
import re
|
||||
|
||||
def FullOTA_Assertions(info):
|
||||
OTA_Assertions(info)
|
||||
OTA_Assertions(info, info.input_zip)
|
||||
return
|
||||
|
||||
def FullOTA_InstallEnd(info):
|
||||
@@ -26,15 +26,16 @@ def FullOTA_InstallEnd(info):
|
||||
return
|
||||
|
||||
def IncrementalOTA_Assertions(info):
|
||||
OTA_Assertions(info)
|
||||
OTA_Assertions(info, info.input_zip)
|
||||
return
|
||||
|
||||
def IncrementalOTA_InstallEnd(info):
|
||||
info.input_zip = info.target_zip
|
||||
OTA_InstallEnd(info)
|
||||
return
|
||||
|
||||
def OTA_Assertions(info):
|
||||
android_info = info.input_zip.read("OTA/android-info.txt")
|
||||
def OTA_Assertions(info, input_zip):
|
||||
android_info = input_zip.read("OTA/android-info.txt")
|
||||
m = re.search(r'require\s+version-bootloader-min\s*=\s*(\S+)', android_info.decode('utf-8'))
|
||||
if m:
|
||||
bootloader_version = m.group(1)
|
||||
|
||||
@@ -1,262 +0,0 @@
|
||||
LOCAL_PATH := $(call my-dir)
|
||||
|
||||
# Init files
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := fstab.ramplus
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/fstab.ramplus
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.audio.samsung.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.audio.samsung.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.fingerprint.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.fingerprint.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.nfc.samsung.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.nfc.samsung.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.qcom.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.qcom.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init/hw
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.qti.kernel.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.qti.kernel.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init/hw
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.qti.media.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.qti.media.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.ramplus.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.ramplus.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.samsung.bsp.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.samsung.bsp.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init/hw
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.samsung.display.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.samsung.display.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init/hw
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.samsung.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.samsung.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init/hw
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.target.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.target.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init/hw
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.vendor.onebinary.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.vendor.onebinary.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := vendor.samsung.rilchip.qcom.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/vendor.samsung.rilchip.qcom.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.vendor.rilcommon.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.vendor.rilcommon.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.vendor.sensors.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/init.vendor.sensors.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := wifi_firmware.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/wifi_firmware.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := ueventd.qcom.rc
|
||||
LOCAL_MODULE_STEM := ueventd.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/ueventd.qcom.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := wifi_qcom_wcn6750.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/wifi_qcom_wcn6750.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := wifi_sec.rc
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := etc/wifi_sec.rc
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
# /vendor/bin scripts
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.class_main.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/init.class_main.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.kernel.post_boot.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/init.kernel.post_boot.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.kernel.post_boot-yupik.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/init.kernel.post_boot-yupik.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.qcom.class_core.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/init.qcom.class_core.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.qcom.early_boot.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/init.qcom.early_boot.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.qcom.post_boot.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/init.qcom.post_boot.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.qcom.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/init.qcom.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.qti.chg_policy.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/init.qti.chg_policy.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.qti.kernel.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/init.qti.kernel.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.qti.media.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/init.qti.media.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := init.qti.qcv.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/init.qti.qcv.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := vendor_modprobe.sh
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_MODULE_CLASS := ETC
|
||||
LOCAL_SRC_FILES := bin/vendor_modprobe.sh
|
||||
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/bin
|
||||
include $(BUILD_PREBUILT)
|
||||
@@ -1,61 +0,0 @@
|
||||
# Copyright (c) 2019 The Linux Foundation. All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted (subject to the limitations in the
|
||||
# disclaimer below) 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.
|
||||
#
|
||||
# NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE
|
||||
# GRANTED BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT
|
||||
# HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED
|
||||
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
# IN NO EVENT SHALL THE COPYRIGHT HOLDER 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.
|
||||
|
||||
# Android fstab file.
|
||||
# The filesystem that contains the filesystem checker binary (typically /system) cannot
|
||||
# specify MF_CHECK, and must come before any filesystems that do specify MF_CHECK
|
||||
|
||||
#<src> <mnt_point> <type> <mnt_flags and options> <fs_mgr_flags>
|
||||
system /system ext4 ro wait,logical,first_stage_mount
|
||||
system /system f2fs ro wait,logical,first_stage_mount
|
||||
system /system erofs ro wait,logical,first_stage_mount
|
||||
vendor /vendor ext4 ro wait,logical,first_stage_mount
|
||||
product /product ext4 ro wait,logical,first_stage_mount
|
||||
odm /odm ext4 ro wait,logical,first_stage_mount
|
||||
/dev/block/bootdevice/by-name/boot /boot emmc defaults defaults
|
||||
/dev/block/bootdevice/by-name/recovery /recovery emmc defaults defaults
|
||||
/dev/block/bootdevice/by-name/misc /misc emmc defaults defaults,first_stage_mount
|
||||
/dev/block/by-name/metadata /metadata ext4 noatime,nosuid,nodev,noauto_da_alloc,discard,journal_checksum,data=ordered,errors=panic,sync wait,formattable,first_stage_mount,check
|
||||
/dev/block/bootdevice/by-name/cache /cache ext4 noatime,nosuid,nodev,noauto_da_alloc,discard,journal_checksum,data=ordered,errors=panic wait,check
|
||||
/dev/block/bootdevice/by-name/persist /mnt/vendor/persist ext4 noatime,nosuid,nodev,noauto_da_alloc,discard,journal_checksum,data=ordered,errors=panic wait,check
|
||||
/dev/block/bootdevice/by-name/userdata /data f2fs noatime,nosuid,nodev,discard,usrquota,grpquota,fsync_mode=nobarrier,reserve_root=32768,resgid=5678,inlinecrypt latemount,wait,check,fileencryption=aes-256-xts:aes-256-cts:v2+inlinecrypt_optimized,quota,reservedsize=128M,sysfs_path=/sys/devices/platform/soc/1d84000.ufshc,checkpoint=fs,keydirectory=/metadata/vold/metadata_encryption
|
||||
/dev/block/bootdevice/by-name/apnhlos /vendor/firmware_mnt vfat ro,shortname=lower,uid=0,gid=1000,dmask=227,fmask=337,context=u:object_r:firmware_file:s0 wait
|
||||
/dev/block/bootdevice/by-name/modem /vendor/firmware-modem vfat ro,shortname=lower,uid=0,gid=1000,dmask=227,fmask=337,context=u:object_r:firmware_file:s0 wait
|
||||
/dev/block/bootdevice/by-name/efs /mnt/vendor/efs ext4 noatime,nosuid,nodev,noauto_da_alloc,discard,journal_checksum,data=ordered,errors=panic wait,check
|
||||
/dev/block/bootdevice/by-name/sec_efs /efs ext4 noatime,nosuid,nodev,noauto_da_alloc,discard,journal_checksum,data=ordered,errors=panic wait,check
|
||||
/dev/block/bootdevice/by-name/dsp /vendor/dsp ext4 ro,nosuid,nodev,barrier=1 wait
|
||||
|
||||
# VOLD:samsung/common/fstab_non_AB.samsung
|
||||
/devices/platform/soc/8804000.sdhci/mmc_host* auto auto defaults wait,voldmanaged=sdcard:auto,encryptable=userdata
|
||||
/devices/platform/soc/*.ssusb/*.dwc3/xhci-hcd.*.auto* auto auto defaults voldmanaged=usb:auto
|
||||
|
||||
# Samsung ODE
|
||||
67
sepolicy/private/devicesettings_app.te
Normal file
67
sepolicy/private/devicesettings_app.te
Normal file
@@ -0,0 +1,67 @@
|
||||
app_domain(devicesettings_app)
|
||||
|
||||
# Allow devicesettings_app to find *_service
|
||||
allow devicesettings_app {
|
||||
activity_service
|
||||
activity_task_service
|
||||
app_api_service
|
||||
audioserver_service
|
||||
audio_service
|
||||
autofill_service
|
||||
batterystats_service
|
||||
cameraserver_service
|
||||
cameraserver_service
|
||||
content_capture_service
|
||||
device_state_service
|
||||
drmserver_service
|
||||
game_service
|
||||
gpu_service
|
||||
hint_service
|
||||
media_session_service
|
||||
mediaextractor_service
|
||||
mediametrics_service
|
||||
mediaserver_service
|
||||
netstats_service
|
||||
permission_checker_service
|
||||
sensorservice_service
|
||||
statusbar_service
|
||||
surfaceflinger_service
|
||||
thermal_service
|
||||
trust_service
|
||||
voiceinteraction_service
|
||||
}:service_manager find;
|
||||
|
||||
# Allow devicesettings_app read and write /data/data subdirectory
|
||||
allow devicesettings_app system_app_data_file:dir create_dir_perms;
|
||||
allow devicesettings_app system_app_data_file:{ file lnk_file } create_file_perms;
|
||||
|
||||
# Allow binder communication with gpuservice
|
||||
binder_call(devicesettings_app, gpuservice)
|
||||
|
||||
# Allow devicesettings_app to get settingsdebug.instant.packages prop
|
||||
get_prop(devicesettings_app, settingslib_prop)
|
||||
|
||||
# Allow reading thermal sensor data
|
||||
r_dir_file(devicesettings_app, sysfs_thermal)
|
||||
allow devicesettings_app sysfs_thermal:file { read open };
|
||||
allow devicesettings_app sysfs:file { read open };
|
||||
|
||||
# Allow reading battery information for charging speed tile
|
||||
# Primary battery sysfs paths
|
||||
allow devicesettings_app sysfs_batteryinfo:file r_file_perms;
|
||||
allow devicesettings_app sysfs_power:file r_file_perms;
|
||||
allow devicesettings_app sysfs_battery:dir search;
|
||||
allow devicesettings_app sysfs_battery:file r_file_perms;
|
||||
|
||||
# Allow charging bypass to overwrite
|
||||
allow devicesettings_app sysfs_battery_writable:dir r_dir_perms;
|
||||
allow devicesettings_app sysfs_battery_writable:file { open read write getattr ioctl };
|
||||
|
||||
# Specific battery file access (fallback if contexts above don't work)
|
||||
allow devicesettings_app sysfs:file { read open getattr ioctl };
|
||||
|
||||
# Allow reading battery manager information
|
||||
allow devicesettings_app proc_stat:file r_file_perms;
|
||||
|
||||
# Allow Quick Settings tile service binding
|
||||
allow devicesettings_app system_server:binder { call transfer };
|
||||
2
sepolicy/private/file_contexts
Normal file
2
sepolicy/private/file_contexts
Normal file
@@ -0,0 +1,2 @@
|
||||
# Charging Bypass
|
||||
/sys/class/power_supply/battery/batt_slate_mode u:object_r:sysfs_battery_writable:s0
|
||||
@@ -0,0 +1,4 @@
|
||||
allow hal_samsung_camera_flashlight_default sysfs_camera:dir search;
|
||||
allow hal_samsung_camera_flashlight_default sysfs_camera:file rw_file_perms;
|
||||
allow hal_samsung_camera_flashlight_default sysfs_camera_writable:dir search;
|
||||
allow hal_samsung_camera_flashlight_default sysfs_camera_writable:file rw_file_perms;
|
||||
2
sepolicy/private/property_contexts
Normal file
2
sepolicy/private/property_contexts
Normal file
@@ -0,0 +1,2 @@
|
||||
# SettingsLib
|
||||
settingsdebug.instant.packages u:object_r:settingslib_prop:s0
|
||||
2
sepolicy/private/seapp_contexts
Normal file
2
sepolicy/private/seapp_contexts
Normal file
@@ -0,0 +1,2 @@
|
||||
# Parts
|
||||
user=system seinfo=platform name=org.lineageos.settings domain=devicesettings_app type=system_app_data_file levelFrom=all
|
||||
2
sepolicy/public/devicesettings_app.te
Normal file
2
sepolicy/public/devicesettings_app.te
Normal file
@@ -0,0 +1,2 @@
|
||||
type devicesettings_app, domain;
|
||||
typeattribute devicesettings_app mlstrustedsubject;
|
||||
@@ -1 +1,4 @@
|
||||
type sysfs_battery, sysfs_type, r_fs_type, fs_type;
|
||||
type sysfs_battery_writable, sysfs_type, rw_fs_type, fs_type;
|
||||
type sysfs_camera, sysfs_type, r_fs_type, fs_type;
|
||||
type sysfs_camera_writable, sysfs_type, r_fs_type, fs_type;
|
||||
|
||||
2
sepolicy/public/property.te
Normal file
2
sepolicy/public/property.te
Normal file
@@ -0,0 +1,2 @@
|
||||
# SettingsLib
|
||||
system_public_prop(settingslib_prop)
|
||||
16
sepolicy/vendor/devicesettings_app.te
vendored
Normal file
16
sepolicy/vendor/devicesettings_app.te
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
allow devicesettings_app vendor_sysfs_graphics:dir search;
|
||||
allow devicesettings_app vendor_sysfs_graphics:file rw_file_perms;
|
||||
|
||||
allow devicesettings_app vendor_sysfs_kgsl:dir search;
|
||||
|
||||
allow devicesettings_app vendor_sysfs_kgsl:{ file lnk_file } rw_file_perms;
|
||||
|
||||
allow devicesettings_app property_socket:sock_file { read write getattr };
|
||||
allow devicesettings_app init:unix_stream_socket connectto;
|
||||
|
||||
allow devicesettings_app vendor_sysfs_battery_supply:dir search;
|
||||
allow devicesettings_app vendor_sysfs_battery_supply:file r_file_perms;
|
||||
|
||||
allow devicesettings_app proc_stat:file { read open getattr };
|
||||
|
||||
allow devicesettings_app vendor_sysfs_kgsl_gpuclk:file { read open getattr };
|
||||
4
sepolicy/vendor/file.te
vendored
4
sepolicy/vendor/file.te
vendored
@@ -1,5 +1,4 @@
|
||||
# SYSFS
|
||||
type sysfs_camera, sysfs_type, r_fs_type, fs_type;
|
||||
type sysfs_fingerprint, sysfs_type, r_fs_type, fs_type;
|
||||
type sysfs_iio, sysfs_type, r_fs_type, fs_type;
|
||||
type sysfs_input, sysfs_type, r_fs_type, fs_type;
|
||||
@@ -13,8 +12,6 @@ type sysfs_wifi, sysfs_type, r_fs_type, fs_type;
|
||||
|
||||
type sysfs_audio_writable, sysfs_type, rw_fs_type, fs_type;
|
||||
type sysfs_backlight_writable, sysfs_type, rw_fs_type, fs_type;
|
||||
type sysfs_camera_writable, sysfs_type, r_fs_type, fs_type;
|
||||
type sysfs_battery_writable, sysfs_type, rw_fs_type, fs_type;
|
||||
type sysfs_lcd_writable, sysfs_type, rw_fs_type, fs_type;
|
||||
type sysfs_power_writable, sysfs_type, rw_fs_type, fs_type;
|
||||
type sysfs_sensors_writable, sysfs_type, rw_fs_type, fs_type;
|
||||
@@ -26,7 +23,6 @@ type sysfs_wifi_writable, sysfs_type, rw_fs_type, fs_type;
|
||||
type biometrics_vendor_data_file, file_type, data_file_type;
|
||||
type conn_vendor_data_file, file_type, data_file_type;
|
||||
type radio_vendor_data_file, file_type, data_file_type;
|
||||
type gatekeeper_vendor_data_file, file_type, data_file_type;
|
||||
|
||||
# EFS types
|
||||
type app_efs_file, file_type;
|
||||
|
||||
12
sepolicy/vendor/file_contexts
vendored
12
sepolicy/vendor/file_contexts
vendored
@@ -2,7 +2,6 @@
|
||||
/data/vendor/biometrics(/.*)? u:object_r:biometrics_vendor_data_file:s0
|
||||
/data/vendor/conn(/.*)? u:object_r:conn_vendor_data_file:s0
|
||||
/data/vendor/secradio(/.*)? u:object_r:radio_vendor_data_file:s0
|
||||
/data/vendor/gatekeeper(/.*)? u:object_r:gatekeeper_vendor_data_file:s0
|
||||
|
||||
# DEV
|
||||
/dev/block/platform/soc/1d84000.ufshc/by-name/dsp u:object_r:dsp_block_device:s0
|
||||
@@ -22,7 +21,6 @@
|
||||
/dev/goodix_fp u:object_r:fp_sensor_device:s0
|
||||
|
||||
# NFC
|
||||
/dev/sec-nfc u:object_r:nfc_device:s0
|
||||
/dev/pn547 u:object_r:nfc_device:s0
|
||||
|
||||
# qos
|
||||
@@ -31,6 +29,9 @@
|
||||
# radio
|
||||
/dev/drb u:object_r:drb_device:s0
|
||||
|
||||
# Process and system statistics files
|
||||
/proc/stat u:object_r:proc_stat:s0
|
||||
|
||||
# EFS
|
||||
/efs/Battery(/.*)? u:object_r:battery_efs_file:s0
|
||||
/efs/biometrics(/.*)? u:object_r:biometrics_efs_file:s0
|
||||
@@ -56,12 +57,11 @@
|
||||
/(vendor|system/vendor)/bin/hw/android\.hardware\.drm@[0-9]\.[0-9]-service\.widevine u:object_r:hal_drm_widevine_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/android\.hardware\.keymaster@[0-9]\.[0-9]-service\.samsung u:object_r:hal_keymaster_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/android\.hardware\.power(@[0-9]\.[0-9])?-service\.pixel-libperfmgr u:object_r:hal_power_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/android\.hardware\.nfc@[0-9]\.[0-9]-service\.samsung u:object_r:hal_nfc_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/android\.hardware\.nfc-service\.sec u:object_r:hal_nfc_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/nxp\.android\.hardware\.nfc@[0-9]\.[0-9]-service u:object_r:hal_nfc_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/vendor\.lineage\.fastcharge@[0-9]\.[0-9]-service\.samsung u:object_r:hal_lineage_fastcharge_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/vendor\.lineage\.touch\@[0-9]\.[0-9]-service.samsung_sm7325 u:object_r:hal_lineage_touch_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/vendor\.lineage\.touch-service\.samsung u:object_r:hal_lineage_touch_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/secril_config_svc u:object_r:secril_config_svc_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/vendor\.lineage\.livedisplay@2\.0-service.samsung-qcom\.sm7325 u:object_r:hal_lineage_livedisplay_sysfs_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/vendor\.lineage\.livedisplay-service.samsung-qcom u:object_r:hal_lineage_livedisplay_qti_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/android.hardware.biometrics.fingerprint-service.samsung u:object_r:hal_fingerprint_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/vendor.samsung.hardware.thermal@1.0-service u:object_r:hal_thermal_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/android.hardware.sensors-service.samsung-multihal u:object_r:hal_sensors_default_exec:s0
|
||||
|
||||
1
sepolicy/vendor/hal_gatekeeper_default.te
vendored
1
sepolicy/vendor/hal_gatekeeper_default.te
vendored
@@ -1 +0,0 @@
|
||||
allow hal_gatekeeper_default gatekeeper_vendor_data_file:dir { read open };
|
||||
@@ -1,6 +0,0 @@
|
||||
# hal_lineage_fastcharge_default
|
||||
|
||||
set_prop(hal_lineage_fastcharge, vendor_fastcharge_prop)
|
||||
|
||||
allow hal_lineage_fastcharge_default sysfs_sec_switch:dir search;
|
||||
allow hal_lineage_fastcharge_default sysfs_sec_switch_writable:file rw_file_perms;
|
||||
@@ -1,2 +1,5 @@
|
||||
allow hal_lineage_health_default sysfs_sec_switch:dir search;
|
||||
allow hal_lineage_health_default sysfs_sec_switch_writable:file rw_file_perms;
|
||||
|
||||
rw_dir_file(hal_lineage_health_default, sysfs_battery_writable)
|
||||
r_dir_file(hal_lineage_health_default, sysfs_battery)
|
||||
7
sepolicy/vendor/hal_lineage_livedisplay_qti.te
vendored
Normal file
7
sepolicy/vendor/hal_lineage_livedisplay_qti.te
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
# /sys/devices/virtual/lcd/panel
|
||||
allow hal_lineage_livedisplay_qti sysfs_lcd_writable:file { read write open };
|
||||
|
||||
# /sys/devices/virtual/mdnie/mdnie/
|
||||
allow hal_lineage_livedisplay_qti sysfs_mdnie_writable:dir search;
|
||||
allow hal_lineage_livedisplay_qti sysfs_mdnie_writable:file { read write open getattr };
|
||||
allow hal_lineage_livedisplay_qti vendor_sysfs_graphics:file write;
|
||||
10
sepolicy/vendor/hal_lineage_livedisplay_sysfs.te
vendored
10
sepolicy/vendor/hal_lineage_livedisplay_sysfs.te
vendored
@@ -1,10 +0,0 @@
|
||||
# /sys/devices/virtual/lcd/panel
|
||||
allow hal_lineage_livedisplay_sysfs sysfs_lcd_writable:file { read write open };
|
||||
|
||||
# /sys/devices/virtual/mdnie/mdnie/
|
||||
allow hal_lineage_livedisplay_sysfs sysfs_mdnie_writable:dir search;
|
||||
allow hal_lineage_livedisplay_sysfs sysfs_mdnie_writable:file { read write open getattr };
|
||||
allow hal_lineage_livedisplay_sysfs vendor_sysfs_graphics:file write;
|
||||
|
||||
allow hal_lineage_livedisplay_sysfs vendor_display_vendor_data_file:dir { write add_name search };
|
||||
allow hal_lineage_livedisplay_sysfs vendor_display_vendor_data_file:file { read write open create getattr };
|
||||
1
sepolicy/vendor/hal_power_default.te
vendored
1
sepolicy/vendor/hal_power_default.te
vendored
@@ -37,7 +37,6 @@ allow hal_power_default vendor_sysfs_devfreq:file { write open };
|
||||
|
||||
allow hal_power_default property_socket:sock_file write;
|
||||
unix_socket_connect(hal_power_default, property, init)
|
||||
set_prop(hal_power_default, vendor_power_prop)
|
||||
|
||||
# for lcd_onoff node
|
||||
allow hal_power_default { sysfs_sensors vendor_sysfs_sensors }:dir search;
|
||||
|
||||
9
sepolicy/vendor/property.te
vendored
9
sepolicy/vendor/property.te
vendored
@@ -1,11 +1,2 @@
|
||||
# Fastcharge
|
||||
vendor_internal_prop(vendor_fastcharge_prop)
|
||||
|
||||
# NFC
|
||||
vendor_internal_prop(vendor_nfc_prop)
|
||||
|
||||
# power
|
||||
vendor_internal_prop(vendor_power_prop)
|
||||
|
||||
# qseecom
|
||||
vendor_internal_prop(vendor_qseecomd_prop)
|
||||
|
||||
6
sepolicy/vendor/property_contexts
vendored
6
sepolicy/vendor/property_contexts
vendored
@@ -6,18 +6,12 @@ vendor.bluetooth_fw_ver u:object_r:vendor_bluetooth_pro
|
||||
vendor.bluetooth_nv_ver u:object_r:vendor_bluetooth_prop:s0
|
||||
persist.vendor.bt. u:object_r:vendor_bluetooth_prop:s0
|
||||
|
||||
# fastcharge
|
||||
persist.vendor.sec.fastchg_enabled u:object_r:vendor_fastcharge_prop:s0
|
||||
|
||||
# NFC
|
||||
ro.vendor.nfc. u:object_r:vendor_nfc_prop:s0
|
||||
|
||||
# Perf
|
||||
ro.vendor.extension_library u:object_r:vendor_mpctl_prop:s0
|
||||
|
||||
# Power
|
||||
vendor.powerhal. u:object_r:vendor_power_prop:s0
|
||||
|
||||
# RIL
|
||||
ro.vendor.multisim. u:object_r:vendor_radio_prop:s0
|
||||
ro.vendor.radio. u:object_r:vendor_radio_prop:s0
|
||||
|
||||
3
sepolicy/vendor/tee.te
vendored
3
sepolicy/vendor/tee.te
vendored
@@ -1,9 +1,6 @@
|
||||
# Tee
|
||||
set_prop(tee, vendor_qseecomd_prop)
|
||||
|
||||
allow tee gatekeeper_vendor_data_file:dir { write add_name read open search };
|
||||
allow tee gatekeeper_vendor_data_file:file { create write open read getattr };
|
||||
|
||||
# This is for randomly generated TEE directories in /efs
|
||||
allow tee efs_file:dir { search read write open add_name };
|
||||
allow tee efs_file:file { read write open getattr create };
|
||||
|
||||
4
sepolicy/vendor/vendor_init.te
vendored
4
sepolicy/vendor/vendor_init.te
vendored
@@ -7,10 +7,8 @@ allow vendor_init system_file:file { read getattr open };
|
||||
|
||||
allow vendor_init block_device:lnk_file setattr;
|
||||
|
||||
set_prop(vendor_init, vendor_power_prop)
|
||||
|
||||
dontaudit vendor_init cache_file:dir search;
|
||||
|
||||
dontaudit vendor_init default_prop:file read;
|
||||
|
||||
allow vendor_init vts_status_prop:file read;
|
||||
allow vendor_init vts_status_prop:file read;
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
// Copyright (C) 2019 The LineageOS 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: "vendor.lineage.touch@1.0-service.samsung_sm7325",
|
||||
init_rc: ["vendor.lineage.touch@1.0-service.samsung_sm7325.rc"],
|
||||
defaults: ["hidl_defaults"],
|
||||
relative_install_path: "hw",
|
||||
// FIXME: this should be 'vendor: true' for modules that will eventually be
|
||||
// on AOSP.
|
||||
proprietary: true,
|
||||
local_include_dirs: ["include"],
|
||||
srcs: [
|
||||
"GloveMode.cpp",
|
||||
"TouchscreenGesture.cpp",
|
||||
"service.cpp"
|
||||
],
|
||||
shared_libs: [
|
||||
"libbase",
|
||||
"libbinder",
|
||||
"libhidlbase",
|
||||
"libutils",
|
||||
"vendor.lineage.touch@1.0",
|
||||
],
|
||||
}
|
||||
@@ -1,61 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019 The LineageOS 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.
|
||||
*/
|
||||
|
||||
#include <fstream>
|
||||
|
||||
#include "GloveMode.h"
|
||||
|
||||
namespace vendor {
|
||||
namespace lineage {
|
||||
namespace touch {
|
||||
namespace V1_0 {
|
||||
namespace samsung {
|
||||
|
||||
bool GloveMode::isSupported() {
|
||||
std::ifstream file(TSP_CMD_LIST_NODE);
|
||||
if (file.is_open()) {
|
||||
std::string line;
|
||||
while (getline(file, line)) {
|
||||
if (!line.compare("glove_mode")) return true;
|
||||
}
|
||||
file.close();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// Methods from ::vendor::lineage::touch::V1_0::IGloveMode follow.
|
||||
Return<bool> GloveMode::isEnabled() {
|
||||
std::ifstream file(TSP_CMD_RESULT_NODE);
|
||||
if (file.is_open()) {
|
||||
std::string line;
|
||||
getline(file, line);
|
||||
if (!line.compare("glove_mode,1:OK")) return true;
|
||||
file.close();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
Return<bool> GloveMode::setEnabled(bool enabled) {
|
||||
std::ofstream file(TSP_CMD_NODE);
|
||||
file << "glove_mode," << (enabled ? "1" : "0");
|
||||
return true;
|
||||
}
|
||||
|
||||
} // namespace samsung
|
||||
} // namespace V1_0
|
||||
} // namespace touch
|
||||
} // namespace lineage
|
||||
} // namespace vendor
|
||||
@@ -1,55 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2022 The LineageOS 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.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <hidl/MQDescriptor.h>
|
||||
#include <hidl/Status.h>
|
||||
#include <vendor/lineage/touch/1.0/IGloveMode.h>
|
||||
#include "samsung_touch.h"
|
||||
|
||||
namespace vendor {
|
||||
namespace lineage {
|
||||
namespace touch {
|
||||
namespace V1_0 {
|
||||
namespace samsung {
|
||||
|
||||
using ::android::hardware::hidl_array;
|
||||
using ::android::hardware::hidl_memory;
|
||||
using ::android::hardware::hidl_string;
|
||||
using ::android::hardware::hidl_vec;
|
||||
using ::android::hardware::Return;
|
||||
using ::android::hardware::Void;
|
||||
using ::android::sp;
|
||||
|
||||
class GloveMode : public IGloveMode {
|
||||
public:
|
||||
GloveMode() = default;
|
||||
|
||||
bool isSupported();
|
||||
|
||||
// Methods from ::vendor::lineage::touch::V1_0::IGloveMode follow.
|
||||
Return<bool> isEnabled() override;
|
||||
Return<bool> setEnabled(bool enabled) override;
|
||||
|
||||
// Methods from ::android::hidl::base::V1_0::IBase follow.
|
||||
};
|
||||
|
||||
} // namespace samsung
|
||||
} // namespace V1_0
|
||||
} // namespace touch
|
||||
} // namespace lineage
|
||||
} // namespace vendor
|
||||
@@ -1,67 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019 The LineageOS 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.
|
||||
*/
|
||||
|
||||
#include <fstream>
|
||||
|
||||
#include "TouchscreenGesture.h"
|
||||
|
||||
namespace vendor {
|
||||
namespace lineage {
|
||||
namespace touch {
|
||||
namespace V1_0 {
|
||||
namespace samsung {
|
||||
|
||||
static constexpr const char* kTspPath = TSP_CMD_NODE;
|
||||
|
||||
const std::map<int32_t, TouchscreenGesture::GestureInfo> TouchscreenGesture::kGestureInfoMap = {
|
||||
// clang-format off
|
||||
{0, {0x1c7, "Single Tap"}},
|
||||
// clang-format on
|
||||
};
|
||||
|
||||
bool TouchscreenGesture::isSupported() {
|
||||
std::ifstream file(kTspPath);
|
||||
return file.good();
|
||||
}
|
||||
|
||||
// Methods from ::vendor::lineage::touch::V1_0::ITouchscreenGesture follow.
|
||||
Return<void> TouchscreenGesture::getSupportedGestures(getSupportedGestures_cb resultCb) {
|
||||
std::vector<Gesture> gestures;
|
||||
|
||||
for (const auto& entry : kGestureInfoMap) {
|
||||
gestures.push_back({entry.first, entry.second.name, entry.second.keycode});
|
||||
}
|
||||
resultCb(gestures);
|
||||
|
||||
return Void();
|
||||
}
|
||||
|
||||
Return<bool> TouchscreenGesture::setGestureEnabled(
|
||||
const ::vendor::lineage::touch::V1_0::Gesture&, bool enabled) {
|
||||
std::fstream file(kTspPath);
|
||||
|
||||
file << "singletap_enable," << (enabled ? "1" : "0");
|
||||
|
||||
return !file.fail();
|
||||
}
|
||||
|
||||
// Methods from ::android::hidl::base::V1_0::IBase follow.
|
||||
|
||||
} // namespace samsung
|
||||
} // namespace V1_0
|
||||
} // namespace touch
|
||||
} // namespace lineage
|
||||
} // namespace vendor
|
||||
@@ -1,62 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019-2022 The LineageOS 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.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <hidl/MQDescriptor.h>
|
||||
#include <hidl/Status.h>
|
||||
#include <vendor/lineage/touch/1.0/ITouchscreenGesture.h>
|
||||
#include "samsung_touch.h"
|
||||
|
||||
namespace vendor {
|
||||
namespace lineage {
|
||||
namespace touch {
|
||||
namespace V1_0 {
|
||||
namespace samsung {
|
||||
|
||||
using ::android::hardware::hidl_array;
|
||||
using ::android::hardware::hidl_memory;
|
||||
using ::android::hardware::hidl_string;
|
||||
using ::android::hardware::hidl_vec;
|
||||
using ::android::hardware::Return;
|
||||
using ::android::hardware::Void;
|
||||
using ::android::sp;
|
||||
|
||||
class TouchscreenGesture : public ITouchscreenGesture {
|
||||
public:
|
||||
bool isSupported();
|
||||
|
||||
// Methods from ::vendor::lineage::touch::V1_0::ITouchscreenGesture follow.
|
||||
Return<void> getSupportedGestures(getSupportedGestures_cb resultCb) override;
|
||||
Return<bool> setGestureEnabled(const ::vendor::lineage::touch::V1_0::Gesture& gesture,
|
||||
bool enabled) override;
|
||||
|
||||
private:
|
||||
typedef struct {
|
||||
int32_t keycode;
|
||||
const char* name;
|
||||
} GestureInfo;
|
||||
static const std::map<int32_t, GestureInfo> kGestureInfoMap; // id -> info
|
||||
};
|
||||
|
||||
// FIXME: most likely delete, this is only for passthrough implementations
|
||||
// extern "C" ITouchscreenGesture* HIDL_FETCH_ITouchscreenGesture(const char* name);
|
||||
|
||||
} // namespace samsung
|
||||
} // namespace V1_0
|
||||
} // namespace touch
|
||||
} // namespace lineage
|
||||
} // namespace vendor
|
||||
@@ -1,33 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2021 The LineageOS 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 SAMSUNG_TOUCH_H
|
||||
#define SAMSUNG_TOUCH_H
|
||||
|
||||
/*
|
||||
* Board specific nodes
|
||||
*
|
||||
* If your kernel exposes these controls in another place, you can either
|
||||
* symlink to the locations given here, or override this header in your
|
||||
* device tree.
|
||||
*/
|
||||
|
||||
// For GloveMode
|
||||
#define TSP_CMD_LIST_NODE "/sys/class/sec/tsp/cmd_list"
|
||||
#define TSP_CMD_RESULT_NODE "/sys/class/sec/tsp/cmd_result"
|
||||
#define TSP_CMD_NODE "/sys/class/sec/tsp/cmd"
|
||||
|
||||
#endif // SAMSUNG_TOUCH_H
|
||||
@@ -1,82 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2019 The LineageOS 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 "vendor.lineage.touch@1.0-service.samsung_sm7325"
|
||||
|
||||
#include <android-base/logging.h>
|
||||
#include <binder/ProcessState.h>
|
||||
#include <hidl/HidlTransportSupport.h>
|
||||
|
||||
#include "GloveMode.h"
|
||||
#include "TouchscreenGesture.h"
|
||||
|
||||
using android::hardware::configureRpcThreadpool;
|
||||
using android::hardware::joinRpcThreadpool;
|
||||
using android::sp;
|
||||
using android::status_t;
|
||||
using android::OK;
|
||||
|
||||
using ::vendor::lineage::touch::V1_0::samsung::GloveMode;
|
||||
using ::vendor::lineage::touch::V1_0::samsung::TouchscreenGesture;
|
||||
|
||||
int main() {
|
||||
sp<GloveMode> gloveMode;
|
||||
sp<TouchscreenGesture> touchscreenGesture;
|
||||
status_t status;
|
||||
|
||||
LOG(INFO) << "Touch HAL service is starting.";
|
||||
|
||||
gloveMode = new GloveMode();
|
||||
if (gloveMode == nullptr) {
|
||||
LOG(ERROR) << "Can not create an instance of Touch HAL GloveMode Iface, exiting.";
|
||||
goto shutdown;
|
||||
}
|
||||
|
||||
touchscreenGesture = new TouchscreenGesture();
|
||||
if (touchscreenGesture == nullptr) {
|
||||
LOG(ERROR) << "Can not create an instance of Touch HAL TouchscreenGesture Iface, exiting.";
|
||||
goto shutdown;
|
||||
}
|
||||
|
||||
configureRpcThreadpool(1, true /*callerWillJoin*/);
|
||||
|
||||
if (gloveMode->isSupported()) {
|
||||
status = gloveMode->registerAsService();
|
||||
if (status != OK) {
|
||||
LOG(ERROR) << "Could not register service for Touch HAL GloveMode Iface (" << status
|
||||
<< ")";
|
||||
goto shutdown;
|
||||
}
|
||||
}
|
||||
|
||||
if (touchscreenGesture->isSupported()) {
|
||||
status = touchscreenGesture->registerAsService();
|
||||
if (status != OK) {
|
||||
LOG(ERROR) << "Could not register service for Touch HAL TouchscreenGesture Iface ("
|
||||
<< status << ")";
|
||||
goto shutdown;
|
||||
}
|
||||
}
|
||||
|
||||
LOG(INFO) << "Touch HAL service is ready.";
|
||||
joinRpcThreadpool();
|
||||
// Should not pass this line
|
||||
|
||||
shutdown:
|
||||
// In normal operation, we don't expect the thread pool to shutdown
|
||||
LOG(ERROR) << "Touch HAL service is shutting down.";
|
||||
return 1;
|
||||
}
|
||||
@@ -1,8 +0,0 @@
|
||||
on early-init
|
||||
chown system radio /sys/class/sec/tsp/cmd
|
||||
chmod 0664 /sys/class/sec/tsp/cmd
|
||||
|
||||
service vendor.touch-hal-1-0 /vendor/bin/hw/vendor.lineage.touch@1.0-service.samsung_sm7325
|
||||
class hal
|
||||
user system
|
||||
group system
|
||||
@@ -21,8 +21,6 @@ audio.offload.video=true
|
||||
vendor.audio.offload.track.enable=true
|
||||
audio.deep_buffer.media=true
|
||||
vendor.audio.offload.multiaac.enable=true
|
||||
vendor.audio.dolby.ds2.enabled=false
|
||||
vendor.audio.dolby.ds2.hardbypass=false
|
||||
vendor.audio.offload.multiple.enabled=false
|
||||
vendor.audio.offload.passthrough=false
|
||||
vendor.voice.path.for.pcm.voip=true
|
||||
|
||||
Reference in New Issue
Block a user