e3q: Fix camera

Change-Id: If6c242499680e9fb57b4c3417b851858314cd3db
This commit is contained in:
David Wronek 2025-01-12 20:34:15 +01:00
parent c025acecd5
commit cec76c9796
10 changed files with 71 additions and 45 deletions

View File

@ -1,15 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2014 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<permissions>
<assign-permission name="com.samsung.permission.SSENSOR" uid="cameraserver" />
</permissions>

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2014 The Android Open Source Project <!-- Copyright (C) 2008 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License"); Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License. you may not use this file except in compliance with the License.
You may obtain a copy of the License at You may obtain a copy of the License at
@ -10,6 +10,14 @@
See the License for the specific language governing permissions and See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
--> -->
<!-- This file is used to define the mappings between lower-level system
user and group IDs and the higher-level permission names managed
by the platform.
Be VERY careful when editing this file! Mistakes made here can open
big security holes.
-->
<permissions> <permissions>
<assign-permission name="com.samsung.permission.HRM_EXT" uid="cameraserver" /> <assign-permission name="com.samsung.permission.HRM_EXT" uid="cameraserver" />
<assign-permission name="com.samsung.permission.SSENSOR" uid="cameraserver" />
</permissions> </permissions>

View File

@ -1,12 +1,4 @@
<compatibility-matrix version="8.0" type="framework"> <compatibility-matrix version="8.0" type="framework">
<hal format="aidl" optional="true">
<name>vendor.samsung.hardware.hyper</name>
<version>2</version>
<interface>
<name>ISehHyPer</name>
<instance>default</instance>
</interface>
</hal>
<hal format="aidl" optional="true"> <hal format="aidl" optional="true">
<name>vendor.samsung.hardware.authfw</name> <name>vendor.samsung.hardware.authfw</name>
<interface> <interface>

View File

@ -107,8 +107,7 @@ PRODUCT_COPY_FILES += \
frameworks/native/data/etc/android.hardware.camera.front.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.front.xml \ frameworks/native/data/etc/android.hardware.camera.front.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.front.xml \
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.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.camera.raw.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.raw.xml \
$(LOCAL_PATH)/configs/permissions/com.samsung.permission.HRM_EXT.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.samsung.permission.HRM_EXT.xml \ $(LOCAL_PATH)/configs/permissions/platform-samsung.xml:$(TARGET_COPY_OUT_SYSTEM)/etc/permissions/platform-samsung.xml
$(LOCAL_PATH)/configs/permissions/com.samsung.permission.SSENSOR.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/com.samsung.permission.SSENSOR.xml
# DebugFS # DebugFS
PRODUCT_SET_DEBUGFS_RESTRICTIONS := true PRODUCT_SET_DEBUGFS_RESTRICTIONS := true

View File

