├── .clang-format ├── Android.bp ├── Euicc ├── Android.bp ├── AndroidManifest.xml ├── hidden-api-whitelist-org.lineageos.euicc.xml ├── org.lineageos.euicc.xml ├── proguard.flags ├── res │ ├── raw │ │ ├── esim_intro_illustration_lottie.json │ │ └── sim_illustration_lottie_bottom.json │ └── values │ │ └── strings.xml └── src │ └── org │ └── lineageos │ └── euicc │ ├── BootCompletedReceiver.kt │ ├── EuiccDisabler.kt │ └── EuiccReceiver.kt ├── KeyHandler ├── Android.bp ├── AndroidManifest.xml ├── proguard.flags ├── res │ ├── values-ast-rES │ │ └── strings.xml │ ├── values-az │ │ └── strings.xml │ ├── values-bg │ │ └── strings.xml │ ├── values-ca │ │ └── strings.xml │ ├── values-cs │ │ └── strings.xml │ ├── values-cy │ │ └── strings.xml │ ├── values-da │ │ └── strings.xml │ ├── values-de │ │ └── strings.xml │ ├── values-el │ │ └── strings.xml │ ├── values-en-rAU │ │ └── strings.xml │ ├── values-en-rCA │ │ └── strings.xml │ ├── values-en-rGB │ │ └── strings.xml │ ├── values-en-rIN │ │ └── strings.xml │ ├── values-es │ │ └── strings.xml │ ├── values-fa │ │ └── strings.xml │ ├── values-fi │ │ └── strings.xml │ ├── values-fr │ │ └── strings.xml │ ├── values-fur-rIT │ │ └── strings.xml │ ├── values-ga-rIE │ │ └── strings.xml │ ├── values-hu │ │ └── strings.xml │ ├── values-in │ │ └── strings.xml │ ├── values-is │ │ └── strings.xml │ ├── values-it │ │ └── strings.xml │ ├── values-ja │ │ └── strings.xml │ ├── values-ka │ │ └── strings.xml │ ├── values-ko │ │ └── strings.xml │ ├── values-nl │ │ └── strings.xml │ ├── values-pl │ │ └── strings.xml │ ├── values-pt-rBR │ │ └── strings.xml │ ├── values-pt-rPT │ │ └── strings.xml │ ├── values-ro │ │ └── strings.xml │ ├── values-ru │ │ └── strings.xml │ ├── values-sl │ │ └── strings.xml │ ├── values-sq │ │ └── strings.xml │ ├── values-sv │ │ └── strings.xml │ ├── values-tr │ │ └── strings.xml │ ├── values-vi │ │ └── strings.xml │ ├── values-zh-rCN │ │ └── strings.xml │ ├── values-zh-rTW │ │ └── strings.xml │ ├── values │ │ ├── arrays.xml │ │ └── strings.xml │ └── xml │ │ └── button_panel.xml ├── src │ └── org │ │ └── lineageos │ │ └── settings │ │ └── device │ │ ├── ButtonSettingsActivity.kt │ │ ├── ButtonSettingsFragment.kt │ │ ├── ConfigPanelSearchIndexablesProvider.kt │ │ └── KeyHandler.kt ├── tri-state-key-calibrate.rc └── tri-state-key-calibrate.sh ├── README.md ├── aidl ├── commondcs │ ├── Android.bp │ ├── CommonDcsAidlHalService.cpp │ ├── CommonDcsAidlHalService.h │ ├── service.cpp │ ├── vendor.oplus.hardware.commondcs-service.rc │ └── vendor.oplus.hardware.commondcs-service.xml ├── fingerprint │ ├── Android.bp │ ├── Fingerprint.cpp │ ├── Fingerprint.h │ ├── Session.cpp │ ├── Session.h │ ├── android.hardware.biometrics.fingerprint-service.oplus.rc │ ├── android.hardware.biometrics.fingerprint-service.oplus.xml │ └── service.cpp ├── ir │ ├── Android.bp │ ├── ConsumerIr.cpp │ ├── ConsumerIr.h │ ├── android.hardware.ir-service.oplus.rc │ ├── android.hardware.ir-service.xml │ └── service.cpp ├── osense-client │ ├── Android.bp │ ├── OsenseAidlHalReporter.cpp │ ├── OsenseAidlHalReporter.h │ ├── service.cpp │ ├── vendor.oplus.hardware.osense.client-service.rc │ └── vendor.oplus.hardware.osense.client-service.xml ├── powershare │ ├── Android.bp │ ├── PowerShare.cpp │ ├── PowerShare.h │ ├── service.cpp │ ├── vendor.lineage.powershare-service.oplus.rc │ └── vendor.lineage.powershare-service.oplus.xml ├── sensors │ ├── AlsCorrection.cpp │ ├── AlsCorrection.h │ ├── Android.bp │ ├── HalProxy.cpp │ ├── HalProxyCallback.cpp │ ├── als │ │ ├── Android.bp │ │ ├── aidl_api │ │ │ └── vendor.lineage.oplus_als │ │ │ │ ├── 1 │ │ │ │ ├── .hash │ │ │ │ └── vendor │ │ │ │ │ └── lineage │ │ │ │ │ └── oplus_als │ │ │ │ │ ├── AreaRgbCaptureResult.aidl │ │ │ │ │ └── IAreaCapture.aidl │ │ │ │ └── current │ │ │ │ └── vendor │ │ │ │ └── lineage │ │ │ │ └── oplus_als │ │ │ │ ├── AreaRgbCaptureResult.aidl │ │ │ │ └── IAreaCapture.aidl │ │ ├── default │ │ │ ├── .clang-format │ │ │ ├── Android.bp │ │ │ ├── AreaCapture.cpp │ │ │ ├── AreaCapture.h │ │ │ ├── main.cpp │ │ │ ├── vendor.lineage.oplus_als.service.rc │ │ │ └── vendor.lineage.oplus_als.service.xml │ │ └── vendor │ │ │ └── lineage │ │ │ └── oplus_als │ │ │ ├── AreaRgbCaptureResult.aidl │ │ │ └── IAreaCapture.aidl │ ├── android.hardware.sensors-service.oplus-multihal.rc │ ├── android.hardware.sensors.oplus-multihal.xml │ └── service.cpp └── vibrator │ ├── qti │ ├── Android.bp │ ├── Vibrator.cpp │ ├── effect │ │ ├── Android.bp │ │ ├── VibrationEffectConfig.h │ │ ├── effect.cpp │ │ └── effect.h │ ├── include │ │ └── Vibrator.h │ ├── service.cpp │ ├── vendor.qti.hardware.vibrator.service.oplus.rc │ └── vendor.qti.hardware.vibrator.service.oplus.xml │ └── richtap │ ├── Android.bp │ ├── Vibrator.cpp │ ├── Vibrator.h │ ├── aac_vibra_function.h │ ├── android.hardware.vibrator.service.oplus-richtap.rc │ ├── android.hardware.vibrator.service.oplus-richtap.xml │ └── service.cpp ├── audio_amplifier ├── Android.bp └── audio_amplifier.c ├── doze ├── Android.bp ├── AndroidManifest.xml ├── proguard.flags ├── res │ ├── drawable │ │ ├── ic_pickup.xml │ │ └── ic_pocket.xml │ ├── values │ │ ├── arrays.xml │ │ └── config.xml │ └── xml │ │ └── doze_settings.xml └── src │ └── org │ └── lineageos │ └── settings │ └── doze │ ├── BootCompletedReceiver.kt │ ├── DozeService.kt │ ├── DozeSettingsActivity.kt │ ├── DozeSettingsFragment.kt │ ├── PickupSensor.kt │ ├── PocketSensor.kt │ └── Utils.kt ├── fingerprint ├── Android.bp ├── UdfpsExtension.cpp └── shims │ ├── Android.bp │ ├── BiometricsFingerprintShim.cpp │ └── SensorPropsShim.cpp ├── hidl ├── fingerprint │ ├── Android.bp │ ├── BiometricsFingerprint.cpp │ ├── BiometricsFingerprint.h │ ├── android.hardware.biometrics.fingerprint@2.3-service.oplus.rc │ ├── android.hardware.biometrics.fingerprint@2.3-service.oplus.xml │ ├── qwerty.kl │ └── service.cpp ├── livedisplay │ ├── Android.bp │ ├── AntiFlicker.cpp │ ├── DisplayModes.cpp │ ├── SunlightEnhancement.cpp │ ├── include │ │ └── livedisplay │ │ │ └── oplus │ │ │ ├── AntiFlicker.h │ │ │ ├── DisplayModes.h │ │ │ └── SunlightEnhancement.h │ ├── service.cpp │ ├── vendor.lineage.livedisplay@2.1-service.oplus-af.xml │ ├── vendor.lineage.livedisplay@2.1-service.oplus-dm.xml │ ├── vendor.lineage.livedisplay@2.1-service.oplus-pa.xml │ ├── vendor.lineage.livedisplay@2.1-service.oplus-se.xml │ └── vendor.lineage.livedisplay@2.1-service.oplus.rc └── touch │ ├── Android.bp │ ├── HighTouchPollingRate.cpp │ ├── HighTouchPollingRate.h │ ├── TouchscreenGesture.cpp │ ├── TouchscreenGesture.h │ ├── TouchscreenGestureConfig.h │ ├── service.cpp │ ├── vendor.lineage.touch@1.0-service.oplus.rc │ └── vendor.lineage.touch@1.0-service.oplus.xml ├── interfaces ├── Android.bp ├── aidl │ └── vendor │ │ └── oplus │ │ └── hardware │ │ ├── commondcs │ │ ├── ICommonDcsAidlHalService.aidl │ │ └── StringPair.aidl │ │ ├── osense │ │ └── client │ │ │ ├── IOsenseAidlHalReporter.aidl │ │ │ ├── OsenseAidlHalNotifyRequest.aidl │ │ │ ├── OsenseAidlHalSaRequest.aidl │ │ │ ├── OsenseControlInfo.aidl │ │ │ ├── OsenseCpuControlData.aidl │ │ │ ├── OsenseCpuMIGData.aidl │ │ │ ├── OsenseDataRange.aidl │ │ │ └── OsenseGpuControlData.aidl │ │ └── touch │ │ ├── IOplusTouch.aidl │ │ └── OplusTouchInfo.aidl ├── aidl_api │ ├── vendor.oplus.hardware.commondcs │ │ ├── 1 │ │ │ ├── .hash │ │ │ └── vendor │ │ │ │ └── oplus │ │ │ │ └── hardware │ │ │ │ └── commondcs │ │ │ │ ├── ICommonDcsAidlHalService.aidl │ │ │ │ └── StringPair.aidl │ │ └── current │ │ │ └── vendor │ │ │ └── oplus │ │ │ └── hardware │ │ │ └── commondcs │ │ │ ├── ICommonDcsAidlHalService.aidl │ │ │ └── StringPair.aidl │ ├── vendor.oplus.hardware.osense.client │ │ ├── 1 │ │ │ ├── .hash │ │ │ └── vendor │ │ │ │ └── oplus │ │ │ │ └── hardware │ │ │ │ └── osense │ │ │ │ └── client │ │ │ │ ├── IOsenseAidlHalReporter.aidl │ │ │ │ ├── OsenseAidlHalNotifyRequest.aidl │ │ │ │ ├── OsenseAidlHalSaRequest.aidl │ │ │ │ ├── OsenseControlInfo.aidl │ │ │ │ ├── OsenseCpuControlData.aidl │ │ │ │ ├── OsenseCpuMIGData.aidl │ │ │ │ ├── OsenseDataRange.aidl │ │ │ │ └── OsenseGpuControlData.aidl │ │ └── current │ │ │ └── vendor │ │ │ └── oplus │ │ │ └── hardware │ │ │ └── osense │ │ │ └── client │ │ │ ├── IOsenseAidlHalReporter.aidl │ │ │ ├── OsenseAidlHalNotifyRequest.aidl │ │ │ ├── OsenseAidlHalSaRequest.aidl │ │ │ ├── OsenseControlInfo.aidl │ │ │ ├── OsenseCpuControlData.aidl │ │ │ ├── OsenseCpuMIGData.aidl │ │ │ ├── OsenseDataRange.aidl │ │ │ └── OsenseGpuControlData.aidl │ └── vendor.oplus.hardware.touch │ │ ├── 1 │ │ ├── .hash │ │ └── vendor │ │ │ └── oplus │ │ │ └── hardware │ │ │ └── touch │ │ │ └── IOplusTouch.aidl │ │ ├── 2 │ │ ├── .hash │ │ └── vendor │ │ │ └── oplus │ │ │ └── hardware │ │ │ └── touch │ │ │ ├── IOplusTouch.aidl │ │ │ └── OplusTouchInfo.aidl │ │ └── current │ │ └── vendor │ │ └── oplus │ │ └── hardware │ │ └── touch │ │ ├── IOplusTouch.aidl │ │ └── OplusTouchInfo.aidl ├── oplus │ └── hardware │ │ └── biometrics │ │ └── fingerprint │ │ └── 2.1 │ │ ├── Android.bp │ │ ├── IBiometricsFingerprint.hal │ │ └── IBiometricsFingerprintClientCallbackEx.hal └── update-makefiles.sh ├── kernel-headers ├── Android.bp └── include │ └── oplus │ ├── oplus_display_panel.h │ └── oplus_ir_core.h ├── oplus-fwk ├── Android.bp ├── oplus-fwk.mk └── src │ ├── android │ ├── app │ │ ├── OplusActivityManager.java │ │ ├── OplusWhiteListManager.java │ │ └── job │ │ │ └── IJobInfoExt.java │ ├── bluetooth │ │ └── OplusBluetoothAdapter.java │ ├── common │ │ ├── IOplusCommonFactory.java │ │ ├── IOplusCommonFeature.java │ │ ├── OplusFeatureList.java │ │ └── OplusFrameworkFactory.java │ ├── content │ │ └── res │ │ │ └── OplusBaseConfiguration.java │ ├── hardware │ │ └── camera2 │ │ │ ├── IOplusCameraManager.java │ │ │ └── OplusCameraManager.java │ ├── os │ │ ├── OplusKeyEventManager.java │ │ ├── OplusManager.java │ │ └── OplusSystemProperties.java │ ├── telephony │ │ └── OplusTelephonyManager.java │ └── view │ │ ├── OplusWindowManager.java │ │ └── animation │ │ ├── OplusBezierInterpolator.java │ │ └── OplusUnitBezier.java │ ├── com │ ├── android │ │ ├── ims │ │ │ └── IImsCallSessionImplWrapper.java │ │ ├── internal │ │ │ └── telephony │ │ │ │ ├── OplusFeature.java │ │ │ │ └── OplusFeatureHelper.java │ │ └── telephony │ │ │ └── ims │ │ │ └── aidl │ │ │ └── IImsRil.aidl │ └── oplus │ │ ├── app │ │ ├── OPlusAccessControlManager.java │ │ ├── OplusAppEnterInfo.java │ │ ├── OplusAppExitInfo.java │ │ ├── OplusAppInfo.java │ │ ├── OplusAppSwitchConfig.java │ │ └── OplusAppSwitchManager.java │ │ ├── content │ │ └── OplusFeatureConfigManager.java │ │ ├── flexiblewindow │ │ └── FlexibleTaskView.java │ │ ├── ims │ │ ├── IImsExt.aidl │ │ └── stub │ │ │ └── ImsServiceControllerExt.java │ │ ├── nec │ │ └── IOplusNecManager.java │ │ ├── orms │ │ ├── OplusResourceManager.java │ │ └── info │ │ │ └── OrmsSaParam.java │ │ ├── os │ │ ├── OplusBuild.java │ │ ├── OplusUsbEnvironment.java │ │ └── WaveformEffect.java │ │ ├── osense │ │ ├── OsenseResClient.java │ │ ├── OsenseResEventClient.java │ │ └── eventinfo │ │ │ ├── IOsenseEventCallback.java │ │ │ └── OsenseEventCallback.java │ │ ├── screenshot │ │ ├── OplusLongshotCustomController.java │ │ ├── OplusLongshotViewBase.java │ │ └── OplusLongshowViewInfo.java │ │ ├── uifirst │ │ └── OplusUIFirstManager.java │ │ ├── util │ │ ├── OplusChangeTextUtil.java │ │ └── OplusNetworkUtil.java │ │ ├── wrapper │ │ ├── os │ │ │ ├── PowerManager.java │ │ │ ├── ServiceManager.java │ │ │ └── SystemProperties.java │ │ └── view │ │ │ └── IWindowManager.java │ │ └── zoomwindow │ │ ├── IOplusZoomWindowObserver.aidl │ │ ├── OplusZoomWindowInfo.aidl │ │ ├── OplusZoomWindowInfo.java │ │ └── OplusZoomWindowManager.java │ ├── net │ └── oneplus │ │ └── odm │ │ └── OpDeviceManagerInjector.java │ └── oplus │ └── content │ └── res │ └── OplusExtraConfiguration.java ├── overlay ├── generic │ ├── Android.bp │ ├── FrameworksResGeneric │ │ ├── Android.bp │ │ ├── AndroidManifest.xml │ │ └── res │ │ │ └── values │ │ │ └── config.xml │ ├── SettingsProviderResGeneric │ │ ├── Android.bp │ │ ├── AndroidManifest.xml │ │ └── res │ │ │ └── values │ │ │ └── defaults.xml │ └── generic.mk └── qssi │ ├── Android.bp │ ├── FrameworksResCommon │ ├── Android.bp │ ├── AndroidManifest.xml │ └── res │ │ ├── values-mcc234-mnc15-en-rGB │ │ └── config.xml │ │ ├── values-mcc234-mnc15-en-rIN │ │ └── config.xml │ │ ├── values-mcc234-mnc15 │ │ └── config.xml │ │ ├── values-mcc262-mnc2-en-rGB │ │ └── config.xml │ │ ├── values-mcc262-mnc2-en-rIN │ │ └── config.xml │ │ ├── values-mcc262-mnc2 │ │ └── config.xml │ │ ├── values-mcc262-mnc4-en-rGB │ │ └── config.xml │ │ ├── values-mcc262-mnc4-en-rIN │ │ └── config.xml │ │ ├── values-mcc262-mnc4 │ │ └── config.xml │ │ ├── values-mcc262-mnc9-en-rGB │ │ └── config.xml │ │ ├── values-mcc262-mnc9-en-rIN │ │ └── config.xml │ │ ├── values-mcc262-mnc9 │ │ └── config.xml │ │ ├── values-mcc310-mnc120 │ │ └── config.xml │ │ ├── values-mcc310-mnc260 │ │ └── config.xml │ │ ├── values-mcc310-mnc4 │ │ └── config.xml │ │ ├── values-mcc310-mnc410 │ │ └── config.xml │ │ ├── values-mcc311-mnc480 │ │ ├── bools.xml │ │ └── config.xml │ │ ├── values-mcc460-mnc11 │ │ └── config.xml │ │ ├── values-mcc460-mnc3 │ │ └── config.xml │ │ └── values │ │ └── config.xml │ ├── OPlusWifiResCommon │ ├── Android.bp │ ├── AndroidManifest.xml │ └── res │ │ └── values │ │ └── config.xml │ ├── SystemUIResCommon │ ├── Android.bp │ ├── AndroidManifest.xml │ └── res │ │ └── values │ │ └── config.xml │ ├── TelephonyResCommon │ ├── Android.bp │ ├── AndroidManifest.xml │ └── res │ │ └── values │ │ └── config.xml │ ├── WifiResCommon │ ├── Android.bp │ ├── AndroidManifest.xml │ └── res │ │ └── values │ │ └── config.xml │ └── qssi.mk ├── sensors ├── Android.bp ├── Sensor.cpp ├── Sensor.h ├── SensorsSscCustomFlag.cpp ├── SensorsSubHal.cpp └── SensorsSubHal.h ├── sepolicy └── qti │ ├── SEPolicy.mk │ ├── private │ ├── compat │ │ ├── 32.0 │ │ │ └── 32.0.ignore.cil │ │ └── 33.0 │ │ │ └── 33.0.ignore.cil │ ├── file_contexts │ ├── hal_lineage_oplus_als_aidl.te │ ├── property_contexts │ └── service_contexts │ ├── public │ ├── attributes │ ├── file.te │ ├── property.te │ ├── service.te │ └── te_macros │ └── vendor │ ├── attributes │ ├── common-um │ ├── hal_fingerprint_default.te │ └── rild.te │ ├── device.te │ ├── fastbootd.te │ ├── file.te │ ├── file_contexts │ ├── genfs_contexts │ ├── hal_audio_default.te │ ├── hal_bluetooth_default.te │ ├── hal_bootctl.te │ ├── hal_camera_default.te │ ├── hal_face_default.te │ ├── hal_fingerprint_default.te │ ├── hal_graphics_composer_default.te │ ├── hal_ir_default.te │ ├── hal_lineage_livedisplay_qti.te │ ├── hal_lineage_powershare_default.te │ ├── hal_lineage_touch_default.te │ ├── hal_nfc_default.te │ ├── hal_oplus_cammidasservice_aidl.te │ ├── hal_oplus_commondcs_aidl.te │ ├── hal_oplus_osense_aidl.te │ ├── hal_oplus_performance_aidl.te │ ├── hal_oplus_project_aidl.te │ ├── hal_oplus_touch_aidl.te │ ├── hal_oplus_touchdaemon.te │ ├── hal_oplus_urcc_aidl.te │ ├── hal_power_default.te │ ├── hal_secure_element_default.te │ ├── hal_sensors_default.te │ ├── hal_vibrator_default.te │ ├── hwservice.te │ ├── hwservice_contexts │ ├── init.te │ ├── kernel.te │ ├── legacy-um │ ├── file_contexts │ ├── genfs_contexts │ ├── vendor_hal_qteeconnector_qti.te │ ├── vendor_qti_init_shell.te │ ├── vndservice.te │ └── vndservice_contexts │ ├── mediacodec.te │ ├── property.te │ ├── property_contexts │ ├── rild.te │ ├── service.te │ ├── service_contexts │ ├── sm8450 │ ├── file_contexts │ ├── hal_face_default.te │ └── vendor_agmservice_qti.te │ ├── sm8550 │ ├── file_contexts │ └── hal_face_default.te │ ├── system_server.te │ ├── tee.te │ ├── tri-state-key-calibrate.te │ ├── ueventd.te │ ├── update_engine_common.te │ ├── vendor_hal_cameraMDM_default.te │ ├── vendor_hal_oplusSensor_aidl.te │ ├── vendor_hal_oplusSensor_default.te │ ├── vendor_hal_perf_default.te │ ├── vendor_init.te │ ├── vendor_mdm_helper.te │ ├── vendor_poweroffalarm_app.te │ ├── vendor_qtelephony.te │ ├── vendor_qti_init_shell.te │ ├── vendor_rmt_storage.te │ ├── vendor_sensors.te │ ├── vendor_thermal-engine.te │ ├── vendor_wcnss_service.te │ ├── vendor_wvmkiller.te │ ├── vl53l1_daemon_main.te │ ├── vndservice.te │ ├── vndservice_contexts │ ├── vndservicemanager.te │ └── wlchgmonitor.te ├── usb ├── Android.bp └── usb_compositions.conf ├── vintf └── device_framework_matrix.xml └── wvmkiller ├── Android.bp ├── main.cpp └── wvmkiller.rc /.clang-format: -------------------------------------------------------------------------------- 1 | ../../build/soong/scripts/system-clang-format -------------------------------------------------------------------------------- /Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // SPDX-FileCopyrightText: 2022-2025 The LineageOS Project 3 | // SPDX-License-Identifier: Apache-2.0 4 | // 5 | 6 | soong_namespace { 7 | imports: [ 8 | "hardware/google/interfaces", 9 | "hardware/google/pixel", 10 | ], 11 | } 12 | 13 | prebuilt_hidl_interfaces { 14 | name: "hidl_oplus_cameraextension_interface", 15 | interfaces: [ 16 | "vendor.oplus.hardware.cameraextension@1.0::ICameraExtensionService", 17 | ], 18 | } 19 | 20 | prebuilt_hidl_interfaces { 21 | name: "hidl_pixelworks_feature_interface", 22 | interfaces: [ 23 | "vendor.pixelworks.hardware.feature@1.0::IIrisFeature", 24 | ], 25 | } 26 | -------------------------------------------------------------------------------- /Euicc/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2023 The LineageOS Project 3 | // 4 | // SPDX-License-Identifier: Apache-2.0 5 | // 6 | 7 | android_app { 8 | name: "OplusEuicc", 9 | 10 | srcs: ["src/**/*.kt"], 11 | 12 | sdk_version: "current", 13 | product_specific: true, 14 | certificate: "platform", 15 | privileged: true, 16 | 17 | optimize: { 18 | proguard_flags_files: ["proguard.flags"], 19 | }, 20 | required: [ 21 | "org.lineageos.euicc.xml", 22 | "hidden-api-whitelist-org.lineageos.euicc.xml", 23 | ], 24 | } 25 | 26 | prebuilt_etc { 27 | name: "org.lineageos.euicc.xml", 28 | relative_install_path: "permissions", 29 | filename: "org.lineageos.euicc.xml", 30 | src: "org.lineageos.euicc.xml", 31 | product_specific: true, 32 | } 33 | 34 | prebuilt_etc { 35 | name: "hidden-api-whitelist-org.lineageos.euicc.xml", 36 | relative_install_path: "sysconfig", 37 | filename: "hidden-api-whitelist-org.lineageos.euicc.xml", 38 | src: "hidden-api-whitelist-org.lineageos.euicc.xml", 39 | product_specific: true, 40 | } 41 | -------------------------------------------------------------------------------- /Euicc/hidden-api-whitelist-org.lineageos.euicc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /Euicc/org.lineageos.euicc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /Euicc/proguard.flags: -------------------------------------------------------------------------------- 1 | -keep class org.lineageos.euicc.* { 2 | *; 3 | } 4 | -------------------------------------------------------------------------------- /Euicc/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | {\"sim_illustration_lottie_mappings\":[{\"devices\":[\"OP594DL1\"],\"illustration_lottie\":\"sim_illustration_lottie_bottom\"}]} 8 | {\"sim-slot-mappings\":[{\"devices\":[\"OP594DL1\"],\"esim-slot-ids\":[1],\"psim-slot-ids\":[0]}]} 9 | 10 | -------------------------------------------------------------------------------- /Euicc/src/org/lineageos/euicc/BootCompletedReceiver.kt: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2021 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package org.lineageos.euicc 7 | 8 | import android.content.BroadcastReceiver 9 | import android.content.Context 10 | import android.content.Intent 11 | import android.util.Log 12 | 13 | class BootCompletedReceiver : BroadcastReceiver() { 14 | override fun onReceive(context: Context, intent: Intent) { 15 | Log.d(TAG, "Received boot completed intent") 16 | EuiccDisabler.enableOrDisableEuicc(context) 17 | } 18 | 19 | companion object { 20 | private const val TAG = "OplusEuiccBootReceiver" 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Euicc/src/org/lineageos/euicc/EuiccReceiver.kt: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2023 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package org.lineageos.euicc 7 | 8 | import android.content.BroadcastReceiver 9 | import android.content.Context 10 | import android.content.Intent 11 | import android.util.Log 12 | 13 | class EuiccReceiver : BroadcastReceiver() { 14 | override fun onReceive(context: Context, intent: Intent) { 15 | Log.d(TAG, "Received PARTNER_CUSTOMIZATION intent") 16 | } 17 | 18 | companion object { 19 | private const val TAG = "OplusEuiccReceiver" 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /KeyHandler/Android.bp: -------------------------------------------------------------------------------- 1 | android_app { 2 | name: "KeyHandler", 3 | 4 | srcs: ["src/**/*.kt"], 5 | 6 | certificate: "platform", 7 | platform_apis: true, 8 | system_ext_specific: true, 9 | 10 | static_libs: [ 11 | "org.lineageos.settings.resources", 12 | ], 13 | 14 | optimize: { 15 | proguard_flags_files: ["proguard.flags"], 16 | }, 17 | } 18 | 19 | sh_binary { 20 | name: "tri-state-key-calibrate", 21 | init_rc: ["tri-state-key-calibrate.rc"], 22 | src: "tri-state-key-calibrate.sh", 23 | vendor: true, 24 | } 25 | -------------------------------------------------------------------------------- /KeyHandler/proguard.flags: -------------------------------------------------------------------------------- 1 | -keep class org.lineageos.settings.device.* { 2 | *; 3 | } 4 | -------------------------------------------------------------------------------- /KeyHandler/res/values-ast-rES/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Eslizador pa les alertes 8 | Aición 9 | Posición cimera 10 | Posición central 11 | Posición baxera 12 | Nada 13 | Silenciu 14 | Normal 15 | Vibración 16 | Namás con prioridá 17 | Silenciu total 18 | Namás les alarmes 19 | Desactivar el soníu multimedia 20 | Desactiva\'l soníu de los elementos multimedia al cambiar a «Silenciu» 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-az/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Xəbərdarlıq diyircəyi 8 | Hərəkət 9 | Üst mövqe 10 | Orta mövqe 11 | Alt mövqe 12 | Heç biri 13 | Səssiz 14 | Normal 15 | Titrəmə 16 | Yalnız prioritet 17 | Tam səssizlik 18 | Yalnız zəngli saatlar 19 | Media səsi yoxdur 20 | Səssizə keçərkən medianı səssizə al 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-bg/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Плъзгач за предупреждение 8 | Действие 9 | Горна позиция 10 | Средна позиция 11 | Долна позиция 12 | Нищо 13 | Без звук 14 | Нормален 15 | Вибрация 16 | Само важни 17 | Тотална тишина 18 | Само будилници 19 | Заглуши 20 | Заглуши само когато се превключва в тих режим 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-ca/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Control lliscant d\'alerta 8 | Acció 9 | Posició superior 10 | Posició central 11 | Posició inferior 12 | Cap 13 | Silenci 14 | Normal 15 | Vibració 16 | Només prioritat 17 | Silenci total 18 | Només alarmes 19 | Silencia la multimèdia 20 | Silencia el contingut multimèdia quan canvieu a silenci 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-cs/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Posuvník oznámení 8 | Akce 9 | Pozice nahoře 10 | Pozice uprostřed 11 | Pozice dole 12 | Žádný 13 | Tichý 14 | Normální 15 | Vibrace 16 | Pouze prioritní 17 | Úplné ticho 18 | Pouze budíky 19 | Ztlumit média 20 | Ztlumit média při přechodu na tichý režim 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-cy/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Llithridd rhybuddion 8 | Gweithred 9 | Lleoliad brig 10 | Lleoliad canol 11 | Lleoliad gwaelod 12 | Dim 13 | Distaw 14 | Arferol 15 | Dirgryniad 16 | Blaenoriaeth yn unig 17 | Distawrwydd llwyr 18 | Larymau yn unig 19 | Tewi cyfryngau 20 | Tewi cyfryngau wrth newid i ddistaw 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-da/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Ingen 8 | 9 | -------------------------------------------------------------------------------- /KeyHandler/res/values-de/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Alarmschieberegler 8 | Aktion 9 | Obere Position 10 | Mittlere Position 11 | Untere Position 12 | Keine 13 | Lautlos 14 | Normal 15 | Vibration 16 | Nur Priorität 17 | Völlige Stille 18 | Nur Alarme 19 | Medien stumm 20 | Bei Stummschaltung auch Medien stummschalten 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-el/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Διακόπτης ειδοποιήσεων 8 | Ενέργεια 9 | Πάνω θέση 10 | Μεσαία θέση 11 | Κάτω θέση 12 | Τίποτα 13 | Αθόρυβο 14 | Κανονικό 15 | Δόνηση 16 | Μόνο προτεραιότητας 17 | Πλήρης σίγαση 18 | Μόνο ξυπνητήρια 19 | Σίγαση πολυμέσων 20 | Σίγαση πολυμέσων κατά την εναλλαγή σε αθόρυβο 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-en-rAU/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Alert slider 8 | Action 9 | Top position 10 | Middle position 11 | Bottom position 12 | None 13 | Silent 14 | Normal 15 | Vibration 16 | Priority only 17 | Total silence 18 | Alarms only 19 | Mute media 20 | Mute media when switching to silent 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-en-rCA/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Alert slider 8 | Action 9 | Top position 10 | Middle position 11 | Bottom position 12 | None 13 | Silent 14 | Normal 15 | Vibration 16 | Priority only 17 | Total silence 18 | Alarms only 19 | Mute media 20 | Mute media when switching to silent 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-en-rGB/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Alert slider 8 | Action 9 | Top position 10 | Middle position 11 | Bottom position 12 | None 13 | Silent 14 | Normal 15 | Vibration 16 | Priority only 17 | Total silence 18 | Alarms only 19 | Mute media 20 | Mute media when switching to silent 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-en-rIN/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Alert slider 8 | Action 9 | Top position 10 | Middle position 11 | Bottom position 12 | None 13 | Silent 14 | Normal 15 | Vibration 16 | Priority only 17 | Total silence 18 | Alarms only 19 | Mute media 20 | Mute media when switching to silent 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-es/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Control deslizante de alertas 8 | Acción 9 | Posición superior 10 | Posición central 11 | Posición inferior 12 | Ninguno 13 | Silencio 14 | Normal 15 | Vibración 16 | Solo prioritarias 17 | Silencio total 18 | Solo alarmas 19 | Silenciar multimedia 20 | Silenciar multimedia al activar el modo silencio 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-fa/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | نوار لغزنده هشدار 8 | عمل 9 | موقعیت بالا 10 | موقعیت وسط 11 | موقعیت پایین 12 | هیچ 13 | بی‌صدا 14 | عادی 15 | لرزش 16 | فقط اولویت ها 17 | سکوت کامل 18 | فقط هشدار ها 19 | رسانه بی صدا 20 | هنگام جابجایی به بی‌صدا، رسانه را بی‌صدا کنید 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-fi/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Mykistä media 8 | Mykistä media kun vaihdetaan äänettömään tilaan. 9 | 10 | -------------------------------------------------------------------------------- /KeyHandler/res/values-fr/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Curseur d\'alerte 8 | Action 9 | En haut 10 | Au milieu 11 | En bas 12 | Aucun 13 | Silencieux 14 | Normal 15 | Vibration 16 | Prioritaires uniquement 17 | Silence total 18 | Alarmes uniquement 19 | Couper le son du média 20 | Couper le son du média lors du passage en mode silencieux 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-fur-rIT/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Cursôr notifichis 8 | Azion 9 | Posizion superiôr 10 | Posizion centrâl 11 | Posizion inferiôr 12 | Nissune 13 | Cidin 14 | Normâl 15 | Vibrazion 16 | Dome prioritâts 17 | Cidin dal dut 18 | Dome sveis 19 | Cidine il multimedia 20 | Cidine i multimedia se tu passis ae modalitât cidine 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-ga-rIE/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Sleamhnán foláirimh 8 | Gníomh 9 | Seasamh barr 10 | Seasamh meánach 11 | Seasamh bun 12 | Dada 13 | Ciúin 14 | Gnáth 15 | Creathadh 16 | Tosaíocht amháin 17 | Ciúnas iomlán 18 | Aláraim amháin 19 | Balbhaigh meáin 20 | Balbhaigh na meáin nuair a bhíonn tú ag aistriú chuig an gciúin 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-hu/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Riasztási csúszka 8 | Művelet 9 | Felül 10 | Középen 11 | Alul 12 | Egyik sem 13 | Néma 14 | Normális 15 | Rezgés 16 | Csak a fontosak 17 | Teljes némítás 18 | Csak az ébresztések 19 | Médianémítás 20 | Médianémítás csendesre váltáskor 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-in/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Tindakan 8 | Posisi atas 9 | Posisi tengah 10 | Posisi bawah 11 | Tidak ada 12 | Senyap 13 | Normal 14 | Getaran 15 | Hanya prioritas 16 | Senyap total 17 | Hanya alarm 18 | 19 | -------------------------------------------------------------------------------- /KeyHandler/res/values-is/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Aðvaranasleði 8 | Aðgerð 9 | Staða efst 10 | Miðjustaða 11 | Staða neðst 12 | Ekkert 13 | Hljóðlaust 14 | Venjulegt 15 | Titringur 16 | Aðeins í forgangi 17 | Algjör þögn 18 | Aðeins áminningar 19 | Þagga niður margmiðlun 20 | Þagga niður efni þegar skipt er í hljóðlaust 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-it/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Slider notifiche 8 | Azione 9 | Posizione superiore 10 | Posizione centrale 11 | Posizione inferiore 12 | Nessuna 13 | Silenzioso 14 | Normale 15 | Vibrazione 16 | Solo priorità 17 | Silenzio totale 18 | Solo sveglie 19 | Silenzia media 20 | Silenzia i media quando si passa alla modalità silenziosa 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-ja/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | アラートスライダー 8 | 動作 9 | 上部 10 | 中央 11 | 下部 12 | なし 13 | サイレント 14 | 標準 15 | バイブ 16 | 重要な通知のみ 17 | 完全サイレント 18 | アラームのみ 19 | メディアをミュート 20 | サイレントモードに切り替えたときにメディア音量をミュートします 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-ka/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | გაფრთხილების სრიალა 8 | მოქმედება 9 | ზედა მდებარეობა 10 | შუა მდებარეობა 11 | ქვედა მდებარეობა 12 | არცერთი 13 | უხმო 14 | ჩვეულებრივი 15 | ვიბრაცია 16 | მხოლოდ უპირატესი 17 | სრულიად უხმო 18 | მხოლოდ მაღვიძარები 19 | ფაილის დადუმება 20 | ფაილის დადუმება უხმოზე გადართვისას 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-ko/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 알림 슬라이더 8 | 동작 9 | 슬라이더가 위쪽에 있을 때 10 | 슬라이더가 중간에 있을 때 11 | 슬라이더가 아래에 있을 때 12 | 없음 13 | 무음 14 | 일반 15 | 진동 16 | 중요 알림만 17 | 완전 무음 18 | 알람만 19 | 미디어 볼륨 음소거 20 | 무음으로 전환할 때 미디어 볼륨 음소거 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-nl/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Schuifregelaar meldingen 8 | Actie 9 | Bovenste positie 10 | Middelste positie 11 | Onderste positie 12 | Geen 13 | Stil 14 | Normaal 15 | Trillen 16 | Alleen prioriteit 17 | Totale stilte 18 | Alleen alarmen 19 | Media dempen 20 | Media dempen bij overschakelen naar stil 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-pl/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Suwak alarmowy 8 | Akcja 9 | Górna pozycja 10 | Środkowa pozycja 11 | Dolna pozycja 12 | Brak 13 | Cichy 14 | Normalny 15 | Wibracje 16 | Tylko priorytetowe 17 | Całkowita cisza 18 | Tylko alarmy 19 | Wycisz multimedia 20 | Wycisz multimedia po przełączeniu na Cichy 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-pt-rBR/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Controle deslizante de alerta 8 | Ação 9 | Em cima 10 | No centro 11 | Em baixo 12 | Nenhum 13 | Silencioso 14 | Normal 15 | Vibração 16 | Somente prioridade 17 | Silêncio total 18 | Somente alarmes 19 | Silenciar mídia 20 | Silenciar mídia ao mudar para o modo silencioso 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-pt-rPT/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Botão deslizante 8 | Ação 9 | Para cima 10 | No meio 11 | Em baixo 12 | Nenhum 13 | Silencioso 14 | Normal 15 | Vibração 16 | Apenas prioritárias 17 | Silêncio total 18 | Apenas alarmes 19 | Silenciar multimédia 20 | Silenciar multimédia ao ativar modo silencioso 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-ro/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Alert slider 8 | Acțiune 9 | Sus 10 | Mijloc 11 | Jos 12 | Niciuna 13 | Silențios 14 | Normal 15 | Vibrație 16 | Numai cu prioritate 17 | Niciun sunet 18 | Numai alarme 19 | Fără sunet media 20 | Fără sunet media când se schimbă la silențios 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-ru/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Переключатель оповещений 8 | Действие 9 | Верхнее положение 10 | Среднее положение 11 | Нижнее положение 12 | Ничего 13 | Без звука 14 | Обычный 15 | Вибрация 16 | Только важные 17 | Полная тишина 18 | Только будильник 19 | Выключить звук медиа 20 | Отключение звука мультимедиа при переключении на беззвучный режим 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-sl/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Drsnik za opozorila 8 | Dejanje 9 | Zgornji položaj 10 | Srednji položaj 11 | Spodnji položaj 12 | Brez 13 | Tiho 14 | Običajno 15 | Vibriranje 16 | Samo prednostno 17 | Popolna tišina 18 | Samo budilke 19 | Utišaj predstavnost 20 | Utišaj predstavnost med preklapljanjem na tiho 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-sq/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Rrëshqitësi i alarmit 8 | Veprimi 9 | Pozicioni i lartë 10 | Pozicioni i mesëm 11 | Pozicioni i poshtëm 12 | Asnjë 13 | Pa zë 14 | Normal 15 | Dridhje 16 | Vetëm kryesoret 17 | Heshtje e plotë 18 | Vetëm alarmet 19 | Hesht median 20 | Çaktivizo median kur kalon në heshtje 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-sv/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Åtgärd 8 | Inget 9 | Normal 10 | Vibration 11 | Endast prioritet 12 | Endast alarm 13 | 14 | -------------------------------------------------------------------------------- /KeyHandler/res/values-tr/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Uyarı kaydırıcısı 8 | Eylem 9 | Üst konum 10 | Orta konum 11 | Alt konum 12 | Hiçbiri 13 | Sessiz 14 | Normal 15 | Titreşim 16 | Sadece öncelik 17 | Tam sessizlik 18 | Yalnızca alarmlar 19 | Medyayı sustur 20 | Sessize geçerken medyayı sustur 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-vi/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | Thanh trượt cảnh báo 8 | Thao tác 9 | Vị trí trên cùng 10 | Vị trí giữa 11 | Vị trí dưới cùng 12 | Không có 13 | Im lặng 14 | Bình thường 15 | Rung 16 | Chỉ ưu tiên 17 | Hoàn toàn im lặng 18 | Chỉ báo thức 19 | Tắt tiếng phương tiện 20 | Tắt tiếng phương tiện khi chuyển sang chế độ im lặng 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-zh-rCN/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 警报滑块 8 | 操作 9 | 顶部位置 10 | 中间位置 11 | 底部位置 12 | 13 | 静音 14 | 正常 15 | 振动 16 | 仅限优先 17 | 完全静音 18 | 仅限闹钟 19 | 静音,包括媒体音量 20 | 切换静音同时静音媒体 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values-zh-rTW/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 警示滑桿 8 | 動作 9 | 頂部位置 10 | 中間位置 11 | 底部位置 12 | 13 | 靜音 14 | 一般 15 | 震動 16 | 僅限優先 17 | 一律靜音 18 | 僅限鬧鐘 19 | 靜音,包括媒體 20 | 切換靜音時靜音媒體 21 | 22 | -------------------------------------------------------------------------------- /KeyHandler/res/values/arrays.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | @string/alert_slider_mode_none 9 | @string/alert_slider_mode_normal 10 | @string/alert_slider_mode_vibration 11 | @string/alert_slider_mode_silent 12 | @string/alert_slider_mode_dnd_priority_only 13 | @string/alert_slider_mode_dnd_total_silence 14 | @string/alert_slider_mode_dnd_alarms_only 15 | 16 | 17 | 18 | -1 19 | 2 20 | 1 21 | 0 22 | 3 23 | 4 24 | 5 25 | 26 | 27 | -------------------------------------------------------------------------------- /KeyHandler/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | Alert slider 9 | Action 10 | Top position 11 | Middle position 12 | Bottom position 13 | None 14 | Silent 15 | Normal 16 | Vibration 17 | Priority only 18 | Total silence 19 | Alarms only 20 | Mute media 21 | Mute media when switching to silent 22 | 23 | -------------------------------------------------------------------------------- /KeyHandler/src/org/lineageos/settings/device/ButtonSettingsActivity.kt: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2021-2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package org.lineageos.settings.device 7 | 8 | import android.os.Bundle 9 | 10 | import com.android.settingslib.collapsingtoolbar.CollapsingToolbarBaseActivity 11 | 12 | class ButtonSettingsActivity : CollapsingToolbarBaseActivity() { 13 | public override fun onCreate(savedInstanceState: Bundle?) { 14 | super.onCreate(savedInstanceState) 15 | fragmentManager.beginTransaction().replace( 16 | com.android.settingslib.collapsingtoolbar.R.id.content_frame, 17 | ButtonSettingsFragment() 18 | ).commit() 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /KeyHandler/src/org/lineageos/settings/device/ButtonSettingsFragment.kt: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2021 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package org.lineageos.settings.device 7 | 8 | import android.os.Bundle 9 | import android.view.MenuItem 10 | import androidx.preference.PreferenceFragment 11 | 12 | class ButtonSettingsFragment : PreferenceFragment() { 13 | override fun onCreatePreferences(savedInstanceState: Bundle?, rootKey: String?) { 14 | addPreferencesFromResource(R.xml.button_panel) 15 | activity.actionBar!!.setDisplayHomeAsUpEnabled(true) 16 | } 17 | 18 | override fun addPreferencesFromResource(preferencesResId: Int) { 19 | super.addPreferencesFromResource(preferencesResId) 20 | } 21 | 22 | override fun onOptionsItemSelected(item: MenuItem): Boolean { 23 | when (item.itemId) { 24 | R.id.home -> { 25 | activity.finish() 26 | return true 27 | } 28 | } 29 | return super.onOptionsItemSelected(item) 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /KeyHandler/tri-state-key-calibrate.rc: -------------------------------------------------------------------------------- 1 | service vendor.tri-state-key-calibrate /vendor/bin/tri-state-key-calibrate 2 | class main 3 | user system 4 | group system 5 | oneshot 6 | disabled 7 | 8 | on post-fs-data 9 | start vendor.tri-state-key-calibrate 10 | -------------------------------------------------------------------------------- /KeyHandler/tri-state-key-calibrate.sh: -------------------------------------------------------------------------------- 1 | #!/vendor/bin/sh 2 | if [[ -f /mnt/vendor/persist/engineermode/tri_state_hall_data ]]; then 3 | CALIBRATION_DATA="$(cat /mnt/vendor/persist/engineermode/tri_state_hall_data)" 4 | CALIBRATION_DATA="${CALIBRATION_DATA//;/,}" 5 | echo -n $CALIBRATION_DATA > /proc/tristatekey/hall_data_calib 6 | fi 7 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # hardware/oplus 2 | 3 | ## Soong options 4 | 5 | | Namespace | Variable | Description | Default | 6 | | --------- | -------- | ----------- | ------- | 7 | | OPLUS_LINEAGE_LIVEDISPLAY_HAL | ENABLE_AF | Enable AntiFlicker feature | false | 8 | | OPLUS_LINEAGE_LIVEDISPLAY_HAL | ENABLE_DM | Enable DisplayModes feature | false | 9 | | OPLUS_LINEAGE_LIVEDISPLAY_HAL | ENABLE_PA | Enable PictureAdjustment feature | true | 10 | | OPLUS_LINEAGE_LIVEDISPLAY_HAL | ENABLE_SE | Enable SunlightEnhancement feature | true | 11 | | OPLUS_LINEAGE_TOUCH_HAL | INCLUDE_DIR | Device specific include dir path | | 12 | | OPLUS_LINEAGE_VIBRATOR_HAL | INCLUDE_DIR | Device specific include dir path | | 13 | | OPLUS_LINEAGE_VIBRATOR_HAL | USE_EFFECT_STREAM | Enable effect stream feature | false | 14 | | QTI_GPT_UTILS | USE_BSG_FRAMEWORK | Enable BSG framework feature | true | 15 | -------------------------------------------------------------------------------- /aidl/commondcs/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2025 The LineageOS Project 3 | // 4 | // SPDX-License-Identifier: Apache-2.0 5 | // 6 | 7 | cc_binary { 8 | name: "vendor.oplus.hardware.commondcs-service", 9 | vendor: true, 10 | relative_install_path: "hw", 11 | init_rc: ["vendor.oplus.hardware.commondcs-service.rc"], 12 | vintf_fragments: ["vendor.oplus.hardware.commondcs-service.xml"], 13 | srcs: [ 14 | "CommonDcsAidlHalService.cpp", 15 | "service.cpp", 16 | ], 17 | shared_libs: [ 18 | "libbase", 19 | "libbinder_ndk", 20 | "vendor.oplus.hardware.commondcs-V1-ndk", 21 | ], 22 | } 23 | -------------------------------------------------------------------------------- /aidl/commondcs/CommonDcsAidlHalService.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2025 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | #include "CommonDcsAidlHalService.h" 8 | 9 | namespace aidl { 10 | namespace vendor { 11 | namespace oplus { 12 | namespace hardware { 13 | namespace commondcs { 14 | 15 | ndk::ScopedAStatus CommonDcsAidlHalService::notifyMsgToCommonDcs( 16 | const std::vector& data, const std::string& logTag, const std::string& eventId, 17 | int32_t* _aidl_return) { 18 | *_aidl_return = 0; 19 | return ndk::ScopedAStatus::ok(); 20 | } 21 | 22 | } // namespace commondcs 23 | } // namespace hardware 24 | } // namespace oplus 25 | } // namespace vendor 26 | } // namespace aidl 27 | -------------------------------------------------------------------------------- /aidl/commondcs/CommonDcsAidlHalService.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2025 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | #pragma once 8 | 9 | #include 10 | 11 | namespace aidl { 12 | namespace vendor { 13 | namespace oplus { 14 | namespace hardware { 15 | namespace commondcs { 16 | 17 | struct CommonDcsAidlHalService : public BnCommonDcsAidlHalService { 18 | ndk::ScopedAStatus notifyMsgToCommonDcs(const std::vector& data, 19 | const std::string& logTag, const std::string& eventId, 20 | int32_t* _aidl_return) final; 21 | }; 22 | 23 | } // namespace commondcs 24 | } // namespace hardware 25 | } // namespace oplus 26 | } // namespace vendor 27 | } // namespace aidl 28 | -------------------------------------------------------------------------------- /aidl/commondcs/service.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2025 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | #include "CommonDcsAidlHalService.h" 8 | 9 | #include 10 | #include 11 | #include 12 | 13 | using ::aidl::vendor::oplus::hardware::commondcs::CommonDcsAidlHalService; 14 | 15 | int main() { 16 | ABinderProcess_setThreadPoolMaxThreadCount(0); 17 | std::shared_ptr service = 18 | ndk::SharedRefBase::make(); 19 | 20 | const std::string instance = std::string() + CommonDcsAidlHalService::descriptor + "/default"; 21 | binder_status_t status = 22 | AServiceManager_addService(service->asBinder().get(), instance.c_str()); 23 | CHECK_EQ(status, STATUS_OK); 24 | 25 | ABinderProcess_joinThreadPool(); 26 | return EXIT_FAILURE; // should not reach 27 | } 28 | -------------------------------------------------------------------------------- /aidl/commondcs/vendor.oplus.hardware.commondcs-service.rc: -------------------------------------------------------------------------------- 1 | service vendor.commondcs /vendor/bin/hw/vendor.oplus.hardware.commondcs-service 2 | class hal 3 | user system 4 | group system 5 | -------------------------------------------------------------------------------- /aidl/commondcs/vendor.oplus.hardware.commondcs-service.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | vendor.oplus.hardware.commondcs 4 | 1 5 | ICommonDcsAidlHalService/default 6 | 7 | 8 | -------------------------------------------------------------------------------- /aidl/fingerprint/Android.bp: -------------------------------------------------------------------------------- 1 | cc_binary { 2 | name: "android.hardware.biometrics.fingerprint-service.oplus", 3 | relative_install_path: "hw", 4 | init_rc: ["android.hardware.biometrics.fingerprint-service.oplus.rc"], 5 | vintf_fragments: ["android.hardware.biometrics.fingerprint-service.oplus.xml"], 6 | srcs: [ 7 | "Fingerprint.cpp", 8 | "Session.cpp", 9 | "service.cpp", 10 | ], 11 | shared_libs: [ 12 | "libbase", 13 | "libbinder_ndk", 14 | "android.hardware.biometrics.fingerprint-V4-ndk", 15 | "android.hardware.biometrics.common-V4-ndk", 16 | "android.hardware.biometrics.common.thread", 17 | "android.hardware.biometrics.common.util", 18 | ], 19 | vendor: true, 20 | } 21 | -------------------------------------------------------------------------------- /aidl/fingerprint/Fingerprint.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2025 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | #include "Fingerprint.h" 7 | 8 | namespace aidl { 9 | namespace android { 10 | namespace hardware { 11 | namespace biometrics { 12 | namespace fingerprint { 13 | 14 | ndk::ScopedAStatus Fingerprint::getSensorProps(std::vector* /*out*/) { 15 | return ndk::ScopedAStatus::fromExceptionCode(EX_UNSUPPORTED_OPERATION); 16 | } 17 | 18 | ndk::ScopedAStatus Fingerprint::createSession(int32_t /*sensorId*/, int32_t /*userId*/, 19 | const std::shared_ptr& /*cb*/, 20 | std::shared_ptr* /*out*/) { 21 | return ndk::ScopedAStatus::fromExceptionCode(EX_UNSUPPORTED_OPERATION); 22 | } 23 | 24 | } // namespace fingerprint 25 | } // namespace biometrics 26 | } // namespace hardware 27 | } // namespace android 28 | } // namespace aidl 29 | -------------------------------------------------------------------------------- /aidl/fingerprint/Fingerprint.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2025 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | #pragma once 7 | 8 | #include 9 | 10 | using ::aidl::android::hardware::biometrics::fingerprint::ISession; 11 | using ::aidl::android::hardware::biometrics::fingerprint::ISessionCallback; 12 | using ::aidl::android::hardware::biometrics::fingerprint::SensorProps; 13 | 14 | namespace aidl { 15 | namespace android { 16 | namespace hardware { 17 | namespace biometrics { 18 | namespace fingerprint { 19 | 20 | class Fingerprint : public BnFingerprint { 21 | public: 22 | ndk::ScopedAStatus getSensorProps(std::vector* _aidl_return) override; 23 | ndk::ScopedAStatus createSession(int32_t sensorId, int32_t userId, 24 | const std::shared_ptr& cb, 25 | std::shared_ptr* out) override; 26 | }; 27 | 28 | } // namespace fingerprint 29 | } // namespace biometrics 30 | } // namespace hardware 31 | } // namespace android 32 | } // namespace aidl 33 | -------------------------------------------------------------------------------- /aidl/fingerprint/android.hardware.biometrics.fingerprint-service.oplus.rc: -------------------------------------------------------------------------------- 1 | service vendor.fingerprint-default /vendor/bin/hw/android.hardware.biometrics.fingerprint-service.oplus 2 | class hal 3 | user system 4 | group system input uhid 5 | shutdown critical 6 | -------------------------------------------------------------------------------- /aidl/fingerprint/android.hardware.biometrics.fingerprint-service.oplus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | android.hardware.biometrics.fingerprint 4 | IFingerprint/default 5 | 6 | 7 | -------------------------------------------------------------------------------- /aidl/fingerprint/service.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2025 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | #include "Fingerprint.h" 7 | 8 | #include 9 | #include 10 | #include 11 | 12 | using ::aidl::android::hardware::biometrics::fingerprint::Fingerprint; 13 | 14 | int main() { 15 | ABinderProcess_setThreadPoolMaxThreadCount(0); 16 | std::shared_ptr fingerprint = ndk::SharedRefBase::make(); 17 | 18 | const std::string instance = std::string() + Fingerprint::descriptor + "/default"; 19 | binder_status_t status = AServiceManager_addService(fingerprint->asBinder().get(), instance.c_str()); 20 | CHECK(status == STATUS_OK); 21 | 22 | ABinderProcess_joinThreadPool(); 23 | return EXIT_FAILURE; // should not reach 24 | } 25 | -------------------------------------------------------------------------------- /aidl/ir/Android.bp: -------------------------------------------------------------------------------- 1 | cc_binary { 2 | name: "android.hardware.ir-service.oplus", 3 | vendor: true, 4 | relative_install_path: "hw", 5 | init_rc: ["android.hardware.ir-service.oplus.rc"], 6 | vintf_fragments: ["android.hardware.ir-service.xml"], 7 | srcs: [ 8 | "ConsumerIr.cpp", 9 | "service.cpp", 10 | ], 11 | shared_libs: [ 12 | "android.hardware.ir-V1-ndk", 13 | "libbase", 14 | "libbinder_ndk", 15 | ], 16 | header_libs: [ 17 | "kernel_headers.oplus", 18 | ], 19 | } 20 | -------------------------------------------------------------------------------- /aidl/ir/ConsumerIr.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2025 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | #pragma once 7 | 8 | #include 9 | 10 | namespace aidl { 11 | namespace android { 12 | namespace hardware { 13 | namespace ir { 14 | 15 | class ConsumerIr : public BnConsumerIr { 16 | public: 17 | ConsumerIr(); 18 | 19 | private: 20 | ::ndk::ScopedAStatus getCarrierFreqs(std::vector* _aidl_return) override; 21 | ::ndk::ScopedAStatus transmit(int32_t in_carrierFreqHz, 22 | const std::vector& in_pattern) override; 23 | 24 | std::vector supportedFreqs; 25 | }; 26 | 27 | } // namespace ir 28 | } // namespace hardware 29 | } // namespace android 30 | } // namespace aidl 31 | -------------------------------------------------------------------------------- /aidl/ir/android.hardware.ir-service.oplus.rc: -------------------------------------------------------------------------------- 1 | on boot 2 | chown system system /dev/oplus_consumer_ir 3 | chmod 0644 /dev/oplus_consumer_ir 4 | 5 | service vendor.ir-default /vendor/bin/hw/android.hardware.ir-service.oplus 6 | class hal 7 | user system 8 | group system 9 | interface aidl android.hardware.ir.IConsumerIr/default 10 | -------------------------------------------------------------------------------- /aidl/ir/android.hardware.ir-service.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | android.hardware.ir 4 | 1 5 | IConsumerIr/default 6 | 7 | 8 | -------------------------------------------------------------------------------- /aidl/ir/service.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2025 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | #include "ConsumerIr.h" 7 | 8 | #include 9 | #include 10 | #include 11 | 12 | using ::aidl::android::hardware::ir::ConsumerIr; 13 | 14 | int main() { 15 | ABinderProcess_setThreadPoolMaxThreadCount(0); 16 | std::shared_ptr consumerIr = ndk::SharedRefBase::make(); 17 | 18 | const std::string instance = std::string() + ConsumerIr::descriptor + "/default"; 19 | binder_status_t status = 20 | AServiceManager_addService(consumerIr->asBinder().get(), instance.c_str()); 21 | CHECK_EQ(status, STATUS_OK); 22 | 23 | ABinderProcess_joinThreadPool(); 24 | return EXIT_FAILURE; // should not reach 25 | } 26 | -------------------------------------------------------------------------------- /aidl/osense-client/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2024 The LineageOS Project 3 | // 4 | // SPDX-License-Identifier: Apache-2.0 5 | // 6 | 7 | cc_binary { 8 | name: "vendor.oplus.hardware.osense.client-service", 9 | vendor: true, 10 | relative_install_path: "hw", 11 | init_rc: ["vendor.oplus.hardware.osense.client-service.rc"], 12 | vintf_fragments: ["vendor.oplus.hardware.osense.client-service.xml"], 13 | srcs: [ 14 | "OsenseAidlHalReporter.cpp", 15 | "service.cpp", 16 | ], 17 | shared_libs: [ 18 | "libbase", 19 | "libbinder_ndk", 20 | "vendor.oplus.hardware.osense.client-V1-ndk", 21 | ], 22 | } 23 | -------------------------------------------------------------------------------- /aidl/osense-client/service.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | #include "OsenseAidlHalReporter.h" 8 | 9 | #include 10 | #include 11 | #include 12 | 13 | using ::aidl::vendor::oplus::hardware::osense::client::OsenseAidlHalReporter; 14 | 15 | int main() { 16 | ABinderProcess_setThreadPoolMaxThreadCount(0); 17 | std::shared_ptr reporter = 18 | ndk::SharedRefBase::make(); 19 | 20 | const std::string instance = std::string() + OsenseAidlHalReporter::descriptor + "/default"; 21 | binder_status_t status = 22 | AServiceManager_addService(reporter->asBinder().get(), instance.c_str()); 23 | CHECK_EQ(status, STATUS_OK); 24 | 25 | ABinderProcess_joinThreadPool(); 26 | return EXIT_FAILURE; // should not reach 27 | } 28 | -------------------------------------------------------------------------------- /aidl/osense-client/vendor.oplus.hardware.osense.client-service.rc: -------------------------------------------------------------------------------- 1 | service vendor.osense_client /vendor/bin/hw/vendor.oplus.hardware.osense.client-service 2 | class hal 3 | user system 4 | group system 5 | -------------------------------------------------------------------------------- /aidl/osense-client/vendor.oplus.hardware.osense.client-service.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | vendor.oplus.hardware.osense.client 4 | 1 5 | IOsenseAidlHalReporter/default 6 | 7 | 8 | -------------------------------------------------------------------------------- /aidl/powershare/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // SPDX-FileCopyrightText: 2025 The LineageOS Project 3 | // SPDX-License-Identifier: Apache-2.0 4 | // 5 | 6 | cc_binary { 7 | name: "vendor.lineage.powershare-service.oplus", 8 | vintf_fragments: ["vendor.lineage.powershare-service.oplus.xml"], 9 | init_rc: ["vendor.lineage.powershare-service.oplus.rc"], 10 | vendor: true, 11 | relative_install_path: "hw", 12 | srcs: [ 13 | "PowerShare.cpp", 14 | "service.cpp", 15 | ], 16 | shared_libs: [ 17 | "libbase", 18 | "liblog", 19 | "libbinder_ndk", 20 | "libutils", 21 | "vendor.lineage.powershare-V1-ndk", 22 | ], 23 | } 24 | -------------------------------------------------------------------------------- /aidl/powershare/PowerShare.h: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2025 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | #pragma once 7 | 8 | #include 9 | 10 | namespace aidl { 11 | namespace vendor { 12 | namespace lineage { 13 | namespace powershare { 14 | 15 | class PowerShare : public BnPowerShare { 16 | public: 17 | ndk::ScopedAStatus getMinBattery(int32_t* _aidl_return) override; 18 | ndk::ScopedAStatus isEnabled(bool* _aidl_return) override; 19 | ndk::ScopedAStatus setEnabled(bool enable) override; 20 | ndk::ScopedAStatus setMinBattery(int32_t minBattery) override; 21 | }; 22 | 23 | } // namespace powershare 24 | } // namespace lineage 25 | } // namespace vendor 26 | } // namespace aidl 27 | -------------------------------------------------------------------------------- /aidl/powershare/service.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2025 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | #include "PowerShare.h" 7 | 8 | #include 9 | #include 10 | #include 11 | 12 | using aidl::vendor::lineage::powershare::PowerShare; 13 | 14 | int main() { 15 | ABinderProcess_setThreadPoolMaxThreadCount(0); 16 | std::shared_ptr powershare = ndk::SharedRefBase::make(); 17 | 18 | const std::string instance = std::string(PowerShare::descriptor) + "/default"; 19 | binder_status_t status = 20 | AServiceManager_addService(powershare->asBinder().get(), instance.c_str()); 21 | CHECK_EQ(status, STATUS_OK); 22 | 23 | ABinderProcess_joinThreadPool(); 24 | return EXIT_FAILURE; // should not reach 25 | } 26 | -------------------------------------------------------------------------------- /aidl/powershare/vendor.lineage.powershare-service.oplus.rc: -------------------------------------------------------------------------------- 1 | on init 2 | chown system system /proc/wireless/enable_tx 3 | 4 | service vendor.powershare-hal /vendor/bin/hw/vendor.lineage.powershare-service.oplus 5 | class hal 6 | user system 7 | group system 8 | -------------------------------------------------------------------------------- /aidl/powershare/vendor.lineage.powershare-service.oplus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | vendor.lineage.powershare 4 | 1 5 | IPowerShare/default 6 | 7 | 8 | -------------------------------------------------------------------------------- /aidl/sensors/AlsCorrection.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2021-2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | #pragma once 8 | 9 | #include 10 | #include 11 | 12 | namespace android { 13 | namespace hardware { 14 | namespace sensors { 15 | namespace V2_1 { 16 | namespace implementation { 17 | 18 | static constexpr int SENSOR_TYPE_QTI_WISE_LIGHT = 33171103; 19 | 20 | class AlsCorrection { 21 | public: 22 | static void init(); 23 | static void process(Event& event); 24 | }; 25 | 26 | } // namespace implementation 27 | } // namespace V2_1 28 | } // namespace sensors 29 | } // namespace hardware 30 | } // namespace android 31 | -------------------------------------------------------------------------------- /aidl/sensors/als/Android.bp: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | aidl_interface { 8 | name: "vendor.lineage.oplus_als", 9 | vendor_available: true, 10 | srcs: ["vendor/lineage/oplus_als/*.aidl"], 11 | stability: "vintf", 12 | owner: "lineage", 13 | backend: { 14 | cpp: { 15 | enabled: false, 16 | }, 17 | java: { 18 | enabled: false, 19 | }, 20 | }, 21 | versions_with_info: [ 22 | { 23 | version: "1", 24 | imports: [], 25 | }, 26 | ], 27 | } 28 | -------------------------------------------------------------------------------- /aidl/sensors/als/aidl_api/vendor.lineage.oplus_als/1/.hash: -------------------------------------------------------------------------------- 1 | adce6a8cc870bbfa03fa544897422ba03b47cbb0 -------------------------------------------------------------------------------- /aidl/sensors/als/aidl_api/vendor.lineage.oplus_als/1/vendor/lineage/oplus_als/AreaRgbCaptureResult.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.lineage.oplus_als; 8 | 9 | @VintfStability 10 | parcelable AreaRgbCaptureResult { 11 | float r; 12 | float g; 13 | float b; 14 | } 15 | -------------------------------------------------------------------------------- /aidl/sensors/als/aidl_api/vendor.lineage.oplus_als/1/vendor/lineage/oplus_als/IAreaCapture.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.lineage.oplus_als; 8 | 9 | import vendor.lineage.oplus_als.AreaRgbCaptureResult; 10 | 11 | @VintfStability 12 | interface IAreaCapture { 13 | AreaRgbCaptureResult getAreaBrightness(); 14 | } 15 | -------------------------------------------------------------------------------- /aidl/sensors/als/aidl_api/vendor.lineage.oplus_als/current/vendor/lineage/oplus_als/AreaRgbCaptureResult.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.lineage.oplus_als; 8 | 9 | @VintfStability 10 | parcelable AreaRgbCaptureResult { 11 | float r; 12 | float g; 13 | float b; 14 | } 15 | -------------------------------------------------------------------------------- /aidl/sensors/als/aidl_api/vendor.lineage.oplus_als/current/vendor/lineage/oplus_als/IAreaCapture.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.lineage.oplus_als; 8 | 9 | import vendor.lineage.oplus_als.AreaRgbCaptureResult; 10 | 11 | @VintfStability 12 | interface IAreaCapture { 13 | AreaRgbCaptureResult getAreaBrightness(); 14 | } 15 | -------------------------------------------------------------------------------- /aidl/sensors/als/default/.clang-format: -------------------------------------------------------------------------------- 1 | ../../../../../build/soong/scripts/system-clang-format -------------------------------------------------------------------------------- /aidl/sensors/als/default/Android.bp: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | cc_binary { 8 | name: "vendor.lineage.oplus_als.service", 9 | init_rc: ["vendor.lineage.oplus_als.service.rc"], 10 | vintf_fragments: ["vendor.lineage.oplus_als.service.xml"], 11 | relative_install_path: "hw", 12 | system_ext_specific: true, 13 | srcs: [ 14 | "AreaCapture.cpp", 15 | "main.cpp", 16 | ], 17 | shared_libs: [ 18 | "libbase", 19 | "libbinder", 20 | "libbinder_ndk", 21 | "libgui", 22 | "libui", 23 | "libutils", 24 | "liblog", 25 | "vendor.lineage.oplus_als-V1-ndk", 26 | ], 27 | } 28 | -------------------------------------------------------------------------------- /aidl/sensors/als/default/AreaCapture.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2021-2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | #pragma once 8 | 9 | #include 10 | #include 11 | 12 | namespace aidl { 13 | namespace vendor { 14 | namespace lineage { 15 | namespace oplus_als { 16 | 17 | class AreaCapture : public BnAreaCapture { 18 | public: 19 | AreaCapture(); 20 | ndk::ScopedAStatus getAreaBrightness(AreaRgbCaptureResult* _aidl_return) override; 21 | 22 | private: 23 | static ::android::sp<::android::IBinder> getInternalDisplayToken(); 24 | 25 | ::android::Rect m_screenshot_rect; 26 | }; 27 | 28 | } // namespace oplus_als 29 | } // namespace lineage 30 | } // namespace vendor 31 | } // namespace aidl 32 | -------------------------------------------------------------------------------- /aidl/sensors/als/default/main.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | #include "AreaCapture.h" 8 | 9 | #include 10 | #include 11 | #include 12 | 13 | using ::aidl::vendor::lineage::oplus_als::AreaCapture; 14 | 15 | int main() { 16 | ABinderProcess_setThreadPoolMaxThreadCount(0); 17 | ABinderProcess_startThreadPool(); 18 | std::shared_ptr ac = ndk::SharedRefBase::make(); 19 | 20 | const auto instance = std::string(AreaCapture::descriptor) + "/default"; 21 | binder_status_t status = AServiceManager_addService(ac->asBinder().get(), instance.c_str()); 22 | CHECK_EQ(status, STATUS_OK); 23 | 24 | ABinderProcess_joinThreadPool(); 25 | return EXIT_FAILURE; // should not reach 26 | } 27 | -------------------------------------------------------------------------------- /aidl/sensors/als/default/vendor.lineage.oplus_als.service.rc: -------------------------------------------------------------------------------- 1 | service vendor.lineage.oplus_als.service /system_ext/bin/hw/vendor.lineage.oplus_als.service 2 | class hal 3 | user system 4 | group system 5 | task_profiles ServiceCapacityLow 6 | interface aidl vendor.lineage.oplus_als.IAreaCapture/default 7 | -------------------------------------------------------------------------------- /aidl/sensors/als/default/vendor.lineage.oplus_als.service.xml: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | vendor.lineage.oplus_als 8 | IAreaCapture/default 9 | 10 | 11 | -------------------------------------------------------------------------------- /aidl/sensors/als/vendor/lineage/oplus_als/AreaRgbCaptureResult.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.lineage.oplus_als; 8 | 9 | @VintfStability 10 | parcelable AreaRgbCaptureResult { 11 | float r; 12 | float g; 13 | float b; 14 | } 15 | -------------------------------------------------------------------------------- /aidl/sensors/als/vendor/lineage/oplus_als/IAreaCapture.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.lineage.oplus_als; 8 | 9 | import vendor.lineage.oplus_als.AreaRgbCaptureResult; 10 | 11 | @VintfStability 12 | interface IAreaCapture { 13 | AreaRgbCaptureResult getAreaBrightness(); 14 | } 15 | -------------------------------------------------------------------------------- /aidl/sensors/android.hardware.sensors-service.oplus-multihal.rc: -------------------------------------------------------------------------------- 1 | on boot 2 | chmod 666 /sys/kernel/oplus_display/aod_light_mode_set 3 | 4 | service vendor.sensors-hal-multihal /vendor/bin/hw/android.hardware.sensors-service.oplus-multihal 5 | class hal 6 | user system 7 | group system wakelock context_hub input uhid 8 | task_profiles ServiceCapacityLow 9 | capabilities BLOCK_SUSPEND 10 | rlimit rtprio 10 10 11 | -------------------------------------------------------------------------------- /aidl/sensors/android.hardware.sensors.oplus-multihal.xml: -------------------------------------------------------------------------------- 1 | 16 | 17 | 18 | 19 | android.hardware.sensors 20 | 3 21 | ISensors/default 22 | 23 | 24 | -------------------------------------------------------------------------------- /aidl/sensors/service.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2021 The Android Open Source Project 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #include 18 | #include 19 | #include 20 | #include "HalProxyAidl.h" 21 | 22 | using ::aidl::android::hardware::sensors::implementation::HalProxyAidl; 23 | 24 | int main() { 25 | ABinderProcess_setThreadPoolMaxThreadCount(0); 26 | 27 | // Make a default multihal sensors service 28 | auto halProxy = ndk::SharedRefBase::make(); 29 | const std::string halProxyName = std::string() + HalProxyAidl::descriptor + "/default"; 30 | binder_status_t status = 31 | AServiceManager_addService(halProxy->asBinder().get(), halProxyName.c_str()); 32 | CHECK_EQ(status, STATUS_OK); 33 | 34 | ABinderProcess_joinThreadPool(); 35 | return EXIT_FAILURE; // should not reach 36 | } 37 | -------------------------------------------------------------------------------- /aidl/vibrator/qti/Android.bp: -------------------------------------------------------------------------------- 1 | Common_CFlags = ["-Wall"] 2 | Common_CFlags += ["-Werror"] 3 | 4 | cc_library_shared { 5 | name: "vendor.qti.hardware.vibrator.impl.oplus", 6 | vendor: true, 7 | cflags: Common_CFlags + select(soong_config_variable("OPLUS_LINEAGE_VIBRATOR_HAL", "USE_EFFECT_STREAM"), { 8 | "true": ["-DUSE_EFFECT_STREAM"], 9 | default: [], 10 | }), 11 | srcs: [ 12 | "Vibrator.cpp", 13 | ], 14 | shared_libs: [ 15 | "libcutils", 16 | "libutils", 17 | "liblog", 18 | "libbinder_ndk", 19 | "android.hardware.vibrator-V1-ndk", 20 | ] + select(soong_config_variable("OPLUS_LINEAGE_VIBRATOR_HAL", "USE_EFFECT_STREAM"), { 21 | "true": ["liboplusvibratoreffect"], 22 | default: [], 23 | }), 24 | export_include_dirs: ["include"], 25 | } 26 | 27 | cc_binary { 28 | name: "vendor.qti.hardware.vibrator.service.oplus", 29 | vendor: true, 30 | relative_install_path: "hw", 31 | init_rc: ["vendor.qti.hardware.vibrator.service.oplus.rc"], 32 | vintf_fragments: [ 33 | "vendor.qti.hardware.vibrator.service.oplus.xml", 34 | ], 35 | cflags: Common_CFlags, 36 | srcs: [ 37 | "service.cpp", 38 | ], 39 | shared_libs: [ 40 | "libcutils", 41 | "libutils", 42 | "libbase", 43 | "libbinder_ndk", 44 | "android.hardware.vibrator-V1-ndk", 45 | "vendor.qti.hardware.vibrator.impl.oplus", 46 | ], 47 | } 48 | -------------------------------------------------------------------------------- /aidl/vibrator/qti/effect/Android.bp: -------------------------------------------------------------------------------- 1 | cc_library_shared { 2 | name: "liboplusvibratoreffect", 3 | vendor: true, 4 | srcs: [ 5 | "effect.cpp", 6 | ], 7 | shared_libs: [ 8 | "libcutils", 9 | "libutils", 10 | ], 11 | include_dirs: select(soong_config_variable("OPLUS_LINEAGE_VIBRATOR_HAL", "INCLUDE_DIR"), { 12 | any @ flag_val: [flag_val], 13 | default: [], 14 | }), 15 | } 16 | -------------------------------------------------------------------------------- /aidl/vibrator/qti/vendor.qti.hardware.vibrator.service.oplus.rc: -------------------------------------------------------------------------------- 1 | on boot 2 | chown system system /sys/class/leds/vibrator/rtp 3 | chown system system /sys/class/leds/vibrator/vmax 4 | chown system system /sys/class/leds/vibrator/waveform_index 5 | 6 | service vendor.qti.vibrator /vendor/bin/hw/vendor.qti.hardware.vibrator.service.oplus 7 | class hal 8 | user system 9 | group system input 10 | -------------------------------------------------------------------------------- /aidl/vibrator/richtap/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2025 The LineageOS Project 3 | // SPDX-License-Identifier: Apache-2.0 4 | // 5 | 6 | cc_binary { 7 | name: "android.hardware.vibrator.service.oplus-richtap", 8 | vendor: true, 9 | cflags: [ 10 | "-Wall", 11 | "-Werror", 12 | "-DLOG_TAG=\"android.hardware.vibrator.service.oplus\"", 13 | ], 14 | relative_install_path: "hw", 15 | init_rc: ["android.hardware.vibrator.service.oplus-richtap.rc"], 16 | vintf_fragments: [ 17 | "android.hardware.vibrator.service.oplus-richtap.xml", 18 | ], 19 | srcs: [ 20 | "service.cpp", 21 | "Vibrator.cpp", 22 | ], 23 | shared_libs: [ 24 | "libcutils", 25 | "libutils", 26 | "liblog", 27 | "libbase", 28 | "libbinder_ndk", 29 | "libaacvibrator", 30 | "android.hardware.vibrator-V2-ndk", 31 | ], 32 | } 33 | 34 | cc_library_shared { 35 | name: "libaacvibrator", 36 | soc_specific: true, 37 | } 38 | -------------------------------------------------------------------------------- /aidl/vibrator/richtap/android.hardware.vibrator.service.oplus-richtap.rc: -------------------------------------------------------------------------------- 1 | on boot 2 | chown system system /dev/awinic_haptic 3 | chmod 0600 /dev/awinic_haptic 4 | 5 | service vendor.vibrator /vendor/bin/hw/android.hardware.vibrator.service.oplus-richtap 6 | class late_start 7 | user system 8 | group system input 9 | setenv RICHTAP_DEVICE_PATH /dev/awinic_haptic 10 | setenv ENV_RICHTAP_CONFIG_PATH /odm/etc/aac_richtap.config 11 | -------------------------------------------------------------------------------- /aidl/vibrator/richtap/android.hardware.vibrator.service.oplus-richtap.xml: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | android.hardware.vibrator 8 | 2 9 | IVibrator/default 10 | 11 | 12 | -------------------------------------------------------------------------------- /aidl/vibrator/richtap/service.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * SPDX-FileCopyrightText: 2025 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | #include 7 | #include 8 | #include 9 | 10 | #include "Vibrator.h" 11 | 12 | using aidl::android::hardware::vibrator::Vibrator; 13 | 14 | int main() { 15 | ABinderProcess_setThreadPoolMaxThreadCount(0); 16 | std::shared_ptr vib = ndk::SharedRefBase::make(); 17 | 18 | const std::string instance = std::string() + Vibrator::descriptor + "/default"; 19 | binder_status_t status = AServiceManager_addService(vib->asBinder().get(), instance.c_str()); 20 | CHECK(status == STATUS_OK); 21 | 22 | ABinderProcess_joinThreadPool(); 23 | return EXIT_FAILURE; // should not reach 24 | } 25 | -------------------------------------------------------------------------------- /doze/Android.bp: -------------------------------------------------------------------------------- 1 | android_app { 2 | name: "OplusDoze", 3 | defaults: ["SettingsLibDefaults"], 4 | 5 | srcs: ["src/**/*.kt"], 6 | 7 | certificate: "platform", 8 | platform_apis: true, 9 | system_ext_specific: true, 10 | 11 | static_libs: [ 12 | "androidx.core_core", 13 | "androidx.preference_preference", 14 | "org.lineageos.settings.resources", 15 | ], 16 | 17 | optimize: { 18 | proguard_flags_files: ["proguard.flags"], 19 | }, 20 | } 21 | -------------------------------------------------------------------------------- /doze/proguard.flags: -------------------------------------------------------------------------------- 1 | -keepclasseswithmembers class * { 2 | public (android.content.Context, android.util.AttributeSet); 3 | } 4 | 5 | -keep class ** extends androidx.preference.PreferenceFragment 6 | -keep class org.lineageos.settings.doze.* { 7 | *; 8 | } 9 | -------------------------------------------------------------------------------- /doze/res/drawable/ic_pickup.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /doze/res/drawable/ic_pocket.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /doze/res/values/arrays.xml: -------------------------------------------------------------------------------- 1 | 2 | 17 | 18 | 19 | 20 | @string/disabled 21 | @string/pick_up_gesture_summary 22 | @string/pick_up_wake_gesture_summary 23 | 24 | 25 | 26 | 0 27 | 1 28 | 2 29 | 30 | 31 | -------------------------------------------------------------------------------- /doze/res/values/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 1.0 24 | 0.0 25 | 26 | -------------------------------------------------------------------------------- /doze/src/org/lineageos/settings/doze/BootCompletedReceiver.kt: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2021 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package org.lineageos.settings.doze 7 | 8 | import android.content.BroadcastReceiver 9 | import android.content.Context 10 | import android.content.Intent 11 | import android.util.Log 12 | 13 | class BootCompletedReceiver : BroadcastReceiver() { 14 | override fun onReceive(context: Context, intent: Intent) { 15 | Log.d(TAG, "Starting") 16 | Utils.checkDozeService(context) 17 | } 18 | 19 | companion object { 20 | private const val TAG = "OplusDoze" 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /doze/src/org/lineageos/settings/doze/DozeSettingsActivity.kt: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2021-2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package org.lineageos.settings.doze 7 | 8 | import android.os.Bundle 9 | import com.android.settingslib.collapsingtoolbar.CollapsingToolbarBaseActivity 10 | 11 | class DozeSettingsActivity : CollapsingToolbarBaseActivity() { 12 | override fun onCreate(savedInstanceState: Bundle?) { 13 | super.onCreate(savedInstanceState) 14 | supportFragmentManager 15 | .beginTransaction() 16 | .replace( 17 | com.android.settingslib.collapsingtoolbar.R.id.content_frame, 18 | DozeSettingsFragment(), 19 | TAG 20 | ).commit() 21 | } 22 | 23 | companion object { 24 | private const val TAG = "DozeSettingsActivity" 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /fingerprint/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2025 The LineageOS Project 3 | // 4 | // SPDX-License-Identifier: Apache-2.0 5 | // 6 | 7 | cc_library_static { 8 | name: "libudfps_extension.oplus", 9 | srcs: ["UdfpsExtension.cpp"], 10 | include_dirs: [ 11 | "frameworks/native/services/surfaceflinger/CompositionEngine/include", 12 | ], 13 | header_libs: [ 14 | "generated_kernel_headers", 15 | ], 16 | } 17 | -------------------------------------------------------------------------------- /fingerprint/UdfpsExtension.cpp: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2022-2024 The LineageOS Project 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #include 18 | 19 | #if __has_include() 20 | #include 21 | #elif __has_include() 22 | #include 23 | #endif 24 | 25 | uint32_t getUdfpsDimZOrder(uint32_t z) { 26 | return 0x41000005; 27 | } 28 | 29 | uint32_t getUdfpsZOrder(uint32_t z, bool touched) { 30 | #ifdef FOD_PRESSED_LAYER_ZORDER 31 | return touched ? z | FOD_PRESSED_LAYER_ZORDER : z; 32 | #else 33 | return touched ? 0x41000033 : z; 34 | #endif 35 | } 36 | 37 | uint64_t getUdfpsUsageBits(uint64_t usageBits, bool /*touched*/) { 38 | return usageBits; 39 | } 40 | -------------------------------------------------------------------------------- /fingerprint/shims/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2025 The LineageOS Project 3 | // 4 | // SPDX-License-Identifier: Apache-2.0 5 | // 6 | 7 | cc_defaults { 8 | name: "libshims_aidl_fingerprint.oplus_defaults", 9 | srcs: ["SensorPropsShim.cpp"], 10 | shared_libs: ["libbase"], 11 | device_specific: true, 12 | } 13 | 14 | cc_library_shared { 15 | name: "libshims_aidl_fingerprint_v2.oplus", 16 | defaults: ["libshims_aidl_fingerprint.oplus_defaults"], 17 | static_libs: ["android.hardware.biometrics.fingerprint-V2-ndk"], 18 | } 19 | 20 | cc_library_shared { 21 | name: "libshims_aidl_fingerprint_v3.oplus", 22 | defaults: ["libshims_aidl_fingerprint.oplus_defaults"], 23 | static_libs: ["android.hardware.biometrics.fingerprint-V3-ndk"], 24 | } 25 | 26 | cc_library_shared { 27 | name: "libshims_aidl_fingerprint_v4.oplus", 28 | defaults: ["libshims_aidl_fingerprint.oplus_defaults"], 29 | static_libs: ["android.hardware.biometrics.fingerprint-V4-ndk"], 30 | } 31 | 32 | cc_library { 33 | name: "libshims_fingerprint.oplus", 34 | srcs: ["BiometricsFingerprintShim.cpp"], 35 | shared_libs: [ 36 | "libcutils", 37 | "liblog", 38 | ], 39 | device_specific: true, 40 | } 41 | -------------------------------------------------------------------------------- /hidl/fingerprint/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2022-2025 The LineageOS Project 3 | // 4 | // SPDX-License-Identifier: Apache-2.0 5 | // 6 | 7 | cc_binary { 8 | name: "android.hardware.biometrics.fingerprint@2.3-service.oplus", 9 | defaults: ["hidl_defaults"], 10 | init_rc: ["android.hardware.biometrics.fingerprint@2.3-service.oplus.rc"], 11 | vintf_fragments: ["android.hardware.biometrics.fingerprint@2.3-service.oplus.xml"], 12 | vendor: true, 13 | relative_install_path: "hw", 14 | srcs: [ 15 | "BiometricsFingerprint.cpp", 16 | "service.cpp", 17 | ], 18 | shared_libs: [ 19 | "libbase", 20 | "libhidlbase", 21 | "libutils", 22 | "android.hardware.biometrics.fingerprint@2.1", 23 | "android.hardware.biometrics.fingerprint@2.2", 24 | "android.hardware.biometrics.fingerprint@2.3", 25 | "vendor.oplus.hardware.biometrics.fingerprint@2.1", 26 | ], 27 | header_libs: ["kernel_headers.oplus"], 28 | required: ["qwerty.kl"], 29 | } 30 | 31 | prebuilt_usr_keylayout { 32 | name: "qwerty.kl", 33 | src: "qwerty.kl", 34 | vendor: true, 35 | } 36 | -------------------------------------------------------------------------------- /hidl/fingerprint/android.hardware.biometrics.fingerprint@2.3-service.oplus.rc: -------------------------------------------------------------------------------- 1 | service vendor.fps_hal_oplus /vendor/bin/hw/android.hardware.biometrics.fingerprint@2.3-service.oplus 2 | class late_start 3 | user system 4 | group system 5 | -------------------------------------------------------------------------------- /hidl/fingerprint/android.hardware.biometrics.fingerprint@2.3-service.oplus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | android.hardware.biometrics.fingerprint 4 | hwbinder 5 | 2.3 6 | 7 | IBiometricsFingerprint 8 | default 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /hidl/fingerprint/qwerty.kl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pjgowtham/android_hardware_oplus/8688966c39e59e31376cf12c325c9aadf3962f6b/hidl/fingerprint/qwerty.kl -------------------------------------------------------------------------------- /hidl/livedisplay/vendor.lineage.livedisplay@2.1-service.oplus-af.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | vendor.lineage.livedisplay 4 | hwbinder 5 | 2.1 6 | 7 | IAntiFlicker 8 | default 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /hidl/livedisplay/vendor.lineage.livedisplay@2.1-service.oplus-dm.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | vendor.lineage.livedisplay 4 | hwbinder 5 | 2.1 6 | 7 | IDisplayModes 8 | default 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /hidl/livedisplay/vendor.lineage.livedisplay@2.1-service.oplus-pa.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | vendor.lineage.livedisplay 4 | hwbinder 5 | 2.1 6 | @2.0::IPictureAdjustment/default 7 | 8 | 9 | -------------------------------------------------------------------------------- /hidl/livedisplay/vendor.lineage.livedisplay@2.1-service.oplus-se.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | vendor.lineage.livedisplay 4 | hwbinder 5 | 2.1 6 | 7 | ISunlightEnhancement 8 | default 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /hidl/livedisplay/vendor.lineage.livedisplay@2.1-service.oplus.rc: -------------------------------------------------------------------------------- 1 | service vendor.livedisplay-hal-2-1 /vendor/bin/hw/vendor.lineage.livedisplay@2.1-service.oplus 2 | class late_start 3 | user system 4 | group system 5 | -------------------------------------------------------------------------------- /hidl/touch/Android.bp: -------------------------------------------------------------------------------- 1 | cc_binary { 2 | name: "vendor.lineage.touch@1.0-service.oplus", 3 | defaults: ["hidl_defaults"], 4 | init_rc: ["vendor.lineage.touch@1.0-service.oplus.rc"], 5 | vintf_fragments: ["vendor.lineage.touch@1.0-service.oplus.xml"], 6 | vendor: true, 7 | relative_install_path: "hw", 8 | srcs: [ 9 | "HighTouchPollingRate.cpp", 10 | "TouchscreenGesture.cpp", 11 | "service.cpp", 12 | ], 13 | shared_libs: [ 14 | "libbase", 15 | "libhidlbase", 16 | "libutils", 17 | "vendor.lineage.touch@1.0", 18 | ], 19 | include_dirs: select(soong_config_variable("OPLUS_LINEAGE_TOUCH_HAL", "INCLUDE_DIR"), { 20 | any @ flag_val: [flag_val], 21 | default: [], 22 | }), 23 | } 24 | -------------------------------------------------------------------------------- /hidl/touch/HighTouchPollingRate.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2022 The LineageOS Project 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #pragma once 18 | 19 | #include 20 | #include 21 | #include 22 | 23 | namespace vendor { 24 | namespace lineage { 25 | namespace touch { 26 | namespace V1_0 { 27 | namespace implementation { 28 | 29 | using ::android::hardware::Return; 30 | using ::android::hardware::Void; 31 | 32 | class HighTouchPollingRate : public IHighTouchPollingRate { 33 | public: 34 | // Methods from ::vendor::lineage::touch::V1_0::IHighTouchPollingRate follow. 35 | Return isEnabled() override; 36 | Return setEnabled(bool enabled) override; 37 | }; 38 | 39 | } // namespace implementation 40 | } // namespace V1_0 41 | } // namespace touch 42 | } // namespace lineage 43 | } // namespace vendor 44 | -------------------------------------------------------------------------------- /hidl/touch/TouchscreenGestureConfig.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2022 The LineageOS Project 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #pragma once 18 | 19 | #include "TouchscreenGesture.h" 20 | 21 | namespace vendor { 22 | namespace lineage { 23 | namespace touch { 24 | namespace V1_0 { 25 | namespace implementation { 26 | 27 | const int TouchscreenGesture::kSupportedGestures = makeBitField( 28 | kGestureUpVee, kGestureDownVee, kGestureLeftVee, kGestureRightVee, kGestureCircle, 29 | kGestureDoubleSwipe, kGestureLeftToRight, kGestureRightToLeft, kGestureUpToDown, 30 | kGestureDownToUp, kGestureM, kGestureW, kGestureSingleTap, kGestureS); 31 | 32 | } // namespace implementation 33 | } // namespace V1_0 34 | } // namespace touch 35 | } // namespace lineage 36 | } // namespace vendor 37 | -------------------------------------------------------------------------------- /hidl/touch/vendor.lineage.touch@1.0-service.oplus.rc: -------------------------------------------------------------------------------- 1 | service vendor.touch-hal-1-0 /vendor/bin/hw/vendor.lineage.touch@1.0-service.oplus 2 | class hal 3 | user system 4 | group system 5 | -------------------------------------------------------------------------------- /hidl/touch/vendor.lineage.touch@1.0-service.oplus.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | vendor.lineage.touch 4 | hwbinder 5 | 1.0 6 | 7 | ITouchscreenGesture 8 | default 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/commondcs/ICommonDcsAidlHalService.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2025 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.commondcs; 8 | 9 | import vendor.oplus.hardware.commondcs.StringPair; 10 | 11 | @VintfStability 12 | interface ICommonDcsAidlHalService { 13 | int notifyMsgToCommonDcs(in List data, String logTag, String eventId); 14 | } 15 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/commondcs/StringPair.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2025 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.commondcs; 8 | 9 | @VintfStability 10 | parcelable StringPair { 11 | String key; 12 | String value; 13 | } 14 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/osense/client/IOsenseAidlHalReporter.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.osense.client; 8 | 9 | import vendor.oplus.hardware.osense.client.OsenseAidlHalNotifyRequest; 10 | import vendor.oplus.hardware.osense.client.OsenseAidlHalSaRequest; 11 | import vendor.oplus.hardware.osense.client.OsenseControlInfo; 12 | 13 | @VintfStability 14 | interface IOsenseAidlHalReporter { 15 | int checkAccessPermission(String identity); 16 | void osenseClrSceneAction(String identity, long request); 17 | void osenseSetNotification(String identity, in OsenseAidlHalNotifyRequest osenseHalNotifyRequest); 18 | void osenseSetSceneAction(String identity, in OsenseAidlHalSaRequest osenseHalSaRequest); 19 | void osenseResetCtrlData(String identity); 20 | void osenseSetCtrlData(String identity, in OsenseControlInfo ctrldata); 21 | } 22 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/osense/client/OsenseAidlHalNotifyRequest.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.osense.client; 8 | 9 | @VintfStability 10 | parcelable OsenseAidlHalNotifyRequest { 11 | int msg_src; 12 | int msg_type; 13 | int param1; 14 | int param2; 15 | int param3; 16 | String param4; 17 | } 18 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/osense/client/OsenseAidlHalSaRequest.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.osense.client; 8 | 9 | @VintfStability 10 | parcelable OsenseAidlHalSaRequest { 11 | String scene; 12 | String action; 13 | int timeout; 14 | long request; 15 | } 16 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/osense/client/OsenseControlInfo.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.osense.client; 8 | 9 | import vendor.oplus.hardware.osense.client.OsenseCpuControlData; 10 | import vendor.oplus.hardware.osense.client.OsenseCpuMIGData; 11 | import vendor.oplus.hardware.osense.client.OsenseGpuControlData; 12 | 13 | @VintfStability 14 | parcelable OsenseControlInfo { 15 | int cpu_cluster_num; 16 | int gpu_cluster_num; 17 | OsenseCpuControlData[] cpuParam1; 18 | OsenseGpuControlData[] param1; 19 | OsenseCpuMIGData[] cpu_mig_data; 20 | int control_mask; 21 | } 22 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/osense/client/OsenseCpuControlData.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.osense.client; 8 | 9 | import vendor.oplus.hardware.osense.client.OsenseDataRange; 10 | 11 | @VintfStability 12 | parcelable OsenseCpuControlData { 13 | OsenseDataRange core; 14 | OsenseDataRange freq; 15 | int control_type; 16 | } 17 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/osense/client/OsenseCpuMIGData.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.osense.client; 8 | 9 | @VintfStability 10 | parcelable OsenseCpuMIGData { 11 | int migUp; 12 | int migDown; 13 | } 14 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/osense/client/OsenseDataRange.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.osense.client; 8 | 9 | @VintfStability 10 | parcelable OsenseDataRange { 11 | int max; 12 | int min; 13 | } 14 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/osense/client/OsenseGpuControlData.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.osense.client; 8 | 9 | import vendor.oplus.hardware.osense.client.OsenseDataRange; 10 | 11 | @VintfStability 12 | parcelable OsenseGpuControlData { 13 | OsenseDataRange core; 14 | OsenseDataRange freq; 15 | int control_type; 16 | } 17 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/touch/IOplusTouch.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024-2025 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.touch; 8 | 9 | import vendor.oplus.hardware.touch.OplusTouchInfo; 10 | 11 | @VintfStability 12 | interface IOplusTouch { 13 | int initialize(); 14 | int isTouchNodeSupport(int deviceId, int nodeFlag); 15 | String touchReadNodeFile(int deviceId, int nodeFlag); 16 | int touchWriteNodeFile(int deviceId, int nodeFlag, String info); 17 | int touchWriteBtInfo(int deviceId, int nodeFlag, String info); 18 | void touchWriteNodeFileOneWay(int deviceId, int nodeFlag, String info); 19 | int touchNotifyClient(int clientFlag, in OplusTouchInfo info); 20 | } 21 | -------------------------------------------------------------------------------- /interfaces/aidl/vendor/oplus/hardware/touch/OplusTouchInfo.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2025 The LineageOS Project 3 | * 4 | * SPDX-License-Identifier: Apache-2.0 5 | */ 6 | 7 | package vendor.oplus.hardware.touch; 8 | 9 | @VintfStability 10 | parcelable OplusTouchInfo { 11 | String info; 12 | long time; 13 | int deviceId; 14 | int nodeFlag; 15 | int data; 16 | } 17 | -------------------------------------------------------------------------------- /interfaces/aidl_api/vendor.oplus.hardware.commondcs/1/.hash: -------------------------------------------------------------------------------- 1 | 09625174a36ecef0c9ef003e2a4efbdecd0d4657 2 | -------------------------------------------------------------------------------- /interfaces/aidl_api/vendor.oplus.hardware.osense.client/1/.hash: -------------------------------------------------------------------------------- 1 | f2f84fb4f333781b052895cec8412ff6bbe04680 2 | -------------------------------------------------------------------------------- /interfaces/aidl_api/vendor.oplus.hardware.touch/1/.hash: -------------------------------------------------------------------------------- 1 | 96d841410c418efe125914cb06730209b5fb78fe 2 | -------------------------------------------------------------------------------- /interfaces/aidl_api/vendor.oplus.hardware.touch/2/.hash: -------------------------------------------------------------------------------- 1 | ba896653ea356edaec80eb3dfeafefdc9b5c26ac 2 | -------------------------------------------------------------------------------- /interfaces/oplus/hardware/biometrics/fingerprint/2.1/Android.bp: -------------------------------------------------------------------------------- 1 | // This file is autogenerated by hidl-gen -Landroidbp. 2 | 3 | hidl_interface { 4 | name: "vendor.oplus.hardware.biometrics.fingerprint@2.1", 5 | root: "vendor.oplus", 6 | system_ext_specific: true, 7 | srcs: [ 8 | "IBiometricsFingerprint.hal", 9 | "IBiometricsFingerprintClientCallbackEx.hal", 10 | ], 11 | interfaces: [ 12 | "android.hardware.biometrics.fingerprint@2.1", 13 | "android.hardware.biometrics.fingerprint@2.2", 14 | "android.hardware.biometrics.fingerprint@2.3", 15 | "android.hidl.base@1.0", 16 | ], 17 | gen_java: true, 18 | } 19 | -------------------------------------------------------------------------------- /interfaces/oplus/hardware/biometrics/fingerprint/2.1/IBiometricsFingerprint.hal: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2022 The LineageOS Project 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | package vendor.oplus.hardware.biometrics.fingerprint@2.1; 18 | 19 | import android.hardware.biometrics.fingerprint@2.1::types; 20 | import android.hardware.biometrics.fingerprint@2.3; 21 | import IBiometricsFingerprintClientCallbackEx; 22 | 23 | interface IBiometricsFingerprint extends @2.3::IBiometricsFingerprint { 24 | setHalCallback(IBiometricsFingerprintClientCallbackEx clientCallback) generates (uint64_t deviceId); 25 | sendFingerprintCmd(int32_t cmdId, vec in_buf) generates (RequestStatus debugErrno); 26 | }; 27 | -------------------------------------------------------------------------------- /interfaces/oplus/hardware/biometrics/fingerprint/2.1/IBiometricsFingerprintClientCallbackEx.hal: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2022 The LineageOS Project 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | package vendor.oplus.hardware.biometrics.fingerprint@2.1; 18 | 19 | interface IBiometricsFingerprintClientCallbackEx { 20 | oneway onEngineeringInfoUpdated(uint32_t lenth, vec keys, vec values); 21 | oneway onFingerprintCmd(int32_t cmdId, vec result, uint32_t resultLen); 22 | }; 23 | -------------------------------------------------------------------------------- /interfaces/update-makefiles.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | source $ANDROID_BUILD_TOP/system/tools/hidl/update-makefiles-helper.sh 4 | 5 | do_makefiles_update \ 6 | "vendor.oplus:hardware/oplus/interfaces/oplus" 7 | -------------------------------------------------------------------------------- /kernel-headers/Android.bp: -------------------------------------------------------------------------------- 1 | cc_library_headers { 2 | name: "kernel_headers.oplus", 3 | export_include_dirs: ["include"], 4 | vendor: true, 5 | } 6 | -------------------------------------------------------------------------------- /kernel-headers/include/oplus/oplus_ir_core.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2025 The LineageOS Project 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | #pragma once 18 | 19 | #include 20 | 21 | #define IR_IOCTL_GROUP 0xE5 22 | 23 | #define IR_GET_INF _IO(IR_IOCTL_GROUP, 0x01) 24 | #define IR_SEND_PATTERN _IO(IR_IOCTL_GROUP, 0x02) 25 | 26 | struct pattern_params { 27 | int32_t carrier_freq; 28 | uint32_t size; 29 | uint32_t pattern[]; 30 | }; 31 | -------------------------------------------------------------------------------- /oplus-fwk/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2024 The LineageOS Project 3 | // 4 | // SPDX-License-Identifier: Apache-2.0 5 | // 6 | 7 | java_library { 8 | name: "oplus-fwk", 9 | installable: true, 10 | 11 | srcs: [ 12 | "src/**/*.aidl", 13 | "src/**/*.java", 14 | ], 15 | } 16 | -------------------------------------------------------------------------------- /oplus-fwk/oplus-fwk.mk: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2024 The LineageOS Project 3 | # 4 | # SPDX-License-Identifier: Apache-2.0 5 | # 6 | 7 | PRODUCT_PACKAGES += oplus-fwk 8 | PRODUCT_BOOT_JARS += oplus-fwk 9 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/app/OplusActivityManager.java: -------------------------------------------------------------------------------- 1 | package android.app; 2 | 3 | import android.os.RemoteException; 4 | 5 | import com.oplus.app.OplusAppInfo; 6 | 7 | import java.util.ArrayList; 8 | import java.util.List; 9 | 10 | public class OplusActivityManager { 11 | 12 | private static OplusActivityManager sOplusActivityManager = null; 13 | private static ArrayList sTopAppInfos = new ArrayList(); 14 | 15 | public static OplusActivityManager getInstance() { 16 | if (sOplusActivityManager == null) { 17 | sOplusActivityManager = new OplusActivityManager(); 18 | } 19 | return sOplusActivityManager; 20 | } 21 | 22 | public List getAllTopAppInfos() throws RemoteException { 23 | return (ArrayList) sTopAppInfos.clone(); 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/app/OplusWhiteListManager.java: -------------------------------------------------------------------------------- 1 | package android.app; 2 | 3 | import android.content.Context; 4 | 5 | import java.util.ArrayList; 6 | 7 | public class OplusWhiteListManager { 8 | 9 | public OplusWhiteListManager(Context context) {} 10 | 11 | public ArrayList getStageProtectListFromPkg(String calledPkg, int type) { 12 | return new ArrayList<>(); 13 | } 14 | 15 | public void addStageProtectInfo(String pkg, long timeout) {} 16 | 17 | public void removeStageProtectInfo(String pkg) {} 18 | } 19 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/app/job/IJobInfoExt.java: -------------------------------------------------------------------------------- 1 | package android.app.job; 2 | 3 | public interface IJobInfoExt { 4 | 5 | public final class JobBuilderExt { 6 | 7 | public boolean mIsOplusJob; 8 | 9 | public JobBuilderExt setRequiresBattIdle(boolean requiresBattIdle, int extra) { 10 | return this; 11 | } 12 | } 13 | 14 | default boolean getBooleanConstraint(String type, boolean defValue) { 15 | return defValue; 16 | } 17 | 18 | default String getStringConstraint(String type, String defValue) { 19 | return defValue; 20 | } 21 | 22 | default int getIntConstraint(String type, int defValue) { 23 | return defValue; 24 | } 25 | 26 | default long getLongConstraint(String type, long defValue) { 27 | return defValue; 28 | } 29 | 30 | default void setBooleanConstraint(String type, boolean value) {} 31 | 32 | default void setStringConstraint(String type, String value) {} 33 | 34 | default void setIntConstraint(String type, int value) {} 35 | 36 | default void setLongConstraint(JobInfo job, String type, long value) {} 37 | 38 | default void initJobInfo(Object in) {} 39 | 40 | default void initJobInfoPure(JobBuilderExt jobBuilderExt) {} 41 | 42 | default void writeToParcelJobInfo(Object out, int flags) {} 43 | } 44 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/bluetooth/OplusBluetoothAdapter.java: -------------------------------------------------------------------------------- 1 | package android.bluetooth; 2 | 3 | public class OplusBluetoothAdapter { 4 | 5 | private static OplusBluetoothAdapter sAdapter = null; 6 | 7 | public static OplusBluetoothAdapter getOplusBluetoothAdapter() { 8 | if (sAdapter == null) { 9 | sAdapter = new OplusBluetoothAdapter(); 10 | } 11 | return sAdapter; 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/common/IOplusCommonFactory.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package android.common; 7 | 8 | public interface IOplusCommonFactory { 9 | boolean isValid(int i); 10 | 11 | default T getFeature(T def, Object... vars) { 12 | verityParams(def); 13 | return def; 14 | } 15 | 16 | default void verityParams(T def) { 17 | if (def == null) { 18 | throw new IllegalArgumentException("def can not be null"); 19 | } 20 | if (def.index() == OplusFeatureList.OplusIndex.End) { 21 | throw new IllegalArgumentException(def + "must override index() method"); 22 | } 23 | } 24 | 25 | default void verityParamsType(String key, Object[] vars, int num, Class... types) { 26 | if (vars == null || types == null || vars.length != num || types.length != num) { 27 | throw new IllegalArgumentException(key + " need +" + num + " params"); 28 | } 29 | for (int i = 0; i < num; i++) { 30 | if (vars[i] != null && !types[i].isInstance(vars[i])) { 31 | throw new IllegalArgumentException(types[i].getName() + " is not instance " + vars[i]); 32 | } 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/common/IOplusCommonFeature.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package android.common; 7 | 8 | public interface IOplusCommonFeature { 9 | default OplusFeatureList.OplusIndex index() { 10 | return OplusFeatureList.OplusIndex.End; 11 | } 12 | 13 | default IOplusCommonFeature getDefault() { 14 | return null; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/common/OplusFrameworkFactory.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package android.common; 7 | 8 | public class OplusFrameworkFactory implements IOplusCommonFactory { 9 | public static OplusFrameworkFactory sInstance = null; 10 | 11 | public static OplusFrameworkFactory getInstance() { 12 | if (sInstance == null) { 13 | sInstance = new OplusFrameworkFactory(); 14 | } 15 | return sInstance; 16 | } 17 | 18 | @Override 19 | public boolean isValid(int index) { 20 | boolean validOplus = 21 | index < OplusFeatureList.OplusIndex.EndOplusFrameworkFactory.ordinal() && 22 | index > OplusFeatureList.OplusIndex.StartOplusFrameworkFactory.ordinal(); 23 | boolean vaildOplusOs = 24 | index < OplusFeatureList.OplusIndex.EndOplusOsFrameworkFactory.ordinal() && 25 | index > OplusFeatureList.OplusIndex.StartOplusOsFrameworkFactory.ordinal(); 26 | return vaildOplusOs || validOplus; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/content/res/OplusBaseConfiguration.java: -------------------------------------------------------------------------------- 1 | package android.content.res; 2 | 3 | import oplus.content.res.OplusExtraConfiguration; 4 | 5 | public abstract class OplusBaseConfiguration { 6 | 7 | public OplusExtraConfiguration getOplusExtraConfiguration() { 8 | return null; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/os/OplusKeyEventManager.java: -------------------------------------------------------------------------------- 1 | package android.os; 2 | 3 | import android.view.KeyEvent; 4 | 5 | public class OplusKeyEventManager { 6 | 7 | public interface OnKeyEventObserver { 8 | void onKeyEvent(KeyEvent event); 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/os/OplusManager.java: -------------------------------------------------------------------------------- 1 | package android.os; 2 | 3 | import java.util.Map; 4 | 5 | public class OplusManager { 6 | 7 | public static void onStamp(String eventId, Map logMap) {} 8 | } 9 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/os/OplusSystemProperties.java: -------------------------------------------------------------------------------- 1 | package android.os; 2 | 3 | public class OplusSystemProperties { 4 | 5 | public static String get(String key) { 6 | return SystemProperties.get(key); 7 | } 8 | 9 | public static String get(String key, String def) { 10 | return SystemProperties.get(key, def); 11 | } 12 | 13 | public static int getInt(String key, int def) { 14 | return SystemProperties.getInt(key, def); 15 | } 16 | 17 | public static boolean getBoolean(String key, boolean def) { 18 | return SystemProperties.getBoolean(key, def); 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/telephony/OplusTelephonyManager.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package android.telephony; 7 | 8 | import android.content.Context; 9 | 10 | public class OplusTelephonyManager { 11 | private static OplusTelephonyManager sInstance = null; 12 | 13 | public OplusTelephonyManager(Context context) {} 14 | 15 | public static OplusTelephonyManager getInstance(Context context) { 16 | if (sInstance == null) { 17 | sInstance = new OplusTelephonyManager(context); 18 | } 19 | return sInstance; 20 | } 21 | 22 | public String getImsType(int slotId) { 23 | return null; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/view/OplusWindowManager.java: -------------------------------------------------------------------------------- 1 | package android.view; 2 | 3 | public class OplusWindowManager { 4 | 5 | public OplusWindowManager() {} 6 | 7 | public void requestKeyguard(String command) {} 8 | } 9 | -------------------------------------------------------------------------------- /oplus-fwk/src/android/view/animation/OplusBezierInterpolator.java: -------------------------------------------------------------------------------- 1 | package android.view.animation; 2 | 3 | public class OplusBezierInterpolator extends BaseInterpolator { 4 | 5 | private static final float ABOVE_ZERO = 0.0001f; 6 | private static final float BELOW_ONE = 0.9999f; 7 | 8 | private static final double ABOVE_ONE = 1.0d; 9 | private static final double EPSILON = 0.0000625d; 10 | 11 | private OplusUnitBezier mOplusUnitBezier; 12 | 13 | private boolean mLimit; 14 | 15 | public OplusBezierInterpolator(double p1x, double p1y, double p2x, double p2y, boolean limit) { 16 | mLimit = limit; 17 | mOplusUnitBezier = new OplusUnitBezier(p1x, p1y, p2x, p2y); 18 | } 19 | 20 | @Override 21 | public float getInterpolation(float input) { 22 | double interpolation = mOplusUnitBezier.solve(input, EPSILON); 23 | if (mLimit) { 24 | final boolean above = input >= ABOVE_ZERO && input <= BELOW_ONE; 25 | if (interpolation > ABOVE_ONE && !above) { 26 | interpolation = ABOVE_ONE; 27 | } 28 | } 29 | return (float) interpolation; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/android/ims/IImsCallSessionImplWrapper.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package com.android.ims; 7 | 8 | public interface IImsCallSessionImplWrapper { 9 | default void unMuteStateReporting() {} 10 | } 11 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/android/internal/telephony/OplusFeature.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package com.android.internal.telephony; 7 | 8 | public class OplusFeature { 9 | public static final boolean OPLUS_FEATURE_CALL_RECOVERY_DISABLED = false; 10 | public static final boolean OPLUS_FEATURE_RADIO_VIRTUALMODEM = false; 11 | public static final boolean OPLUS_FEATURE_UST_CARRIER_CONFIG = false; 12 | public static final boolean OPLUS_FEATURE_UST_TOAST = false; 13 | } 14 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/android/internal/telephony/OplusFeatureHelper.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package com.android.internal.telephony; 7 | 8 | import com.oplus.content.OplusFeatureConfigManager; 9 | 10 | import java.util.List; 11 | 12 | public class OplusFeatureHelper { 13 | private static OplusFeatureHelper sInstance = null; 14 | 15 | public static OplusFeatureHelper getInstance() { 16 | if (sInstance == null) { 17 | sInstance = new OplusFeatureHelper(); 18 | } 19 | return sInstance; 20 | } 21 | 22 | public boolean hasFeature(String featureName) { 23 | return false; 24 | } 25 | 26 | public boolean enableFeature(String featureName) { 27 | return true; 28 | } 29 | 30 | public boolean disableFeature(String featureName) { 31 | return true; 32 | } 33 | 34 | public void notifyFeaturesUpdate(String action, String actionValue) {} 35 | 36 | public boolean registerFeatureObserver(List features, FeatureObserver observer) { 37 | return true; 38 | } 39 | 40 | public boolean unregisterFeatureObserver(FeatureObserver observer) { 41 | return true; 42 | } 43 | 44 | public static class FeatureObserver implements OplusFeatureConfigManager.OnFeatureObserver {} 45 | } 46 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/android/telephony/ims/aidl/IImsRil.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package android.telephony.ims.aidl; 7 | 8 | interface IImsRil { 9 | } 10 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/app/OPlusAccessControlManager.java: -------------------------------------------------------------------------------- 1 | package com.oplus.app; 2 | 3 | import android.os.UserHandle; 4 | 5 | public class OPlusAccessControlManager { 6 | 7 | private static OPlusAccessControlManager sOPlusAccessControlManager = null; 8 | 9 | public static final int USER_CURRENT = UserHandle.myUserId(); 10 | 11 | public static OPlusAccessControlManager getInstance() { 12 | if (sOPlusAccessControlManager == null) { 13 | sOPlusAccessControlManager = new OPlusAccessControlManager(); 14 | } 15 | return sOPlusAccessControlManager; 16 | } 17 | 18 | public boolean isEncryptPass(String packageName, int userId) { 19 | return true; 20 | } 21 | 22 | public boolean isEncryptedPackage(String packageName, int userId) { 23 | return true; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/app/OplusAppEnterInfo.java: -------------------------------------------------------------------------------- 1 | package com.oplus.app; 2 | 3 | public class OplusAppEnterInfo { 4 | 5 | public OplusAppEnterInfo() {} 6 | } 7 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/app/OplusAppExitInfo.java: -------------------------------------------------------------------------------- 1 | package com.oplus.app; 2 | 3 | public class OplusAppExitInfo { 4 | 5 | public OplusAppExitInfo() {} 6 | } 7 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/app/OplusAppInfo.java: -------------------------------------------------------------------------------- 1 | package com.oplus.app; 2 | 3 | public class OplusAppInfo { 4 | 5 | public OplusAppInfo() {} 6 | } 7 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/app/OplusAppSwitchConfig.java: -------------------------------------------------------------------------------- 1 | package com.oplus.app; 2 | 3 | import java.util.List; 4 | 5 | public class OplusAppSwitchConfig { 6 | 7 | public void addAppConfig(int type, List list) {} 8 | } 9 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/app/OplusAppSwitchManager.java: -------------------------------------------------------------------------------- 1 | package com.oplus.app; 2 | 3 | import android.content.Context; 4 | 5 | public class OplusAppSwitchManager { 6 | 7 | private static OplusAppSwitchManager sOplusAppSwitchManager = null; 8 | 9 | public static int APP_SWITCH_VERSION = 1; 10 | 11 | public static OplusAppSwitchManager getInstance() { 12 | if (sOplusAppSwitchManager == null) { 13 | sOplusAppSwitchManager = new OplusAppSwitchManager(); 14 | } 15 | return sOplusAppSwitchManager; 16 | } 17 | 18 | public boolean registerAppSwitchObserver(Context context, 19 | OnAppSwitchObserver observer, OplusAppSwitchConfig config) { 20 | return true; 21 | } 22 | 23 | public boolean unregisterAppSwitchObserver(Context context, OnAppSwitchObserver observer) { 24 | return true; 25 | } 26 | 27 | public interface OnAppSwitchObserver { 28 | 29 | void onActivityEnter(OplusAppEnterInfo oplusAppEnterInfo); 30 | 31 | void onActivityExit(OplusAppExitInfo oplusAppExitInfo); 32 | 33 | void onAppEnter(OplusAppEnterInfo oplusAppEnterInfo); 34 | 35 | void onAppExit(OplusAppExitInfo oplusAppExitInfo); 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/content/OplusFeatureConfigManager.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package com.oplus.content; 7 | 8 | import android.text.TextUtils; 9 | 10 | import java.util.List; 11 | 12 | public class OplusFeatureConfigManager { 13 | public static OplusFeatureConfigManager sInstance = null; 14 | 15 | public static OplusFeatureConfigManager getInstance() { 16 | if (sInstance == null) { 17 | sInstance = new OplusFeatureConfigManager(); 18 | } 19 | return sInstance; 20 | } 21 | 22 | public interface OnFeatureObserver { 23 | default void onFeatureUpdate(List features) {} 24 | } 25 | 26 | public boolean hasFeature(String name) { 27 | return false; 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/ims/IImsExt.aidl: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package com.oplus.ims; 7 | 8 | interface IImsExt { 9 | } 10 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/ims/stub/ImsServiceControllerExt.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2024 The LineageOS Project 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | package com.oplus.ims.stub; 7 | 8 | import android.content.Context; 9 | 10 | import com.oplus.ims.IImsExt; 11 | 12 | import java.util.concurrent.Executor; 13 | 14 | public class ImsServiceControllerExt { 15 | private final ImsExtStub mImsExtStub; 16 | 17 | public ImsServiceControllerExt(Context context, Executor executor) { 18 | mImsExtStub = new ImsExtStub(); 19 | } 20 | 21 | public IImsExt getIImsExt() { 22 | return mImsExtStub; 23 | } 24 | 25 | public static class ImsExtStub extends IImsExt.Stub {} 26 | } 27 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/orms/OplusResourceManager.java: -------------------------------------------------------------------------------- 1 | package com.oplus.orms; 2 | 3 | import com.oplus.orms.info.OrmsSaParam; 4 | 5 | public class OplusResourceManager { 6 | 7 | private static OplusResourceManager sOplusResourceManager = null; 8 | 9 | public static OplusResourceManager getInstance(Class clazz) { 10 | if (sOplusResourceManager == null) { 11 | sOplusResourceManager = new OplusResourceManager(); 12 | } 13 | return sOplusResourceManager; 14 | } 15 | 16 | public long ormsSetSceneAction(OrmsSaParam ormsSaParam) { 17 | return -1L; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/orms/info/OrmsSaParam.java: -------------------------------------------------------------------------------- 1 | package com.oplus.orms.info; 2 | 3 | public class OrmsSaParam { 4 | 5 | public OrmsSaParam() {} 6 | 7 | public OrmsSaParam(String scene, String action, int timeout) {} 8 | } 9 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/os/OplusBuild.java: -------------------------------------------------------------------------------- 1 | package com.oplus.os; 2 | 3 | public class OplusBuild { 4 | 5 | public static final int OplusOS_11_3 = 22; 6 | 7 | public static int getOplusOSVERSION() { 8 | return 23; 9 | } 10 | 11 | public static class VERSION { 12 | public static final String RELEASE = "unknown"; 13 | 14 | public static final int SDK_VERSION = getOplusOSVERSION(); 15 | public static final int SDK_SUB_VERSION = 1; 16 | } 17 | 18 | } 19 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/osense/OsenseResClient.java: -------------------------------------------------------------------------------- 1 | package com.oplus.osense; 2 | 3 | public class OsenseResClient { 4 | 5 | public static OsenseResClient get(Class clazz) { 6 | return null; 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/osense/OsenseResEventClient.java: -------------------------------------------------------------------------------- 1 | package com.oplus.osense; 2 | 3 | public class OsenseResEventClient { 4 | 5 | private static OsenseResEventClient sInstance; 6 | 7 | public static OsenseResEventClient getInstance() { 8 | if (sInstance == null) { 9 | sInstance = new OsenseResEventClient(); 10 | } 11 | return sInstance; 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/osense/eventinfo/IOsenseEventCallback.java: -------------------------------------------------------------------------------- 1 | package com.oplus.osense.eventinfo; 2 | 3 | import android.os.Binder; 4 | import android.os.IBinder; 5 | import android.os.IInterface; 6 | 7 | public interface IOsenseEventCallback extends IInterface { 8 | 9 | public static class Default implements IOsenseEventCallback { 10 | @Override 11 | public IBinder asBinder() { 12 | return null; 13 | } 14 | } 15 | 16 | public static abstract class Stub extends Binder implements IOsenseEventCallback { 17 | @Override 18 | public IBinder asBinder() { 19 | return this; 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/osense/eventinfo/OsenseEventCallback.java: -------------------------------------------------------------------------------- 1 | package com.oplus.osense.eventinfo; 2 | 3 | import com.oplus.osense.eventinfo.IOsenseEventCallback; 4 | 5 | public class OsenseEventCallback extends IOsenseEventCallback.Stub { 6 | } 7 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/screenshot/OplusLongshotCustomController.java: -------------------------------------------------------------------------------- 1 | package com.oplus.screenshot; 2 | 3 | public class OplusLongshotCustomController { 4 | 5 | public OplusLongshotCustomController(OplusLongshotViewBase view, String source) {} 6 | } 7 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/screenshot/OplusLongshotViewBase.java: -------------------------------------------------------------------------------- 1 | package com.oplus.screenshot; 2 | 3 | import android.content.Context; 4 | 5 | public interface OplusLongshotViewBase { 6 | 7 | boolean canLongScroll(); 8 | 9 | int computeLongScrollExtent(); 10 | 11 | int computeLongScrollOffset(); 12 | 13 | int computeLongScrollRange(); 14 | 15 | boolean findViewsLongshotInfo(OplusLongshowViewInfo oplusLongshowViewInfo); 16 | 17 | Context getContext(); 18 | 19 | boolean isLongshotVisibleToUser(); 20 | } 21 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/screenshot/OplusLongshowViewInfo.java: -------------------------------------------------------------------------------- 1 | package com.oplus.screenshot; 2 | 3 | public class OplusLongshowViewInfo { 4 | 5 | public OplusLongshowViewInfo() {} 6 | } 7 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/uifirst/OplusUIFirstManager.java: -------------------------------------------------------------------------------- 1 | package com.oplus.uifirst; 2 | 3 | public class OplusUIFirstManager { 4 | 5 | private static OplusUIFirstManager sOplusUIFirstManager = null; 6 | 7 | public static OplusUIFirstManager getInstance() { 8 | if (sOplusUIFirstManager == null) { 9 | sOplusUIFirstManager = new OplusUIFirstManager(); 10 | } 11 | return sOplusUIFirstManager; 12 | } 13 | 14 | public void setUxThreadValue(int pid, int tid, String value) {} 15 | } 16 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/wrapper/os/PowerManager.java: -------------------------------------------------------------------------------- 1 | package com.oplus.wrapper.os; 2 | 3 | public class PowerManager { 4 | 5 | private final android.os.PowerManager mPowerManager; 6 | 7 | public PowerManager(android.os.PowerManager powerManager) { 8 | mPowerManager = powerManager; 9 | } 10 | 11 | public int getMaximumScreenBrightnessSetting() { 12 | return mPowerManager.getMaximumScreenBrightnessSetting(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/wrapper/os/ServiceManager.java: -------------------------------------------------------------------------------- 1 | package com.oplus.wrapper.os; 2 | 3 | import android.os.IBinder; 4 | 5 | public class ServiceManager { 6 | 7 | public static IBinder checkService(String name) { 8 | return android.os.ServiceManager.checkService(name); 9 | } 10 | 11 | public static IBinder getService(String name) { 12 | return android.os.ServiceManager.getService(name); 13 | } 14 | 15 | public static void addService(String name, IBinder token) { 16 | android.os.ServiceManager.addService(name, token); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/wrapper/os/SystemProperties.java: -------------------------------------------------------------------------------- 1 | package com.oplus.wrapper.os; 2 | 3 | public class SystemProperties { 4 | 5 | public static String get(String key) { 6 | return android.os.SystemProperties.get(key, ""); 7 | } 8 | 9 | public static String get(String key, String def) { 10 | return android.os.SystemProperties.get(key, def); 11 | } 12 | 13 | public static int getInt(String key, int def) { 14 | return android.os.SystemProperties.getInt(key, def); 15 | } 16 | 17 | public static boolean getBoolean(String key, boolean def) { 18 | return android.os.SystemProperties.getBoolean(key, def); 19 | } 20 | 21 | public static void set(String key, String val) { 22 | android.os.SystemProperties.set(key, val); 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/zoomwindow/IOplusZoomWindowObserver.aidl: -------------------------------------------------------------------------------- 1 | package com.oplus.zoomwindow; 2 | 3 | import com.oplus.zoomwindow.OplusZoomWindowInfo; 4 | 5 | interface IOplusZoomWindowObserver { 6 | 7 | void onInputMethodChanged(boolean isShown); 8 | void onZoomWindowDied(String appName); 9 | void onZoomWindowHide(inout OplusZoomWindowInfo info); 10 | void onZoomWindowShow(inout OplusZoomWindowInfo info); 11 | } 12 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/zoomwindow/OplusZoomWindowInfo.aidl: -------------------------------------------------------------------------------- 1 | package com.oplus.zoomwindow; 2 | 3 | parcelable OplusZoomWindowInfo; 4 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/zoomwindow/OplusZoomWindowInfo.java: -------------------------------------------------------------------------------- 1 | package com.oplus.zoomwindow; 2 | 3 | import android.os.Parcel; 4 | import android.os.Parcelable; 5 | 6 | public class OplusZoomWindowInfo implements Parcelable { 7 | 8 | public static final Parcelable.Creator CREATOR = 9 | new Parcelable.Creator() { 10 | 11 | @Override 12 | public OplusZoomWindowInfo createFromParcel(Parcel source) { 13 | return new OplusZoomWindowInfo(source); 14 | } 15 | 16 | @Override 17 | public OplusZoomWindowInfo[] newArray(int size) { 18 | return new OplusZoomWindowInfo[size]; 19 | } 20 | }; 21 | 22 | public OplusZoomWindowInfo() {} 23 | 24 | public OplusZoomWindowInfo(Parcel in) {} 25 | 26 | public OplusZoomWindowInfo(OplusZoomWindowInfo in) {} 27 | 28 | @Override 29 | public int describeContents() { 30 | return 0; 31 | } 32 | 33 | @Override 34 | public void writeToParcel(Parcel dest, int flags) {} 35 | 36 | public void readFromParcel(Parcel in) {} 37 | } 38 | -------------------------------------------------------------------------------- /oplus-fwk/src/com/oplus/zoomwindow/OplusZoomWindowManager.java: -------------------------------------------------------------------------------- 1 | package com.oplus.zoomwindow; 2 | 3 | public class OplusZoomWindowManager { 4 | 5 | public static OplusZoomWindowManager sOplusZoomWindowManager = null; 6 | 7 | public static OplusZoomWindowManager getInstance() { 8 | if (sOplusZoomWindowManager == null) { 9 | sOplusZoomWindowManager = new OplusZoomWindowManager(); 10 | } 11 | return sOplusZoomWindowManager; 12 | } 13 | 14 | public boolean registerZoomWindowObserver(IOplusZoomWindowObserver observer) { 15 | return false; 16 | } 17 | 18 | public boolean unregisterZoomWindowObserver(IOplusZoomWindowObserver observer) { 19 | return false; 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /oplus-fwk/src/net/oneplus/odm/OpDeviceManagerInjector.java: -------------------------------------------------------------------------------- 1 | package net.oneplus.odm; 2 | 3 | import android.content.Context; 4 | 5 | import java.util.Map; 6 | 7 | public class OpDeviceManagerInjector { 8 | 9 | private static OpDeviceManagerInjector sOpDeviceManagerInjector = null; 10 | 11 | public void preserveAppData(Context a, String b, Map c, Map d) {} 12 | 13 | public static OpDeviceManagerInjector getInstance() { 14 | if (sOpDeviceManagerInjector == null) { 15 | sOpDeviceManagerInjector = new OpDeviceManagerInjector(); 16 | } 17 | return sOpDeviceManagerInjector; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /oplus-fwk/src/oplus/content/res/OplusExtraConfiguration.java: -------------------------------------------------------------------------------- 1 | package oplus.content.res; 2 | 3 | public class OplusExtraConfiguration { 4 | 5 | public OplusExtraConfiguration() {} 6 | } 7 | -------------------------------------------------------------------------------- /overlay/generic/Android.bp: -------------------------------------------------------------------------------- 1 | soong_namespace { 2 | } 3 | -------------------------------------------------------------------------------- /overlay/generic/FrameworksResGeneric/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2023 The LineageOS Project 3 | // SPDX-License-Identifier: Apache-2.0 4 | // 5 | 6 | runtime_resource_overlay { 7 | name: "FrameworksResGeneric", 8 | vendor: true, 9 | } 10 | -------------------------------------------------------------------------------- /overlay/generic/FrameworksResGeneric/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 8 | 9 | 13 | 14 | -------------------------------------------------------------------------------- /overlay/generic/FrameworksResGeneric/res/values/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 10 | com.google.android.euicc 11 | 12 | 13 | -------------------------------------------------------------------------------- /overlay/generic/SettingsProviderResGeneric/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2023 The LineageOS Project 3 | // SPDX-License-Identifier: Apache-2.0 4 | // 5 | 6 | runtime_resource_overlay { 7 | name: "SettingsProviderResGeneric", 8 | vendor: true, 9 | } 10 | -------------------------------------------------------------------------------- /overlay/generic/SettingsProviderResGeneric/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 8 | 9 | 13 | 14 | -------------------------------------------------------------------------------- /overlay/generic/SettingsProviderResGeneric/res/values/defaults.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | true 10 | 11 | 12 | -------------------------------------------------------------------------------- /overlay/generic/generic.mk: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2023 The LineageOS Project 3 | # 4 | # SPDX-License-Identifier: Apache-2.0 5 | # 6 | 7 | PRODUCT_PACKAGES += \ 8 | FrameworksResGeneric \ 9 | SettingsProviderResGeneric 10 | 11 | PRODUCT_SOONG_NAMESPACES += \ 12 | $(LOCAL_PATH) 13 | -------------------------------------------------------------------------------- /overlay/qssi/Android.bp: -------------------------------------------------------------------------------- 1 | soong_namespace { 2 | } 3 | -------------------------------------------------------------------------------- /overlay/qssi/FrameworksResCommon/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2022 The LineageOS Project 3 | // SPDX-License-Identifier: Apache-2.0 4 | // 5 | 6 | runtime_resource_overlay { 7 | name: "FrameworksResCommon", 8 | vendor: true, 9 | } 10 | -------------------------------------------------------------------------------- /overlay/qssi/FrameworksResCommon/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 8 | 9 | 13 | 14 | -------------------------------------------------------------------------------- /overlay/qssi/FrameworksResCommon/res/values-mcc310-mnc120/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 13 | 6 14 | 15 | 16 | -------------------------------------------------------------------------------- /overlay/qssi/FrameworksResCommon/res/values-mcc310-mnc260/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 13 | 3 14 | 15 | 16 | -------------------------------------------------------------------------------- /overlay/qssi/FrameworksResCommon/res/values-mcc310-mnc4/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 13 | 6 14 | 15 | 16 | -------------------------------------------------------------------------------- /overlay/qssi/FrameworksResCommon/res/values-mcc310-mnc410/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 13 | 3 14 | 15 | 16 | -------------------------------------------------------------------------------- /overlay/qssi/FrameworksResCommon/res/values-mcc311-mnc480/bools.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 11 | true 12 | 13 | 14 | -------------------------------------------------------------------------------- /overlay/qssi/FrameworksResCommon/res/values-mcc311-mnc480/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 13 | 6 14 | 15 | 16 | -------------------------------------------------------------------------------- /overlay/qssi/FrameworksResCommon/res/values-mcc460-mnc11/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 13 | 6 14 | 15 | 16 | -------------------------------------------------------------------------------- /overlay/qssi/FrameworksResCommon/res/values-mcc460-mnc3/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 13 | 6 14 | 15 | 16 | -------------------------------------------------------------------------------- /overlay/qssi/OPlusWifiResCommon/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2022 The LineageOS Project 3 | // SPDX-License-Identifier: Apache-2.0 4 | // 5 | 6 | runtime_resource_overlay { 7 | name: "OPlusWifiResCommon", 8 | vendor: true, 9 | } 10 | -------------------------------------------------------------------------------- /overlay/qssi/OPlusWifiResCommon/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 8 | 9 | 14 | 15 | -------------------------------------------------------------------------------- /overlay/qssi/SystemUIResCommon/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2022 The LineageOS Project 3 | // SPDX-License-Identifier: Apache-2.0 4 | // 5 | 6 | runtime_resource_overlay { 7 | name: "SystemUIResCommon", 8 | vendor: true, 9 | } 10 | -------------------------------------------------------------------------------- /overlay/qssi/SystemUIResCommon/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 8 | 9 | 13 | 14 | -------------------------------------------------------------------------------- /overlay/qssi/TelephonyResCommon/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2022 The LineageOS Project 3 | // SPDX-License-Identifier: Apache-2.0 4 | // 5 | 6 | runtime_resource_overlay { 7 | name: "TelephonyResCommon", 8 | vendor: true, 9 | } 10 | -------------------------------------------------------------------------------- /overlay/qssi/TelephonyResCommon/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 8 | 9 | 13 | 14 | -------------------------------------------------------------------------------- /overlay/qssi/WifiResCommon/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2022 The LineageOS Project 3 | // SPDX-License-Identifier: Apache-2.0 4 | // 5 | 6 | runtime_resource_overlay { 7 | name: "WifiResCommon", 8 | vendor: true, 9 | } 10 | -------------------------------------------------------------------------------- /overlay/qssi/WifiResCommon/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 8 | 9 | 14 | 15 | -------------------------------------------------------------------------------- /overlay/qssi/qssi.mk: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2022 The LineageOS Project 3 | # 4 | # SPDX-License-Identifier: Apache-2.0 5 | # 6 | 7 | PRODUCT_PACKAGES += \ 8 | FrameworksResCommon \ 9 | OPlusWifiResCommon \ 10 | SystemUIResCommon \ 11 | TelephonyResCommon \ 12 | WifiResCommon 13 | 14 | PRODUCT_SOONG_NAMESPACES += \ 15 | $(LOCAL_PATH) 16 | -------------------------------------------------------------------------------- /sensors/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2022-2024 The LineageOS Project 3 | // 4 | // SPDX-License-Identifier: Apache-2.0 5 | // 6 | 7 | cc_library_shared { 8 | name: "sensors.oplus", 9 | defaults: ["hidl_defaults"], 10 | srcs: [ 11 | "Sensor.cpp", 12 | "SensorsSubHal.cpp", 13 | ], 14 | shared_libs: [ 15 | "android.hardware.sensors@1.0", 16 | "android.hardware.sensors@2.0", 17 | "android.hardware.sensors@2.0-ScopedWakelock", 18 | "android.hardware.sensors@2.1", 19 | "libcutils", 20 | "libfmq", 21 | "libhardware", 22 | "libhidlbase", 23 | "liblog", 24 | "libpower", 25 | "libutils", 26 | ], 27 | static_libs: [ 28 | "android.hardware.sensors@1.0-convert", 29 | "android.hardware.sensors@2.X-multihal", 30 | ], 31 | cflags: [ 32 | "-DLOG_TAG=\"sensors.oplus\"", 33 | ], 34 | vendor: true, 35 | } 36 | 37 | cc_library_shared { 38 | name: "sensors.ssc_custom_flag", 39 | srcs: ["SensorsSscCustomFlag.cpp"], 40 | vendor: true, 41 | } 42 | -------------------------------------------------------------------------------- /sepolicy/qti/SEPolicy.mk: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2022-2024 The LineageOS Project 3 | # 4 | # SPDX-License-Identifier: Apache-2.0 5 | # 6 | 7 | SEPOLICY_PLATFORM := $(subst device/qcom/sepolicy_vndr/,,$(SEPOLICY_PATH)) 8 | 9 | BOARD_VENDOR_SEPOLICY_DIRS += \ 10 | hardware/oplus/sepolicy/qti/vendor \ 11 | hardware/oplus/sepolicy/qti/vendor/$(SEPOLICY_PLATFORM) 12 | 13 | SYSTEM_EXT_PRIVATE_SEPOLICY_DIRS += \ 14 | hardware/oplus/sepolicy/qti/private \ 15 | hardware/oplus/sepolicy/qti/private/$(SEPOLICY_PLATFORM) 16 | 17 | SYSTEM_EXT_PUBLIC_SEPOLICY_DIRS += \ 18 | hardware/oplus/sepolicy/qti/public \ 19 | hardware/oplus/sepolicy/qti/public/$(SEPOLICY_PLATFORM) 20 | 21 | ifneq ($(SEPOLICY_PLATFORM), legacy-um) 22 | BOARD_VENDOR_SEPOLICY_DIRS += \ 23 | hardware/oplus/sepolicy/qti/vendor/common-um 24 | 25 | SYSTEM_EXT_PRIVATE_SEPOLICY_DIRS += \ 26 | hardware/oplus/sepolicy/qti/private/common-um 27 | 28 | SYSTEM_EXT_PUBLIC_SEPOLICY_DIRS += \ 29 | hardware/oplus/sepolicy/qti/public/common-um 30 | endif 31 | 32 | include device/lineage/sepolicy/libperfmgr/sepolicy.mk 33 | -------------------------------------------------------------------------------- /sepolicy/qti/private/compat/32.0/32.0.ignore.cil: -------------------------------------------------------------------------------- 1 | ;; new_objects - a collection of types that have been introduced that have no 2 | ;; analogue in older policy. Thus, we do not need to map these types to 3 | ;; previous ones. Add here to pass checkapi tests. 4 | (type new_objects) 5 | (typeattribute new_objects) 6 | (typeattributeset new_objects 7 | ( new_objects 8 | system_fingerprint_prop 9 | system_oplus_iris_prop 10 | system_oplus_project_prop 11 | system_oplus_touch_prop 12 | vendor_persist_engineer_file)) 13 | -------------------------------------------------------------------------------- /sepolicy/qti/private/compat/33.0/33.0.ignore.cil: -------------------------------------------------------------------------------- 1 | ;; new_objects - a collection of types that have been introduced that have no 2 | ;; analogue in older policy. Thus, we do not need to map these types to 3 | ;; previous ones. Add here to pass checkapi tests. 4 | (type new_objects) 5 | (typeattribute new_objects) 6 | (typeattributeset new_objects 7 | ( new_objects 8 | system_fingerprint_prop 9 | system_oplus_iris_prop 10 | system_oplus_project_prop 11 | system_oplus_touch_prop 12 | vendor_persist_engineer_file)) 13 | -------------------------------------------------------------------------------- /sepolicy/qti/private/file_contexts: -------------------------------------------------------------------------------- 1 | # Sensors 2 | /(system_ext|system/system_ext)/bin/hw/vendor\.lineage\.oplus_als.service u:object_r:hal_lineage_oplus_als_aidl_exec:s0 3 | -------------------------------------------------------------------------------- /sepolicy/qti/private/hal_lineage_oplus_als_aidl.te: -------------------------------------------------------------------------------- 1 | type hal_lineage_oplus_als_aidl, domain, coredomain; 2 | binder_use(hal_lineage_oplus_als_aidl) 3 | 4 | allow hal_lineage_oplus_als_aidl fwk_stats_service:service_manager find; 5 | binder_call(hal_lineage_oplus_als_aidl, system_server) 6 | 7 | hal_server_domain(hal_lineage_oplus_als_aidl, hal_lineage_oplus_als) 8 | 9 | type hal_lineage_oplus_als_aidl_exec, exec_type, system_file_type, file_type; 10 | init_daemon_domain(hal_lineage_oplus_als_aidl) 11 | 12 | binder_call(hal_lineage_oplus_als_client, hal_lineage_oplus_als_server) 13 | 14 | hal_attribute_service(hal_lineage_oplus_als, hal_lineage_oplus_als_aidl_service) 15 | 16 | hal_client_domain(hal_lineage_oplus_als_aidl, hal_graphics_allocator) 17 | 18 | binder_call(hal_lineage_oplus_als_aidl, surfaceflinger) 19 | binder_call(surfaceflinger, hal_lineage_oplus_als_aidl) 20 | 21 | allow hal_lineage_oplus_als_aidl hal_graphics_allocator_hwservice:hwservice_manager find; 22 | allow hal_lineage_oplus_als_aidl hal_graphics_mapper_hwservice:hwservice_manager find; 23 | 24 | allow hal_lineage_oplus_als_aidl surfaceflinger_service:service_manager find; 25 | 26 | allow hal_lineage_oplus_als_aidl ion_device:chr_file rw_file_perms; 27 | 28 | get_prop(hal_lineage_oplus_als_aidl, vendor_sensors_als_prop) 29 | -------------------------------------------------------------------------------- /sepolicy/qti/private/service_contexts: -------------------------------------------------------------------------------- 1 | # Sensors 2 | vendor.lineage.oplus_als.IAreaCapture/default u:object_r:hal_lineage_oplus_als_aidl_service:s0 3 | -------------------------------------------------------------------------------- /sepolicy/qti/public/attributes: -------------------------------------------------------------------------------- 1 | hal_attribute(lineage_oplus_als) 2 | -------------------------------------------------------------------------------- /sepolicy/qti/public/file.te: -------------------------------------------------------------------------------- 1 | # Engineering 2 | type vendor_persist_engineer_file, file_type; 3 | -------------------------------------------------------------------------------- /sepolicy/qti/public/property.te: -------------------------------------------------------------------------------- 1 | # Display 2 | vendor_internal_prop(system_oplus_iris_prop) 3 | 4 | # Fingerprint 5 | vendor_internal_prop(system_fingerprint_prop) 6 | 7 | # Radio 8 | system_public_prop(system_oplus_radio_prop) 9 | 10 | # Sensors 11 | system_public_prop(vendor_sensors_als_prop) 12 | 13 | # Touch 14 | system_public_prop(system_oplus_touch_prop) 15 | 16 | # Version 17 | system_vendor_config_prop(system_oplus_project_prop) 18 | -------------------------------------------------------------------------------- /sepolicy/qti/public/service.te: -------------------------------------------------------------------------------- 1 | type hal_lineage_oplus_als_aidl_service, hal_service_type, service_manager_type; 2 | -------------------------------------------------------------------------------- /sepolicy/qti/public/te_macros: -------------------------------------------------------------------------------- 1 | ##################################### 2 | # vendor_hal_attribute(hal_name) 3 | # Add an attribute for vendor hal implementations. 4 | define(`vendor_hal_attribute', ` 5 | attribute vendor_hal_$1; 6 | attribute vendor_hal_$1_client; 7 | attribute vendor_hal_$1_server; 8 | ') 9 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/attributes: -------------------------------------------------------------------------------- 1 | vendor_hal_attribute(cameraMDM) 2 | vendor_hal_attribute(oplusSensor) 3 | vendor_hal_attribute(oplus_cammidasservice) 4 | vendor_hal_attribute(oplus_commondcs) 5 | vendor_hal_attribute(oplus_osense) 6 | vendor_hal_attribute(oplus_performance) 7 | vendor_hal_attribute(oplus_project) 8 | vendor_hal_attribute(oplus_touch) 9 | vendor_hal_attribute(oplus_touchdaemon) 10 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/common-um/hal_fingerprint_default.te: -------------------------------------------------------------------------------- 1 | allow hal_fingerprint_default vendor_dmabuf_qseecom_heap_device:chr_file r_file_perms; 2 | allow hal_fingerprint_default vendor_dmabuf_qseecom_ta_heap_device:chr_file r_file_perms; 3 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/common-um/rild.te: -------------------------------------------------------------------------------- 1 | allow rild vendor_qms_service:service_manager find; 2 | 3 | hal_client_domain(rild, vendor_hal_qms_qti) 4 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/device.te: -------------------------------------------------------------------------------- 1 | # Fingerprint 2 | type fingerprint_device, dev_type; 3 | 4 | # IR 5 | type oplus_consumer_ir_device, dev_type; 6 | 7 | # Reserve 8 | type vendor_reserve_partition, dev_type; 9 | 10 | # Sensors 11 | type ssc_interactive_device, dev_type; 12 | 13 | # TOF 14 | type vendor_tof_device, dev_type; 15 | 16 | # Touch 17 | type oplus_touchdaemon_device, dev_type; 18 | 19 | # Ultrasound 20 | type ultrasound_device, dev_type; 21 | 22 | # Vibrator 23 | type aac_richtap_device, dev_type; 24 | 25 | # Wlchgmonitor 26 | type wlchg_device, dev_type; 27 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/fastbootd.te: -------------------------------------------------------------------------------- 1 | recovery_only(` 2 | allow fastbootd vendor_efs_boot_dev:blk_file rw_file_perms; 3 | allow fastbootd vendor_modem_efs_partition_device:blk_file rw_file_perms; 4 | ') 5 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/file.te: -------------------------------------------------------------------------------- 1 | # Alert Slider 2 | type vendor_proc_tri_state_key, fs_type, proc_type; 3 | 4 | # Camera 5 | type vendor_camera_update_data_file, file_type, data_file_type; 6 | type vendor_persist_camera_file, file_type; 7 | 8 | # Charging 9 | type vendor_proc_wireless, fs_type, proc_type; 10 | 11 | # Display 12 | type vendor_proc_display, fs_type, proc_type; 13 | 14 | # Engineering 15 | type vendor_proc_engineer, fs_type, proc_type; 16 | 17 | # Fingerprint 18 | type vendor_persist_fingerprint_file, file_type; 19 | type vendor_proc_fingerprint, fs_type, proc_type; 20 | 21 | # Flash 22 | type vendor_proc_flash, fs_type, proc_type; 23 | 24 | # Graphics 25 | type vendor_sysfs_sde_crtc, fs_type, sysfs_type; 26 | 27 | # Input 28 | type proc_bus_input, fs_type, proc_type; 29 | 30 | # Performance 31 | type vendor_proc_oplus_scheduler, fs_type, proc_type; 32 | 33 | # Sensors 34 | type vendor_proc_eng_cali_file, fs_type, proc_type; 35 | type vendor_proc_oplus_als_file, fs_type, proc_type; 36 | type vendor_sysfs_sensor_fb, fs_type, sysfs_type; 37 | 38 | # TOF 39 | type vendor_sysfs_tof, fs_type, sysfs_type; 40 | 41 | # Touch 42 | type oplus_touchdaemon_socket, file_type; 43 | type vendor_persist_oplus_touch_file, file_type, data_file_type; 44 | type vendor_proc_oplus_touch, fs_type, proc_type; 45 | 46 | # Ultrasound 47 | type vendor_proc_ultrasound, fs_type, proc_type; 48 | 49 | # Versioning 50 | type vendor_proc_oplus_version, fs_type, proc_type; 51 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_audio_default.te: -------------------------------------------------------------------------------- 1 | allow hal_audio_default ultrasound_device:chr_file rw_file_perms; 2 | 3 | get_prop(hal_audio_default, boot_status_prop) 4 | get_prop(hal_audio_default, vendor_audio_debug_prop) 5 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_bluetooth_default.te: -------------------------------------------------------------------------------- 1 | hal_client_domain(hal_bluetooth_default, vendor_hal_oplus_project) 2 | 3 | r_dir_file(hal_bluetooth_default, vendor_proc_oplus_version) 4 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_bootctl.te: -------------------------------------------------------------------------------- 1 | allow hal_bootctl vendor_modem_efs_partition_device:blk_file getattr; 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_face_default.te: -------------------------------------------------------------------------------- 1 | allow hal_face_default gpu_device:chr_file rw_file_perms; 2 | allow hal_face_default tee_device:chr_file rw_file_perms; 3 | get_prop(hal_face_default, camera_config_prop) 4 | get_prop(hal_face_default, system_oplus_project_prop) 5 | set_prop(hal_face_default, vendor_face_prop) 6 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_graphics_composer_default.te: -------------------------------------------------------------------------------- 1 | binder_call(hal_graphics_composer_default, hal_graphics_composer_default) 2 | 3 | allow hal_graphics_composer_default vendor_proc_display:file r_file_perms; 4 | 5 | set_prop(hal_graphics_composer_default, system_oplus_iris_prop) 6 | get_prop(hal_graphics_composer_default, system_oplus_project_prop) 7 | set_prop(hal_graphics_composer_default, vendor_display_prop) 8 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_ir_default.te: -------------------------------------------------------------------------------- 1 | allow hal_ir_default oplus_consumer_ir_device:chr_file rw_file_perms; 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_lineage_livedisplay_qti.te: -------------------------------------------------------------------------------- 1 | allow hal_lineage_livedisplay_qti graphics_device:chr_file rw_file_perms; 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_lineage_powershare_default.te: -------------------------------------------------------------------------------- 1 | rw_dir_file(hal_lineage_powershare_default, vendor_proc_wireless) 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_lineage_touch_default.te: -------------------------------------------------------------------------------- 1 | rw_dir_file(hal_lineage_touch_default, vendor_proc_display) 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_nfc_default.te: -------------------------------------------------------------------------------- 1 | allow hal_nfc_default vendor_nfc_vendor_data_file:dir search; 2 | 3 | set_prop(hal_nfc_default, vendor_nfc_nq_prop) 4 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_oplus_cammidasservice_aidl.te: -------------------------------------------------------------------------------- 1 | type hal_oplus_cammidasservice_aidl, domain; 2 | binder_use(hal_oplus_cammidasservice_aidl) 3 | 4 | allow hal_oplus_cammidasservice_aidl fwk_stats_service:service_manager find; 5 | binder_call(hal_oplus_cammidasservice_aidl, system_server) 6 | 7 | hal_server_domain(hal_oplus_cammidasservice_aidl, vendor_hal_oplus_cammidasservice) 8 | 9 | type hal_oplus_cammidasservice_aidl_exec, exec_type, vendor_file_type, file_type; 10 | init_daemon_domain(hal_oplus_cammidasservice_aidl) 11 | 12 | binder_call(vendor_hal_oplus_cammidasservice_client, vendor_hal_oplus_cammidasservice_server) 13 | 14 | hal_attribute_service(vendor_hal_oplus_cammidasservice, hal_oplus_cammidasservice_aidl_service) 15 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_oplus_commondcs_aidl.te: -------------------------------------------------------------------------------- 1 | type hal_oplus_commondcs_aidl, domain; 2 | binder_use(hal_oplus_commondcs_aidl) 3 | 4 | hal_server_domain(hal_oplus_commondcs_aidl, vendor_hal_oplus_commondcs) 5 | 6 | type hal_oplus_commondcs_aidl_exec, exec_type, vendor_file_type, file_type; 7 | init_daemon_domain(hal_oplus_commondcs_aidl) 8 | 9 | binder_call(vendor_hal_oplus_commondcs_client, vendor_hal_oplus_commondcs_server) 10 | 11 | hal_attribute_service(vendor_hal_oplus_commondcs, hal_oplus_commondcs_aidl_service) 12 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_oplus_osense_aidl.te: -------------------------------------------------------------------------------- 1 | type hal_oplus_osense_aidl, domain; 2 | binder_use(hal_oplus_osense_aidl) 3 | 4 | hal_server_domain(hal_oplus_osense_aidl, vendor_hal_oplus_osense) 5 | 6 | type hal_oplus_osense_aidl_exec, exec_type, vendor_file_type, file_type; 7 | init_daemon_domain(hal_oplus_osense_aidl) 8 | 9 | binder_call(vendor_hal_oplus_osense_client, vendor_hal_oplus_osense_server) 10 | 11 | hal_attribute_service(vendor_hal_oplus_osense, hal_oplus_osense_aidl_service) 12 | 13 | allow vendor_hal_oplus_osense_client hal_oplus_osense_aidl_service:service_manager find; 14 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_oplus_performance_aidl.te: -------------------------------------------------------------------------------- 1 | type hal_oplus_performance_aidl, domain; 2 | binder_use(hal_oplus_performance_aidl) 3 | 4 | hal_server_domain(hal_oplus_performance_aidl, vendor_hal_oplus_performance) 5 | 6 | type hal_oplus_performance_aidl_exec, exec_type, vendor_file_type, file_type; 7 | init_daemon_domain(hal_oplus_performance_aidl) 8 | 9 | add_service(hal_oplus_performance_aidl, hal_oplus_performance_aidl_service) 10 | binder_call(vendor_hal_oplus_performance_client, vendor_hal_oplus_performance_server) 11 | 12 | allow vendor_hal_oplus_performance_client hal_oplus_performance_aidl_service:service_manager find; 13 | 14 | r_dir_file(hal_oplus_performance_aidl, proc_version) 15 | rw_dir_file(hal_oplus_performance_aidl, vendor_proc_oplus_scheduler) 16 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_oplus_project_aidl.te: -------------------------------------------------------------------------------- 1 | type hal_oplus_project_aidl, domain; 2 | binder_use(hal_oplus_project_aidl) 3 | 4 | hal_server_domain(hal_oplus_project_aidl, vendor_hal_oplus_project) 5 | 6 | type hal_oplus_project_aidl_exec, exec_type, vendor_file_type, file_type; 7 | init_daemon_domain(hal_oplus_project_aidl) 8 | 9 | binder_call(vendor_hal_oplus_project_client, vendor_hal_oplus_project_server) 10 | 11 | hal_attribute_service(vendor_hal_oplus_project, hal_oplus_project_aidl_service) 12 | 13 | allow vendor_hal_oplus_project_client hal_oplus_project_aidl_service:service_manager find; 14 | 15 | r_dir_file(hal_oplus_project_aidl, vendor_proc_oplus_version) 16 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_oplus_touch_aidl.te: -------------------------------------------------------------------------------- 1 | type hal_oplus_touch_aidl, domain; 2 | binder_use(hal_oplus_touch_aidl) 3 | vndbinder_use(hal_oplus_touch_aidl) 4 | 5 | hal_server_domain(hal_oplus_touch_aidl, vendor_hal_oplus_touch) 6 | hal_client_domain(hal_oplus_touch_aidl, vendor_hal_oplus_touchdaemon) 7 | 8 | type hal_oplus_touch_aidl_exec, exec_type, vendor_file_type, file_type; 9 | init_daemon_domain(hal_oplus_touch_aidl) 10 | 11 | binder_call(vendor_hal_oplus_touch_client, vendor_hal_oplus_touch_server) 12 | 13 | hal_attribute_service(vendor_hal_oplus_touch, hal_oplus_touch_aidl_service) 14 | 15 | allow hal_oplus_touch_aidl hal_oplus_touchdaemon:binder call; 16 | 17 | allow hal_oplus_touch_aidl touchDeamonBinder_service:service_manager find; 18 | 19 | unix_socket_send(hal_oplus_touch_aidl, oplus_touchdaemon, hal_oplus_touchdaemon) 20 | 21 | rw_dir_file(hal_oplus_touch_aidl, oplus_touchdaemon_device) 22 | rw_dir_file(hal_oplus_touch_aidl, vendor_proc_display) 23 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_oplus_urcc_aidl.te: -------------------------------------------------------------------------------- 1 | type hal_oplus_urcc_aidl, domain; 2 | vndbinder_use(hal_oplus_urcc_aidl) 3 | 4 | type hal_oplus_urcc_aidl_exec, exec_type, vendor_file_type, file_type; 5 | init_daemon_domain(hal_oplus_urcc_aidl) 6 | 7 | set_prop(hal_oplus_urcc_aidl, vendor_oplus_urcc_prop) 8 | 9 | allow hal_oplus_urcc_aidl self:capability ipc_lock; 10 | allow hal_oplus_urcc_aidl servicemanager:binder call; 11 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_power_default.te: -------------------------------------------------------------------------------- 1 | allow hal_power_default vendor_latency_device:chr_file rw_file_perms; 2 | 3 | hal_client_domain(hal_power_default, vendor_hal_oplus_touch) 4 | allow hal_power_default hal_oplus_touch_aidl_service:service_manager find; 5 | binder_call(hal_power_default, hal_oplus_touch_aidl); 6 | 7 | rw_dir_file(hal_power_default, vendor_proc_display) 8 | rw_dir_file(hal_power_default, vendor_sysfs_sde_crtc) 9 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_secure_element_default.te: -------------------------------------------------------------------------------- 1 | allow hal_secure_element_default nfc_device:chr_file { getattr }; 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_sensors_default.te: -------------------------------------------------------------------------------- 1 | allow hal_sensors_default ssc_interactive_device:chr_file rw_file_perms; 2 | allow hal_sensors_default ultrasound_device:chr_file rw_file_perms; 3 | 4 | binder_use(hal_sensors_default) 5 | 6 | get_prop(hal_sensors_default, vendor_sensors_als_prop) 7 | 8 | hal_client_domain(hal_sensors_default, hal_lineage_oplus_als) 9 | 10 | r_dir_file(hal_sensors_default, vendor_proc_eng_cali_file) 11 | r_dir_file(hal_sensors_default, vendor_proc_oplus_als_file) 12 | r_dir_file(hal_sensors_default, vendor_proc_oplus_version) 13 | r_dir_file(hal_sensors_default, vendor_proc_ultrasound) 14 | rw_dir_file(hal_sensors_default, vendor_persist_engineer_file) 15 | rw_dir_file(hal_sensors_default, vendor_proc_display) 16 | rw_dir_file(hal_sensors_default, vendor_sysfs_graphics) 17 | rw_dir_file(hal_sensors_default, vendor_sysfs_sensor_fb) 18 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hal_vibrator_default.te: -------------------------------------------------------------------------------- 1 | allow hal_vibrator_default aac_richtap_device:chr_file rw_file_perms; 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/hwservice.te: -------------------------------------------------------------------------------- 1 | # Camera 2 | type vendor_hal_camera_extension_hwservice, hwservice_manager_type, protected_hwservice; 3 | type vendor_hal_cameraMDM_hwservice, hwservice_manager_type, protected_hwservice; 4 | 5 | # CommonDcs 6 | type vendor_hal_commondcs_hwservice, hwservice_manager_type, protected_hwservice; 7 | 8 | # ORMS 9 | type vendor_hal_orms_hwservice, hwservice_manager_type, protected_hwservice; 10 | 11 | # Osense 12 | type vendor_hal_osense_hwservice, hwservice_manager_type, protected_hwservice; 13 | 14 | # Sensors 15 | type vendor_hal_oplusSensor_hwservice, hwservice_manager_type, protected_hwservice; 16 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/init.te: -------------------------------------------------------------------------------- 1 | allow init vendor_sysfs_usb_supply:file w_file_perms; 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/kernel.te: -------------------------------------------------------------------------------- 1 | allow kernel vendor_file:file r_file_perms; 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/legacy-um/file_contexts: -------------------------------------------------------------------------------- 1 | # eSE 2 | /(odm|vendor/odm)/bin/hw/vendor\.qti\.esepowermanager@1\.1-service u:object_r:vendor_hal_esepowermanager_qti_exec:s0 3 | 4 | # NFC 5 | /vendor/bin/hw/android\.hardware\.nfc-service\.st u:object_r:hal_nfc_default_exec:s0 6 | /vendor/bin/hw/android\.hardware\.nfc@1\.2-service\.st u:object_r:hal_nfc_default_exec:s0 7 | /dev/st21nfc u:object_r:nfc_device:s0 8 | 9 | # Widevine 10 | /(odm|vendor/odm)/bin/hw/android\.hardware\.drm@1\.[0-4]+-service\.widevine u:object_r:vendor_hal_drm_widevine_exec:s0 11 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/legacy-um/vendor_hal_qteeconnector_qti.te: -------------------------------------------------------------------------------- 1 | add_service(vendor_hal_qteeconnector_qti, vendor_qms_service) 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/legacy-um/vendor_qti_init_shell.te: -------------------------------------------------------------------------------- 1 | create_dir_file(vendor_qti_init_shell, vendor_persist_wcnss_service_file) 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/legacy-um/vndservice.te: -------------------------------------------------------------------------------- 1 | # QTEE 2 | type vendor_qms_service, vndservice_manager_type; 3 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/legacy-um/vndservice_contexts: -------------------------------------------------------------------------------- 1 | # QTEE 2 | com.qualcomm.qti.qms.service.trustzoneaccess.GetClientAppInfo u:object_r:vendor_qms_service:s0 3 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/mediacodec.te: -------------------------------------------------------------------------------- 1 | set_prop(mediacodec, vendor_video_prop) 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/property.te: -------------------------------------------------------------------------------- 1 | # Face 2 | vendor_internal_prop(vendor_face_prop) 3 | 4 | # Fingerprint 5 | vendor_internal_prop(vendor_fingerprint_prop) 6 | 7 | # Modem 8 | vendor_internal_prop(vendor_modem_prop) 9 | 10 | # RIL 11 | vendor_internal_prop(vendor_nw_exported_system_prop) 12 | 13 | # Touch 14 | vendor_internal_prop(vendor_oplus_touch_prop) 15 | 16 | # URCC 17 | vendor_internal_prop(vendor_oplus_urcc_prop) 18 | 19 | # Widevine 20 | vendor_internal_prop(vendor_wvmkiller_prop) 21 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/rild.te: -------------------------------------------------------------------------------- 1 | allow rild mnt_vendor_file:dir search; 2 | 3 | allow rild vendor_proc_display:file r_file_perms; 4 | 5 | r_dir_file(rild, vendor_proc_engineer) 6 | 7 | set_prop(rild, vendor_nw_exported_system_prop) 8 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/service.te: -------------------------------------------------------------------------------- 1 | # Camera 2 | type hal_oplus_cammidasservice_aidl_service, hal_service_type, service_manager_type; 3 | 4 | # CommonsDcs 5 | type hal_oplus_commondcs_aidl_service, hal_service_type, service_manager_type; 6 | 7 | # OSENSE 8 | type hal_oplus_osense_aidl_service, hal_service_type, service_manager_type; 9 | 10 | # Performance 11 | type hal_oplus_performance_aidl_service, hal_service_type, service_manager_type; 12 | 13 | # Project 14 | type hal_oplus_project_aidl_service, hal_service_type, service_manager_type; 15 | 16 | # Sensor 17 | type hal_oplusSensor_aidl_service, hal_service_type, service_manager_type; 18 | 19 | # Touch 20 | type hal_oplus_touch_aidl_service, hal_service_type, service_manager_type; 21 | 22 | # URCC 23 | type hal_oplus_urcc_aidl_service, hal_service_type, service_manager_type; 24 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/sm8450/file_contexts: -------------------------------------------------------------------------------- 1 | # eSE 2 | /(odm|vendor/odm)/bin/hw/vendor\.qti\.esepowermanager@1\.1-service u:object_r:vendor_hal_esepowermanager_qti_exec:s0 3 | 4 | # Widevine 5 | /(odm|vendor/odm)/bin/hw/android\.hardware\.drm@1\.[0-4]+-service\.widevine u:object_r:vendor_hal_drm_widevine_exec:s0 6 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/sm8450/hal_face_default.te: -------------------------------------------------------------------------------- 1 | allow hal_face_default vendor_dmabuf_qseecom_heap_device:chr_file rw_file_perms; 2 | allow hal_face_default vendor_dmabuf_qseecom_ta_heap_device:chr_file rw_file_perms; 3 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/sm8450/vendor_agmservice_qti.te: -------------------------------------------------------------------------------- 1 | hal_client_domain(vendor_agmservice_qti, vendor_hal_oplus_performance) 2 | 3 | binder_call(vendor_agmservice_qti, hal_oplus_performance_aidl) 4 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/sm8550/file_contexts: -------------------------------------------------------------------------------- 1 | # eSE 2 | /(odm|vendor/odm)/bin/hw/vendor\.qti\.esepowermanager@1\.1-service u:object_r:vendor_hal_esepowermanager_qti_exec:s0 3 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/sm8550/hal_face_default.te: -------------------------------------------------------------------------------- 1 | allow hal_face_default vendor_dmabuf_qseecom_heap_device:chr_file rw_file_perms; 2 | allow hal_face_default vendor_dmabuf_qseecom_ta_heap_device:chr_file rw_file_perms; 3 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/system_server.te: -------------------------------------------------------------------------------- 1 | rw_dir_file(system_server, vendor_proc_tri_state_key) 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/tee.te: -------------------------------------------------------------------------------- 1 | # Face 2 | rw_dir_file(tee, face_vendor_data_file) 3 | allow tee face_vendor_data_file:dir { write remove_name add_name }; 4 | 5 | # Fingerprint 6 | rw_dir_file(tee, vendor_persist_fingerprint_file) 7 | allow tee vendor_persist_fingerprint_file:dir { write remove_name add_name }; 8 | allow tee vendor_persist_fingerprint_file:file { create unlink }; 9 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/tri-state-key-calibrate.te: -------------------------------------------------------------------------------- 1 | type tri-state-key-calibrate, domain; 2 | type tri-state-key-calibrate_exec, exec_type, vendor_file_type, file_type; 3 | 4 | init_daemon_domain(tri-state-key-calibrate) 5 | 6 | allow tri-state-key-calibrate vendor_toolbox_exec:file rx_file_perms; 7 | 8 | allow tri-state-key-calibrate mnt_vendor_file:dir search; 9 | 10 | rw_dir_file(tri-state-key-calibrate, vendor_proc_tri_state_key) 11 | r_dir_file(tri-state-key-calibrate, vendor_persist_engineer_file) 12 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/ueventd.te: -------------------------------------------------------------------------------- 1 | allow ueventd vendor_persist_display_file:dir search; 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/update_engine_common.te: -------------------------------------------------------------------------------- 1 | allow update_engine_common vendor_modem_efs_partition_device:blk_file rw_file_perms; 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_hal_cameraMDM_default.te: -------------------------------------------------------------------------------- 1 | type vendor_hal_cameraMDM_default, domain; 2 | hal_server_domain(vendor_hal_cameraMDM_default, vendor_hal_cameraMDM) 3 | 4 | type vendor_hal_cameraMDM_default_exec, exec_type, vendor_file_type, file_type; 5 | init_daemon_domain(vendor_hal_cameraMDM_default) 6 | 7 | binder_call(vendor_hal_cameraMDM_client, vendor_hal_cameraMDM_server) 8 | binder_call(vendor_hal_cameraMDM_server, vendor_hal_cameraMDM_client) 9 | 10 | hal_attribute_hwservice(vendor_hal_cameraMDM, vendor_hal_cameraMDM_hwservice) 11 | 12 | allow vendor_hal_cameraMDM_default vendor_hal_perf_hwservice:hwservice_manager find; 13 | 14 | allow vendor_hal_cameraMDM_default tee_device:chr_file rw_file_perms; 15 | allow vendor_hal_cameraMDM_default ion_device:chr_file rw_file_perms; 16 | 17 | allow vendor_hal_cameraMDM_default vendor_camera_data_file:dir create_dir_perms; 18 | allow vendor_hal_cameraMDM_default vendor_camera_data_file:file create_file_perms; 19 | 20 | r_dir_file(vendor_hal_cameraMDM_default, firmware_file) 21 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_hal_oplusSensor_aidl.te: -------------------------------------------------------------------------------- 1 | type hal_oplusSensor_aidl, domain; 2 | binder_use(hal_oplusSensor_aidl) 3 | 4 | hal_server_domain(hal_oplusSensor_aidl, vendor_hal_oplusSensor) 5 | 6 | type hal_oplusSensor_aidl_exec, exec_type, vendor_file_type, file_type; 7 | init_daemon_domain(hal_oplusSensor_aidl) 8 | 9 | binder_call(vendor_hal_oplusSensor_client, vendor_hal_oplusSensor_server) 10 | 11 | hal_attribute_service(vendor_hal_oplusSensor, hal_oplusSensor_aidl_service) 12 | 13 | allow hal_oplusSensor_aidl vendor_reserve_partition:blk_file r_file_perms; 14 | 15 | allow hal_oplusSensor_aidl mnt_vendor_file:dir search; 16 | 17 | allow hal_oplusSensor_aidl block_device:dir search; 18 | 19 | r_dir_file(hal_oplusSensor_aidl, vendor_persist_engineer_file) 20 | r_dir_file(hal_oplusSensor_aidl, vendor_persist_sensors_file) 21 | r_dir_file(hal_oplusSensor_aidl, vendor_proc_oplus_version) 22 | rw_dir_file(hal_oplusSensor_aidl, vendor_proc_eng_cali_file) 23 | rw_dir_file(hal_oplusSensor_aidl, vendor_proc_oplus_als_file) 24 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_hal_oplusSensor_default.te: -------------------------------------------------------------------------------- 1 | type vendor_hal_oplusSensor_default, domain; 2 | hal_server_domain(vendor_hal_oplusSensor_default, vendor_hal_oplusSensor) 3 | 4 | type vendor_hal_oplusSensor_default_exec, exec_type, vendor_file_type, file_type; 5 | init_daemon_domain(vendor_hal_oplusSensor_default) 6 | 7 | binder_call(vendor_hal_oplusSensor_client, vendor_hal_oplusSensor_server) 8 | binder_call(vendor_hal_oplusSensor_server, vendor_hal_oplusSensor_client) 9 | 10 | hal_attribute_hwservice(vendor_hal_oplusSensor, vendor_hal_oplusSensor_hwservice) 11 | 12 | allow vendor_hal_oplusSensor_default vendor_reserve_partition:blk_file r_file_perms; 13 | 14 | allow vendor_hal_oplusSensor_default mnt_vendor_file:dir search; 15 | 16 | allow vendor_hal_oplusSensor_default block_device:dir search; 17 | 18 | r_dir_file(vendor_hal_oplusSensor_default, vendor_persist_engineer_file) 19 | r_dir_file(vendor_hal_oplusSensor_default, vendor_persist_sensors_file) 20 | r_dir_file(vendor_hal_oplusSensor_default, vendor_proc_oplus_version) 21 | rw_dir_file(vendor_hal_oplusSensor_default, vendor_proc_eng_cali_file) 22 | rw_dir_file(vendor_hal_oplusSensor_default, vendor_proc_oplus_als_file) 23 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_hal_perf_default.te: -------------------------------------------------------------------------------- 1 | allow vendor_hal_perf_default hal_oplus_urcc_aidl_service:service_manager find; 2 | 3 | r_dir_file(vendor_hal_perf_default, vendor_sysfs_usb_supply) 4 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_init.te: -------------------------------------------------------------------------------- 1 | allow vendor_init proc_sched:file w_file_perms; 2 | allow vendor_init vendor_proc_display:file w_file_perms; 3 | 4 | set_prop(vendor_init, system_oplus_project_prop) 5 | set_prop(vendor_init, vendor_oplus_touch_prop) 6 | set_prop(vendor_init, vendor_sensors_als_prop) 7 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_mdm_helper.te: -------------------------------------------------------------------------------- 1 | allow vendor_mdm_helper vendor_modem_efs_partition_device:blk_file rw_file_perms; 2 | 3 | r_dir_file(vendor_mdm_helper, vendor_proc_engineer) 4 | r_dir_file(vendor_mdm_helper, vendor_proc_oplus_version) 5 | 6 | set_prop(vendor_mdm_helper, vendor_modem_prop) 7 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_poweroffalarm_app.te: -------------------------------------------------------------------------------- 1 | allow vendor_poweroffalarm_app mnt_vendor_file:dir search; 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_qtelephony.te: -------------------------------------------------------------------------------- 1 | set_prop(vendor_qtelephony, system_oplus_radio_prop) 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_qti_init_shell.te: -------------------------------------------------------------------------------- 1 | allow vendor_qti_init_shell proc_cmdline:file r_file_perms; 2 | 3 | create_dir_file(vendor_qti_init_shell, mnt_vendor_file) 4 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_rmt_storage.te: -------------------------------------------------------------------------------- 1 | allow vendor_rmt_storage vendor_reserve_partition:blk_file rw_file_perms; 2 | allow vendor_rmt_storage vendor_sysfs_soc_sensitive:file r_file_perms; 3 | 4 | get_prop(vendor_rmt_storage, vendor_radio_prop) 5 | 6 | rw_dir_file(vendor_rmt_storage, vendor_proc_engineer) 7 | r_dir_file(vendor_rmt_storage, vendor_proc_oplus_version) 8 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_sensors.te: -------------------------------------------------------------------------------- 1 | rw_dir_file(vendor_sensors, vendor_persist_engineer_file) 2 | rw_dir_file(vendor_sensors, vendor_proc_eng_cali_file) 3 | rw_dir_file(vendor_sensors, vendor_proc_oplus_version) 4 | rw_dir_file(vendor_sensors, vendor_sysfs_sensor_fb) 5 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_thermal-engine.te: -------------------------------------------------------------------------------- 1 | r_dir_file(vendor_thermal-engine, vendor_sysfs_usb_supply) 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_wcnss_service.te: -------------------------------------------------------------------------------- 1 | create_dir_file(vendor_wcnss_service, mnt_vendor_file) 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vendor_wvmkiller.te: -------------------------------------------------------------------------------- 1 | type vendor_wvmkiller, domain; 2 | type vendor_wvmkiller_exec, exec_type, vendor_file_type, file_type; 3 | 4 | init_daemon_domain(vendor_wvmkiller) 5 | 6 | hal_client_domain(vendor_wvmkiller, hal_drm) 7 | 8 | get_prop(vendor_wvmkiller, hwservicemanager_prop) 9 | set_prop(vendor_wvmkiller, vendor_wvmkiller_prop) 10 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vl53l1_daemon_main.te: -------------------------------------------------------------------------------- 1 | type vl53l1_daemon_main, domain; 2 | type vl53l1_daemon_main_exec, exec_type, vendor_file_type, file_type; 3 | 4 | init_daemon_domain(vl53l1_daemon_main) 5 | 6 | allow vl53l1_daemon_main self:{ 7 | netlink_generic_socket 8 | netlink_kobject_uevent_socket 9 | netlink_socket 10 | } create_socket_perms_no_ioctl; 11 | 12 | allow vl53l1_daemon_main self:netlink_iscsi_socket { read write create bind }; 13 | 14 | r_dir_file(vl53l1_daemon_main, vendor_persist_camera_file) 15 | r_dir_file(vl53l1_daemon_main, vendor_sysfs_tof) 16 | rw_dir_file(vl53l1_daemon_main, mnt_vendor_file) 17 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vndservice.te: -------------------------------------------------------------------------------- 1 | # Touch 2 | type touchDeamonBinder_service, vndservice_manager_type; 3 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vndservice_contexts: -------------------------------------------------------------------------------- 1 | # Touch 2 | touchDeamonBinder u:object_r:touchDeamonBinder_service:s0 3 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/vndservicemanager.te: -------------------------------------------------------------------------------- 1 | binder_call(vndservicemanager, vendor_cnd) 2 | -------------------------------------------------------------------------------- /sepolicy/qti/vendor/wlchgmonitor.te: -------------------------------------------------------------------------------- 1 | type wlchgmonitor, domain; 2 | type wlchgmonitor_exec, exec_type, vendor_file_type, file_type; 3 | 4 | init_daemon_domain(wlchgmonitor) 5 | 6 | allow wlchgmonitor kmsg_device:chr_file rw_file_perms; 7 | allow wlchgmonitor wlchg_device:chr_file rw_file_perms; 8 | -------------------------------------------------------------------------------- /usb/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // SPDX-FileCopyrightText: The LineageOS Project 3 | // SPDX-License-Identifier: Apache-2.0 4 | // 5 | 6 | prebuilt_etc { 7 | name: "oplus_usb_compositions.conf", 8 | src: "usb_compositions.conf", 9 | filename_from_src: true, 10 | device_specific: true, 11 | } 12 | -------------------------------------------------------------------------------- /wvmkiller/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2024 The LineageOS Project 3 | // 4 | // SPDX-License-Identifier: Apache-2.0 5 | // 6 | 7 | cc_binary { 8 | name: "wvmkiller", 9 | defaults: ["hidl_defaults"], 10 | init_rc: ["wvmkiller.rc"], 11 | vendor: true, 12 | srcs: ["main.cpp"], 13 | shared_libs: [ 14 | "android.hardware.drm@1.0", 15 | "libbase", 16 | "libhidlbase", 17 | "libutils", 18 | ], 19 | } 20 | -------------------------------------------------------------------------------- /wvmkiller/wvmkiller.rc: -------------------------------------------------------------------------------- 1 | on property:vendor.wvm.disable_l1=1 2 | export FORCE_LEVEL3_OEMCRYPTO yes 3 | restart vendor.drm-widevine-hal-1-3 4 | restart vendor.drm-widevine-hal-1-4 5 | 6 | service vendor.wvmkiller /vendor/bin/wvmkiller 7 | class late_start 8 | user system 9 | group system 10 | oneshot 11 | --------------------------------------------------------------------------------