e3q: Initial device tree

This commit is contained in:
David Wronek
2025-05-04 08:55:44 +02:00
commit 9788fa93aa
15 changed files with 514 additions and 0 deletions

7
Android.bp Normal file
View File

@@ -0,0 +1,7 @@
//
// Copyright (C) 2025 The LineageOS Project
// SPDX-License-Identifier: Apache-2.0
//
soong_namespace {
}

8
AndroidProducts.mk Normal file
View File

@@ -0,0 +1,8 @@
#
# Copyright (C) 2025 The LineageOS Project
#
# SPDX-License-Identifier: Apache-2.0
#
PRODUCT_MAKEFILES := \
$(LOCAL_DIR)/lineage_e3q.mk

22
BoardConfig.mk Normal file
View File

@@ -0,0 +1,22 @@
#
# Copyright (C) 2025 The LineageOS Project
#
# SPDX-License-Identifier: Apache-2.0
#
# Include the common OEM chipset BoardConfig.
include device/samsung/sm8650-common/BoardConfigCommon.mk
DEVICE_PATH := device/samsung/e3q
# Assert
TARGET_OTA_ASSERT_DEVICE := e3q
# Display
TARGET_SCREEN_DENSITY := 600
# Kernel
TARGET_KERNEL_CONFIG += oem/e3q-lego.config
# Include the proprietary files BoardConfig.
include vendor/samsung/e3q/BoardConfigVendor.mk

1
board-info.txt Normal file
View File

@@ -0,0 +1 @@
require board=pineapple|e3q

34
device.mk Normal file
View File

@@ -0,0 +1,34 @@
#
# Copyright (C) 2025 The LineageOS Project
#
# SPDX-License-Identifier: Apache-2.0
#
# AAPT
PRODUCT_AAPT_CONFIG := normal
PRODUCT_AAPT_PREF_CONFIG := xxxhdpi
# Boot animation
TARGET_SCREEN_HEIGHT := 3120
TARGET_SCREEN_WIDTH := 1440
# Init
PRODUCT_PACKAGES += \
init.e3q.rc
# Overlays
PRODUCT_PACKAGES += \
SystemUIResTarget
# Soong namespaces
PRODUCT_SOONG_NAMESPACES += \
$(LOCAL_PATH)
# Product characteristics
PRODUCT_CHARACTERISTICS := phone
# Inherit from the common OEM chipset makefile.
$(call inherit-product, device/samsung/sm8650-common/common.mk)
# Inherit from the proprietary files makefile.
$(call inherit-product, vendor/samsung/e3q/e3q-vendor.mk)

24
extract-files.py Executable file
View File

@@ -0,0 +1,24 @@
#!/usr/bin/env -S PYTHONPATH=../../../tools/extract-utils python3
#
# SPDX-FileCopyrightText: 2024 The LineageOS Project
# SPDX-License-Identifier: Apache-2.0
#
from extract_utils.main import (
ExtractUtils,
ExtractUtilsModule,
)
namespace_imports = [
'vendor/samsung/sm8650-common',
]
module = ExtractUtilsModule(
'e3q',
'samsung',
namespace_imports=namespace_imports,
)
if __name__ == '__main__':
utils = ExtractUtils.device_with_common(module, 'sm8650-common', module.vendor)
utils.run()

11
init/Android.bp Normal file
View File

@@ -0,0 +1,11 @@
//
// Copyright (C) 2025 The LineageOS Project
// SPDX-License-Identifier: Apache-2.0
//
prebuilt_etc {
name: "init.e3q.rc",
src: "init.e3q.rc",
sub_dir: "init/hw",
vendor: true,
}

190
init/init.e3q.rc Normal file
View File