@ -42,8 +42,7 @@ def lib_fixup_vendor_suffix(lib: str, partition: str, *args, **kwargs):
lib_fixups: lib_fixups_user_type = { lib_fixups: lib_fixups_user_type = {
**lib_fixups, **lib_fixups,
( (
'libsecril-client', 'libsecril-client'
'libhyper'
): lib_fixup_vendor_suffix, ): lib_fixup_vendor_suffix,
( (
'libagmclient', 'libagmclient',

11
libshims/Android.bp Normal file
View File

@ -0,0 +1,11 @@
//
// Copyright (C) 2024 The LineageOS Project
//
// SPDX-License-Identifier: Apache-2.0
//
cc_library_shared {
name: "libhypervintf",
srcs: ["libhypervintf/libhypervintf.cpp"],
vendor: true,
}

View File

@ -0,0 +1,32 @@
/*
* Copyright (C) 2024 The LineageOS Project
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <string>
#include <vector>
struct HyPerToken {
};
void hyper_getNewHyPerToken(void) {
}
void hyper_setTokenProcName(HyPerToken*, std::string) {
}
void hyper_checkResourceExist(int) {
}
void hyper_acquire(HyPerToken, std::vector<int>) {
}
void hyper_setProcName(std::string) {
}
void hyper_getSupportedFrequency(int, int) {
}
void hyper_release(HyPerToken) {
}

View File

@ -31,6 +31,9 @@ vendor/lib64/rfs/dsp/libqsegnetengine_dsp_skel.so:vendor/lib/rfsa/adsp/libqsegne
vendor/lib64/rfs/dsp/libscveT2T_skel.so:vendor/lib/rfsa/adsp/libscveT2T_skel.so;SYMLINK=vendor/lib64/rfs/dsp/libscveT2T_skel.so vendor/lib64/rfs/dsp/libscveT2T_skel.so:vendor/lib/rfsa/adsp/libscveT2T_skel.so;SYMLINK=vendor/lib64/rfs/dsp/libscveT2T_skel.so
vendor/lib64/rfs/dsp/libworker_pool.so:vendor/lib/rfsa/adsp/libworker_pool.so vendor/lib64/rfs/dsp/libworker_pool.so:vendor/lib/rfsa/adsp/libworker_pool.so
vendor/lib64/rfs/dsp/snap/libQnnHtpV75Skel.so:vendor/lib/rfsa/adsp/snap/libQnnHtpV75Skel.so;SYMLINK=vendor/lib64/rfs/dsp/snap/libQnnHtpV75Skel.so vendor/lib64/rfs/dsp/snap/libQnnHtpV75Skel.so:vendor/lib/rfsa/adsp/snap/libQnnHtpV75Skel.so;SYMLINK=vendor/lib64/rfs/dsp/snap/libQnnHtpV75Skel.so
vendor/lib64/snap/libQnnHtp.so
vendor/lib64/snap/libQnnHtpV75Stub.so
vendor/lib64/snap/libQnnSystem.so
# Audio # Audio
vendor/etc/LVACFS_Calibration.dat vendor/etc/LVACFS_Calibration.dat
@ -65,6 +68,7 @@ vendor/lib64/libcapiv2svacnnvendor.so
vendor/lib64/libcapiv2svarnnvendor.so vendor/lib64/libcapiv2svarnnvendor.so
vendor/lib64/libcapiv2udk7vendor.so vendor/lib64/libcapiv2udk7vendor.so
vendor/lib64/libcapiv2uvvendor.so vendor/lib64/libcapiv2uvvendor.so
vendor/lib64/libcustomva_intf.so
vendor/lib64/libdsd2pcm.so vendor/lib64/libdsd2pcm.so
vendor/lib64/liblistensoundmodel2vendor.so vendor/lib64/liblistensoundmodel2vendor.so
vendor/lib64/liblx-ar_util.so vendor/lib64/liblx-ar_util.so
@ -526,6 +530,7 @@ vendor/lib64/libfocuspeaking.so
vendor/lib64/libfocuspeaking.uniplugin@1.0.so vendor/lib64/libfocuspeaking.uniplugin@1.0.so
vendor/lib64/libformatConverter.unifunc.so vendor/lib64/libformatConverter.unifunc.so
vendor/lib64/libgaya.so vendor/lib64/libgaya.so
vendor/lib64/libgralloc_helper.unifunc.so
vendor/lib64/libhand_interaction.uniplugin@1.0.so vendor/lib64/libhand_interaction.uniplugin@1.0.so
vendor/lib64/libhandgesture.arcsoft.so vendor/lib64/libhandgesture.arcsoft.so
vendor/lib64/libhdr10plus.so vendor/lib64/libhdr10plus.so
@ -1169,6 +1174,7 @@ vendor/lib64/egl/libq3dtools_adreno.so;SYMLINK=vendor/lib64/libq3dtools_adreno.s
vendor/lib64/egl/libq3dtools_esx.so vendor/lib64/egl/libq3dtools_esx.so
vendor/lib64/libCB.so vendor/lib64/libCB.so
vendor/lib64/libOpenCL.so vendor/lib64/libOpenCL.so
vendor/lib64/libOpenCL_adreno.so
vendor/lib64/libadreno_app_profiles.so vendor/lib64/libadreno_app_profiles.so
vendor/lib64/libadreno_utils.so vendor/lib64/libadreno_utils.so
vendor/lib64/libgpudataproducer.so vendor/lib64/libgpudataproducer.so
@ -1198,15 +1204,7 @@ vendor/bin/hw/vendor.samsung.hardware.health-service
vendor/etc/init/vendor.samsung.hardware.health-service.rc vendor/etc/init/vendor.samsung.hardware.health-service.rc
vendor/lib64/vendor.samsung.hardware.health-V1-ndk.so vendor/lib64/vendor.samsung.hardware.health-V1-ndk.so
# Hyper # HyPer
vendor/bin/hw/vendor.samsung.hardware.hyper-service
vendor/etc/hyper/config_chipset.json
vendor/etc/hyper/config_hyper_permission.json
vendor/etc/hyper/config_vendor.json
vendor/etc/init/hyper-default-sec.rc
vendor/etc/vintf/manifest/hyper-default-sec.xml
vendor/lib64/libhyper.so;MODULE_SUFFIX=_vendor
vendor/lib64/libhypervintf.so
vendor/lib64/vendor.samsung.hardware.hyper-V2-ndk.so vendor/lib64/vendor.samsung.hardware.hyper-V2-ndk.so
# Media # Media
@ -1216,6 +1214,7 @@ vendor/bin/hw/samsung.software.media.c2@1.0-service
vendor/bin/hw/vendor.qti.media.c2@1.0-service vendor/bin/hw/vendor.qti.media.c2@1.0-service
vendor/bin/init.qti.media.sh vendor/bin/init.qti.media.sh
vendor/etc/init/init.qti.media.rc vendor/etc/init/init.qti.media.rc
vendor/etc/init/samsung.software.media.c2@1.0-service.rc
vendor/etc/init/vendor.qti.media.c2@1.0-service.rc vendor/etc/init/vendor.qti.media.c2@1.0-service.rc
vendor/etc/media_codecs.xml vendor/etc/media_codecs.xml
vendor/etc/media_codecs_performance_pineapple.xml vendor/etc/media_codecs_performance_pineapple.xml

View File

@ -79,6 +79,15 @@ on boot
chown system radio /sys/class/sensors/range_sensor/file_p2p chown system radio /sys/class/sensors/range_sensor/file_p2p
chown system radio /sys/class/sensors/range_sensor/file_shape chown system radio /sys/class/sensors/range_sensor/file_shape
# ] Permissions for Range Sensor # ] Permissions for Range Sensor
# mem_boost_mode
chmod 0664 /sys/kernel/mm/vmscan/mem_boost_mode
chown cameraserver system /sys/kernel/mm/vmscan/mem_boost_mode
# rbin mem_boost_mode
chmod 0664 /sys/kernel/rbin/mem_boost_mode
chown cameraserver system /sys/kernel/rbin/mem_boost_mode
on shutdown on shutdown
# service definition # service definition

View File

@ -114,11 +114,3 @@ service factory_ssc /vendor/bin/factory.ssc
on property:sys.boot_completed=1 on property:sys.boot_completed=1
setprop ro.factory.sensor.delay.init 1 setprop ro.factory.sensor.delay.init 1
on property:sys.dexopt.ctrl=true
setprop dalvik.vm.dex2oat-cpu-set "0,1,5,6"
setprop dalvik.vm.dex2oat-threads 4
on property:sys.dexopt.ctrl=false
setprop dalvik.vm.dex2oat-cpu-set ""
set_dex2oat_threads ctrl