@@ -0,0 +1,190 @@
# Copyright (c) 2019-2023, The Linux Foundation. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above
# copyright notice, this list of conditions and the following
# disclaimer in the documentation and/or other materials provided
# with the distribution.
# * Neither the name of The Linux Foundation nor the names of its
# contributors may be used to endorse or promote products derived
# from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
# BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
# BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
# OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
# IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
#
service logger /system/bin/logcat -b all -D -f /metadata/boot_log.txt
class main
user root
group root system
disabled
oneshot
on early-init
on init
on late-init
on post-fs
start logger
on late-fs
on post-fs-data
# MST/NFC Switch
chown system /dev/mst_ctrl
chmod 0660 /dev/mst_ctrl
#mAFPC
mkdir /efs/afc 0760 system system
exec - system system -- /system/bin/mafpc_write
on boot
write /proc/sys/vm/swappiness 100
# SDHMS Slowdown : Cpuset
write /dev/cpuset/abnormal/cpus 0-1,5-6
write /dev/cpuset/moderate/cpus 0-1,5-6
# Permissions for GPU
chown system system /sys/kernel/gpu/gpu_info
# [ Permissions for Range Sensor Sensor
# Range Sensor
chown system radio /sys/class/sensors/range_sensor/ambient
chown system radio /sys/class/sensors/range_sensor/cal01
chown system radio /sys/class/sensors/range_sensor/cal02
chown system radio /sys/class/sensors/range_sensor/cal_uid
chown system radio /sys/class/sensors/range_sensor/open_calibration
chown system radio /sys/class/sensors/range_sensor/calibration
chown system radio /sys/class/sensors/range_sensor/enable
chown system radio /sys/class/sensors/range_sensor/error
chown system radio /sys/class/sensors/range_sensor/frame_rate
chown system radio /sys/class/sensors/range_sensor/fw_version
chown system radio /sys/class/sensors/range_sensor/interrupt
chown system radio /sys/class/sensors/range_sensor/mode
chown system radio /sys/class/sensors/range_sensor/name
chown system radio /sys/class/sensors/range_sensor/range_sigma
chown system radio /sys/class/sensors/range_sensor/status
chown system radio /sys/class/sensors/range_sensor/target_status
chown system radio /sys/class/sensors/range_sensor/temp
chown system radio /sys/class/sensors/range_sensor/test01
chown system radio /sys/class/sensors/range_sensor/test02
chown system radio /sys/class/sensors/range_sensor/test03
chown system radio /sys/class/sensors/range_sensor/test_mode
chown system radio /sys/class/sensors/range_sensor/uid
chown system radio /sys/class/sensors/range_sensor/vendor
chown system radio /sys/class/sensors/range_sensor/zone
chown system radio /sys/class/sensors/range_sensor/file_cal
chown system radio /sys/class/sensors/range_sensor/file_p2p
chown system radio /sys/class/sensors/range_sensor/file_shape
# ] Permissions for Range Sensor
on shutdown
# service definition
# on property triggers
# Create carrier folder for HiddenMenu
on post-fs
mkdir /efs/carrier 0755 radio system
chown radio system /efs/carrier
chown radio system /efs/carrier/HiddenMenu
# For Range Sensor
chmod 0660 /dev/range_sensor
chown system system /dev/range_sensor
mkdir /efs/range_sensor 0770 system system
chown system system /efs/range_sensor/cal_data.bin
chmod 0660 /efs/range_sensor/cal_data.bin
chown system system /efs/range_sensor/vl53l5_cal_shape.bin
chmod 0660 /efs/range_sensor/vl53l5_cal_shape.bin
chown system system /efs/range_sensor/vl53l5_cal_p2p.bin
chmod 0660 /efs/range_sensor/vl53l5_cal_p2p.bin
# Range Sensor
on property:sys.boot_completed=1
write /sys/class/sensors/range_sensor/calibration 0
# some priv-apps of DSH bind mount to DSA priv-apps
on post-fs-data && property:ro.csc.sales_code=DSA
umount /system/carrier
mkdir /mnt/temp
mount none /system/carrier/DSH /mnt/temp bind
mount none /system/carrier/DSA /system/carrier bind
mount none /mnt/temp/priv-app/VisualVoicemailDsh_Stub /system/carrier/priv-app/VisualVoicemailDsh_Stub bind
umount /mnt/temp
rmdir /mnt/temp
# some priv-apps of DSH & DSA bind mount to DSG priv-apps
on post-fs-data && property:ro.csc.sales_code=DSG
umount /system/carrier
mkdir /mnt/temp1
mkdir /mnt/temp2
mount none /system/carrier/DSH /mnt/temp1 bind
mount none /system/carrier/DSA /mnt/temp2 bind
mount none /system/carrier/DSG /system/carrier bind
mount none /mnt/temp1/priv-app/NetworkCompanion /system/carrier/priv-app/NetworkCompanion bind
mount none /mnt/temp1/priv-app/VisualVoicemailDsh_Stub /system/carrier/priv-app/VisualVoicemailDsh_Stub bind
mount none /mnt/temp2/priv-app/Opportunistic /system/carrier/priv-app/Opportunistic bind
umount /mnt/temp1
umount /mnt/temp2
rmdir /mnt/temp1
rmdir /mnt/temp2
# some priv-apps of DSA bind mount to DSH priv-apps
on post-fs-data && property:ro.csc.sales_code=DSH
umount /system/carrier
mkdir /mnt/temp
mount none /system/carrier/DSA /mnt/temp bind
mount none /system/carrier/DSH /system/carrier bind
mount none /mnt/temp/priv-app/Opportunistic /system/carrier/priv-app/Opportunistic bind
umount /mnt/temp
rmdir /mnt/temp
# some priv-apps of TMB bind mount to ASR priv-apps
on post-fs-data && property:ro.csc.sales_code=ASR
umount /system/carrier
mkdir /mnt/temp
mount none /system/carrier/TMB /mnt/temp bind
mount none /system/carrier/ASR /system/carrier bind
mount none /mnt/temp/priv-app/SprintAndroidExtension2_TMB /system/carrier/priv-app/SprintAndroidExtension2_TMB bind
umount /mnt/temp
rmdir /mnt/temp
# some priv-apps of TMB bind mount to TMK priv-apps
on post-fs-data && property:ro.csc.sales_code=TMK
umount /system/carrier
mkdir /mnt/temp
mount none /system/carrier/TMB /mnt/temp bind
mount none /system/carrier/TMK /system/carrier bind
mount none /mnt/temp/priv-app/SprintAndroidExtension2_TMB /system/carrier/priv-app/SprintAndroidExtension2_TMB bind
umount /mnt/temp
rmdir /mnt/temp
# Pageboostd
on property:sys.boot_completed=1
start pageboostd
service pageboostd /system/bin/pageboostd
class main
user system
group system mount radio net_bt sdcard_rw shell media media_rw
socket pageboostd seqpacket 0660 system system
disabled

6
lineage.dependencies Normal file
View File

@@ -0,0 +1,6 @@
[
{
"repository": "android_device_samsung_sm8650-common",
"target_path": "device/samsung/sm8650-common"
}
]

27
lineage_e3q.mk Normal file
View File

@@ -0,0 +1,27 @@
#
# Copyright (C) 2024 The LineageOS Project
#
# SPDX-License-Identifier: Apache-2.0
#
# Inherit from those products. Most specific first.
$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk)
$(call inherit-product, $(SRC_TARGET_DIR)/product/full_base_telephony.mk)
# Inherit some common Lineage stuff.
$(call inherit-product, vendor/lineage/config/common_full_phone.mk)
# Inherit from e3q device
$(call inherit-product, device/samsung/e3q/device.mk)
PRODUCT_NAME := lineage_e3q
PRODUCT_DEVICE := e3q
PRODUCT_BRAND := Samsung
PRODUCT_MODEL := SM-S928B
PRODUCT_MANUFACTURER := Samsung
PRODUCT_GMS_CLIENTID_BASE := android-samsung-ss
PRODUCT_BUILD_PROP_OVERRIDES += \
BuildDesc="e3qxxx-user 15 AP3A.240905.015.A2 S928BXXU4BYD9 release-keys" \
BuildFingerprint="samsung/e3qxxx/e3q:14/UP1A.231005.007/S928BXXU4BYD9:user/release-keys"

View File

@@ -0,0 +1,9 @@
//
// SPDX-FileCopyrightText: 2025 The LineageOS Project
// SPDX-License-Identifier: Apache-2.0
//
runtime_resource_overlay {
name: "SystemUIResTarget",
vendor: true,
}

View File

@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
SPDX-FileCopyrightText: 2025 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.systemui.overlay.target">
<overlay
android:isStatic="true"
android:priority="250"
android:targetPackage="com.android.systemui" />
</manifest>

View File

@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2025 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<!-- Location on the screen of the center of the physical power button. This is a reasonable
default that should be overridden by device-specific overlays. -->
<dimen name="physical_power_button_center_screen_location_y">1330.0px</dimen>
<!-- Microns/ums (1000 um = 1mm) per pixel for the given device. If unspecified, UI that
relies on this value will not be sized correctly. -->
<item name="pixel_pitch" format="float" type="dimen">50.26</item>
</resources>

147
proprietary-files.txt Normal file
View File

@@ -0,0 +1,147 @@
# Unpinned blobs from e3qxxx-user 15 AP3A.240905.015.A2 S928BXXU4BYD9 release-keys
# ACDB
vendor/etc/audconf/OPEN/acdb_cal.acdb
vendor/etc/audconf/OPEN/workspaceFileXml.qwsp
# Audio configs
vendor/etc/audio/sku_pineapple/mixer_paths.xml
vendor/etc/audio/sku_pineapple/resourcemanager.xml
vendor/etc/card-defs.xml
vendor/etc/usecaseKvManager.xml
# Audio firmware
vendor/firmware/cs35l43-bot-dsp1-spk-prot.bin
vendor/firmware/cs35l43-bot-dsp1-spk-prot.wmfw
vendor/firmware/cs35l43-rcv-dsp1-spk-prot.bin
vendor/firmware/cs35l43-rcv-dsp1-spk-prot.wmfw
vendor/firmware/cs40l26-a2h.bin
vendor/firmware/cs40l26-calib.bin
vendor/firmware/cs40l26-calib.wmfw
vendor/firmware/cs40l26-dvl.bin
vendor/firmware/cs40l26-svc.bin
vendor/firmware/cs40l26-svc1.bin
vendor/firmware/cs40l26-svc2.bin
vendor/firmware/cs40l26-svc3.bin
vendor/firmware/cs40l26-wt1.bin
vendor/firmware/cs40l26-wt2.bin
vendor/firmware/cs40l26-wt3.bin
vendor/firmware/cs40l26.bin
vendor/firmware/cs40l26.wmfw
# Audio params
vendor/etc/LVACFS_Calibration.dat
vendor/etc/LVACFS_Configuration.txt
vendor/etc/LVACFS_ControlParams.txt
vendor/etc/SoundBoosterParam.txt
vendor/firmware/SoundBoosterParam.bin
vendor/firmware/dax_param.bin
# Display calibration
vendor/etc/display/qdcm_calib_data_E3_S6E3HAF_AMB679FN01.json
vendor/firmware/E3_S6E3HAE_AMB681AZ01.dat
vendor/firmware/E3_S6E3HAF_AMB679FN01.dat
vendor/firmware/ss_dsi_panel_PBA_BOOTING_FHD.dat
# EVA firmware
vendor/firmware/evass.b00
vendor/firmware/evass.b01
vendor/firmware/evass.b02
vendor/firmware/evass.b03
vendor/firmware/evass.b04
vendor/firmware/evass.b05
vendor/firmware/evass.b06
vendor/firmware/evass.b07
vendor/firmware/evass.b08
vendor/firmware/evass.b09
vendor/firmware/evass.b10
vendor/firmware/evass.b11
vendor/firmware/evass.b12
vendor/firmware/evass.b13
vendor/firmware/evass.b14
vendor/firmware/evass.b15
vendor/firmware/evass.b16
vendor/firmware/evass.b17
vendor/firmware/evass.b18
vendor/firmware/evass.b19
vendor/firmware/evass.mbn
vendor/firmware/evass.mdt
# Graphics (Adreno firmware)
vendor/firmware/gen70900_aqe.fw
vendor/firmware/gen70900_sqe.fw
vendor/firmware/gen70900_zap.mbn
vendor/firmware/gmu_gen70900.bin
# Miscellaneous firmware
vendor/firmware/max77775-extra-fw.bin
vendor/firmware/max77775-fw.bin
vendor/firmware/mfc/mfc_fw_flash_nu1668.bin
# NFC configs
vendor/etc/libnfc-nxp.conf
vendor/etc/nfc/libnfc-nxp_RF.conf
# Secure Element
vendor/etc/libese-nxp.conf
vendor/etc/secnvm/k250a_47000400_0.img
vendor/etc/secnvm/k250a_47000403_1.img
vendor/etc/secnvm/k250a_47000406_f.img
# Sensor configs
vendor/etc/sensors/config/akmlib.json
vendor/etc/sensors/config/json.lst
vendor/etc/sensors/config/lanai_ak991x_0.json
vendor/etc/sensors/config/lanai_ak991x_4.json
vendor/etc/sensors/config/lanai_ak991x_5.json
vendor/etc/sensors/config/lanai_lps22df_0.json
vendor/etc/sensors/config/lanai_lps22hh_0.json
vendor/etc/sensors/config/lanai_lsm6dso_0_0.json
vendor/etc/sensors/config/lanai_lsm6dsv_0_2.json
vendor/etc/sensors/config/lanai_stk3af00_0.json
vendor/etc/sensors/config/lanai_stk3afx_0.json
vendor/etc/sensors/config/lsm6dso_0.json
vendor/etc/sensors/config/lsm6dsv_2.json
# Sensor firmware
vendor/firmware/00_generic_xtalk_shape.bin
vendor/firmware/vl53l8.bin
# Touchscreen firmware
vendor/firmware/tsp_stm/fts2ba61y_e3q.bin
vendor/firmware/tsp_synaptics/s3916a_e3.bin
vendor/firmware/tsp_synaptics/s3916t_e3.bin
# Ultra-wideband
vendor/firmware/uwb/libsr200t_dev_fw.bin
vendor/firmware/uwb/libsr200t_prod_fw.so
# VPU firmware
vendor/firmware/vpu30_2v.mbn
vendor/firmware/vpu30_2v_unsigned.mbn
vendor/firmware/vpu33_4v.mbn
vendor/firmware/vpu33_4v_unsigned.mbn
# Wacom firmware
vendor/firmware/wez02_e3_c0.bin
vendor/firmware/wez02_e3_c1.bin
vendor/firmware/wez02_e3_c2.bin
vendor/firmware/wez02_e3_c3.bin
# Wi-Fi and Bluetooth firmware
vendor/firmware/Data.msc
vendor/firmware/bt_nvm_loading.xml
vendor/firmware/hmtbtfw20.tlv
vendor/firmware/hmtnv20.b20
vendor/firmware/hmtnv20.b39
vendor/firmware/hmtnv20.b3c
vendor/firmware/kiwi/amss20.bin
vendor/firmware/kiwi/bdwlan.elf
vendor/firmware/kiwi/bdwlan.elf1
vendor/firmware/kiwi/bdwlan.elf10
vendor/firmware/kiwi/bdwlan.elf2
vendor/firmware/kiwi/phy_ucode20.elf
vendor/firmware/kiwi/qdss_trace_config_v2.cfg
vendor/firmware/kiwi/regdb.bin
vendor/firmware/wlan-connection-roaming-backup.ini
vendor/firmware/wlan-connection-roaming.ini

1
setup-makefiles.py Executable file
View File

@@ -0,0 +1 @@
#!./extract-files.py --regenerate_makefiles