├── power-libperfmgr ├── hidl │ └── DEPRECATED ├── aidl │ ├── android.hardware.power-service.sm6150.xml │ ├── android.hardware.power-service.sm6150-libperfmgr.rc │ ├── PowerExt.h │ └── Power.h ├── CameraMode.h ├── AudioStreaming.h ├── Android.bp └── disp-power │ └── InteractionHandler.h ├── sepolicy ├── vendor │ ├── proc_net.te │ ├── ueventd.te │ ├── vendor_sensors.te │ ├── vendor_wcnss_service.te │ ├── system_server.te │ ├── hal_bootctl_default.te │ ├── device.te │ ├── hwservice_contexts │ ├── installd.te │ ├── kernel.te │ ├── system_app.te │ ├── tee.te │ ├── hal_sensors_default.te │ ├── property.te │ ├── vendor_thermal-engine.te │ ├── vl53l1.te │ ├── vendor_rmt_storage.te │ ├── motpsd.te │ ├── vendor_init.te │ ├── capsense_reset.te │ ├── rild.te │ ├── init.te │ ├── hal_audio_default.te │ ├── hal_camera_default.te │ ├── hal_power_default.te │ ├── vendor_qti_init_shell.te │ ├── file.te │ └── vendor_init_fingerprint.te └── private │ ├── system_app.te │ ├── system_server.te │ ├── untrusted_app.te │ ├── service.te │ ├── app.te │ ├── init.te │ ├── radio.te │ ├── vendor_qtelephony.te │ └── service_contexts ├── gps ├── android │ ├── Android.mk │ ├── 1.0 │ │ ├── android.hardware.gnss@1.0-service-qti.rc │ │ ├── android.hardware.gnss@1.0-service-qti.xml │ │ └── GnssDebug.h │ ├── 1.1 │ │ ├── android.hardware.gnss@1.1-service-qti.rc │ │ ├── android.hardware.gnss@1.1-service-qti.xml │ │ └── GnssDebug.h │ ├── 2.0 │ │ ├── android.hardware.gnss@2.0-service-qti.rc │ │ ├── android.hardware.gnss@2.0-service-qti.xml │ │ └── GnssDebug.h │ ├── 2.1 │ │ ├── android.hardware.gnss@2.1-service-qti.rc │ │ ├── android.hardware.gnss@2.1-service-qti.xml │ │ └── GnssDebug.h │ └── utils │ │ ├── Android.bp │ │ └── battery_listener.h ├── etc │ ├── gps.conf │ ├── lowi.conf │ ├── Android.bp │ ├── seccomp_policy │ │ ├── gnss@2.0-xtwifi-inet-agent.policy │ │ ├── gnss@2.0-xtra-daemon.policy │ │ └── gnss@2.0-xtwifi-client.policy │ └── flp.conf ├── pla │ └── Android.bp ├── Makefile.am ├── gps_vendor_board.mk ├── core │ ├── loc-core.pc.in │ └── Android.bp ├── utils │ ├── gps-utils.pc.in │ ├── Android.bp │ ├── LocLoggerBase.h │ ├── Makefile.am │ └── MsgTask.h ├── location │ ├── location-api.pc.in │ ├── Android.bp │ └── Makefile.am ├── batching │ ├── location-batching.pc.in │ ├── Android.bp │ └── Makefile.am ├── geofence │ ├── location-geofence.pc.in │ ├── Android.bp │ ├── Makefile.am │ └── configure.ac ├── loc-hal.pc.in ├── gnss │ ├── Android.bp │ └── Makefile.am ├── Android.bp ├── Android.mk └── gps_vendor_product.mk ├── wifi ├── p2p_supplicant_overlay.conf └── wpa_supplicant_overlay.conf ├── Android.bp ├── location ├── utils │ ├── Android.mk │ └── loc_socket │ │ ├── loc-socket.pc.in │ │ ├── Android.mk │ │ └── Makefile.am ├── izat_api │ └── Android.bp ├── loc_api │ └── loc_api_v02 │ │ ├── Android.bp │ │ ├── loc-api-v02.pc.in │ │ ├── Android.mk │ │ ├── Makefile.am │ │ └── loc_api_v02_log.h ├── synergy_loc_api │ ├── Android.bp │ └── Android.mk ├── qapi │ ├── etc │ │ └── qapi.conf │ ├── location-qapi.pc.in │ ├── Makefile.am │ └── configure.ac ├── loc_sll_if │ └── if │ │ └── Android.bp ├── location_api_msg_proto │ ├── Makefile.am │ ├── src │ │ └── Makefile.am │ ├── location-api-msg-proto.pc.in │ └── configure.ac ├── gnsspps │ ├── gnsspps.pc.in │ ├── Android.bp │ ├── Makefile.am │ ├── gnsspps.h │ └── configure.ac ├── Android.mk ├── ntrip-client-integration-api │ ├── ntrip-client-integration-api-testlib.pc.in │ ├── Makefile.am │ ├── configure.ac │ └── ntrip-client-integration-api-testlib.cpp ├── client_api_testapp │ ├── location_client_api_testapp.pc.in │ └── Makefile.am ├── client_api │ ├── location-client-api.pc.in │ ├── README │ └── Makefile.am ├── location_hal_daemon │ ├── location-hal-daemon.pc.in │ ├── Makefile.am │ └── PowerEvtHandler.h ├── integration_api │ ├── README │ ├── Makefile.am │ └── location-integration-api.pc.in ├── Android.bp └── gps_vendor_product.mk ├── rro_overlays └── WifiOverlay │ ├── Android.bp │ └── AndroidManifest.xml ├── configs ├── public.libraries.txt ├── privapp-permissions-hotword.xml ├── media_codecs_vendor_audio.xml ├── system_ext-privapp-permissions-qti.xml ├── msm_irqbalance.conf └── qti_whitelist_system_ext.xml ├── seccomp └── mediacodec-seccomp.policy ├── README.md ├── bootctrl ├── 1.1 │ ├── impl │ │ └── Android.bp │ └── libboot_control_qti │ │ ├── Android.bp │ │ └── libboot_control_qti.h ├── NOTICE └── Android.bp ├── overlay-lineage ├── packages │ └── apps │ │ ├── Dialer │ │ └── java │ │ │ └── com │ │ │ └── android │ │ │ └── dialer │ │ │ └── callrecord │ │ │ └── res │ │ │ └── values │ │ │ └── config.xml │ │ └── Snap │ │ └── res │ │ └── values │ │ └── config.xml └── lineage-sdk │ └── lineage │ └── res │ └── res │ └── values │ └── config.xml ├── init └── Android.bp ├── overlay ├── frameworks │ └── base │ │ ├── packages │ │ └── SystemUI │ │ │ └── res │ │ │ └── values │ │ │ └── config.xml │ │ └── core │ │ └── res │ │ └── res │ │ ├── values-mcc454-mnc03 │ │ └── config.xml │ │ ├── values-mcc454-mnc04 │ │ └── config.xml │ │ ├── values-mcc455-mnc02 │ │ └── config.xml │ │ ├── values-mcc455-mnc07 │ │ └── config.xml │ │ ├── values-mcc310-mnc004 │ │ └── config.xml │ │ ├── values-mcc310-mnc260 │ │ └── config.xml │ │ ├── values-mcc310-mnc410 │ │ └── config.xml │ │ ├── values-mcc310-mnc120 │ │ └── config.xml │ │ ├── values-mcc312-mnc530 │ │ └── config.xml │ │ ├── values-mcc460-mnc03 │ │ └── config.xml │ │ └── values-mcc460-mnc11 │ │ └── config.xml └── packages │ └── services │ └── Telephony │ └── res │ └── values │ └── config.xml ├── gpt-utils └── Android.bp ├── overlay-lineage-fastbootd └── lineage-sdk │ └── lineage │ └── res │ └── res │ └── values │ └── config.xml ├── bluetooth └── include │ └── bdroid_buildcfg.h ├── common_dynamic.mk ├── setup-makefiles.sh ├── rootdir ├── bin │ ├── init.qti.fm.sh │ ├── init.mdm.sh │ ├── init.qcom.efs.sync.sh │ ├── init.crda.sh │ ├── init.qcom.sensors.sh │ ├── init.mmi.laser.sh │ ├── init.qcom.crashdata.sh │ └── init.qti.ims.sh └── etc │ └── init.recovery.qcom.rc ├── mot_aids.fs └── reorder-libs.py /power-libperfmgr/hidl/DEPRECATED: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /sepolicy/vendor/proc_net.te: -------------------------------------------------------------------------------- 1 | allow proc_net proc:filesystem associate; 2 | -------------------------------------------------------------------------------- /sepolicy/vendor/ueventd.te: -------------------------------------------------------------------------------- 1 | allow ueventd self:capability sys_nice; 2 | -------------------------------------------------------------------------------- /sepolicy/vendor/vendor_sensors.te: -------------------------------------------------------------------------------- 1 | r_dir_file(vendor_sensors, sysfs_msm_subsys) 2 | -------------------------------------------------------------------------------- /sepolicy/private/system_app.te: -------------------------------------------------------------------------------- 1 | get_prop(system_app, vendor_persist_camera_prop); 2 | -------------------------------------------------------------------------------- /sepolicy/private/system_server.te: -------------------------------------------------------------------------------- 1 | get_prop(system_server, vendor_persist_camera_prop) 2 | -------------------------------------------------------------------------------- /sepolicy/private/untrusted_app.te: -------------------------------------------------------------------------------- 1 | get_prop(untrusted_app, vendor_persist_camera_prop) 2 | -------------------------------------------------------------------------------- /sepolicy/vendor/vendor_wcnss_service.te: -------------------------------------------------------------------------------- 1 | get_prop(vendor_wcnss_service, moto_boot_prop) 2 | -------------------------------------------------------------------------------- /gps/android/Android.mk: -------------------------------------------------------------------------------- 1 | LOCAL_PATH := $(call my-dir) 2 | include $(call all-subdir-makefiles) 3 | -------------------------------------------------------------------------------- /sepolicy/vendor/system_server.te: -------------------------------------------------------------------------------- 1 | allow system_server hal_audio_default:binder { call transfer }; 2 | -------------------------------------------------------------------------------- /sepolicy/vendor/hal_bootctl_default.te: -------------------------------------------------------------------------------- 1 | allow hal_bootctl_default vendor_uefi_block_device:blk_file getattr; 2 | -------------------------------------------------------------------------------- /gps/etc/gps.conf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SuperiorOS-Devices/device_motorola_sm6150-common/fourteen/gps/etc/gps.conf -------------------------------------------------------------------------------- /sepolicy/private/service.te: -------------------------------------------------------------------------------- 1 | type mot_system_service, service_manager_type; 2 | type mot_radio_service, service_manager_type; 3 | -------------------------------------------------------------------------------- /sepolicy/vendor/device.te: -------------------------------------------------------------------------------- 1 | # VL53L1 2 | type vl53l1_device, dev_type; 3 | 4 | # Thermal 5 | type thermal_device, dev_type; 6 | -------------------------------------------------------------------------------- /sepolicy/private/app.te: -------------------------------------------------------------------------------- 1 | # Allow appdomain to get vendor_persist_camera_prop 2 | get_prop(appdomain, vendor_persist_camera_prop) 3 | -------------------------------------------------------------------------------- /wifi/p2p_supplicant_overlay.conf: -------------------------------------------------------------------------------- 1 | disable_scan_offload=1 2 | p2p_no_group_iface=1 3 | persistent_reconnect=1 4 | bss_max_count=400 5 | -------------------------------------------------------------------------------- /sepolicy/private/init.te: -------------------------------------------------------------------------------- 1 | allow init property_type:file { append create getattr map open read relabelto rename setattr unlink write }; 2 | -------------------------------------------------------------------------------- /Android.bp: -------------------------------------------------------------------------------- 1 | soong_namespace { 2 | imports: [ 3 | "hardware/google/interfaces", 4 | "hardware/google/pixel" 5 | ], 6 | } 7 | -------------------------------------------------------------------------------- /sepolicy/private/radio.te: -------------------------------------------------------------------------------- 1 | allow radio mot_radio_service:service_manager { add find }; 2 | allow radio mot_system_service:service_manager find; 3 | -------------------------------------------------------------------------------- /location/utils/Android.mk: -------------------------------------------------------------------------------- 1 | ifneq ($(QCPATH),) 2 | LOCAL_PATH := $(call my-dir) 3 | include $(call all-makefiles-under,$(LOCAL_PATH)) 4 | endif #QCPATH 5 | -------------------------------------------------------------------------------- /gps/pla/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | cc_library_headers { 3 | 4 | name: "libloc_pla_headers", 5 | export_include_dirs: ["android"], 6 | vendor: true, 7 | } 8 | -------------------------------------------------------------------------------- /location/izat_api/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | cc_library_headers { 3 | 4 | name: "izat_remote_api_headers", 5 | vendor: true, 6 | export_include_dirs: ["."], 7 | } 8 | -------------------------------------------------------------------------------- /sepolicy/vendor/hwservice_contexts: -------------------------------------------------------------------------------- 1 | # ADSPD 2 | motorola.hardware.audio.adspd::IADSP u:object_r:hal_audio_hwservice:s0 3 | -------------------------------------------------------------------------------- /location/loc_api/loc_api_v02/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | cc_library_headers { 3 | 4 | name: "libloc_api_v02_headers", 5 | export_include_dirs: ["."], 6 | vendor: true, 7 | } 8 | -------------------------------------------------------------------------------- /location/synergy_loc_api/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | cc_library_headers { 3 | 4 | name: "libsynergyloc_api_headers", 5 | export_include_dirs: ["."], 6 | vendor: true, 7 | } 8 | -------------------------------------------------------------------------------- /sepolicy/private/vendor_qtelephony.te: -------------------------------------------------------------------------------- 1 | allow vendor_qtelephony mot_radio_service:service_manager find; 2 | allow vendor_qtelephony mot_system_service:service_manager find; 3 | -------------------------------------------------------------------------------- /location/qapi/etc/qapi.conf: -------------------------------------------------------------------------------- 1 | ######################################### 2 | # Timeout for Singleshot 3 | ######################################### 4 | SINGLESHOT_TIMEOUT = 40000 5 | -------------------------------------------------------------------------------- /rro_overlays/WifiOverlay/Android.bp: -------------------------------------------------------------------------------- 1 | runtime_resource_overlay { 2 | name: "WifiOverlay", 3 | theme: "WifiOverlay", 4 | sdk_version: "current", 5 | vendor: true 6 | } 7 | -------------------------------------------------------------------------------- /sepolicy/vendor/installd.te: -------------------------------------------------------------------------------- 1 | allow installd bt_firmware_file:filesystem quotaget; 2 | allow installd firmware_file:filesystem quotaget; 3 | allow installd fsg_firmware_file:filesystem quotaget; 4 | -------------------------------------------------------------------------------- /location/loc_sll_if/if/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | cc_library_headers { 3 | 4 | name: "loc_sll_if_headers", 5 | owner: "qti", 6 | vendor: true, 7 | 8 | export_include_dirs: ["."], 9 | } 10 | -------------------------------------------------------------------------------- /gps/android/1.0/android.hardware.gnss@1.0-service-qti.rc: -------------------------------------------------------------------------------- 1 | service gnss_service /vendor/bin/hw/android.hardware.gnss@1.0-service-qti 2 | class hal 3 | user gps 4 | group system gps radio vendor_qti_diag 5 | -------------------------------------------------------------------------------- /gps/android/1.1/android.hardware.gnss@1.1-service-qti.rc: -------------------------------------------------------------------------------- 1 | service gnss_service /vendor/bin/hw/android.hardware.gnss@1.1-service-qti 2 | class hal 3 | user gps 4 | group system gps radio vendor_qti_diag 5 | -------------------------------------------------------------------------------- /gps/android/2.0/android.hardware.gnss@2.0-service-qti.rc: -------------------------------------------------------------------------------- 1 | service gnss_service /vendor/bin/hw/android.hardware.gnss@2.0-service-qti 2 | class hal 3 | user gps 4 | group system gps radio vendor_qti_diag 5 | -------------------------------------------------------------------------------- /gps/android/2.1/android.hardware.gnss@2.1-service-qti.rc: -------------------------------------------------------------------------------- 1 | service gnss_service /vendor/bin/hw/android.hardware.gnss@2.1-service-qti 2 | class hal 3 | user gps 4 | group system gps radio vendor_qti_diag 5 | -------------------------------------------------------------------------------- /sepolicy/vendor/kernel.te: -------------------------------------------------------------------------------- 1 | allow kernel block_device:blk_file { open read write }; 2 | allow kernel block_device:dir search; 3 | allow kernel fsg_firmware_file:file read; 4 | allow kernel kernel:capability kill; 5 | -------------------------------------------------------------------------------- /sepolicy/vendor/system_app.te: -------------------------------------------------------------------------------- 1 | # FM Radio 2 | get_prop(system_app, vendor_fm_prop) 3 | 4 | # Allow system_app to access zram sysfs nodes 5 | allow system_app sysfs_zram:dir search; 6 | allow system_app sysfs_zram:file r_file_perms; 7 | -------------------------------------------------------------------------------- /sepolicy/vendor/tee.te: -------------------------------------------------------------------------------- 1 | allow tee fingerprint_vendor_data_file:dir create_dir_perms; 2 | allow tee { 3 | fingerprint_vendor_data_file 4 | mnt_vendor_file 5 | }:file create_file_perms; 6 | 7 | allow tee mnt_vendor_file:dir rw_dir_perms; 8 | -------------------------------------------------------------------------------- /gps/Makefile.am: -------------------------------------------------------------------------------- 1 | # Makefile.am - Automake script for gps loc_api 2 | # 3 | 4 | ACLOCAL_AMFLAGS = -I m4 5 | 6 | SUBDIRS = gnss 7 | 8 | pkgconfigdir = $(libdir)/pkgconfig 9 | pkgconfig_DATA = loc-hal.pc 10 | EXTRA_DIST = $(pkgconfig_DATA) 11 | -------------------------------------------------------------------------------- /sepolicy/private/service_contexts: -------------------------------------------------------------------------------- 1 | motoexttelephony u:object_r:mot_radio_service:s0 2 | motoextims u:object_r:mot_radio_service:s0 3 | moto_ext_telephony.registry u:object_r:mot_system_service:s0 4 | -------------------------------------------------------------------------------- /gps/gps_vendor_board.mk: -------------------------------------------------------------------------------- 1 | # Flags from BoardConfigVendor.mk 2 | ifneq ($(TARGET_USES_QMAA),true) 3 | BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE := default 4 | else ifneq ($(TARGET_USES_QMAA_OVERRIDE_GPS),false) 5 | BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE := default 6 | endif 7 | 8 | -------------------------------------------------------------------------------- /location/location_api_msg_proto/Makefile.am: -------------------------------------------------------------------------------- 1 | 2 | ACLOCAL_AMFLAGS = -I m4 3 | 4 | SUBDIRS = src 5 | 6 | library_includedir = $(pkgincludedir) 7 | pkgconfigdir = $(libdir)/pkgconfig 8 | pkgconfig_DATA = location-api-msg-proto.pc 9 | EXTRA_DIST = $(pkgconfig_DATA) 10 | -------------------------------------------------------------------------------- /gps/core/loc-core.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: loc-core 7 | Description: QTI GPS Loc Core 8 | Version: @VERSION@ 9 | Libs: -L${libdir} -lloc_core 10 | Cflags: -I${includedir}/loc-core 11 | -------------------------------------------------------------------------------- /location/gnsspps/gnsspps.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: gnsspps 7 | Description: QTI GPS gnsspps 8 | Version: @VERSION 9 | Libs: -L${libdir} -lgnsspps 10 | Cflags: -I${includedir}/gnsspps 11 | -------------------------------------------------------------------------------- /gps/utils/gps-utils.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: gps-utils 7 | Description: QTI GPS Location utils 8 | Version: @VERSION 9 | Libs: -L${libdir} -lgps_utils 10 | Cflags: -I${includedir}/gps-utils 11 | -------------------------------------------------------------------------------- /power-libperfmgr/aidl/android.hardware.power-service.sm6150.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | android.hardware.power 4 | 2 5 | IPower/default 6 | 7 | 8 | -------------------------------------------------------------------------------- /gps/location/location-api.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: location-api 7 | Description: Location API 8 | Version: @VERSION 9 | Libs: -L${libdir} -llocation_api 10 | Cflags: -I${includedir}/location-api 11 | -------------------------------------------------------------------------------- /location/Android.mk: -------------------------------------------------------------------------------- 1 | LOCAL_PATH := $(call my-dir) 2 | include $(call all-makefiles-under,$(LOCAL_PATH)) 3 | 4 | GNSS_SANITIZE := cfi bounds null unreachable integer 5 | # Activate the following two lines for regression testing 6 | # GNSS_SANITIZE += address 7 | # GNSS_SANITIZE_DIAG := $(GNSS_SANITIZE) 8 | -------------------------------------------------------------------------------- /gps/batching/location-batching.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: location-batching 7 | Description: QTI GPS Batching 8 | Version: @VERSION 9 | Libs: -L${libdir} -lbatching 10 | Cflags: -I${includedir}/location-batching 11 | -------------------------------------------------------------------------------- /wifi/wpa_supplicant_overlay.conf: -------------------------------------------------------------------------------- 1 | disable_scan_offload=1 2 | p2p_disabled=1 3 | tdls_external_control=1 4 | wowlan_triggers=magic_pkt 5 | bss_max_count=400 6 | interworking=1 7 | config_methods=virtual_display virtual_push_button keypad 8 | pmf=1 9 | driver_param="use_p2p_group_interface=1 no_rrm=1" 10 | -------------------------------------------------------------------------------- /gps/geofence/location-geofence.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: location-geofence 7 | Description: QTI GPS Geofence 8 | Version: @VERSION 9 | Libs: -L${libdir} -lgeofencing 10 | Cflags: -I${includedir}/location-geofence 11 | -------------------------------------------------------------------------------- /location/qapi/location-qapi.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: location-qapi 7 | Description: location qapi library 8 | Version: @VERSION@ 9 | Libs: -L${libdir} -llocation_qapi 10 | Cflags: -I${includedir} -I${includedir}/location-qapi -------------------------------------------------------------------------------- /gps/loc-hal.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: loc-hal 7 | Description: QTI GPS Loc HAL 8 | Version: @VERSION 9 | Libs: -L${libdir} -lgnss 10 | Cflags: -I${includedir} -I${includedir}/utils -I${includedir}/core -I${includedir}/loc-hal 11 | -------------------------------------------------------------------------------- /location/loc_api/loc_api_v02/loc-api-v02.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: loc-api-v02 7 | Description: Loc Api V02 8 | Version: @VERSION 9 | Libs: -L${libdir} -lloc_api_v02 10 | Cflags: -I${includedir} -I${includedir}/loc-api-v02 11 | -------------------------------------------------------------------------------- /location/utils/loc_socket/loc-socket.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: loc-socket 7 | Description: location socket library 8 | Version: @VERSION@ 9 | Libs: -L${libdir} -lloc_socket 10 | Cflags: -I${includedir} -I${includedir}/loc-socket -------------------------------------------------------------------------------- /location/ntrip-client-integration-api/ntrip-client-integration-api-testlib.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: ntrip client integration api test app 7 | Description: NTRIP Client integration api test app 8 | Version: @VERSION 9 | Libs: 10 | Cflags: 11 | -------------------------------------------------------------------------------- /location/client_api_testapp/location_client_api_testapp.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: location_client_api_testapp 7 | Description: location_client_api_tesetapp 8 | Version: @VERSION@ 9 | Libs: -L${libdir} -llocation_client_api 10 | Cflags: -I${includedir} -------------------------------------------------------------------------------- /location/client_api/location-client-api.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: location-client-api 7 | Description: location client api library 8 | Version: @VERSION@ 9 | Libs: -L${libdir} -llocation_client_api 10 | Cflags: -I${includedir} -I${includedir}/location-client-api -------------------------------------------------------------------------------- /location/location_hal_daemon/location-hal-daemon.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@ 5 | 6 | Name: location-hal-daemon 7 | Description: location hal daemon service 8 | Version: @VERSION@ 9 | Libs: -L${libdir} -llocation-hal-daemon 10 | Cflags: -I${includedir} -I${includedir}/location-hal-daemon 11 | -------------------------------------------------------------------------------- /sepolicy/vendor/hal_sensors_default.te: -------------------------------------------------------------------------------- 1 | #FIXME: Address input sysfs nodes as sysfs_sensors (/devices/virtual/input/input[0-9]+/name) 2 | r_dir_file(hal_sensors_default, sysfs) 3 | allow hal_sensors_default sysfs:file rw_file_perms; 4 | 5 | allow hal_sensors_default vendor_sysfs_laser:dir r_dir_perms; 6 | allow hal_sensors_default vendor_sysfs_laser:file { setattr rw_file_perms }; 7 | -------------------------------------------------------------------------------- /location/client_api/README: -------------------------------------------------------------------------------- 1 | Location Client Api doc 2 | 3 | 1. Steps to generate doxygen Api doc: 4 | run 5 | mkclientapidoc.sh [output-path] 6 | default output-path is docs/ 7 | default doxgen configuration file is LocationClientApiDoxygen.conf 8 | 9 | 2. below file will be generated: 10 | html/ 11 | -HTML output, where the html/index.html is the home page. 12 | -------------------------------------------------------------------------------- /sepolicy/vendor/property.te: -------------------------------------------------------------------------------- 1 | # Motorola 2 | vendor_public_prop(moto_boot_prop) 3 | vendor_public_prop(moto_fingerprint_prop) 4 | vendor_public_prop(moto_touch_prop) 5 | vendor_public_prop(moto_camera_prop) 6 | 7 | # AOV 8 | vendor_internal_prop(vendor_aov_prop) 9 | 10 | # Power 11 | vendor_internal_prop(power_prop) 12 | 13 | # FM Radio 14 | vendor_public_prop(vendor_fm_prop) 15 | -------------------------------------------------------------------------------- /location/integration_api/README: -------------------------------------------------------------------------------- 1 | Location Client Api doc 2 | 3 | 1. Steps to generate doxygen Api doc: 4 | run 5 | mkclientapidoc.sh [output-path] 6 | default output-path is docs/ 7 | default doxgen configuration file is LocationClientApiDoxygen.conf 8 | 9 | 2. below file will be generated: 10 | html/ 11 | -HTML output, where the html/index.html is the home page. 12 | -------------------------------------------------------------------------------- /configs/public.libraries.txt: -------------------------------------------------------------------------------- 1 | libqti-perfd-client.so 2 | libadsprpc.so 3 | libcdsprpc.so 4 | libsdsprpc.so 5 | libfastcvopt.so 6 | liblistensoundmodel2.so 7 | libOpenCL.so 8 | libnpu.so 9 | libhta_hexagon_runtime.so 10 | libfastcvopt.so 11 | libqmi_cci.so 12 | libqmi_common_so.so 13 | libqmiservices.so 14 | libqmimotext.so 15 | libiqi_bridge.so 16 | liblowlight_ai_portrait.arcsoft.so 17 | libprotobuf-cpp-full.so 18 | libprotobuf-cpp-lite.so 19 | -------------------------------------------------------------------------------- /sepolicy/vendor/vendor_thermal-engine.te: -------------------------------------------------------------------------------- 1 | r_dir_file(vendor_thermal-engine, vendor_sysfs_battery_supply) 2 | r_dir_file(vendor_thermal-engine, sysfs_msm_subsys) 3 | get_prop(vendor_thermal-engine, moto_boot_prop) 4 | allow vendor_thermal-engine { proc_stat proc_loadavg }:file r_file_perms; 5 | allow vendor_thermal-engine thermal_device:chr_file { rw_file_perms ioctl }; 6 | allow vendor_thermal-engine sysfs_hwmon:dir r_dir_perms; 7 | allow vendor_thermal-engine sysfs_hwmon:file rw_file_perms; 8 | -------------------------------------------------------------------------------- /seccomp/mediacodec-seccomp.policy: -------------------------------------------------------------------------------- 1 | # device specific syscalls 2 | # extension of services/mediacodec/minijail/seccomp_policy/mediacodec-seccomp-arm.policy 3 | pselect6: 1 4 | eventfd2: 1 5 | sendto: 1 6 | recvfrom: 1 7 | _llseek: 1 8 | sysinfo: 1 9 | getcwd: 1 10 | getdents64: 1 11 | ARM_cacheflush: 1 12 | inotify_init1: 1 13 | inotify_add_watch: 1 14 | inotify_rm_watch: 1 15 | uname: 1 16 | ueventd: 1 17 | timer_create: 1 18 | timer_settime: 1 19 | rt_sigtimedwait: 1 20 | readlink: 1 21 | open: 1 22 | -------------------------------------------------------------------------------- /sepolicy/vendor/vl53l1.te: -------------------------------------------------------------------------------- 1 | type vl53l1, domain; 2 | type vl53l1_exec, exec_type, vendor_file_type, file_type; 3 | 4 | init_daemon_domain(vl53l1) 5 | 6 | allow vl53l1 self:netlink_socket { read write create bind }; 7 | allow vl53l1 self:netlink_iscsi_socket { bind create read write }; 8 | allow vl53l1 vendor_sysfs_sensors:dir r_dir_perms; 9 | allow vl53l1 vendor_sysfs_sensors:file rw_file_perms; 10 | allow vl53l1 vendor_sysfs_laser:dir r_dir_perms; 11 | allow vl53l1 vendor_sysfs_laser:file rw_file_perms; 12 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | Copyright 2021 - The LineageOS Project 2 | 3 | Device configuration for Motorola SM6150 Devices 4 | ====================================== 5 | 6 | ## Supported Devices 7 | | Device | Codename | Shipped Android Version | 8 | |----------|----------|----------| 9 | | Moto Z4 | foles | 9 | 10 | | Moto one zoom | parker | 9 | 11 | | Moto one hyper | def | 10 | 12 | | Moto one fusion+ | liber | 10 | 13 | | Moto G9 plus | odessa | 10 | 14 | | Moto G stylus (2021) | minsk | 10 | 15 | | Moto G60 | hanoip | 11 | 16 | -------------------------------------------------------------------------------- /sepolicy/vendor/vendor_rmt_storage.te: -------------------------------------------------------------------------------- 1 | r_dir_file(vendor_rmt_storage, fsg_firmware_file) 2 | r_dir_file(vendor_rmt_storage, vendor_persist_file) 3 | 4 | get_prop(vendor_rmt_storage, vendor_radio_prop) 5 | get_prop(vendor_rmt_storage, moto_boot_prop) 6 | 7 | allow vendor_rmt_storage vendor_modem_block_device:blk_file { open read write }; 8 | allow vendor_rmt_storage unlabeled: { file lnk_file } read; 9 | allow vendor_rmt_storage vendor_persist_rfs_file:dir search; 10 | allow vendor_rmt_storage vendor_persist_rfs_file:file rw_file_perms; 11 | -------------------------------------------------------------------------------- /sepolicy/vendor/motpsd.te: -------------------------------------------------------------------------------- 1 | type motpsd, domain; 2 | type motpsd_exec, exec_type, vendor_file_type, file_type; 3 | init_daemon_domain(motpsd) 4 | 5 | # Write to /dev/kmsg 6 | allow motpsd kmsg_device:chr_file rw_file_perms; 7 | 8 | allow motpsd vendor_sysfs_sensors:dir r_dir_perms; 9 | allow motpsd vendor_sysfs_sensors:file rw_file_perms; 10 | r_dir_file(motpsd, sysfs_msm_subsys) 11 | r_dir_file(motpsd, vendor_sysfs_graphics) 12 | get_prop(motpsd, vendor_sensors_prop) 13 | 14 | allow motpsd self:netlink_kobject_uevent_socket { bind create getopt read setopt }; 15 | allow motpsd self:qipcrtr_socket { create getattr read setopt write }; 16 | -------------------------------------------------------------------------------- /sepolicy/vendor/vendor_init.te: -------------------------------------------------------------------------------- 1 | get_prop(vendor_init, moto_boot_prop) 2 | set_prop(vendor_init, moto_boot_prop) 3 | get_prop(vendor_init, vendor_aov_prop) 4 | set_prop(vendor_init, vendor_aov_prop) 5 | get_prop(vendor_init, power_prop) 6 | set_prop(vendor_init, power_prop) 7 | set_prop(vendor_init, vendor_persist_dpm_prop) 8 | set_prop(vendor_init, vendor_camera_prop) 9 | set_prop(vendor_init, vendor_time_service_prop) 10 | set_prop(vendor_init, vendor_fm_prop) 11 | allow vendor_init { proc_dirty proc proc_sched_lib_mask_cpuinfo }:file rw_file_perms; 12 | allow vendor_init self:perf_event cpu; 13 | allow vendor_init system_file:file getattr; 14 | -------------------------------------------------------------------------------- /sepolicy/vendor/capsense_reset.te: -------------------------------------------------------------------------------- 1 | type capsense_reset, domain; 2 | type capsense_reset_exec, exec_type, vendor_file_type, file_type; 3 | init_daemon_domain(capsense_reset) 4 | 5 | # Write to /dev/kmsg 6 | allow capsense_reset kmsg_device:chr_file rw_file_perms; 7 | 8 | allow capsense_reset input_device:dir r_dir_perms; 9 | allow capsense_reset input_device:chr_file r_file_perms; 10 | 11 | allow capsense_reset vendor_sysfs_sensors:dir r_dir_perms; 12 | allow capsense_reset vendor_sysfs_sensors:file rw_file_perms; 13 | 14 | allow capsense_reset vendor_sysfs_capsense:dir r_dir_perms; 15 | allow capsense_reset vendor_sysfs_capsense:file rw_file_perms; 16 | -------------------------------------------------------------------------------- /gps/geofence/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | 3 | cc_library_shared { 4 | 5 | name: "libgeofencing", 6 | vendor: true, 7 | 8 | sanitize: GNSS_SANITIZE, 9 | 10 | srcs: [ 11 | "GeofenceAdapter.cpp", 12 | "location_geofence.cpp", 13 | ], 14 | 15 | shared_libs: [ 16 | "libutils", 17 | "libcutils", 18 | "libgps.utils", 19 | "liblog", 20 | "libloc_core", 21 | ], 22 | 23 | header_libs: [ 24 | "libgps.utils_headers", 25 | "libloc_core_headers", 26 | "libloc_pla_headers", 27 | "liblocation_api_headers", 28 | ], 29 | 30 | cflags: GNSS_CFLAGS, 31 | } 32 | -------------------------------------------------------------------------------- /gps/batching/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | cc_library_shared { 3 | 4 | name: "libbatching", 5 | vendor: true, 6 | 7 | sanitize: GNSS_SANITIZE, 8 | 9 | shared_libs: [ 10 | "libutils", 11 | "libcutils", 12 | "liblog", 13 | "libloc_core", 14 | "libgps.utils", 15 | "libdl", 16 | ], 17 | 18 | srcs: [ 19 | "location_batching.cpp", 20 | "BatchingAdapter.cpp", 21 | ], 22 | 23 | header_libs: [ 24 | "libgps.utils_headers", 25 | "libloc_core_headers", 26 | "libloc_pla_headers", 27 | "liblocation_api_headers", 28 | ], 29 | 30 | cflags: GNSS_CFLAGS, 31 | } 32 | -------------------------------------------------------------------------------- /sepolicy/vendor/rild.te: -------------------------------------------------------------------------------- 1 | get_prop(rild, moto_boot_prop) 2 | get_prop(rild, vendor_radio_prop) 3 | allow rild fwk_sensor_hwservice:hwservice_manager find; 4 | allow rild input_device:chr_file { r_file_perms ioctl }; 5 | allow rild input_device:dir { open read search }; 6 | allow rild proc_moto_boot:file r_file_perms; 7 | allow rild cutback_data_file:dir { ioctl read write getattr lock add_name remove_name search open }; 8 | allow rild cutback_data_file:file { ioctl read write getattr lock append map open }; 9 | allow rild cutback_data_file:sock_file { create write unlink }; 10 | allow rild cutback_socket:sock_file { ioctl read write create getattr setattr lock append map unlink rename open }; 11 | -------------------------------------------------------------------------------- /sepolicy/vendor/init.te: -------------------------------------------------------------------------------- 1 | # Super modem mounting 2 | allow fsg_firmware_file self:filesystem associate; 3 | allow init fsg_firmware_file:dir mounton; 4 | allow init fsg_firmware_file:filesystem { getattr mount relabelfrom unmount }; 5 | allow init firmware_file:filesystem unmount; 6 | 7 | # Allow init to access loop devices 8 | allow init loop_device:blk_file { create setattr unlink }; 9 | allowxperm init loop_device:blk_file ioctl { 10 | LOOP_GET_STATUS64 11 | LOOP_GET_STATUS 12 | LOOP_SET_STATUS64 13 | LOOP_SET_STATUS 14 | BLKFLSBUF 15 | }; 16 | 17 | # Product persist 18 | allow init mnt_product_file:dir mounton; 19 | 20 | # Wlan firmware 21 | allow init firmware_file:file mounton; 22 | -------------------------------------------------------------------------------- /bootctrl/1.1/impl/Android.bp: -------------------------------------------------------------------------------- 1 | filegroup { 2 | name: "android.hardware.boot@1.1-impl-qti_src", 3 | srcs: ["BootControl.cpp"], 4 | } 5 | 6 | cc_defaults { 7 | name: "android.hardware.boot@1.1-impl-qti_defaults", 8 | defaults: [ 9 | "hidl_defaults", 10 | "libboot_control_qti_defaults", 11 | ], 12 | relative_install_path: "hw", 13 | vendor: true, 14 | recovery_available: true, 15 | srcs: [":android.hardware.boot@1.1-impl-qti_src"], 16 | shared_libs: [ 17 | "liblog", 18 | "libhidlbase", 19 | "libhardware", 20 | "libutils", 21 | "android.hardware.boot@1.0", 22 | "android.hardware.boot@1.1", 23 | ], 24 | } 25 | -------------------------------------------------------------------------------- /location/gnsspps/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | cc_library_shared { 3 | 4 | name: "libgnsspps", 5 | vendor: true, 6 | 7 | sanitize: GNSS_SANITIZE, 8 | 9 | shared_libs: [ 10 | "libutils", 11 | "libcutils", 12 | "libgps.utils", 13 | "liblog", 14 | ], 15 | 16 | srcs: ["gnsspps.c"], 17 | 18 | cflags: [ 19 | "-fno-short-enums", 20 | "-D_ANDROID_", 21 | ] + GNSS_CFLAGS, //# Includes 22 | 23 | header_libs: [ 24 | "libgps.utils_headers", 25 | "libloc_pla_headers", 26 | ], 27 | 28 | } 29 | 30 | cc_library_headers { 31 | 32 | name: "libgnsspps_headers", 33 | export_include_dirs: ["."], 34 | vendor: true, 35 | } 36 | -------------------------------------------------------------------------------- /gps/location/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | cc_library_shared { 3 | 4 | name: "liblocation_api", 5 | vendor: true, 6 | 7 | sanitize: GNSS_SANITIZE, 8 | 9 | shared_libs: [ 10 | "libutils", 11 | "libcutils", 12 | "libgps.utils", 13 | "libdl", 14 | "liblog", 15 | ], 16 | 17 | srcs: [ 18 | "LocationAPI.cpp", 19 | "LocationAPIClientBase.cpp", 20 | ], 21 | 22 | cflags: ["-fno-short-enums"] + GNSS_CFLAGS, 23 | 24 | header_libs: [ 25 | "libloc_pla_headers", 26 | "libgps.utils_headers", 27 | ], 28 | 29 | } 30 | 31 | cc_library_headers { 32 | 33 | name: "liblocation_api_headers", 34 | export_include_dirs: ["."], 35 | vendor: true, 36 | } 37 | -------------------------------------------------------------------------------- /gps/gnss/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | 3 | cc_library_shared { 4 | 5 | name: "libgnss", 6 | vendor: true, 7 | 8 | sanitize: GNSS_SANITIZE, 9 | 10 | shared_libs: [ 11 | "libutils", 12 | "libcutils", 13 | "libdl", 14 | "liblog", 15 | "libloc_core", 16 | "libgps.utils", 17 | ], 18 | 19 | srcs: [ 20 | "location_gnss.cpp", 21 | "GnssAdapter.cpp", 22 | "Agps.cpp", 23 | "XtraSystemStatusObserver.cpp", 24 | "NativeAgpsHandler.cpp", 25 | ], 26 | 27 | cflags: ["-fno-short-enums"] + GNSS_CFLAGS, 28 | header_libs: [ 29 | "libgps.utils_headers", 30 | "libloc_core_headers", 31 | "libloc_pla_headers", 32 | "liblocation_api_headers", 33 | ], 34 | 35 | } 36 | -------------------------------------------------------------------------------- /sepolicy/vendor/hal_audio_default.te: -------------------------------------------------------------------------------- 1 | # For interfacing with PowerHAL 2 | hal_client_domain(hal_audio_default, hal_power) 3 | 4 | r_dir_file(hal_audio_default, sysfs_adspd) 5 | allow hal_audio_default sysfs_adspd:file rw_file_perms; 6 | 7 | #FIXME: Address input sysfs nodes as sysfs_adspd (/devices/virtual/input/input[0-9]+/capabilities(/.*)?) 8 | r_dir_file(hal_audio_default, sysfs) 9 | allow hal_audio_default sysfs:file rw_file_perms; 10 | 11 | set_prop(hal_audio_default, vendor_aov_prop) 12 | 13 | unix_socket_connect(hal_audio_default, property, init) 14 | allow hal_audio_default self:binder { call transfer }; 15 | allow hal_audio_default self:fd use; 16 | 17 | allow hal_audio_default input_device:dir r_dir_perms; 18 | allow hal_audio_default input_device:chr_file { r_file_perms ioctl }; 19 | -------------------------------------------------------------------------------- /configs/privapp-permissions-hotword.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /sepolicy/vendor/hal_camera_default.te: -------------------------------------------------------------------------------- 1 | # For interfacing with PowerHAL 2 | hal_client_domain(hal_camera_default, hal_power) 3 | 4 | # Allow hal_camera_default to read to sysfs_kgsl 5 | r_dir_file(hal_camera_default, vendor_sysfs_kgsl) 6 | 7 | # Allow hal_camera_default to read to mnt/vendor/persist 8 | r_dir_file(hal_camera_default, mnt_vendor_file) 9 | 10 | # Camera props 11 | set_prop(hal_camera_default, vendor_camera_prop) 12 | 13 | # VL53L1 14 | allow hal_camera_default vl53l1_device:chr_file rw_file_perms; 15 | 16 | # DSP 17 | allow hal_camera_default vendor_xdsp_device:chr_file read; 18 | 19 | # Props 20 | get_prop(hal_camera_default, moto_boot_prop) 21 | set_prop(hal_camera_default, moto_boot_prop) 22 | get_prop(hal_camera_default, moto_camera_prop) 23 | set_prop(hal_camera_default, moto_camera_prop) 24 | -------------------------------------------------------------------------------- /sepolicy/vendor/hal_power_default.te: -------------------------------------------------------------------------------- 1 | allow hal_power_default { 2 | vendor_sysfs_devfreq 3 | sysfs_msm_subsys 4 | vendor_sysfs_sensors 5 | }:dir search; 6 | 7 | allow hal_power_default { 8 | cgroup 9 | proc 10 | vendor_sysfs_devfreq 11 | sysfs_devices_system_cpu 12 | vendor_sysfs_graphics 13 | vendor_sysfs_kgsl 14 | sysfs_msm_subsys 15 | vendor_sysfs_scsi_host 16 | sysfs_scsi_devices_0000 17 | vendor_sysfs_sensors 18 | }:{ 19 | file 20 | lnk_file 21 | } rw_file_perms; 22 | 23 | allow hal_power_default vendor_latency_device:chr_file rw_file_perms; 24 | 25 | # Rule for hal_power_default to access graphics composer process 26 | unix_socket_connect(hal_power_default, vendor_pps, hal_graphics_composer_default); 27 | 28 | # To get/set powerhal state property 29 | set_prop(hal_power_default, power_prop) 30 | -------------------------------------------------------------------------------- /sepolicy/vendor/vendor_qti_init_shell.te: -------------------------------------------------------------------------------- 1 | get_prop(vendor_qti_init_shell, moto_boot_prop) 2 | set_prop(vendor_qti_init_shell, moto_boot_prop) 3 | get_prop(vendor_qti_init_shell, moto_touch_prop) 4 | set_prop(vendor_qti_init_shell, moto_touch_prop) 5 | allow vendor_qti_init_shell vendor_sysfs_laser:dir r_dir_perms; 6 | allow vendor_qti_init_shell vendor_sysfs_laser:file { setattr rw_file_perms }; 7 | allow vendor_qti_init_shell sysfs_android_usb:dir r_dir_perms; 8 | allow vendor_qti_init_shell sysfs_android_usb:file rw_file_perms; 9 | allow vendor_qti_init_shell kmsg_device:chr_file { open write }; 10 | allow vendor_qti_init_shell vendor_file:file execute_no_trans; 11 | allow vendor_qti_init_shell vendor_file:system module_load; 12 | allow vendor_qti_init_shell vendor_sysfs_touch:dir r_dir_perms; 13 | allow vendor_qti_init_shell vendor_sysfs_touch:file { setattr rw_file_perms }; 14 | -------------------------------------------------------------------------------- /gps/android/utils/Android.bp: -------------------------------------------------------------------------------- 1 | cc_library_static { 2 | 3 | name: "liblocbatterylistener", 4 | vendor: true, 5 | 6 | sanitize: GNSS_SANITIZE, 7 | 8 | cflags: GNSS_CFLAGS + ["-DBATTERY_LISTENER_ENABLED"], 9 | local_include_dirs: ["."], 10 | 11 | srcs: ["battery_listener.cpp"], 12 | 13 | shared_libs: [ 14 | "liblog", 15 | "libhidlbase", 16 | "libcutils", 17 | "libutils", 18 | "android.hardware.health@1.0", 19 | "android.hardware.health@2.0", 20 | "android.hardware.health@2.1", 21 | "android.hardware.power@1.2", 22 | "libbase", 23 | ], 24 | 25 | static_libs: ["libhealthhalutils"], 26 | 27 | header_libs: [ 28 | "libgps.utils_headers", 29 | "libloc_pla_headers", 30 | ], 31 | } 32 | 33 | cc_library_headers { 34 | 35 | name: "liblocbatterylistener_headers", 36 | export_include_dirs: ["."], 37 | } 38 | -------------------------------------------------------------------------------- /sepolicy/vendor/file.te: -------------------------------------------------------------------------------- 1 | # Partitions 2 | type fsg_firmware_file, file_type, contextmount_type, vendor_file_type; 3 | 4 | # charge_only_mode 5 | type chargeonly_data_file, file_type, data_file_type; 6 | type persist_chargeonly_file, file_type, data_file_type; 7 | 8 | # ADSPD 9 | type sysfs_adspd, sysfs_type, fs_type; 10 | 11 | # Cutback 12 | type cutback_data_file, file_type, data_file_type; 13 | type cutback_socket, file_type; 14 | type audio_cutback_data_file, file_type, data_file_type; 15 | 16 | # Power 17 | type sysfs_msm_subsys, sysfs_type, fs_type; 18 | type sysfs_scsi_devices_0000, sysfs_type, fs_type; 19 | type proc_sched_lib_mask_cpuinfo, proc_type, fs_type; 20 | 21 | # Motorola 22 | type proc_moto_boot, proc_type, fs_type; 23 | 24 | # Thermal 25 | type sysfs_hwmon, sysfs_type, fs_type; 26 | 27 | # Fingerprint 28 | type vendor_persist_fps_file, file_type, vendor_persist_type; 29 | 30 | # Capsense 31 | type vendor_sysfs_capsense, sysfs_type, fs_type; 32 | -------------------------------------------------------------------------------- /overlay-lineage/packages/apps/Dialer/java/com/android/dialer/callrecord/res/values/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 17 | 18 | true 19 | 4 20 | 21 | -------------------------------------------------------------------------------- /bootctrl/1.1/libboot_control_qti/Android.bp: -------------------------------------------------------------------------------- 1 | filegroup { 2 | name: "libboot_control_qti_src", 3 | srcs: ["libboot_control_qti.cpp"], 4 | } 5 | 6 | cc_library_headers { 7 | name: "libboot_control_qti_headers", 8 | vendor: true, 9 | recovery_available: true, 10 | export_include_dirs: ["."], 11 | } 12 | 13 | cc_defaults { 14 | name: "libboot_control_qti_defaults", 15 | vendor: true, 16 | recovery_available: true, 17 | shared_libs: [ 18 | "android.hardware.boot@1.1", 19 | "libbase", 20 | "libcutils", 21 | "liblog", 22 | "libz", 23 | ], 24 | static_libs: [ 25 | "libboot_control", 26 | "libbootloader_message_vendor", 27 | "libfstab", 28 | ], 29 | owner: "qti", 30 | cflags: [ 31 | "-Wall", 32 | "-Werror", 33 | ], 34 | srcs: [ 35 | ":libboot_control_qti_src", 36 | ], 37 | header_libs: ["libboot_control_qti_headers"], 38 | } 39 | -------------------------------------------------------------------------------- /init/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2019 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 | cc_library_static { 18 | name: "libinit_sm6150", 19 | recovery_available: true, 20 | srcs: ["init_sm6150.cpp"], 21 | include_dirs: [ 22 | "system/core/init", 23 | "system/libbase/include" 24 | ], 25 | shared_libs: [ 26 | "libbase", 27 | ] 28 | } 29 | -------------------------------------------------------------------------------- /gps/etc/lowi.conf: -------------------------------------------------------------------------------- 1 | #*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* 2 | # 3 | # LOWI Config file - default 4 | # 5 | # GENERAL DESCRIPTION 6 | # This file contains the config params for LOWI 7 | # 8 | # Copyright (c) 2019 Qualcomm Technologies, Inc. 9 | # All Rights Reserved. 10 | # Confidential and Proprietary - Qualcomm Technologies, Inc. 11 | # 12 | # 2012-2013 Qualcomm Atheros, Inc. 13 | # All Rights Reserved. 14 | # Qualcomm Atheros Confidential and Proprietary. 15 | # 16 | # Export of this technology or software is regulated by the U.S. Government. 17 | # Diversion contrary to U.S. law prohibited. 18 | #=============================================================================*/ 19 | 20 | # X86 ONLY - UBUNTU: 21 | # Copy this file in the same directory where the executable is 22 | 23 | # Log level 24 | # EL_LOG_OFF = 0, EL_ERROR = 1, EL_WARNING = 2, EL_INFO = 3, EL_DEBUG = 4, EL_VERBOSE = 5, EL_LOG_ALL = 100 25 | LOWI_LOG_LEVEL = 3 26 | LOWI_USE_LOWI_LP = 0 27 | 28 | -------------------------------------------------------------------------------- /gps/gnss/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | $(LOCPLA_CFLAGS) \ 3 | $(LOCHAL_CFLAGS) \ 4 | $(GPSUTILS_CFLAGS) \ 5 | $(LOCCORE_CFLAGS) \ 6 | -I./ \ 7 | -I../utils \ 8 | -I$(WORKSPACE)/hardware/qcom/gps/core/data-items \ 9 | -I../location \ 10 | -std=c++1y 11 | 12 | libgnss_la_SOURCES = \ 13 | location_gnss.cpp \ 14 | GnssAdapter.cpp \ 15 | XtraSystemStatusObserver.cpp \ 16 | Agps.cpp \ 17 | NativeAgpsHandler.cpp 18 | 19 | if USE_GLIB 20 | libgnss_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 21 | libgnss_la_LDFLAGS = -lstdc++ -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared -avoid-version 22 | libgnss_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 23 | else 24 | libgnss_la_CFLAGS = $(AM_CFLAGS) 25 | libgnss_la_LDFLAGS = -Wl,-z,defs -lpthread -shared -version-info 1:0:0 26 | libgnss_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 27 | endif 28 | 29 | libgnss_la_LIBADD = -lstdc++ -ldl $(GPSUTILS_LIBS) $(LOCCORE_LIBS) 30 | 31 | #Create and Install libraries 32 | lib_LTLIBRARIES = libgnss.la 33 | -------------------------------------------------------------------------------- /location/gnsspps/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | $(LOCPLA_CFLAGS) \ 3 | $(GPSUTILS_CFLAGS) \ 4 | -I$(WORKSPACE)/system/core/include \ 5 | -I./ 6 | 7 | ACLOCAL_AMFLAGS = -I m4 8 | 9 | libgnsspps_la_SOURCES = \ 10 | gnsspps.c 11 | 12 | if USE_GLIB 13 | libgnsspps_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 14 | libgnsspps_la_LDFLAGS = -lstdc++ -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared -version-info 1:0:0 15 | libgnsspps_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 16 | else 17 | libgnsspps_la_CFLAGS = $(AM_CFLAGS) 18 | libgnsspps_la_LDFLAGS = -Wl,-z,defs -lpthread -shared -version-info 1:0:0 19 | libgnsspps_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 20 | endif 21 | 22 | libgnsspps_la_LIBADD = -lstdc++ $(GPSUTILS_LIBS) 23 | 24 | library_include_HEADERS = \ 25 | gnsspps.h 26 | 27 | #Create and Install libraries 28 | lib_LTLIBRARIES = libgnsspps.la 29 | 30 | library_includedir = $(pkgincludedir) 31 | pkgconfigdir = $(libdir)/pkgconfig 32 | pkgconfig_DATA = gnsspps.pc 33 | EXTRA_DIST = $(pkgconfig_DATA) 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /overlay/frameworks/base/packages/SystemUI/res/values/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 19 | 20 | 22 | 23 | 24 | true 25 | 26 | -------------------------------------------------------------------------------- /power-libperfmgr/CameraMode.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2018 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 | #ifndef POWER_LIBPERFMGR_CAMERAMODE_H_ 18 | #define POWER_LIBPERFMGR_CAMERAMODE_H_ 19 | 20 | enum CameraStreamingMode { 21 | CAMERA_STREAMING_OFF = 0, 22 | CAMERA_STREAMING, 23 | CAMERA_STREAMING_1080P, 24 | CAMERA_STREAMING_60FPS, 25 | CAMERA_STREAMING_4K, 26 | CAMERA_STREAMING_SECURE, 27 | CAMERA_STREAMING_MAX 28 | }; 29 | 30 | #endif // POWER_LIBPERFMGR_CAMERAMODE_H_ 31 | -------------------------------------------------------------------------------- /location/synergy_loc_api/Android.mk: -------------------------------------------------------------------------------- 1 | LOCAL_PATH := $(call my-dir) 2 | 3 | include $(CLEAR_VARS) 4 | 5 | LOCAL_MODULE := libsynergy_loc_api 6 | LOCAL_SANITIZE += $(GNSS_SANITIZE) 7 | # activate the following line for debug purposes only, comment out for production 8 | #LOCAL_SANITIZE_DIAG += $(GNSS_SANITIZE_DIAG) 9 | 10 | LOCAL_MODULE_PATH_32 := $(TARGET_OUT_VENDOR)/lib 11 | LOCAL_MODULE_PATH_64 := $(TARGET_OUT_VENDOR)/lib64 12 | LOCAL_MODULE_TAGS := optional 13 | LOCAL_VENDOR_MODULE := true 14 | 15 | LOCAL_SHARED_LIBRARIES := \ 16 | libutils \ 17 | libcutils \ 18 | libqmi_cci \ 19 | libqmi_common_so \ 20 | libloc_core \ 21 | libgps.utils \ 22 | libdl \ 23 | liblog 24 | 25 | LOCAL_SRC_FILES = \ 26 | SynergyLocApi.cpp 27 | 28 | LOCAL_CFLAGS += \ 29 | -fno-short-enums \ 30 | -D_ANDROID_ 31 | 32 | ## Includes 33 | LOCAL_HEADER_LIBRARIES := \ 34 | libloc_core_headers \ 35 | libgps.utils_headers \ 36 | libloc_pla_headers \ 37 | loc_sll_if_headers \ 38 | liblocation_api_headers 39 | 40 | LOCAL_CFLAGS += $(GNSS_CFLAGS) 41 | include $(BUILD_SHARED_LIBRARY) 42 | -------------------------------------------------------------------------------- /sepolicy/vendor/vendor_init_fingerprint.te: -------------------------------------------------------------------------------- 1 | type vendor_init_fingerprint, domain; 2 | type vendor_init_fingerprint_exec, exec_type, vendor_file_type, file_type; 3 | init_daemon_domain(vendor_init_fingerprint) 4 | 5 | # Write to /dev/kmsg 6 | allow vendor_init_fingerprint kmsg_device:chr_file rw_file_perms; 7 | 8 | allow vendor_init_fingerprint ctl_start_prop:file { read getattr map open }; 9 | allow vendor_init_fingerprint ctl_start_prop:property_service set; 10 | allow vendor_init_fingerprint fingerprint_device:chr_file r_file_perms; 11 | allow vendor_init_fingerprint kernel:key search; 12 | allow vendor_init_fingerprint self:capability sys_module; 13 | allow vendor_init_fingerprint vendor_file:system module_load; 14 | allow vendor_init_fingerprint vendor_toolbox_exec:file rx_file_perms; 15 | allow vendor_init_fingerprint vendor_persist_fps_file:file r_file_perms; 16 | allow vendor_init_fingerprint vendor_persist_fps_file:dir r_dir_perms; 17 | allow vendor_init_fingerprint mnt_vendor_file:dir search; 18 | 19 | get_prop(vendor_init_fingerprint, moto_boot_prop) 20 | set_prop(vendor_init_fingerprint, moto_fingerprint_prop) 21 | -------------------------------------------------------------------------------- /power-libperfmgr/AudioStreaming.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2019 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 | #ifndef POWER_LIBPERFMGR_AUDIOSTREAMING_H_ 18 | #define POWER_LIBPERFMGR_AUDIOSTREAMING_H_ 19 | 20 | enum AUDIO_STREAMING_HINT { 21 | AUDIO_STREAMING_OFF = 0, 22 | AUDIO_STREAMING_ON = 1, 23 | TPU_BOOST_OFF = 1000, 24 | TPU_BOOST_SHORT = 1001, 25 | TPU_BOOST_LONG = 1002 26 | }; 27 | 28 | enum TPU_HINT_DURATION_MS { SHORT = 200, LONG = 2000 }; 29 | 30 | #endif // POWER_LIBPERFMGR_AUDIOSTREAMING_H_ 31 | -------------------------------------------------------------------------------- /configs/media_codecs_vendor_audio.xml: -------------------------------------------------------------------------------- 1 | 2 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /gps/utils/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | cc_library_shared { 3 | 4 | name: "libgps.utils", 5 | vendor: true, 6 | 7 | sanitize: GNSS_SANITIZE, 8 | 9 | //# Libs 10 | shared_libs: [ 11 | "libdl", 12 | "libutils", 13 | "libcutils", 14 | "liblog", 15 | "libprocessgroup", 16 | ], 17 | 18 | srcs: [ 19 | "loc_log.cpp", 20 | "loc_cfg.cpp", 21 | "msg_q.c", 22 | "linked_list.c", 23 | "loc_target.cpp", 24 | "LocHeap.cpp", 25 | "LocTimer.cpp", 26 | "LocThread.cpp", 27 | "MsgTask.cpp", 28 | "loc_misc_utils.cpp", 29 | "loc_nmea.cpp", 30 | "LocIpc.cpp", 31 | "LogBuffer.cpp", 32 | ], 33 | 34 | cflags: [ 35 | "-fno-short-enums", 36 | "-D_ANDROID_", 37 | ] + GNSS_CFLAGS, 38 | 39 | //# Includes 40 | ldflags: ["-Wl,--export-dynamic"], 41 | 42 | header_libs: [ 43 | "libutils_headers", 44 | "libloc_pla_headers", 45 | "liblocation_api_headers", 46 | ], 47 | } 48 | 49 | cc_library_headers { 50 | 51 | name: "libgps.utils_headers", 52 | export_include_dirs: ["."], 53 | vendor: true, 54 | } 55 | -------------------------------------------------------------------------------- /gpt-utils/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2018 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 | 18 | cc_library { 19 | name: "libgptutils.motorola_sm6150", 20 | vendor: true, 21 | recovery_available: true, 22 | shared_libs: [ 23 | "libcutils", 24 | "liblog", 25 | "libz", 26 | ], 27 | cflags: [ 28 | "-Wall", 29 | "-Werror", 30 | ], 31 | srcs: [ 32 | "gpt-utils.cpp", 33 | ], 34 | owner: "qti", 35 | header_libs: [ 36 | "generated_kernel_headers", 37 | ], 38 | export_include_dirs: ["."], 39 | } 40 | -------------------------------------------------------------------------------- /overlay-lineage-fastbootd/lineage-sdk/lineage/res/res/values/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 18 | 19 | 20 | 21 | restart 22 | restart_recovery 23 | restart_bootloader 24 | restart_fastboot 25 | 26 | 27 | -------------------------------------------------------------------------------- /bluetooth/include/bdroid_buildcfg.h: -------------------------------------------------------------------------------- 1 | /* 2 | * 3 | * Copyright (c) 2013, The Linux Foundation. All rights reserved. 4 | * Not a Contribution, Apache license notifications and license are retained 5 | * for attribution purposes only. 6 | * 7 | * Copyright (C) 2012 The Android Open Source Project 8 | * 9 | * Licensed under the Apache License, Version 2.0 (the "License"); 10 | * you may not use this file except in compliance with the License. 11 | * You may obtain a copy of the License at 12 | * 13 | * http://www.apache.org/licenses/LICENSE-2.0 14 | * 15 | * Unless required by applicable law or agreed to in writing, software 16 | * distributed under the License is distributed on an "AS IS" BASIS, 17 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 18 | * See the License for the specific language governing permissions and 19 | * limitations under the License. 20 | */ 21 | 22 | #ifndef _BDROID_BUILDCFG_H 23 | #define _BDROID_BUILDCFG_H 24 | 25 | #define BTM_DEF_LOCAL_NAME BtmGetDefaultName() 26 | // Disables read remote device feature 27 | #define BTM_WBS_INCLUDED TRUE 28 | #define BTIF_HF_WBS_PREFERRED TRUE 29 | 30 | #define BLE_VND_INCLUDED TRUE 31 | #endif 32 | -------------------------------------------------------------------------------- /gps/Android.bp: -------------------------------------------------------------------------------- 1 | GNSS_CFLAGS = [ 2 | "-Werror", 3 | "-Wno-error=unused-parameter", 4 | "-Wno-error=macro-redefined", 5 | "-Wno-error=reorder", 6 | "-Wno-error=missing-braces", 7 | "-Wno-error=self-assign", 8 | "-Wno-error=enum-conversion", 9 | "-Wno-error=logical-op-parentheses", 10 | "-Wno-error=null-arithmetic", 11 | "-Wno-error=null-conversion", 12 | "-Wno-error=parentheses-equality", 13 | "-Wno-error=undefined-bool-conversion", 14 | "-Wno-error=tautological-compare", 15 | "-Wno-error=switch", 16 | "-Wno-error=date-time", 17 | ] 18 | 19 | /* Activate the following for regression testing */ 20 | GNSS_SANITIZE = { 21 | /* address: true,*/ 22 | cfi: true, 23 | misc_undefined: [ 24 | "bounds", 25 | "null", 26 | "unreachable", 27 | "integer", 28 | ], 29 | } 30 | 31 | /* Activate the following for debug purposes only, 32 | comment out for production */ 33 | GNSS_SANITIZE_DIAG = { 34 | /* 35 | diag: { 36 | cfi: true, 37 | misc_undefined: [ 38 | "bounds", 39 | "null", 40 | "unreachable", 41 | "integer", 42 | ], 43 | }, 44 | */ 45 | } 46 | -------------------------------------------------------------------------------- /location/Android.bp: -------------------------------------------------------------------------------- 1 | GNSS_CFLAGS = [ 2 | "-Werror", 3 | "-Wno-error=unused-parameter", 4 | "-Wno-error=macro-redefined", 5 | "-Wno-error=reorder", 6 | "-Wno-error=missing-braces", 7 | "-Wno-error=self-assign", 8 | "-Wno-error=enum-conversion", 9 | "-Wno-error=logical-op-parentheses", 10 | "-Wno-error=null-arithmetic", 11 | "-Wno-error=null-conversion", 12 | "-Wno-error=parentheses-equality", 13 | "-Wno-error=undefined-bool-conversion", 14 | "-Wno-error=tautological-compare", 15 | "-Wno-error=switch", 16 | "-Wno-error=date-time", 17 | ] 18 | 19 | /* Activate the following for regression testing */ 20 | GNSS_SANITIZE = { 21 | /* address: true,*/ 22 | cfi: true, 23 | misc_undefined: [ 24 | "bounds", 25 | "null", 26 | "unreachable", 27 | "integer", 28 | ], 29 | } 30 | 31 | /* Activate the following for debug purposes only, 32 | comment out for production */ 33 | GNSS_SANITIZE_DIAG = { 34 | /* 35 | diag: { 36 | cfi: true, 37 | misc_undefined: [ 38 | "bounds", 39 | "null", 40 | "unreachable", 41 | "integer", 42 | ], 43 | }, 44 | */ 45 | } 46 | -------------------------------------------------------------------------------- /gps/core/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | cc_library_shared { 3 | 4 | name: "libloc_core", 5 | vendor: true, 6 | 7 | sanitize: GNSS_SANITIZE, 8 | 9 | shared_libs: [ 10 | "liblog", 11 | "libutils", 12 | "libcutils", 13 | "libgps.utils", 14 | "libdl", 15 | "liblog", 16 | ], 17 | 18 | srcs: [ 19 | "LocApiBase.cpp", 20 | "LocAdapterBase.cpp", 21 | "ContextBase.cpp", 22 | "LocContext.cpp", 23 | "loc_core_log.cpp", 24 | "data-items/DataItemsFactoryProxy.cpp", 25 | "SystemStatusOsObserver.cpp", 26 | "SystemStatus.cpp", 27 | ], 28 | 29 | cflags: [ 30 | "-fno-short-enums", 31 | "-D_ANDROID_", 32 | ] + GNSS_CFLAGS, 33 | 34 | local_include_dirs: [ 35 | "data-items", 36 | "observer", 37 | ], 38 | 39 | header_libs: [ 40 | "libutils_headers", 41 | "libgps.utils_headers", 42 | "libloc_pla_headers", 43 | "liblocation_api_headers", 44 | ], 45 | 46 | } 47 | 48 | cc_library_headers { 49 | 50 | name: "libloc_core_headers", 51 | vendor: true, 52 | export_include_dirs: ["."] + [ 53 | "data-items", 54 | "observer", 55 | ], 56 | } 57 | -------------------------------------------------------------------------------- /common_dynamic.mk: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2019-2020 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 | # AB Partitions 18 | AB_OTA_PARTITIONS += \ 19 | recovery \ 20 | product 21 | 22 | # Crypto 23 | PRODUCT_PROPERTY_OVERRIDES += \ 24 | ro.crypto.dm_default_key.options_format.version=2 \ 25 | ro.crypto.volume.metadata.method=dm-default-key \ 26 | ro.crypto.volume.options=::v2 27 | 28 | # Fstab 29 | PRODUCT_COPY_FILES += \ 30 | $(LOCAL_PATH)/rootdir/etc/fstab_dynamic.qcom:$(TARGET_COPY_OUT_RAMDISK)/fstab.qcom 31 | 32 | # Fastbootd 33 | PRODUCT_PACKAGES += \ 34 | fastbootd 35 | 36 | # Overlays 37 | DEVICE_PACKAGE_OVERLAYS += \ 38 | $(LOCAL_PATH)/overlay-lineage-fastbootd 39 | -------------------------------------------------------------------------------- /rro_overlays/WifiOverlay/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 16 | 17 | 22 | 23 | 28 | 29 | -------------------------------------------------------------------------------- /location/utils/loc_socket/Android.mk: -------------------------------------------------------------------------------- 1 | LOCAL_PATH := $(call my-dir) 2 | 3 | include $(CLEAR_VARS) 4 | 5 | LOCAL_MODULE := libloc_socket 6 | LOCAL_SANITIZE += $(GNSS_SANITIZE) 7 | # activate the following line for debug purposes only, comment out for production 8 | #LOCAL_SANITIZE_DIAG += $(GNSS_SANITIZE_DIAG) 9 | LOCAL_MODULE_PATH_32 := $(TARGET_OUT_VENDOR)/lib 10 | LOCAL_MODULE_PATH_64 := $(TARGET_OUT_VENDOR)/lib64 11 | LOCAL_MODULE_TAGS := optional 12 | 13 | LOCAL_SHARED_LIBRARIES := \ 14 | libutils \ 15 | libcutils \ 16 | liblog \ 17 | libgps.utils 18 | 19 | LOCAL_SRC_FILES := \ 20 | LocSocket.cpp 21 | 22 | LOCAL_CFLAGS := \ 23 | -fno-short-enums \ 24 | -D_ANDROID_ 25 | 26 | ## Includes 27 | LOCAL_C_INCLUDES := \ 28 | $(TARGET_OUT_HEADERS)/qmi-framework/inc \ 29 | $(TARGET_OUT_HEADERS)/qmi/inc 30 | LOCAL_HEADER_LIBRARIES := \ 31 | libloc_core_headers \ 32 | libgps.utils_headers \ 33 | libloc_pla_headers \ 34 | liblocation_api_headers 35 | LOCAL_CFLAGS += $(GNSS_CFLAGS) 36 | 37 | ifeq ($(TARGET_KERNEL_VERSION),$(filter $(TARGET_KERNEL_VERSION),3.18 4.4 4.9)) 38 | LOCAL_CFLAGS += -DUSE_QSOCKET 39 | LOCAL_C_INCLUDES += $(TARGET_OUT_HEADERS)/qsocket/inc 40 | LOCAL_SHARED_LIBRARIES += libqsocket 41 | endif 42 | 43 | include $(BUILD_SHARED_LIBRARY) 44 | -------------------------------------------------------------------------------- /location/loc_api/loc_api_v02/Android.mk: -------------------------------------------------------------------------------- 1 | LOCAL_PATH := $(call my-dir) 2 | 3 | include $(CLEAR_VARS) 4 | 5 | LOCAL_MODULE := libloc_api_v02 6 | LOCAL_SANITIZE += $(GNSS_SANITIZE) 7 | # activate the following line for debug purposes only, comment out for production 8 | #LOCAL_SANITIZE_DIAG += $(GNSS_SANITIZE_DIAG) 9 | LOCAL_MODULE_PATH_32 := $(TARGET_OUT_VENDOR)/lib 10 | LOCAL_MODULE_PATH_64 := $(TARGET_OUT_VENDOR)/lib64 11 | LOCAL_MODULE_TAGS := optional 12 | 13 | LOCAL_SHARED_LIBRARIES := \ 14 | libutils \ 15 | libcutils \ 16 | libqmi_cci \ 17 | libqmi_common_so \ 18 | libloc_core \ 19 | libgps.utils \ 20 | libdl \ 21 | liblog 22 | 23 | LOCAL_SRC_FILES = \ 24 | LocApiV02.cpp \ 25 | loc_api_v02_log.cpp \ 26 | loc_api_v02_client.cpp \ 27 | loc_api_sync_req.cpp \ 28 | location_service_v02.c 29 | 30 | LOCAL_CFLAGS += \ 31 | -fno-short-enums \ 32 | -D_ANDROID_ 33 | 34 | ## Includes 35 | LOCAL_C_INCLUDES := \ 36 | $(TARGET_OUT_HEADERS)/qmi-framework/inc \ 37 | $(TARGET_OUT_HEADERS)/qmi/inc 38 | LOCAL_HEADER_LIBRARIES := \ 39 | libloc_core_headers \ 40 | libgps.utils_headers \ 41 | libloc_pla_headers \ 42 | liblocation_api_headers \ 43 | libqmi_common_headers \ 44 | libqmi_cci_headers 45 | 46 | LOCAL_CFLAGS += $(GNSS_CFLAGS) 47 | include $(BUILD_SHARED_LIBRARY) 48 | -------------------------------------------------------------------------------- /gps/batching/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | $(GPSUTILS_CFLAGS) \ 3 | $(LOCCORE_CFLAGS) \ 4 | -I./ \ 5 | -std=c++1y \ 6 | -D__func__=__PRETTY_FUNCTION__ \ 7 | -fno-short-enums 8 | 9 | ACLOCAL_AMFLAGS = -I m4 10 | 11 | requiredlibs = \ 12 | $(GPSUTILS_LIBS) \ 13 | $(LOCCORE_LIBS) \ 14 | -llog 15 | 16 | h_sources = \ 17 | BatchingAdapter.h 18 | 19 | libbatching_la_SOURCES = \ 20 | location_batching.cpp \ 21 | BatchingAdapter.cpp 22 | 23 | if USE_GLIB 24 | libbatching_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 25 | libbatching_la_LDFLAGS = -lstdc++ -g -Wl,-z,defs -lpthread $(requiredlibs) @GLIB_LIBS@ -shared -version-info 1:0:0 26 | libbatching_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 27 | else 28 | libbatching_la_CFLAGS = $(AM_CFLAGS) 29 | libbatching_la_LDFLAGS = -Wl,-z,defs -lpthread $(requiredlibs) -shared -version-info 1:0:0 30 | libbatching_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 31 | endif 32 | 33 | library_include_HEADERS = $(h_sources) 34 | 35 | library_includedir = $(pkgincludedir) 36 | 37 | #Create and Install libraries 38 | lib_LTLIBRARIES = libbatching.la 39 | 40 | pkgconfigdir = $(libdir)/pkgconfig 41 | pkgconfig_DATA = location-batching.pc 42 | sysconf_DATA = $(WORKSPACE)/hardware/qcom/gps/etc/flp.conf 43 | EXTRA_DIST = $(pkgconfig_DATA) 44 | 45 | -------------------------------------------------------------------------------- /gps/location/Makefile.am: -------------------------------------------------------------------------------- 1 | ACLOCAL_AMFLAGS = -I m4 2 | 3 | AM_CFLAGS = \ 4 | -I./ \ 5 | -I../utils \ 6 | $(LOCPLA_CFLAGS) \ 7 | $(GPSUTILS_CFLAGS) \ 8 | -std=c++11 9 | 10 | liblocation_api_la_SOURCES = \ 11 | LocationAPI.cpp \ 12 | LocationAPIClientBase.cpp 13 | 14 | if USE_EXTERNAL_AP 15 | AM_CFLAGS += -DFEATURE_EXTERNAL_AP 16 | endif 17 | 18 | if USE_GLIB 19 | liblocation_api_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 20 | liblocation_api_la_LDFLAGS = -lstdc++ -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared -version-info 1:0:0 21 | liblocation_api_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 22 | else 23 | liblocation_api_la_CFLAGS = $(AM_CFLAGS) 24 | liblocation_api_la_LDFLAGS = -Wl,-z,defs -lpthread -shared -version-info 1:0:0 25 | liblocation_api_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 26 | endif 27 | 28 | liblocation_api_la_LIBADD = -lstdc++ -ldl $(GPSUTILS_LIBS) 29 | 30 | library_include_HEADERS = \ 31 | LocationAPI.h \ 32 | LocationAPIClientBase.h \ 33 | location_interface.h \ 34 | LocationDataTypes.h \ 35 | ILocationAPI.h 36 | 37 | #Create and Install libraries 38 | lib_LTLIBRARIES = liblocation_api.la 39 | 40 | library_includedir = $(pkgincludedir) 41 | 42 | pkgconfigdir = $(libdir)/pkgconfig 43 | pkgconfig_DATA = location-api.pc 44 | EXTRA_DIST = $(pkgconfig_DATA) 45 | -------------------------------------------------------------------------------- /location/client_api_testapp/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | -DDEBUG \ 3 | -I./ \ 4 | $(GPSUTILS_CFLAGS) \ 5 | $(LOCUTILS_CFLAGS) \ 6 | $(LOCCLIENTAPI_CFLAGS) \ 7 | $(LOCINTEGRATIONAPI_CFLAGS) \ 8 | -std=c++11 9 | # HALDAEMON is requird only for msg.h 10 | 11 | ACLOCAL_AMFLAGS = -I m4 12 | AM_CPPFLAGS = -std=c++11 13 | 14 | requiredlibs = \ 15 | $(LOCCLIENTAPI_LIBS) \ 16 | $(LOCINTEGRATIONAPI_LIBS) 17 | 18 | h_sources = 19 | 20 | c_sources = \ 21 | main.cpp 22 | 23 | location_client_api_testapp_SOURCES = \ 24 | $(c_sources) $(h_sources) 25 | 26 | ###################### 27 | # Build location_client_api_testapp 28 | ###################### 29 | 30 | if USE_GLIB 31 | location_client_api_testapp_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 32 | location_client_api_testapp_LDFLAGS = -lstdc++ -g -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared -version-info 1:0:0 33 | location_client_api_testapp_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 34 | else 35 | location_client_api_testapp_CFLAGS = $(AM_CFLAGS) 36 | location_client_api_testapp_LDFLAGS = -lstdc++ -Wl,-z,defs -lpthread -shared -version-info 1:0:0 37 | location_client_api_testapp_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 38 | endif 39 | 40 | location_client_api_testapp_LDADD = $(requiredlibs) -lstdc++ -lc -ldl 41 | 42 | bin_PROGRAMS = location_client_api_testapp 43 | 44 | -------------------------------------------------------------------------------- /setup-makefiles.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Copyright (C) 2016 The CyanogenMod Project 4 | # Copyright (C) 2017-2020 The LineageOS Project 5 | # 6 | # SPDX-License-Identifier: Apache-2.0 7 | # 8 | 9 | set -e 10 | 11 | # Load extract_utils and do some sanity checks 12 | MY_DIR="${BASH_SOURCE%/*}" 13 | if [[ ! -d "${MY_DIR}" ]]; then MY_DIR="${PWD}"; fi 14 | 15 | ANDROID_ROOT="${MY_DIR}/../../.." 16 | 17 | HELPER="${ANDROID_ROOT}/tools/extract-utils/extract_utils.sh" 18 | if [ ! -f "${HELPER}" ]; then 19 | echo "Unable to find helper script at ${HELPER}" 20 | exit 1 21 | fi 22 | source "${HELPER}" 23 | 24 | # Initialize the helper for common 25 | setup_vendor "${DEVICE_COMMON}" "${VENDOR}" "${ANDROID_ROOT}" true 26 | 27 | # Copyright headers and guards 28 | write_headers "foles parker def liber odessa minsk hanoip" 29 | 30 | # The standard common blobs 31 | write_makefiles "${MY_DIR}/proprietary-files.txt" true 32 | 33 | # Finish 34 | write_footers 35 | 36 | if [ -s "${MY_DIR}/../${DEVICE}/proprietary-files.txt" ]; then 37 | # Reinitialize the helper for device 38 | setup_vendor "${DEVICE}" "${VENDOR}" "${ANDROID_ROOT}" false 39 | 40 | # Warning headers and guards 41 | write_headers 42 | 43 | # The standard device blobs 44 | write_makefiles "${MY_DIR}/../${DEVICE}/proprietary-files.txt" true 45 | 46 | # Finish 47 | write_footers 48 | fi 49 | -------------------------------------------------------------------------------- /location/utils/loc_socket/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | -DDEBUG \ 3 | -I src/ \ 4 | -I inc/ \ 5 | $(QMIFW_CFLAGS) \ 6 | $(GPSUTILS_CFLAGS) \ 7 | -fpermissive 8 | 9 | if USE_QSOCKET 10 | AM_CFLAGS += -DUSE_QSOCKET 11 | endif 12 | 13 | ACLOCAL_AMFLAGS = -I m4 14 | AM_CPPFLAGS = -std=c++14 15 | 16 | requiredlibs = \ 17 | $(QMIFW_LIBS) \ 18 | $(GPSUTILS_LIBS) 19 | 20 | c_sources = \ 21 | LocSocket.cpp 22 | 23 | libloc_socket_la_SOURCES = \ 24 | $(c_sources) 25 | 26 | ###################### 27 | # Build loc_socket 28 | ###################### 29 | 30 | if USE_GLIB 31 | libloc_socket_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 32 | libloc_socket_la_LDFLAGS = -lstdc++ -g -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared -version-info 1:0:0 33 | libloc_socket_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 34 | else 35 | libloc_socket_la_CFLAGS = $(AM_CFLAGS) 36 | libloc_socket_la_LDFLAGS = -lstdc++ -Wl,-z,defs -lpthread -shared -version-info 1:0:0 37 | libloc_socket_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 38 | endif 39 | 40 | libloc_socket_la_LIBADD = $(requiredlibs) -lstdc++ 41 | 42 | #Create and Install libraries 43 | library_include_HEADERS = 44 | lib_LTLIBRARIES = libloc_socket.la 45 | 46 | library_includedir = $(pkgincludedir) 47 | pkgconfigdir = $(libdir)/pkgconfig 48 | pkgconfig_DATA = loc-socket.pc 49 | EXTRA_DIST = $(pkgconfig_DATA) 50 | 51 | -------------------------------------------------------------------------------- /overlay-lineage/packages/apps/Snap/res/values/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 16 | 17 | 19 | 20 | 21 | true 22 | 23 | 24 | false 25 | 26 | 27 | false 28 | 29 | 30 | true 31 | 32 | -------------------------------------------------------------------------------- /power-libperfmgr/aidl/android.hardware.power-service.sm6150-libperfmgr.rc: -------------------------------------------------------------------------------- 1 | service vendor.power-hal-aidl /vendor/bin/hw/android.hardware.power-service.sm6150-libperfmgr 2 | class hal 3 | user root 4 | group system input 5 | priority -20 6 | 7 | on late-fs 8 | start vendor.power-hal-aidl 9 | 10 | # Restart powerHAL when framework died 11 | on property:init.svc.zygote=restarting && property:vendor.powerhal.state=* 12 | setprop vendor.powerhal.state "" 13 | setprop vendor.powerhal.audio "" 14 | setprop vendor.powerhal.rendering "" 15 | restart vendor.power-hal-aidl 16 | 17 | # Clean up after b/163539793 resolved 18 | on property:vendor.powerhal.dalvik.vm.dex2oat-threads=* 19 | setprop dalvik.vm.dex2oat-threads ${vendor.powerhal.dalvik.vm.dex2oat-threads} 20 | setprop dalvik.vm.restore-dex2oat-threads ${vendor.powerhal.dalvik.vm.dex2oat-threads} 21 | 22 | on property:vendor.powerhal.dalvik.vm.dex2oat-cpu-set=* 23 | setprop dalvik.vm.dex2oat-cpu-set ${vendor.powerhal.dalvik.vm.dex2oat-cpu-set} 24 | setprop dalvik.vm.restore-dex2oat-cpu-set ${vendor.powerhal.dalvik.vm.dex2oat-cpu-set} 25 | 26 | # Restart powerHAL when debug property set 27 | on property:ro.debuggable=1 && property:vendor.powerhal.config.debug=* 28 | restart vendor.power-hal-aidl 29 | 30 | on property:persist.vendor.powerhal.config.debug=* 31 | setprop vendor.powerhal.config.debug ${persist.vendor.powerhal.config.debug} 32 | 33 | -------------------------------------------------------------------------------- /location/qapi/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | -DDEBUG \ 3 | -I src/ \ 4 | -I inc/ \ 5 | $(GPSUTILS_CFLAGS) \ 6 | $(LOCCLIENTAPI_CFLAGS) \ 7 | -std=c++11 8 | 9 | ACLOCAL_AMFLAGS = -I m4 10 | AM_CPPFLAGS = -std=c++11 11 | 12 | requiredlibs = \ 13 | $(GPSUTILS_LIBS) \ 14 | $(LOCCLIENTAPI_LIBS) 15 | 16 | h_sources = \ 17 | inc/qapi_location.h 18 | 19 | c_sources = \ 20 | src/qapi_location.cpp 21 | 22 | liblocation_qapi_la_SOURCES = \ 23 | $(c_sources) $(h_sources) 24 | 25 | ###################### 26 | # Build location_qapi 27 | ###################### 28 | 29 | if USE_GLIB 30 | liblocation_qapi_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 31 | liblocation_qapi_la_LDFLAGS = -lstdc++ -g -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared -version-info 1:0:0 32 | liblocation_qapi_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 33 | else 34 | liblocation_qapi_la_CFLAGS = $(AM_CFLAGS) 35 | liblocation_qapi_la_LDFLAGS = -lstdc++ -Wl,-z,defs -lpthread -shared -version-info 1:0:0 36 | liblocation_qapi_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 37 | endif 38 | 39 | liblocation_qapi_la_LIBADD = $(requiredlibs) -lstdc++ 40 | 41 | #Create and Install libraries 42 | library_include_HEADERS = $(h_sources) 43 | lib_LTLIBRARIES = liblocation_qapi.la 44 | 45 | library_includedir = $(pkgincludedir) 46 | pkgconfigdir = $(libdir)/pkgconfig 47 | pkgconfig_DATA = location-qapi.pc 48 | EXTRA_DIST = $(pkgconfig_DATA) 49 | -------------------------------------------------------------------------------- /location/ntrip-client-integration-api/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | $(GPSUTILS_CFLAGS) \ 3 | -D__STDC_FORMAT_MACROS \ 4 | -Dstrlcpy=g_strlcpy \ 5 | -Dstrlcat=g_strlcat \ 6 | -std=c++11 7 | 8 | ACLOCAL_AMFLAGS = -I m4 9 | 10 | 11 | c_sources = \ 12 | ntrip-client-integration-api-testlib.cpp 13 | 14 | libntripclient_integration_api_test_la_SOURCES = \ 15 | $(c_sources) 16 | 17 | if USE_GLIB 18 | libntripclient_integration_api_test_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ -include glib.h 19 | libntripclient_integration_api_test_la_LDFLAGS = -lstdc++ -g -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared -version-info 1:0:0 20 | libntripclient_integration_api_test_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ -include glib.h 21 | else 22 | libntripclient_integration_api_test_la_CFLAGS = $(AM_CFLAGS) 23 | libntripclient_integration_api_test_la_LDFLAGS = -Wl,-z,defs -lpthread -shared -version-info 1:0:0 24 | libntripclient_integration_api_test_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 25 | endif 26 | 27 | libntripclient_integration_api_test_la_LIBADD = -ldl -lstdc++ $(GPSUTILS_LIBS) 28 | 29 | #Create and Install libraries 30 | library_include_HEADERS = $(h_sources) 31 | lib_LTLIBRARIES = libntripclient_integration_api_test.la 32 | 33 | library_includedir = $(pkgincludedir) 34 | pkgconfigdir = $(libdir)/pkgconfig 35 | pkgconfig_DATA = ntrip-client-integration-api-testlib.pc 36 | EXTRA_DIST = $(pkgconfig_DATA) -------------------------------------------------------------------------------- /location/location_api_msg_proto/src/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | -I./ \ 3 | -D__STDC_FORMAT_MACROS \ 4 | -Dstrlcpy=g_strlcpy \ 5 | -Dstrlcat=g_strlcat \ 6 | $(GPSUTILS_CFLAGS) \ 7 | -std=c++14 8 | 9 | ACLOCAL_AMFLAGS = -I m4 10 | 11 | requiredlibs = \ 12 | $(GPSUTILS_LIBS) \ 13 | -lprotobuf 14 | 15 | liblocation_api_msg_proto_la_SOURCES = \ 16 | LocationApiDataTypes.pb.cc \ 17 | LocationApiMsg.pb.cc \ 18 | LocationApiMsg.cpp \ 19 | LocationApiPbMsgConv.cpp 20 | 21 | library_include_HEADERS = \ 22 | LocationApiMsg.h \ 23 | LocationApiDataTypes.pb.h \ 24 | LocationApiMsg.pb.h \ 25 | LocationApiPbMsgConv.h 26 | 27 | if USE_GLIB 28 | liblocation_api_msg_proto_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ -include glib.h 29 | liblocation_api_msg_proto_la_LDFLAGS = -lstdc++ -g -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared -version-info 1:0:0 30 | liblocation_api_msg_proto_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ -include glib.h 31 | else 32 | liblocation_api_msg_proto_la_CFLAGS = $(AM_CFLAGS) 33 | liblocation_api_msg_proto_la_LDFLAGS = -Wl,-z,defs -lpthread -shared -version-info 1:0:0 34 | liblocation_api_msg_proto_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 35 | endif 36 | 37 | liblocation_api_msg_proto_la_LIBADD = $(requiredlibs) -ldl -lstdc++ 38 | 39 | library_includedir = $(pkgincludedir) 40 | #Create and Install libraries 41 | lib_LTLIBRARIES = liblocation_api_msg_proto.la 42 | -------------------------------------------------------------------------------- /location/gps_vendor_product.mk: -------------------------------------------------------------------------------- 1 | # vendor opensource packages 2 | ifneq ($(BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE),) 3 | 4 | # Activate the following two lines for regression testing 5 | #GNSS_SANITIZE := address cfi alignment bounds null unreachable integer 6 | #GNSS_SANITIZE_DIAG := address cfi alignment bounds null unreachable integer 7 | 8 | # Add product packages 9 | #add QMI libraries for QMI targets 10 | LOC_BOARD_PLATFORM_LIST += msm8953 11 | LOC_BOARD_PLATFORM_LIST += msm8937 12 | LOC_BOARD_PLATFORM_LIST += msm8998 13 | LOC_BOARD_PLATFORM_LIST += apq8098_latv 14 | LOC_BOARD_PLATFORM_LIST += sdm660 15 | LOC_BOARD_PLATFORM_LIST += sdm845 16 | LOC_BOARD_PLATFORM_LIST += msmpeafowl 17 | LOC_BOARD_PLATFORM_LIST += sdm710 18 | LOC_BOARD_PLATFORM_LIST += qcs605 19 | LOC_BOARD_PLATFORM_LIST += msmnile 20 | LOC_BOARD_PLATFORM_LIST += sdmshrike 21 | LOC_BOARD_PLATFORM_LIST += $(MSMSTEPPE) 22 | LOC_BOARD_PLATFORM_LIST += $(TRINKET) 23 | LOC_BOARD_PLATFORM_LIST += kona 24 | LOC_BOARD_PLATFORM_LIST += lito 25 | LOC_BOARD_PLATFORM_LIST += bengal 26 | LOC_BOARD_PLATFORM_LIST += atoll 27 | LOC_BOARD_PLATFORM_LIST += lahaina 28 | LOC_BOARD_PLATFORM_LIST += holi 29 | 30 | ifneq (,$(filter $(LOC_BOARD_PLATFORM_LIST),$(TARGET_BOARD_PLATFORM))) 31 | 32 | PRODUCT_PACKAGES += libloc_api_v02 33 | PRODUCT_PACKAGES += libgnsspps 34 | PRODUCT_PACKAGES += libsynergy_loc_api 35 | PRODUCT_PACKAGES += izat_remote_api_headers 36 | PRODUCT_PACKAGES += loc_sll_if_headers 37 | 38 | endif #is-board-platform-in-list 39 | 40 | endif#BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE 41 | -------------------------------------------------------------------------------- /gps/geofence/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = -Wundef \ 2 | -Wno-trigraphs \ 3 | -g -O0 \ 4 | -fno-inline \ 5 | -fno-short-enums \ 6 | -fpic \ 7 | ${GPSUTILS_CFLAGS} \ 8 | ${LOCCORE_CFLAGS} \ 9 | $(LOCPLA_CFLAGS) \ 10 | -D__func__=__PRETTY_FUNCTION__ \ 11 | -std=c++1y 12 | 13 | AM_CPPFLAGS = $(AM_CFLAGS) 14 | 15 | ACLOCAL_AMFLAGS = -I m4 16 | 17 | requiredlibs = \ 18 | ${LOCCORE_LIBS} \ 19 | $(GPSUTILS_LIBS) \ 20 | -llog 21 | 22 | h_sources = \ 23 | GeofenceAdapter.h 24 | 25 | c_sources = \ 26 | GeofenceAdapter.cpp \ 27 | location_geofence.cpp 28 | 29 | libgeofencing_la_SOURCES = $(c_sources) 30 | if USE_GLIB 31 | libgeofencing_la_CFLAGS = -DUSE_GLIB @GLIB_CFLAGS@ $(AM_CFLAGS) 32 | libgeofencing_la_CPPFLAGS = -DUSE_GLIB @GLIB_CFLAGS@ $(AM_CFLAGS) $(AM_CPPFLAGS) 33 | libgeofencing_la_LDFLAGS = -lstdc++ -Wl,-z,defs @GLIB_LIBS@ $(requiredlibs) -shared -version-info 1:0:0 34 | libgeofencing_la_LIBDADD = $(requiredlibs) -lstdc++ @GLIB_LIBS@ 35 | else 36 | libgeofencing_la_CFLAGS = $(AM_CFLAGS) 37 | libgeofencing_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 38 | libgeofencing_la_LDFLAGS = -lstdc++ -Wl,-z,defs $(requiredlibs) -shared -version-info 1:0:0 39 | libgeofencing_la_LIBDADD = $(requiredlibs) -lstdc++ 40 | endif 41 | 42 | library_include_HEADERS = $(h_sources) 43 | 44 | library_includedir = $(pkgincludedir) 45 | 46 | lib_LTLIBRARIES = libgeofencing.la 47 | 48 | pkgconfigdir = $(libdir)/pkgconfig 49 | pkgconfig_DATA = location-geofence.pc 50 | EXTRA_DIST = $(pkgconfig_DATA) 51 | -------------------------------------------------------------------------------- /bootctrl/NOTICE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2016, The Linux Foundation. All rights reserved. 2 | 3 | Redistribution and use in source and binary forms, with or without 4 | modification, are permitted provided that the following conditions are 5 | met: 6 | * Redistributions of source code must retain the above copyright 7 | notice, this list of conditions and the following disclaimer. 8 | * Redistributions in binary form must reproduce the above 9 | copyright notice, this list of conditions and the following 10 | disclaimer in the documentation and/or other materials provided 11 | with the distribution. 12 | * Neither the name of The Linux Foundation nor the names of its 13 | contributors may be used to endorse or promote products derived 14 | from this software without specific prior written permission. 15 | 16 | THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 17 | WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 18 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 19 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 20 | BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21 | CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22 | SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 23 | BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 24 | WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 26 | IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | -------------------------------------------------------------------------------- /bootctrl/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2019 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 | filegroup { 18 | name: "bootctrl_hal_src", 19 | srcs: [ 20 | "boot_control.cpp", 21 | ], 22 | } 23 | 24 | cc_defaults { 25 | name: "bootctrl_hal_defaults", 26 | proprietary: true, 27 | recovery_available: true, 28 | header_libs: [ 29 | "libhardware_headers", 30 | "libsystem_headers", 31 | ], 32 | shared_libs: [ 33 | "libcutils", 34 | "liblog", 35 | "libz", 36 | ], 37 | owner: "qti", 38 | relative_install_path: "hw", 39 | cflags: [ 40 | "-Wall", 41 | "-Werror", 42 | ], 43 | srcs: [ 44 | ":bootctrl_hal_src", 45 | ], 46 | 47 | } 48 | 49 | cc_library_shared { 50 | name: "android.hardware.boot@1.1-impl-qti", 51 | stem: "android.hardware.boot@1.0-impl-1.1-qti", 52 | defaults: ["android.hardware.boot@1.1-impl-qti_defaults"], 53 | static_libs: ["libgptutils.motorola_sm6150"], 54 | } 55 | -------------------------------------------------------------------------------- /location/loc_api/loc_api_v02/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | -I. \ 3 | $(LOCPLA_CFLAGS) \ 4 | $(GPSUTILS_CFLAGS) \ 5 | $(LOCCORE_CFLAGS) \ 6 | $(QMIFW_CFLAGS) \ 7 | -fno-short-enums \ 8 | -D__func__=__PRETTY_FUNCTION__ \ 9 | -DTARGET_USES_QCOM_BSP 10 | 11 | libloc_api_v02_la_SOURCES = \ 12 | LocApiV02.cpp \ 13 | loc_api_v02_log.cpp \ 14 | loc_api_v02_client.cpp \ 15 | loc_api_sync_req.cpp \ 16 | location_service_v02.c 17 | 18 | if USE_GLIB 19 | libloc_api_v02_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 20 | libloc_api_v02_la_LDFLAGS = -lstdc++ -Wl,-z,defs -lpthread -lcutils @GLIB_LIBS@ -shared -version-info 1:0:0 21 | libloc_api_v02_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 22 | else 23 | libloc_api_v02_la_CFLAGS = $(AM_CFLAGS) 24 | libloc_api_v02_la_LDFLAGS = -lstdc++ -Wl,-z,defs -lpthread -lcutils -shared -version-info 1:0:0 25 | libloc_api_v02_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 26 | endif 27 | 28 | libloc_api_v02_la_CXXFLAGS = -std=c++0x 29 | libloc_api_v02_la_LIBADD = -lstdc++ -ldl -lutils $(QMIFW_LIBS) $(GPSUTILS_LIBS) $(LOCCORE_LIBS) 30 | 31 | library_include_HEADERS = \ 32 | location_service_v02.h \ 33 | loc_api_v02_log.h \ 34 | loc_api_v02_client.h \ 35 | loc_api_sync_req.h \ 36 | LocApiV02.h \ 37 | loc_util_log.h 38 | 39 | library_includedir = $(pkgincludedir)/loc_api_v02 40 | 41 | #Create and Install libraries 42 | lib_LTLIBRARIES = libloc_api_v02.la 43 | 44 | library_includedir = $(pkgincludedir) 45 | pkgconfigdir = $(libdir)/pkgconfig 46 | pkgconfig_DATA = loc-api-v02.pc 47 | EXTRA_DIST = $(pkgconfig_DATA) 48 | -------------------------------------------------------------------------------- /overlay/packages/services/Telephony/res/values/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 16 | 17 | 21 | 22 | 24 | 25 | 26 | org.codeaurora.ims 27 | 28 | 29 | com.android.service.ims 30 | 31 | -------------------------------------------------------------------------------- /gps/Android.mk: -------------------------------------------------------------------------------- 1 | ifneq ($(BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE),) 2 | 3 | # Set required flags 4 | GNSS_CFLAGS := \ 5 | -Werror \ 6 | -Wno-error=unused-parameter \ 7 | -Wno-error=macro-redefined \ 8 | -Wno-error=reorder \ 9 | -Wno-error=missing-braces \ 10 | -Wno-error=self-assign \ 11 | -Wno-error=enum-conversion \ 12 | -Wno-error=logical-op-parentheses \ 13 | -Wno-error=null-arithmetic \ 14 | -Wno-error=null-conversion \ 15 | -Wno-error=parentheses-equality \ 16 | -Wno-error=undefined-bool-conversion \ 17 | -Wno-error=tautological-compare \ 18 | -Wno-error=switch \ 19 | -Wno-error=date-time 20 | 21 | GNSS_HIDL_VERSION = 2.1 22 | 23 | GNSS_HIDL_LEGACY_MEASURMENTS_TARGET_LIST += msm8937 24 | GNSS_HIDL_LEGACY_MEASURMENTS_TARGET_LIST += msm8953 25 | GNSS_HIDL_LEGACY_MEASURMENTS_TARGET_LIST += msm8998 26 | GNSS_HIDL_LEGACY_MEASURMENTS_TARGET_LIST += apq8098_latv 27 | GNSS_HIDL_LEGACY_MEASURMENTS_TARGET_LIST += sdm710 28 | GNSS_HIDL_LEGACY_MEASURMENTS_TARGET_LIST += qcs605 29 | GNSS_HIDL_LEGACY_MEASURMENTS_TARGET_LIST += sdm845 30 | GNSS_HIDL_LEGACY_MEASURMENTS_TARGET_LIST += sdm660 31 | 32 | ifneq (,$(filter $(GNSS_HIDL_LEGACY_MEASURMENTS_TARGET_LIST),$(TARGET_BOARD_PLATFORM))) 33 | GNSS_HIDL_LEGACY_MEASURMENTS = true 34 | endif 35 | 36 | LOCAL_PATH := $(call my-dir) 37 | include $(call all-makefiles-under,$(LOCAL_PATH)) 38 | 39 | GNSS_SANITIZE := cfi bounds null unreachable integer 40 | # Activate the following two lines for regression testing 41 | #GNSS_SANITIZE += address 42 | #GNSS_SANITIZE_DIAG := $(GNSS_SANITIZE) 43 | 44 | endif # ifneq ($(BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE),) 45 | -------------------------------------------------------------------------------- /gps/gps_vendor_product.mk: -------------------------------------------------------------------------------- 1 | # HAL packages 2 | ifneq ($(BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE),) 3 | 4 | # GPS-HIDL 5 | LOC_BOARD_PLATFORM_LIST += msm8937 6 | LOC_BOARD_PLATFORM_LIST += msm8953 7 | LOC_BOARD_PLATFORM_LIST += msm8998 8 | LOC_BOARD_PLATFORM_LIST += apq8098_latv 9 | LOC_BOARD_PLATFORM_LIST += sdm710 10 | LOC_BOARD_PLATFORM_LIST += qcs605 11 | LOC_BOARD_PLATFORM_LIST += sdm845 12 | LOC_BOARD_PLATFORM_LIST += sdm660 13 | LOC_BOARD_PLATFORM_LIST += msmnile 14 | LOC_BOARD_PLATFORM_LIST += sdmshrike 15 | LOC_BOARD_PLATFORM_LIST += $(MSMSTEPPE) 16 | LOC_BOARD_PLATFORM_LIST += $(TRINKET) 17 | LOC_BOARD_PLATFORM_LIST += kona 18 | LOC_BOARD_PLATFORM_LIST += atoll 19 | LOC_BOARD_PLATFORM_LIST += lito 20 | LOC_BOARD_PLATFORM_LIST += bengal 21 | LOC_BOARD_PLATFORM_LIST += lahaina 22 | LOC_BOARD_PLATFORM_LIST += holi 23 | 24 | # Add product packages 25 | ifneq (,$(filter $(LOC_BOARD_PLATFORM_LIST),$(TARGET_BOARD_PLATFORM))) 26 | 27 | PRODUCT_PACKAGES += gps.conf 28 | PRODUCT_PACKAGES += flp.conf 29 | PRODUCT_PACKAGES += gnss_antenna_info.conf 30 | PRODUCT_PACKAGES += libloc_pla_headers 31 | PRODUCT_PACKAGES += liblocation_api_headers 32 | PRODUCT_PACKAGES += libgps.utils_headers 33 | PRODUCT_PACKAGES += liblocation_api 34 | PRODUCT_PACKAGES += libgps.utils 35 | PRODUCT_PACKAGES += libbatching 36 | PRODUCT_PACKAGES += libgeofencing 37 | PRODUCT_PACKAGES += libloc_core 38 | PRODUCT_PACKAGES += libgnss 39 | 40 | PRODUCT_PACKAGES += android.hardware.gnss@2.1-impl-qti 41 | PRODUCT_PACKAGES += android.hardware.gnss@2.1-service-qti 42 | 43 | endif # ifneq (,$(filter $(LOC_BOARD_PLATFORM_LIST),$(TARGET_BOARD_PLATFORM))) 44 | endif # ifneq ($(BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE),) 45 | -------------------------------------------------------------------------------- /configs/system_ext-privapp-permissions-qti.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 23 | 24 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /rootdir/bin/init.qti.fm.sh: -------------------------------------------------------------------------------- 1 | #!/vendor/bin/sh 2 | # Copyright (c) 2019 Qualcomm Technologies, Inc. 3 | # All Rights Reserved. 4 | # Confidential and Proprietary - Qualcomm Technologies, Inc. 5 | # 6 | # Copyright (c) 2009-2011, 2015, 2017 The Linux Foundation. All rights reserved. 7 | # 8 | 9 | setprop vendor.hw.fm.init 0 10 | 11 | mode=`getprop vendor.hw.fm.mode` 12 | version=199217 13 | 14 | LOG_TAG="qti-fm" 15 | LOG_NAME="${0}:" 16 | 17 | loge () 18 | { 19 | /vendor/bin/log -t $LOG_TAG -p e "$LOG_NAME $@" 20 | } 21 | 22 | logi () 23 | { 24 | /vendor/bin/log -t $LOG_TAG -p i "$LOG_NAME $@" 25 | } 26 | 27 | failed () 28 | { 29 | loge "$1: exit code $2" 30 | exit $2 31 | } 32 | 33 | logi "In FM shell Script" 34 | logi "mode: $mode" 35 | logi "Version : $version" 36 | 37 | #$fm_qsoc_patches 38 | # 39 | case $mode in 40 | "normal") 41 | logi "inserting the radio transport module" 42 | echo 1 > /sys/module/radio_iris_transport/parameters/fmsmd_set 43 | /vendor/bin/fm_qsoc_patches $version 0 44 | ;; 45 | "wa_enable") 46 | /vendor/bin/fm_qsoc_patches $version 1 47 | ;; 48 | "wa_disable") 49 | /vendor/bin/fm_qsoc_patches $version 2 50 | ;; 51 | *) 52 | logi "Shell: Default case" 53 | /vendor/bin/fm_qsoc_patches $version 0 54 | ;; 55 | esac 56 | 57 | exit_code_fm_qsoc_patches=$? 58 | 59 | case $exit_code_fm_qsoc_patches in 60 | 0) 61 | logi "FM QSoC calibration and firmware download succeeded" 62 | ;; 63 | *) 64 | failed "FM QSoC firmware download and/or calibration failed" $exit_code_fm_qsoc_patches 65 | ;; 66 | esac 67 | 68 | setprop vendor.hw.fm.init 1 69 | 70 | exit 0 71 | -------------------------------------------------------------------------------- /gps/etc/Android.bp: -------------------------------------------------------------------------------- 1 | 2 | prebuilt_etc { 3 | 4 | name: "apdr.conf", 5 | vendor: true, 6 | src: "apdr.conf", 7 | } 8 | 9 | prebuilt_etc { 10 | 11 | name: "gps.conf", 12 | vendor: true, 13 | src: "gps.conf", 14 | } 15 | 16 | prebuilt_etc { 17 | 18 | name: "flp.conf", 19 | vendor: true, 20 | src: "flp.conf", 21 | } 22 | 23 | prebuilt_etc { 24 | 25 | name: "izat.conf", 26 | vendor: true, 27 | src: "izat.conf", 28 | } 29 | 30 | prebuilt_etc { 31 | 32 | name: "lowi.conf", 33 | vendor: true, 34 | src: "lowi.conf", 35 | } 36 | 37 | prebuilt_etc { 38 | 39 | name: "sap.conf", 40 | vendor: true, 41 | src: "sap.conf", 42 | } 43 | 44 | prebuilt_etc { 45 | 46 | name: "xtwifi.conf", 47 | vendor: true, 48 | src: "xtwifi.conf", 49 | } 50 | 51 | prebuilt_etc { 52 | 53 | name: "gnss_antenna_info.conf", 54 | vendor: true, 55 | src: "gnss_antenna_info.conf", 56 | } 57 | 58 | prebuilt_etc { 59 | name: "gnss@2.0-base.policy", 60 | vendor: true, 61 | sub_dir: "seccomp_policy", 62 | src: "seccomp_policy/gnss@2.0-base.policy", 63 | } 64 | 65 | prebuilt_etc { 66 | name: "gnss@2.0-xtra-daemon.policy", 67 | vendor: true, 68 | sub_dir: "seccomp_policy", 69 | src: "seccomp_policy/gnss@2.0-xtra-daemon.policy", 70 | } 71 | 72 | prebuilt_etc { 73 | name: "gnss@2.0-xtwifi-client.policy", 74 | vendor: true, 75 | sub_dir: "seccomp_policy", 76 | src: "seccomp_policy/gnss@2.0-xtwifi-client.policy", 77 | } 78 | 79 | prebuilt_etc { 80 | name: "gnss@2.0-xtwifi-inet-agent.policy", 81 | vendor: true, 82 | sub_dir: "seccomp_policy", 83 | src: "seccomp_policy/gnss@2.0-xtwifi-inet-agent.policy", 84 | } 85 | -------------------------------------------------------------------------------- /mot_aids.fs: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (C) 2017 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 | [AID_VENDOR_MOT_ACCY] 17 | value: 5000 18 | 19 | [AID_VENDOR_MOT_PWRIC] 20 | value: 5001 21 | 22 | [AID_VENDOR_MOT_USB] 23 | value: 5002 24 | 25 | [AID_VENDOR_MOT_DRM] 26 | value: 5003 27 | 28 | [AID_VENDOR_MOT_TCMD] 29 | value: 5004 30 | 31 | [AID_VENDOR_MOT_SEC_RTC] 32 | value: 5005 33 | 34 | [AID_VENDOR_MOT_TOMBSTONE] 35 | value: 5006 36 | 37 | [AID_VENDOR_MOT_TPAPI] 38 | value: 5007 39 | 40 | [AID_VENDOR_MOT_SECCLKD] 41 | value: 5008 42 | 43 | [AID_VENDOR_MOT_WHISPER] 44 | value: 5009 45 | 46 | [AID_VENDOR_MOT_CAIF] 47 | value: 5010 48 | 49 | [AID_VENDOR_MOT_DLNA] 50 | value: 5011 51 | 52 | [AID_VENDOR_MOT_ATVC] 53 | value: 5012 54 | 55 | [AID_VENDOR_MOT_DBVC] 56 | value: 5014 57 | 58 | [AID_VENDOR_FINGERP] 59 | value: 5015 60 | 61 | [AID_VENDOR_MOT_ESDFS] 62 | value: 5016 63 | 64 | [AID_VENDOR_POWER] 65 | value: 5017 66 | 67 | [AID_VENDOR_ITSON] 68 | value: 5018 69 | 70 | [AID_VENDOR_MOT_DTV] 71 | value: 5019 72 | 73 | [AID_VENDOR_MOT_MOD] 74 | value: 5020 75 | 76 | [AID_VENDOR_MOT_SHARED] 77 | value: 5323 78 | 79 | [AID_VENDOR_MOT_COMMON] 80 | value: 5341 81 | -------------------------------------------------------------------------------- /power-libperfmgr/aidl/PowerExt.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2020 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 | #pragma once 18 | 19 | #include 20 | #include 21 | #include 22 | 23 | #include 24 | #include 25 | 26 | namespace aidl { 27 | namespace google { 28 | namespace hardware { 29 | namespace power { 30 | namespace impl { 31 | namespace pixel { 32 | 33 | class PowerExt : public ::aidl::google::hardware::power::extension::pixel::BnPowerExt { 34 | public: 35 | PowerExt() {} 36 | ndk::ScopedAStatus setMode(const std::string &mode, bool enabled) override; 37 | ndk::ScopedAStatus isModeSupported(const std::string &mode, bool *_aidl_return) override; 38 | ndk::ScopedAStatus setBoost(const std::string &boost, int32_t durationMs) override; 39 | ndk::ScopedAStatus isBoostSupported(const std::string &boost, bool *_aidl_return) override; 40 | 41 | private: 42 | }; 43 | 44 | } // namespace pixel 45 | } // namespace impl 46 | } // namespace power 47 | } // namespace hardware 48 | } // namespace google 49 | } // namespace aidl 50 | -------------------------------------------------------------------------------- /configs/msm_irqbalance.conf: -------------------------------------------------------------------------------- 1 | # Copyright (c) 2017, The Linux Foundation. All rights reserved. 2 | # 3 | # Redistribution and use in source and binary forms, with or without 4 | # modification, are permitted provided that the following conditions are 5 | # met: 6 | # * Redistributions of source code must retain the above copyright 7 | # notice, this list of conditions and the following disclaimer. 8 | # * Redistributions in binary form must reproduce the above 9 | # copyright notice, this list of conditions and the following 10 | # disclaimer in the documentation and/or other materials provided 11 | # with the distribution. 12 | # * Neither the name of The Linux Foundation nor the names of its 13 | # contributors may be used to endorse or promote products derived 14 | # from this software without specific prior written permission. 15 | # 16 | # THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 17 | # WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 18 | # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 19 | # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 20 | # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21 | # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22 | # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 23 | # BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 24 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | # OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 26 | # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | # 28 | # 29 | 30 | PRIO=1,1,1,1,0,0,0,0 31 | #arch_timer, arm-pmu, arch_mem_timer, msm_drm, kgsl-3d0 32 | IGNORED_IRQ=19,21,38,115,332 33 | -------------------------------------------------------------------------------- /location/location_hal_daemon/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | -DDEBUG \ 3 | -I./ \ 4 | $(LOCCORE_CFLAGS) \ 5 | $(GPSUTILS_CFLAGS) \ 6 | $(LOCAPIMSGPROTO_CFLAGS) \ 7 | -std=c++11 8 | 9 | if USE_SYSTEMD 10 | AM_CFLAGS += -DINIT_SYSTEM_SYSTEMD 11 | else 12 | AM_CFLAGS += -DINIT_SYSTEM_SYSV 13 | endif 14 | 15 | if USE_FEATURE_AUTOMOTIVE 16 | AM_CFLAGS += -DFEATURE_AUTOMOTIVE 17 | endif 18 | 19 | requiredlibs = \ 20 | $(LOCATIONAPI_LIBS) \ 21 | $(GPSUTILS_LIBS) \ 22 | $(LOCAPIMSGPROTO_LIBS) \ 23 | -lprotobuf 24 | 25 | h_sources = \ 26 | LocHalDaemonClientHandler.h \ 27 | LocationApiService.h 28 | 29 | c_sources = \ 30 | LocHalDaemonClientHandler.cpp \ 31 | LocationApiService.cpp \ 32 | main.cpp 33 | 34 | if POWERMANAGER_ENABLED 35 | AM_CFLAGS += $(PM_CFLAGS) -DPOWERMANAGER_ENABLED 36 | c_sources += PowerEvtHandler.cpp 37 | requiredlibs += $(PM_LIBS) 38 | endif 39 | 40 | location_hal_daemon_SOURCES = \ 41 | $(c_sources) $(h_sources) 42 | 43 | ###################### 44 | # Build location_hal_daemon 45 | ###################### 46 | 47 | if USE_GLIB 48 | location_hal_daemon_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 49 | location_hal_daemon_LDFLAGS = -lstdc++ -g -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared 50 | location_hal_daemon_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 51 | else 52 | location_hal_daemon_CFLAGS = $(AM_CFLAGS) 53 | location_hal_daemon_LDFLAGS = -Wl,-z,defs -lpthread -shared 54 | location_hal_daemon_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 55 | endif 56 | 57 | location_hal_daemon_LDADD = $(requiredlibs) -lcutils -ldl 58 | 59 | bin_PROGRAMS = location_hal_daemon 60 | 61 | library_include_HEADERS = $(h_sources) 62 | library_includedir = $(pkgincludedir) 63 | 64 | pkgconfigdir = $(libdir)/pkgconfig 65 | pkgconfig_DATA = location-hal-daemon.pc 66 | EXTRA_DIST = $(pkgconfig_DATA) 67 | 68 | -------------------------------------------------------------------------------- /rootdir/bin/init.mdm.sh: -------------------------------------------------------------------------------- 1 | #! /vendor/bin/sh 2 | 3 | # Copyright (c) 2013, The Linux Foundation. All rights reserved. 4 | # 5 | # Redistribution and use in source and binary forms, with or without 6 | # modification, are permitted provided that the following conditions are met: 7 | # * Redistributions of source code must retain the above copyright 8 | # notice, this list of conditions and the following disclaimer. 9 | # * Redistributions in binary form must reproduce the above copyright 10 | # notice, this list of conditions and the following disclaimer in the 11 | # documentation and/or other materials provided with the distribution. 12 | # * Neither the name of Linux Foundation nor 13 | # the names of its contributors may be used to endorse or promote 14 | # products derived from this software without specific prior written 15 | # permission. 16 | # 17 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 18 | # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19 | # IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 20 | # NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR 21 | # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 22 | # EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 23 | # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 24 | # OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 25 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR 26 | # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 27 | # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 | # 29 | 30 | baseband=`getprop ro.baseband` 31 | if [ "$baseband" = "mdm" ] || [ "$baseband" = "mdm2" ]; then 32 | start vendor.mdm_helper 33 | fi 34 | 35 | -------------------------------------------------------------------------------- /rootdir/bin/init.qcom.efs.sync.sh: -------------------------------------------------------------------------------- 1 | #! /vendor/bin/sh 2 | 3 | # Copyright (c) 2012, The Linux Foundation. All rights reserved. 4 | # 5 | # Redistribution and use in source and binary forms, with or without 6 | # modification, are permitted provided that the following conditions are 7 | # met: 8 | # * Redistributions of source code must retain the above copyright 9 | # notice, this list of conditions and the following disclaimer. 10 | # * Redistributions in binary form must reproduce the above 11 | # copyright notice, this list of conditions and the following 12 | # disclaimer in the documentation and/or other materials provided 13 | # with the distribution. 14 | # * Neither the name of The Linux Foundation nor the names of its 15 | # contributors may be used to endorse or promote products derived 16 | # from this software without specific prior written permission. 17 | # 18 | # THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 19 | # WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 20 | # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 21 | # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 22 | # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 23 | # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 24 | # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 25 | # BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 26 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 27 | # OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 28 | # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | # 30 | # 31 | 32 | PATH=/system/bin:$PATH 33 | export PATH 34 | cat /sys/devices/platform/rs300000a7.65536/force_sync 35 | cat /sys/devices/platform/rs300100a7.65536/force_sync 36 | -------------------------------------------------------------------------------- /location/client_api/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | -DDEBUG \ 3 | -I src/ \ 4 | -I inc/ \ 5 | $(GPSUTILS_CFLAGS) \ 6 | $(LOCAPIMSGPROTO_CFLAGS) \ 7 | -std=c++11 8 | 9 | ACLOCAL_AMFLAGS = -I m4 10 | AM_CPPFLAGS = -std=c++11 11 | 12 | requiredlibs = \ 13 | $(GPSUTILS_LIBS) \ 14 | $(LOCAPIMSGPROTO_LIBS) \ 15 | -lprotobuf 16 | 17 | h_sources = \ 18 | src/LocationClientApiImpl.h \ 19 | src/LCAReportLoggerUtil.h \ 20 | inc/LocationClientApi.h 21 | 22 | c_sources = \ 23 | src/LocationClientApiImpl.cpp \ 24 | src/LocationClientApi.cpp \ 25 | src/LCAReportLoggerUtil.cpp 26 | 27 | liblocation_client_api_la_SOURCES = \ 28 | $(c_sources) $(h_sources) 29 | liblocation_client_api_la_h_sources = $(h_sources) 30 | 31 | ###################### 32 | # Build location_client_api 33 | ###################### 34 | 35 | if USE_EXTERNAL_AP 36 | AM_CFLAGS += $(LOCSOCKET_CFLAGS) -DFEATURE_EXTERNAL_AP 37 | requiredlibs += $(LOCSOCKET_LIBS) 38 | endif 39 | 40 | if USE_GLIB 41 | liblocation_client_api_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 42 | liblocation_client_api_la_LDFLAGS = -lstdc++ -g -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared -version-info 1:0:0 43 | liblocation_client_api_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 44 | else 45 | liblocation_client_api_la_CFLAGS = $(AM_CFLAGS) 46 | liblocation_client_api_la_LDFLAGS = -lstdc++ -Wl,-z,defs -lpthread -shared -version-info 1:0:0 47 | liblocation_client_api_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 48 | endif 49 | 50 | liblocation_client_api_la_LIBADD = $(requiredlibs) -lstdc++ -ldl 51 | 52 | #Create and Install libraries 53 | library_include_HEADERS = $(h_sources) 54 | lib_LTLIBRARIES = liblocation_client_api.la 55 | 56 | library_includedir = $(pkgincludedir) 57 | pkgconfigdir = $(libdir)/pkgconfig 58 | pkgconfig_DATA = location-client-api.pc 59 | EXTRA_DIST = $(pkgconfig_DATA) 60 | -------------------------------------------------------------------------------- /gps/utils/LocLoggerBase.h: -------------------------------------------------------------------------------- 1 | /* Copyright (c) 2020 The Linux Foundation. All rights reserved. 2 | * 3 | * Redistribution and use in source and binary forms, with or without 4 | * modification, are permitted provided that the following conditions are 5 | * met: 6 | * * Redistributions of source code must retain the above copyright 7 | * notice, this list of conditions and the following disclaimer. 8 | * * Redistributions in binary form must reproduce the above 9 | * copyright notice, this list of conditions and the following 10 | * disclaimer in the documentation and/or other materials provided 11 | * with the distribution. 12 | * * Neither the name of The Linux Foundation, nor the names of its 13 | * contributors may be used to endorse or promote products derived 14 | * from this software without specific prior written permission. 15 | * 16 | * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 17 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 18 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 19 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 20 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 23 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 24 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 26 | * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | * 28 | */ 29 | #ifndef LOC_LOGGER_BASE_H 30 | #define LOC_LOGGER_BASE_H 31 | 32 | namespace loc_util { 33 | class LocLoggerBase { 34 | public: 35 | virtual void log() {} 36 | }; 37 | } 38 | 39 | #endif 40 | -------------------------------------------------------------------------------- /location/integration_api/Makefile.am: -------------------------------------------------------------------------------- 1 | AM_CFLAGS = \ 2 | -DDEBUG \ 3 | -I src/ \ 4 | -I inc/ \ 5 | $(GPSUTILS_CFLAGS) \ 6 | $(LOCAPIMSGPROTO_CFLAGS) \ 7 | -std=c++11 8 | 9 | ACLOCAL_AMFLAGS = -I m4 10 | AM_CPPFLAGS = -std=c++11 11 | 12 | requiredlibs = \ 13 | $(GPSUTILS_LIBS) \ 14 | $(LOCAPIMSGPROTO_LIBS) \ 15 | -lprotobuf 16 | 17 | h_sources = \ 18 | src/LocationIntegrationApiImpl.h \ 19 | inc/LocationIntegrationApi.h 20 | 21 | c_sources = \ 22 | src/LocationIntegrationApiImpl.cpp \ 23 | src/LocationIntegrationApi.cpp 24 | 25 | liblocation_integration_api_la_SOURCES = \ 26 | $(c_sources) $(h_sources) 27 | liblocation_integration_api_la_h_sources = $(h_sources) 28 | 29 | ###################### 30 | # Build location_integration_api 31 | ###################### 32 | 33 | if USE_EXTERNAL_AP 34 | AM_CFLAGS += $(LOCSOCKET_CFLAGS) -DFEATURE_EXTERNAL_AP 35 | requiredlibs += $(LOCSOCKET_LIBS) 36 | endif 37 | 38 | if USE_GLIB 39 | liblocation_integration_api_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 40 | liblocation_integration_api_la_LDFLAGS = -lstdc++ -g -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared -version-info 1:0:0 41 | liblocation_integration_api_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 42 | else 43 | liblocation_integration_api_la_CFLAGS = $(AM_CFLAGS) 44 | liblocation_integration_api_la_LDFLAGS = -lstdc++ -Wl,-z,defs -lpthread -shared -version-info 1:0:0 45 | liblocation_integration_api_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 46 | endif 47 | 48 | liblocation_integration_api_la_LIBADD = $(requiredlibs) -lstdc++ -ldl 49 | 50 | #Create and Install libraries 51 | library_include_HEADERS = $(h_sources) 52 | lib_LTLIBRARIES = liblocation_integration_api.la 53 | 54 | library_includedir = $(pkgincludedir) 55 | pkgconfigdir = $(libdir)/pkgconfig 56 | pkgconfig_DATA = location-integration-api.pc 57 | EXTRA_DIST = $(pkgconfig_DATA) 58 | -------------------------------------------------------------------------------- /overlay/frameworks/base/core/res/res/values-mcc454-mnc03/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 29 | 30 | 31 | 32 | 33 | true 34 | 35 | -------------------------------------------------------------------------------- /overlay/frameworks/base/core/res/res/values-mcc454-mnc04/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 29 | 30 | 31 | 32 | 33 | true 34 | 35 | -------------------------------------------------------------------------------- /overlay/frameworks/base/core/res/res/values-mcc455-mnc02/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 29 | 30 | 31 | 32 | 33 | true 34 | 35 | -------------------------------------------------------------------------------- /overlay/frameworks/base/core/res/res/values-mcc455-mnc07/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 29 | 30 | 31 | 32 | 33 | true 34 | 35 | -------------------------------------------------------------------------------- /gps/android/1.0/android.hardware.gnss@1.0-service-qti.xml: -------------------------------------------------------------------------------- 1 | 28 | 29 | 30 | android.hardware.gnss 31 | hwbinder 32 | @1.0::IGnss/default 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /gps/android/1.1/android.hardware.gnss@1.1-service-qti.xml: -------------------------------------------------------------------------------- 1 | 28 | 29 | 30 | android.hardware.gnss 31 | hwbinder 32 | @1.1::IGnss/default 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /rootdir/bin/init.crda.sh: -------------------------------------------------------------------------------- 1 | #! /vendor/bin/sh 2 | 3 | # Copyright (c) 2012, The Linux Foundation. All rights reserved. 4 | # 5 | # Redistribution and use in source and binary forms, with or without 6 | # modification, are permitted provided that the following conditions are met: 7 | # * Redistributions of source code must retain the above copyright 8 | # notice, this list of conditions and the following disclaimer. 9 | # * Redistributions in binary form must reproduce the above copyright 10 | # notice, this list of conditions and the following disclaimer in the 11 | # documentation and/or other materials provided with the distribution. 12 | # * Neither the name of The Linux Foundation nor 13 | # the names of its contributors may be used to endorse or promote 14 | # products derived from this software without specific prior written 15 | # permission. 16 | # 17 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 18 | # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19 | # IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 20 | # NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR 21 | # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 22 | # EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 23 | # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 24 | # OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 25 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR 26 | # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 27 | # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 | # 29 | 30 | country=`getprop wlan.crda.country` 31 | # crda takes input in COUNTRY environment variable 32 | if [ $country != "" ] 33 | then 34 | COUNTRY="$country" /system/bin/crda 35 | fi 36 | -------------------------------------------------------------------------------- /rootdir/bin/init.qcom.sensors.sh: -------------------------------------------------------------------------------- 1 | #!/vendor/bin/sh 2 | # Copyright (c) 2020 The Linux Foundation. All rights reserved. 3 | # 4 | # Redistribution and use in source and binary forms, with or without 5 | # modification, are permitted provided that the following conditions are met: 6 | # * Redistributions of source code must retain the above copyright 7 | # notice, this list of conditions and the following disclaimer. 8 | # * Redistributions in binary form must reproduce the above copyright 9 | # notice, this list of conditions and the following disclaimer in the 10 | # documentation and/or other materials provided with the distribution. 11 | # * Neither the name of The Linux Foundation nor 12 | # the names of its contributors may be used to endorse or promote 13 | # products derived from this software without specific prior written 14 | # permission. 15 | # 16 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 17 | # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 18 | # IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 19 | # NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR 20 | # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 21 | # EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 22 | # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 23 | # OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 24 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR 25 | # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 26 | # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | # 28 | 29 | # 30 | # Function to start sensors for SSC enabled platforms 31 | # 32 | cp /vendor/etc/sensors/scripts/* /data/vendor/sensors/scripts/ 33 | chmod a+rw /data/vendor/sensors/scripts/* 34 | -------------------------------------------------------------------------------- /rootdir/etc/init.recovery.qcom.rc: -------------------------------------------------------------------------------- 1 | # Copyright (c) 2017-2018, The Linux Foundation. All rights reserved. 2 | # 3 | # Redistribution and use in source and binary forms, with or without 4 | # modification, are permitted provided that the following conditions are met: 5 | # * Redistributions of source code must retain the above copyright 6 | # notice, this list of conditions and the following disclaimer. 7 | # * Redistributions in binary form must reproduce the above copyright 8 | # notice, this list of conditions and the following disclaimer in the 9 | # documentation and/or other materials provided with the distribution. 10 | # * Neither the name of The Linux Foundation nor 11 | # the names of its contributors may be used to endorse or promote 12 | # products derived from this software without specific prior written 13 | # permission. 14 | # 15 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 16 | # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 17 | # IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 18 | # NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR 19 | # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 20 | # EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 21 | # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 22 | # OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 23 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR 24 | # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 25 | # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 26 | # 27 | 28 | on init 29 | setprop sys.usb.configfs 1 30 | 31 | on fs 32 | wait /dev/block/platform/soc/${ro.boot.bootdevice} 33 | symlink /dev/block/platform/soc/${ro.boot.bootdevice} /dev/block/bootdevice 34 | -------------------------------------------------------------------------------- /gps/android/utils/battery_listener.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019, The Linux Foundation. All rights reserved. 3 | * 4 | * Redistribution and use in source and binary forms, with or without 5 | * modification, are permitted provided that the following conditions are 6 | * met: 7 | * * Redistributions of source code must retain the above copyright 8 | * notice, this list of conditions and the following disclaimer. 9 | * * Redistributions in binary form must reproduce the above 10 | * copyright notice, this list of conditions and the following 11 | * disclaimer in the documentation and/or other materials provided 12 | * with the distribution. 13 | * * Neither the name of The Linux Foundation nor the names of its 14 | * contributors may be used to endorse or promote products derived 15 | * from this software without specific prior written permission. 16 | * 17 | * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 18 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 19 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 20 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 21 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 22 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 23 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 24 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 25 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 26 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 27 | * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 | */ 29 | typedef void (* battery_status_change_fn_t)(bool); 30 | void loc_extn_battery_properties_listener_init(battery_status_change_fn_t fn); 31 | void loc_extn_battery_properties_listener_deinit(); 32 | bool loc_extn_battery_properties_is_charging(); 33 | -------------------------------------------------------------------------------- /gps/android/1.0/GnssDebug.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2016 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 | #ifndef ANDROID_HARDWARE_GNSS_V1_0_GNSSDEBUG_H 18 | #define ANDROID_HARDWARE_GNSS_V1_0_GNSSDEBUG_H 19 | 20 | 21 | #include 22 | #include 23 | 24 | namespace android { 25 | namespace hardware { 26 | namespace gnss { 27 | namespace V1_0 { 28 | namespace implementation { 29 | 30 | using ::android::hardware::gnss::V1_0::IGnssDebug; 31 | using ::android::hardware::Return; 32 | using ::android::hardware::Void; 33 | using ::android::hardware::hidl_vec; 34 | using ::android::hardware::hidl_string; 35 | using ::android::sp; 36 | 37 | /* Interface for GNSS Debug support. */ 38 | struct Gnss; 39 | struct GnssDebug : public IGnssDebug { 40 | GnssDebug(Gnss* gnss); 41 | ~GnssDebug() {}; 42 | 43 | /* 44 | * Methods from ::android::hardware::gnss::V1_0::IGnssDebug follow. 45 | * These declarations were generated from IGnssDebug.hal. 46 | */ 47 | Return getDebugData(getDebugData_cb _hidl_cb) override; 48 | 49 | private: 50 | Gnss* mGnss = nullptr; 51 | }; 52 | 53 | } // namespace implementation 54 | } // namespace V1_0 55 | } // namespace gnss 56 | } // namespace hardware 57 | } // namespace android 58 | 59 | #endif // ANDROID_HARDWARE_GNSS_V1_0_GNSSDEBUG_H 60 | -------------------------------------------------------------------------------- /gps/android/1.1/GnssDebug.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2016 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 | #ifndef ANDROID_HARDWARE_GNSS_V1_1_GNSSDEBUG_H 18 | #define ANDROID_HARDWARE_GNSS_V1_1_GNSSDEBUG_H 19 | 20 | 21 | #include 22 | #include 23 | 24 | namespace android { 25 | namespace hardware { 26 | namespace gnss { 27 | namespace V1_1 { 28 | namespace implementation { 29 | 30 | using ::android::hardware::gnss::V1_0::IGnssDebug; 31 | using ::android::hardware::Return; 32 | using ::android::hardware::Void; 33 | using ::android::hardware::hidl_vec; 34 | using ::android::hardware::hidl_string; 35 | using ::android::sp; 36 | 37 | /* Interface for GNSS Debug support. */ 38 | struct Gnss; 39 | struct GnssDebug : public IGnssDebug { 40 | GnssDebug(Gnss* gnss); 41 | ~GnssDebug() {}; 42 | 43 | /* 44 | * Methods from ::android::hardware::gnss::V1_0::IGnssDebug follow. 45 | * These declarations were generated from IGnssDebug.hal. 46 | */ 47 | Return getDebugData(getDebugData_cb _hidl_cb) override; 48 | 49 | private: 50 | Gnss* mGnss = nullptr; 51 | }; 52 | 53 | } // namespace implementation 54 | } // namespace V1_1 55 | } // namespace gnss 56 | } // namespace hardware 57 | } // namespace android 58 | 59 | #endif // ANDROID_HARDWARE_GNSS_V1_1_GNSSDEBUG_H 60 | -------------------------------------------------------------------------------- /gps/etc/seccomp_policy/gnss@2.0-xtwifi-inet-agent.policy: -------------------------------------------------------------------------------- 1 | 2 | #******************************************************************************* 3 | # Copyright (c) 2020 The Linux Foundation. All rights reserved. 4 | # 5 | # Redistribution and use in source and binary forms, with or without 6 | # modification, are permitted provided that the following conditions are 7 | # met: 8 | # * Redistributions of source code must retain the above copyright 9 | # notice, this list of conditions and the following disclaimer. 10 | # * Redistributions in binary form must reproduce the above 11 | # copyright notice, this list of conditions and the following 12 | # disclaimer in the documentation and/or other materials provided 13 | # with the distribution. 14 | # * Neither the name of The Linux Foundation, nor the names of its 15 | # contributors may be used to endorse or promote products derived 16 | # from this software without specific prior written permission. 17 | # 18 | # THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 19 | # WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 20 | # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 21 | # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 22 | # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 23 | # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 24 | # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 25 | # BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 26 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 27 | # OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 28 | # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | # 30 | #****************************************************************************** 31 | 32 | unlinkat: 1 33 | sched_getaffinity: 1 34 | -------------------------------------------------------------------------------- /gps/android/2.0/android.hardware.gnss@2.0-service-qti.xml: -------------------------------------------------------------------------------- 1 | 28 | 29 | 30 | android.hardware.gnss 31 | hwbinder 32 | @1.1::IGnss/default 33 | @2.0::IGnss/default 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /gps/android/2.1/android.hardware.gnss@2.1-service-qti.xml: -------------------------------------------------------------------------------- 1 | 28 | 29 | 30 | android.hardware.gnss 31 | hwbinder 32 | @1.1::IGnss/default 33 | @2.1::IGnss/default 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /configs/qti_whitelist_system_ext.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 32 | 33 | 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /power-libperfmgr/Android.bp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2018 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 | package { 17 | default_applicable_licenses: ["Android-Apache-2.0"], 18 | } 19 | 20 | cc_library { 21 | name: "libdisppower", 22 | proprietary: true, 23 | srcs: [ 24 | "disp-power/InteractionHandler.cpp", 25 | ], 26 | shared_libs: [ 27 | "libbase", 28 | "libcutils", 29 | "liblog", 30 | "libperfmgr", 31 | "libutils", 32 | ], 33 | } 34 | 35 | cc_binary { 36 | name: "android.hardware.power-service.sm6150-libperfmgr", 37 | relative_install_path: "hw", 38 | init_rc: ["aidl/android.hardware.power-service.sm6150-libperfmgr.rc"], 39 | vintf_fragments: ["aidl/android.hardware.power-service.sm6150.xml"], 40 | vendor: true, 41 | shared_libs: [ 42 | "android.hardware.power-V2-ndk", 43 | "libbase", 44 | "libcutils", 45 | "liblog", 46 | "libutils", 47 | "libbinder_ndk", 48 | "libdisppower", 49 | "libperfmgr", 50 | "libprocessgroup", 51 | "pixel-power-ext-V1-ndk", 52 | ], 53 | srcs: [ 54 | "aidl/service.cpp", 55 | "aidl/Power.cpp", 56 | "aidl/PowerExt.cpp", 57 | "aidl/PowerHintSession.cpp", 58 | "aidl/PowerSessionManager.cpp", 59 | ], 60 | header_libs: [ 61 | "libhardware_headers", 62 | "generated_kernel_headers", 63 | ], 64 | } 65 | -------------------------------------------------------------------------------- /location/integration_api/location-integration-api.pc.in: -------------------------------------------------------------------------------- 1 | /* Copyright (c) 2019 The Linux Foundation. All rights reserved. 2 | * 3 | * Redistribution and use in source and binary forms, with or without 4 | * modification, are permitted provided that the following conditions are 5 | * met: 6 | * * Redistributions of source code must retain the above copyright 7 | * notice, this list of conditions and the following disclaimer. 8 | * * Redistributions in binary form must reproduce the above 9 | * copyright notice, this list of conditions and the following 10 | * disclaimer in the documentation and/or other materials provided 11 | * with the distribution. 12 | * * Neither the name of The Linux Foundation nor the names of its 13 | * contributors may be used to endorse or promote products derived 14 | * from this software without specific prior written permission. 15 | * 16 | * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 17 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 18 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 19 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 20 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 23 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 24 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 26 | * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | */ 28 | 29 | prefix=@prefix@ 30 | exec_prefix=@exec_prefix@ 31 | libdir=@libdir@ 32 | includedir=@includedir@ 33 | 34 | Name: location-integration-api 35 | Description: location integration api library 36 | Version: @VERSION@ 37 | Libs: -L${libdir} -llocation_integration_api 38 | Cflags: -I${includedir} -I${includedir}/location-integration-api -------------------------------------------------------------------------------- /power-libperfmgr/disp-power/InteractionHandler.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2018 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 | #pragma once 18 | 19 | #include 20 | #include 21 | #include 22 | #include 23 | #include 24 | 25 | namespace aidl { 26 | namespace google { 27 | namespace hardware { 28 | namespace power { 29 | namespace impl { 30 | namespace pixel { 31 | 32 | enum InteractionState { 33 | INTERACTION_STATE_UNINITIALIZED, 34 | INTERACTION_STATE_IDLE, 35 | INTERACTION_STATE_INTERACTION, 36 | INTERACTION_STATE_WAITING, 37 | }; 38 | 39 | class InteractionHandler { 40 | public: 41 | InteractionHandler(); 42 | ~InteractionHandler(); 43 | bool Init(); 44 | void Exit(); 45 | void Acquire(int32_t duration); 46 | 47 | private: 48 | void Release(); 49 | void WaitForIdle(int32_t wait_ms, int32_t timeout_ms); 50 | void AbortWaitLocked(); 51 | void Routine(); 52 | 53 | void PerfLock(); 54 | void PerfRel(); 55 | 56 | enum InteractionState mState; 57 | int mIdleFd; 58 | int mEventFd; 59 | int32_t mDurationMs; 60 | struct timespec mLastTimespec; 61 | std::unique_ptr mThread; 62 | std::mutex mLock; 63 | std::condition_variable mCond; 64 | }; 65 | 66 | } // namespace pixel 67 | } // namespace impl 68 | } // namespace power 69 | } // namespace hardware 70 | } // namespace google 71 | } // namespace aidl 72 | -------------------------------------------------------------------------------- /location/location_api_msg_proto/location-api-msg-proto.pc.in: -------------------------------------------------------------------------------- 1 | /* Copyright (c) 2020 The Linux Foundation. All rights reserved. 2 | * 3 | * Redistribution and use in source and binary forms, with or without 4 | * modification, are permitted provided that the following conditions are 5 | * met: 6 | * * Redistributions of source code must retain the above copyright 7 | * notice, this list of conditions and the following disclaimer. 8 | * * Redistributions in binary form must reproduce the above 9 | * copyright notice, this list of conditions and the following 10 | * disclaimer in the documentation and/or other materials provided 11 | * with the distribution. 12 | * * Neither the name of The Linux Foundation nor the names of its 13 | * contributors may be used to endorse or promote products derived 14 | * from this software without specific prior written permission. 15 | * 16 | * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 17 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 18 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 19 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 20 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 23 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 24 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 26 | * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | */ 28 | 29 | prefix=@prefix@ 30 | exec_prefix=@exec_prefix@ 31 | libdir=@libdir@ 32 | includedir=@includedir@ 33 | 34 | Name: location-api-msg-proto 35 | Description: location api msg protobuf library 36 | Version: @VERSION@ 37 | Libs: -L${libdir} -llocation_api_msg_proto 38 | Cflags: -I${includedir} -I${includedir}/location-api-msg-proto 39 | -------------------------------------------------------------------------------- /location/ntrip-client-integration-api/configure.ac: -------------------------------------------------------------------------------- 1 | # configure.ac -- Autoconf script for ntrip-client 2 | # 3 | # Process this file with autoconf to produce a configure script 4 | 5 | # Requires autoconf tool later than 2.61 6 | AC_PREREQ(2.61) 7 | # Initialize the ntrip client package version 1.0.0 8 | AC_INIT([ntrip-client-integration-api-testlib],1.0.0) 9 | # Does not strictly follow GNU Coding standards 10 | AM_INIT_AUTOMAKE([foreign subdir-objects]) 11 | # Disables auto rebuilding of configure, Makefile.ins 12 | AM_MAINTAINER_MODE 13 | # Verifies the --srcdir is correct by checking for the path 14 | AC_CONFIG_SRCDIR([Makefile.am]) 15 | # defines some macros variable to be included by source 16 | AC_CONFIG_HEADERS([config.h]) 17 | AC_CONFIG_MACRO_DIR([m4]) 18 | 19 | # Checks for programs. 20 | AC_PROG_LIBTOOL 21 | AC_PROG_CXX 22 | AC_PROG_CC 23 | AM_PROG_CC_C_O 24 | AC_PROG_AWK 25 | AC_PROG_CPP 26 | AC_PROG_INSTALL 27 | AC_PROG_LN_S 28 | AC_PROG_MAKE_SET 29 | PKG_PROG_PKG_CONFIG 30 | 31 | # Checks for libraries. 32 | PKG_CHECK_MODULES([GPSUTILS], [gps-utils]) 33 | AC_SUBST([GPSUTILS_CFLAGS]) 34 | AC_SUBST([GPSUTILS_LIBS]) 35 | 36 | AC_ARG_WITH([glib], 37 | AC_HELP_STRING([--with-glib], 38 | [enable glib, building HLOS systems which use glib])) 39 | 40 | if (test "x${with_glib}" = "xyes"); then 41 | AC_DEFINE(ENABLE_USEGLIB, 1, [Define if HLOS systems uses glib]) 42 | PKG_CHECK_MODULES(GTHREAD, gthread-2.0 >= 2.16, dummy=yes, 43 | AC_MSG_ERROR(GThread >= 2.16 is required)) 44 | PKG_CHECK_MODULES(GLIB, glib-2.0 >= 2.16, dummy=yes, 45 | AC_MSG_ERROR(GLib >= 2.16 is required)) 46 | GLIB_CFLAGS="$GLIB_CFLAGS $GTHREAD_CFLAGS" 47 | GLIB_LIBS="$GLIB_LIBS $GTHREAD_LIBS" 48 | 49 | AC_SUBST(GLIB_CFLAGS) 50 | AC_SUBST(GLIB_LIBS) 51 | fi 52 | 53 | AM_CONDITIONAL(USE_GLIB, test "x${with_glib}" = "xyes") 54 | 55 | 56 | AC_CONFIG_FILES([ \ 57 | Makefile \ 58 | ntrip-client-integration-api-testlib.pc 59 | ]) 60 | 61 | AC_OUTPUT 62 | -------------------------------------------------------------------------------- /rootdir/bin/init.mmi.laser.sh: -------------------------------------------------------------------------------- 1 | #!/vendor/bin/sh 2 | scriptname=${0##*/} 3 | dbg_on=1 4 | debug() 5 | { 6 | [ $dbg_on ] && echo "Debug: $*" 7 | } 8 | 9 | notice() 10 | { 11 | echo "$*" 12 | echo "$scriptname: $*" > /dev/kmsg 13 | } 14 | 15 | error_and_leave() 16 | { 17 | local err_msg 18 | local err_code=$1 19 | case $err_code in 20 | 1) err_msg="Error: No response";; 21 | 2) err_msg="Error: in factory mode";; 22 | 3) err_msg="Error: calibration file not exist";; 23 | 4) err_msg="Error: the calibration sys file not show up";; 24 | esac 25 | notice "$err_msg" 26 | exit $err_code 27 | } 28 | 29 | bootmode=`getprop ro.bootmode` 30 | if [ $bootmode == "mot-factory" ] 31 | then 32 | error_and_leave 2 33 | fi 34 | 35 | laser_class_path=/sys/devices/virtual/laser 36 | laser_product_string=$(ls $laser_class_path) 37 | laser_product_path=$laser_class_path/$laser_product_string 38 | debug "laser product path: $laser_product_path" 39 | 40 | for laser_file in $laser_product_path/*; do 41 | if [ -f "$laser_file" ]; then 42 | chown root:system $laser_file 43 | fi 44 | done 45 | 46 | bootmode=$(getprop ro.bootmode 2> /dev/null) 47 | if [ $bootmode != "mot-factory" ]; then 48 | # Enable smudge mode 49 | echo 1 > $laser_product_path/smudge_correction_mode 50 | notice "laser smudge mode enabled" 51 | else 52 | # Disable laser smudge mode 53 | echo 0 > $laser_product_path/smudge_correction_mode 54 | notice "factory-mode boot, disable laser smudge mode" 55 | fi 56 | 57 | laser_offset_path=$laser_product_path/offset 58 | laser_offset_string=$(ls $laser_offset_path) 59 | debug "laser offset path: $laser_offset_path" 60 | [ -z "$laser_offset_string" ] && error_and_leave 4 61 | 62 | cal_offset_path=/mnt/vendor/persist/camera/focus/offset_cal 63 | cal_offset_string=$(ls $cal_offset_path) 64 | [ -z "$cal_offset_string" ] && error_and_leave 3 65 | 66 | offset_cal=$(cat $cal_offset_path) 67 | debug "offset cal value [$offset_cal]" 68 | 69 | debug "set cal value to kernel" 70 | echo $offset_cal > $laser_offset_path 71 | notice "laser cal data update success" 72 | -------------------------------------------------------------------------------- /gps/android/2.0/GnssDebug.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2017-2019, The Linux Foundation. All rights reserved. 3 | * Not a Contribution 4 | */ 5 | /* 6 | * Copyright (C) 2016 The Android Open Source Project 7 | * 8 | * Licensed under the Apache License, Version 2.0 (the "License"); 9 | * you may not use this file except in compliance with the License. 10 | * You may obtain a copy of the License at 11 | * 12 | * http://www.apache.org/licenses/LICENSE-2.0 13 | * 14 | * Unless required by applicable law or agreed to in writing, software 15 | * distributed under the License is distributed on an "AS IS" BASIS, 16 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 17 | * See the License for the specific language governing permissions and 18 | * limitations under the License. 19 | */ 20 | 21 | #ifndef ANDROID_HARDWARE_GNSS_V2_0_GNSSDEBUG_H 22 | #define ANDROID_HARDWARE_GNSS_V2_0_GNSSDEBUG_H 23 | 24 | 25 | #include 26 | #include 27 | 28 | namespace android { 29 | namespace hardware { 30 | namespace gnss { 31 | namespace V2_0 { 32 | namespace implementation { 33 | 34 | using ::android::hardware::gnss::V2_0::IGnssDebug; 35 | using ::android::hardware::Return; 36 | using ::android::hardware::Void; 37 | using ::android::hardware::hidl_vec; 38 | using ::android::hardware::hidl_string; 39 | using ::android::sp; 40 | 41 | /* Interface for GNSS Debug support. */ 42 | struct Gnss; 43 | struct GnssDebug : public IGnssDebug { 44 | GnssDebug(Gnss* gnss); 45 | ~GnssDebug() {}; 46 | 47 | // Methods from ::android::hardware::gnss::V1_0::IGnssDebug follow 48 | Return getDebugData(getDebugData_cb _hidl_cb) override; 49 | // Methods from ::android::hardware::gnss::V2_0::IGnssDebug follow. 50 | Return getDebugData_2_0(getDebugData_2_0_cb _hidl_cb) override; 51 | 52 | private: 53 | Gnss* mGnss = nullptr; 54 | }; 55 | 56 | } // namespace implementation 57 | } // namespace V2_0 58 | } // namespace gnss 59 | } // namespace hardware 60 | } // namespace android 61 | 62 | #endif // ANDROID_HARDWARE_GNSS_V2_0_GNSSDEBUG_H 63 | -------------------------------------------------------------------------------- /gps/android/2.1/GnssDebug.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2017-2020, The Linux Foundation. All rights reserved. 3 | * Not a Contribution 4 | */ 5 | /* 6 | * Copyright (C) 2016 The Android Open Source Project 7 | * 8 | * Licensed under the Apache License, Version 2.0 (the "License"); 9 | * you may not use this file except in compliance with the License. 10 | * You may obtain a copy of the License at 11 | * 12 | * http://www.apache.org/licenses/LICENSE-2.0 13 | * 14 | * Unless required by applicable law or agreed to in writing, software 15 | * distributed under the License is distributed on an "AS IS" BASIS, 16 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 17 | * See the License for the specific language governing permissions and 18 | * limitations under the License. 19 | */ 20 | 21 | #ifndef ANDROID_HARDWARE_GNSS_V2_0_GNSSDEBUG_H 22 | #define ANDROID_HARDWARE_GNSS_V2_0_GNSSDEBUG_H 23 | 24 | 25 | #include 26 | #include 27 | 28 | namespace android { 29 | namespace hardware { 30 | namespace gnss { 31 | namespace V2_1 { 32 | namespace implementation { 33 | 34 | using ::android::hardware::gnss::V2_0::IGnssDebug; 35 | using ::android::hardware::Return; 36 | using ::android::hardware::Void; 37 | using ::android::hardware::hidl_vec; 38 | using ::android::hardware::hidl_string; 39 | using ::android::sp; 40 | 41 | /* Interface for GNSS Debug support. */ 42 | struct Gnss; 43 | struct GnssDebug : public IGnssDebug { 44 | GnssDebug(Gnss* gnss); 45 | ~GnssDebug() {}; 46 | 47 | // Methods from ::android::hardware::gnss::V1_0::IGnssDebug follow 48 | Return getDebugData(getDebugData_cb _hidl_cb) override; 49 | // Methods from ::android::hardware::gnss::V2_0::IGnssDebug follow. 50 | Return getDebugData_2_0(getDebugData_2_0_cb _hidl_cb) override; 51 | 52 | private: 53 | Gnss* mGnss = nullptr; 54 | }; 55 | 56 | } // namespace implementation 57 | } // namespace V2_1 58 | } // namespace gnss 59 | } // namespace hardware 60 | } // namespace android 61 | 62 | #endif // ANDROID_HARDWARE_GNSS_V2_0_GNSSDEBUG_H 63 | -------------------------------------------------------------------------------- /overlay/frameworks/base/core/res/res/values-mcc310-mnc004/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 29 | 30 | 31 | 32 | 35 | 6 36 | 37 | -------------------------------------------------------------------------------- /overlay/frameworks/base/core/res/res/values-mcc310-mnc260/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 29 | 30 | 31 | 32 | 35 | 3 36 | 37 | -------------------------------------------------------------------------------- /overlay/frameworks/base/core/res/res/values-mcc310-mnc410/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 29 | 30 | 31 | 32 | 35 | 3 36 | 37 | -------------------------------------------------------------------------------- /overlay/frameworks/base/core/res/res/values-mcc310-mnc120/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 29 | 30 | 31 | 32 | 35 | 6 36 | 37 | 38 | -------------------------------------------------------------------------------- /location/qapi/configure.ac: -------------------------------------------------------------------------------- 1 | # configure.ac -- Autoconf script for gps location-qapi 2 | # 3 | # Process this file with autoconf to produce a configure script 4 | 5 | # Requires autoconf tool later than 2.61 6 | AC_PREREQ(2.61) 7 | # Initialize the location_qapi package version 1.0.0 8 | AC_INIT([location-qapi],1.0.0) 9 | # Does not strictly follow GNU Coding standards 10 | AM_INIT_AUTOMAKE([foreign subdir-objects]) 11 | # Disables auto rebuilding of configure, Makefile.ins 12 | AM_MAINTAINER_MODE 13 | # Verifies the --srcdir is correct by checking for the path 14 | AC_CONFIG_SRCDIR([Makefile.am]) 15 | # defines some macros variable to be included by source 16 | AC_CONFIG_HEADERS([config.h]) 17 | AC_CONFIG_MACRO_DIR([m4]) 18 | 19 | # Checks for programs. 20 | AC_PROG_LIBTOOL 21 | AC_PROG_CXX 22 | AC_PROG_CC 23 | AM_PROG_CC_C_O 24 | AC_PROG_AWK 25 | AC_PROG_CPP 26 | AC_PROG_INSTALL 27 | AC_PROG_LN_S 28 | AC_PROG_MAKE_SET 29 | PKG_PROG_PKG_CONFIG 30 | 31 | # Checks for libraries. 32 | PKG_CHECK_MODULES([GPSUTILS], [gps-utils]) 33 | AC_SUBST([GPSUTILS_CFLAGS]) 34 | AC_SUBST([GPSUTILS_LIBS]) 35 | 36 | PKG_CHECK_MODULES([LOCCLIENTAPI], [location-client-api]) 37 | AC_SUBST([LOCCLIENTAPI_CFLAGS]) 38 | AC_SUBST([LOCCLIENTAPI_LIBS]) 39 | 40 | AC_ARG_WITH([glib], 41 | AC_HELP_STRING([--with-glib], 42 | [enable glib, building HLOS systems which use glib])) 43 | 44 | if (test "x${with_glib}" = "xyes"); then 45 | AC_DEFINE(ENABLE_USEGLIB, 1, [Define if HLOS systems uses glib]) 46 | PKG_CHECK_MODULES(GTHREAD, gthread-2.0 >= 2.16, dummy=yes, 47 | AC_MSG_ERROR(GThread >= 2.16 is required)) 48 | PKG_CHECK_MODULES(GLIB, glib-2.0 >= 2.16, dummy=yes, 49 | AC_MSG_ERROR(GLib >= 2.16 is required)) 50 | GLIB_CFLAGS="$GLIB_CFLAGS $GTHREAD_CFLAGS" 51 | GLIB_LIBS="$GLIB_LIBS $GTHREAD_LIBS" 52 | 53 | AC_SUBST(GLIB_CFLAGS) 54 | AC_SUBST(GLIB_LIBS) 55 | fi 56 | 57 | AM_CONDITIONAL(USE_GLIB, test "x${with_glib}" = "xyes") 58 | 59 | AC_CONFIG_FILES([ \ 60 | Makefile \ 61 | location-qapi.pc 62 | ]) 63 | 64 | AC_OUTPUT 65 | -------------------------------------------------------------------------------- /gps/geofence/configure.ac: -------------------------------------------------------------------------------- 1 | AC_PREREQ(2.61) 2 | AC_INIT([location-geofence], 1.0.0) 3 | AM_INIT_AUTOMAKE([foreign subdir-objects]) 4 | AC_CONFIG_SRCDIR([Makefile.am]) 5 | AC_CONFIG_HEADERS([config.h]) 6 | AC_CONFIG_MACRO_DIR([m4]) 7 | 8 | # Check for programs 9 | AC_PROG_LIBTOOL 10 | AC_PROG_CXX 11 | AC_PROG_CC 12 | AM_PROG_CC_C_O 13 | AC_PROG_AWK 14 | AC_PROG_CPP 15 | AC_PROG_INSTALL 16 | AC_PROG_LN_S 17 | AC_PROG_MAKE_SET 18 | PKG_PROG_PKG_CONFIG 19 | 20 | # Check for libraries 21 | PKG_CHECK_MODULES([GPSUTILS], [gps-utils]) 22 | AC_SUBST([GPSUTILS_CFLAGS]) 23 | AC_SUBST([GPSUTILS_LIBS]) 24 | 25 | PKG_CHECK_MODULES([LOCCORE], [loc-core]) 26 | AC_SUBST([LOCCORE_CFLAGS]) 27 | AC_SUBST([LOCCORE_LIBS]) 28 | 29 | AS_CASE([$host], 30 | [arm*], [ARM=yes], 31 | [ARM=no] 32 | ) 33 | 34 | AC_ARG_WITH([locpla_includes], 35 | AC_HELP_STRING([--with-locpla-includes=@<:@dir@:>@], 36 | [specify the path to locpla-includes in loc-pla_git.bb]), 37 | [locpla_incdir=$withval], 38 | with_locpla_includes=no) 39 | 40 | if test "x$with_locpla_includes" != "xno"; then 41 | AC_SUBST(LOCPLA_CFLAGS, "-I${locpla_incdir}") 42 | fi 43 | 44 | AC_ARG_WITH([glib], 45 | AC_HELP_STRING([--with-glib], 46 | [enable glib, building HLOS systems which use glib])) 47 | 48 | if (test "x${with_glib}" = "xyes"); then 49 | AC_DEFINE(ENABLE_USEGLIB, 1, [Define if HLOS systems uses glib]) 50 | PKG_CHECK_MODULES(GTHREAD, gthread-2.0 >= 2.16, dummy=yes, 51 | AC_MSG_ERROR(GThread >= 2.16 is required)) 52 | PKG_CHECK_MODULES(GLIB, glib-2.0 >= 2.16, dummy=yes, 53 | AC_MSG_ERROR(GLib >= 2.16 is required)) 54 | GLIB_CFLAGS="$GLIB_CFLAGS $GTHREAD_CFLAGS" 55 | GLIB_LIBS="$GLIB_LIBS $GTHREAD_LIBS" 56 | 57 | AC_SUBST(GLIB_CFLAGS) 58 | AC_SUBST(GLIB_LIBS) 59 | fi 60 | 61 | AM_CONDITIONAL(USE_GLIB, test "x${with_glib}" = "xyes") 62 | 63 | AC_SUBST([CFLAGS]) 64 | AC_SUBST([CPPFLAGS]) 65 | AC_SUBST([LIBS]) 66 | 67 | AC_CONFIG_FILES([ \ 68 | Makefile \ 69 | location-geofence.pc 70 | ]) 71 | 72 | AC_OUTPUT 73 | -------------------------------------------------------------------------------- /overlay/frameworks/base/core/res/res/values-mcc312-mnc530/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 30 | 31 | 32 | 33 | "0" 34 | "00" 35 | "*2" 36 | 37 | 38 | -------------------------------------------------------------------------------- /gps/etc/seccomp_policy/gnss@2.0-xtra-daemon.policy: -------------------------------------------------------------------------------- 1 | #******************************************************************************* 2 | # Copyright (c) 2020 The Linux Foundation. All rights reserved. 3 | # 4 | # Redistribution and use in source and binary forms, with or without 5 | # modification, are permitted provided that the following conditions are 6 | # met: 7 | # * Redistributions of source code must retain the above copyright 8 | # notice, this list of conditions and the following disclaimer. 9 | # * Redistributions in binary form must reproduce the above 10 | # copyright notice, this list of conditions and the following 11 | # disclaimer in the documentation and/or other materials provided 12 | # with the distribution. 13 | # * Neither the name of The Linux Foundation, nor the names of its 14 | # contributors may be used to endorse or promote products derived 15 | # from this software without specific prior written permission. 16 | # 17 | # THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 18 | # WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 19 | # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 20 | # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 21 | # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 22 | # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 23 | # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 24 | # BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 25 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 26 | # OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 27 | # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 | # 29 | #****************************************************************************** 30 | bind: 1 31 | getrlimit: 1 32 | 33 | pipe2: 1 34 | 35 | sched_getaffinity: 1 36 | timerfd_create: 1 37 | unlinkat: 1 38 | setpriority: 1 39 | 40 | epoll_create1: 1 41 | epoll_ctl: 1 42 | epoll_pwait: 1 43 | timerfd_settime: 1 44 | 45 | fdatasync: 1 46 | madvise: 1 47 | ftruncate: 1 48 | 49 | -------------------------------------------------------------------------------- /gps/etc/flp.conf: -------------------------------------------------------------------------------- 1 | ################################### 2 | ##### FLP settings ##### 3 | ################################### 4 | 5 | ################################### 6 | # FLP BATCH SIZE 7 | ################################### 8 | # The number of batched locations 9 | # requested to modem. The desired number 10 | # defined below may not be satisfied, as 11 | # the modem can only return the number 12 | # of batched locations that can be allocated, 13 | # which is limited by memory. The default 14 | # batch size defined as 20 as below. 15 | BATCH_SIZE=20 16 | 17 | ################################### 18 | # FLP OUTDOOR TRIP BATCH SIZE 19 | ################################### 20 | # The number of batched locations 21 | # requested to modem for outdoor 22 | # trip batching. The desired number 23 | # defined below may not be satisfied, as 24 | # the modem can only return the number 25 | # of batched locations that can be allocated, 26 | # which is limited by memory. The default 27 | # trip batch size defined as 600 as below. 28 | OUTDOOR_TRIP_BATCH_SIZE=600 29 | 30 | ################################### 31 | # FLP BATCHING SESSION TIMEOUT 32 | ################################### 33 | # Duration with which batch session timeout 34 | # happens in milliseconds. If not specified 35 | # or set to zero, batching session timeout 36 | # defaults to 20 seconds by the modem. 37 | # BATCH_SESSION_TIMEOUT=20000 38 | 39 | ################################### 40 | # FLP BATCHING ACCURACY 41 | ################################### 42 | # Set to one of the defined values below 43 | # to define the accuracy of batching. 44 | # If not specified, accuracy defaults 45 | # to LOW. 46 | # FLP BATCHING ACCURACY values: 47 | # Low accuracy = 0 48 | # Medium accuracy = 1 49 | # High accuracy = 2 50 | ACCURACY=1 51 | 52 | #################################### 53 | # By default if network fixes are not sensor assisted 54 | # these fixes must be dropped. This parameter adds an exception 55 | # for targets where there is no PDR and we still want to 56 | # report out network fixes 57 | # 0: MUST NOT ALLOW NETWORK FIXES 58 | # 1: ALLOW NETWORK FIXES 59 | #################################### 60 | ALLOW_NETWORK_FIXES = 0 61 | -------------------------------------------------------------------------------- /location/gnsspps/gnsspps.h: -------------------------------------------------------------------------------- 1 | /* Copyright (c) 2011-2015, The Linux Foundation. All rights reserved. 2 | * 3 | * Redistribution and use in source and binary forms, with or without 4 | * modification, are permitted provided that the following conditions are 5 | * met: 6 | * * Redistributions of source code must retain the above copyright 7 | * notice, this list of conditions and the following disclaimer. 8 | * * Redistributions in binary form must reproduce the above 9 | * copyright notice, this list of conditions and the following 10 | * disclaimer in the documentation and/or other materials provided 11 | * with the distribution. 12 | * * Neither the name of The Linux Foundatoin, nor the names of its 13 | * contributors may be used to endorse or promote products derived 14 | * from this software without specific prior written permission. 15 | * 16 | * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 17 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 18 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 19 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 20 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 23 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 24 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 26 | * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | */ 28 | #ifndef _GNSSPPS_H 29 | #define _GNSSPPS_H 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif 34 | 35 | /* opens the device and fetches from PPS source */ 36 | int initPPS(char *devname); 37 | /* updates the fine time stamp */ 38 | int getPPS(struct timespec *current_ts, struct timespec *current_boottime, struct timespec *last_boottime); 39 | /* stops fetching and closes the device */ 40 | void deInitPPS(); 41 | 42 | #ifdef __cplusplus 43 | } 44 | #endif 45 | #endif 46 | -------------------------------------------------------------------------------- /overlay/frameworks/base/core/res/res/values-mcc460-mnc03/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 29 | 30 | 31 | 32 | 35 | 6 36 | true 37 | 38 | -------------------------------------------------------------------------------- /overlay/frameworks/base/core/res/res/values-mcc460-mnc11/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 29 | 30 | 31 | 32 | 35 | 6 36 | true 37 | 38 | -------------------------------------------------------------------------------- /gps/utils/Makefile.am: -------------------------------------------------------------------------------- 1 | ACLOCAL_AMFLAGS = -I m4 2 | 3 | AM_CFLAGS = -Wundef \ 4 | -MD \ 5 | -Wno-trigraphs \ 6 | -g -O0 \ 7 | -fno-inline \ 8 | -fno-short-enums \ 9 | -fpic \ 10 | -I./ \ 11 | -std=c++14 \ 12 | $(LOCPLA_CFLAGS) 13 | 14 | libgps_utils_la_h_sources = \ 15 | msg_q.h \ 16 | linked_list.h \ 17 | loc_cfg.h \ 18 | loc_log.h \ 19 | loc_target.h \ 20 | loc_timer.h \ 21 | MsgTask.h \ 22 | LocHeap.h \ 23 | LocThread.h \ 24 | LocTimer.h \ 25 | LocIpc.h \ 26 | SkipList.h\ 27 | loc_misc_utils.h \ 28 | loc_nmea.h \ 29 | gps_extended_c.h \ 30 | gps_extended.h \ 31 | loc_gps.h \ 32 | log_util.h \ 33 | LocSharedLock.h \ 34 | LocUnorderedSetMap.h\ 35 | LocLoggerBase.h 36 | 37 | libgps_utils_la_c_sources = \ 38 | linked_list.c \ 39 | msg_q.c \ 40 | loc_cfg.cpp \ 41 | loc_log.cpp \ 42 | loc_target.cpp \ 43 | LocHeap.cpp \ 44 | LocTimer.cpp \ 45 | LocThread.cpp \ 46 | LocIpc.cpp \ 47 | LogBuffer.cpp \ 48 | MsgTask.cpp \ 49 | loc_misc_utils.cpp \ 50 | loc_nmea.cpp 51 | 52 | library_includedir = $(pkgincludedir) 53 | 54 | library_include_HEADERS = $(libgps_utils_la_h_sources) 55 | 56 | libgps_utils_la_SOURCES = $(libgps_utils_la_c_sources) 57 | 58 | if USE_GLIB 59 | libgps_utils_la_CFLAGS = -DUSE_GLIB $(AM_CFLAGS) @GLIB_CFLAGS@ 60 | libgps_utils_la_LDFLAGS = -lstdc++ -Wl,-z,defs -lpthread @GLIB_LIBS@ -shared -version-info 1:0:0 61 | libgps_utils_la_CPPFLAGS = -DUSE_GLIB $(AM_CFLAGS) $(AM_CPPFLAGS) @GLIB_CFLAGS@ 62 | else 63 | libgps_utils_la_CFLAGS = $(AM_CFLAGS) 64 | libgps_utils_la_LDFLAGS = -Wl,-z,defs -lpthread -shared -version-info 1:0:0 65 | libgps_utils_la_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) 66 | endif 67 | 68 | libgps_utils_la_LIBADD = $(CUTILS_LIBS) -ldl 69 | 70 | #Create and Install libraries 71 | lib_LTLIBRARIES = libgps_utils.la 72 | 73 | pkgconfigdir = $(libdir)/pkgconfig 74 | pkgconfig_DATA = gps-utils.pc 75 | EXTRA_DIST = $(pkgconfig_DATA) 76 | -------------------------------------------------------------------------------- /reorder-libs.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # 3 | # Copyright (C) 2021 The LineageOS Project 4 | # 5 | # SPDX-License-Identifier: Apache-2.0 6 | # 7 | 8 | from functools import cmp_to_key 9 | from locale import LC_ALL, setlocale, strcoll 10 | from pathlib import Path 11 | 12 | FILES = [Path(file) for file in [ 13 | "proprietary-files.txt", 14 | ]] 15 | 16 | setlocale(LC_ALL, "C") 17 | 18 | def strcoll_extract_utils(string1: str, string2: str) -> int: 19 | # Skip logic if one of the string if empty 20 | if not string1 or not string2: 21 | return strcoll(string1, string2) 22 | 23 | # Remove '-' from strings if there, 24 | # it is used to indicate a build target 25 | string1 = string1.removeprefix('-') 26 | string2 = string2.removeprefix('-') 27 | 28 | # If no directories, compare normally 29 | if not "/" in string1 and not "/" in string2: 30 | return strcoll(string1, string2) 31 | 32 | string1_dir = string1.rsplit("/", 1)[0] + "/" 33 | string2_dir = string2.rsplit("/", 1)[0] + "/" 34 | if string1_dir == string2_dir: 35 | # Same directory, compare normally 36 | return strcoll(string1, string2) 37 | 38 | if string1_dir.startswith(string2_dir): 39 | # First string dir is a subdirectory of the second one, 40 | # return string1 > string2 41 | return -1 42 | 43 | if string2_dir.startswith(string1_dir): 44 | # Second string dir is a subdirectory of the first one, 45 | # return string2 > string1 46 | return 1 47 | 48 | # Compare normally 49 | return strcoll(string1, string2) 50 | 51 | for file in FILES: 52 | if not file.is_file(): 53 | print(f"File {str(file)} not found") 54 | continue 55 | 56 | with open(file, 'r') as f: 57 | sections = f.read().split("\n\n") 58 | 59 | ordered_sections = [] 60 | for section in sections: 61 | section_list = [line.strip() for line in section.splitlines()] 62 | section_list.sort(key=cmp_to_key(strcoll_extract_utils)) 63 | ordered_sections.append("\n".join(section_list)) 64 | 65 | with open(file, 'w') as f: 66 | f.write("\n\n".join(ordered_sections).strip() + "\n") 67 | -------------------------------------------------------------------------------- /overlay-lineage/lineage-sdk/lineage/res/res/values/config.xml: -------------------------------------------------------------------------------- 1 | 2 | 18 | 19 | 31 | 64 32 | 33 | 45 | 64 46 | 47 | 48 | true 49 | 50 | -------------------------------------------------------------------------------- /rootdir/bin/init.qcom.crashdata.sh: -------------------------------------------------------------------------------- 1 | #!/vendor/bin/sh 2 | # Copyright (c) 2017, The Linux Foundation. All rights reserved. 3 | # 4 | # Redistribution and use in source and binary forms, with or without 5 | # modification, are permitted provided that the following conditions are 6 | # met: 7 | # * Redistributions of source code must retain the above copyright 8 | # notice, this list of conditions and the following disclaimer. 9 | # * Redistributions in binary form must reproduce the above 10 | # copyright notice, this list of conditions and the following 11 | # disclaimer in the documentation and/or other materials provided 12 | # with the distribution. 13 | # * Neither the name of The Linux Foundation nor the names of its 14 | # contributors may be used to endorse or promote products derived 15 | # from this software without specific prior written permission. 16 | # 17 | # THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 18 | # WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 19 | # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 20 | # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 21 | # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 22 | # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 23 | # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 24 | # BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 25 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 26 | # OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 27 | # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 | # 29 | 30 | abnormalcnt="persist.vendor.crash.cnt" 31 | 32 | abnormal_cnt=`getprop $abnormalcnt` 33 | crash_detect=`getprop persist.vendor.crash.detect` 34 | 35 | if [ "$abnormal_cnt" = "" ] 36 | then 37 | setprop $abnormalcnt 0 38 | fi 39 | 40 | if [ "$crash_detect" = "true" ] 41 | then 42 | abnormal_cnt=`expr $abnormal_cnt + 1` 43 | setprop $abnormalcnt $abnormal_cnt 44 | elif [ "$crash_detect" = "false" ];then 45 | setprop persist.vendor.crash.detect true 46 | else 47 | setprop persist.vendor.crash.detect true 48 | fi 49 | -------------------------------------------------------------------------------- /gps/etc/seccomp_policy/gnss@2.0-xtwifi-client.policy: -------------------------------------------------------------------------------- 1 | 2 | #******************************************************************************* 3 | # Copyright (c) 2020 The Linux Foundation. All rights reserved. 4 | # 5 | # Redistribution and use in source and binary forms, with or without 6 | # modification, are permitted provided that the following conditions are 7 | # met: 8 | # * Redistributions of source code must retain the above copyright 9 | # notice, this list of conditions and the following disclaimer. 10 | # * Redistributions in binary form must reproduce the above 11 | # copyright notice, this list of conditions and the following 12 | # disclaimer in the documentation and/or other materials provided 13 | # with the distribution. 14 | # * Neither the name of The Linux Foundation, nor the names of its 15 | # contributors may be used to endorse or promote products derived 16 | # from this software without specific prior written permission. 17 | # 18 | # THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 19 | # WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 20 | # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 21 | # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 22 | # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 23 | # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 24 | # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 25 | # BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 26 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 27 | # OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 28 | # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | # 30 | #****************************************************************************** 31 | 32 | fdatasync: 1 33 | getdents64: 1 34 | gettimeofday: 1 35 | #ioctl: arg1 == _IOC(_IOC_NONE || arg1 == _IOC(_IOC_READ || arg1 == VSOC_MAYBE_SEND_INTERRUPT_TO_HOST 36 | lseek: 1 37 | madvise: 1 38 | mkdirat: 1 39 | pwrite64: 1 40 | 41 | timerfd_create: 1 42 | timerfd_settime: 1 43 | epoll_create1: 1 44 | epoll_pwait: 1 45 | epoll_ctl: 1 46 | -------------------------------------------------------------------------------- /location/location_hal_daemon/PowerEvtHandler.h: -------------------------------------------------------------------------------- 1 | /* Copyright (c) 2018, The Linux Foundation. All rights reserved. 2 | * 3 | * Redistribution and use in source and binary forms, with or without 4 | * modification, are permitted provided that the following conditions are 5 | * met: 6 | * * Redistributions of source code must retain the above copyright 7 | * notice, this list of conditions and the following disclaimer. 8 | * * Redistributions in binary form must reproduce the above 9 | * copyright notice, this list of conditions and the following 10 | * disclaimer in the documentation and/or other materials provided 11 | * with the distribution. 12 | * * Neither the name of The Linux Foundation, nor the names of its 13 | * contributors may be used to endorse or promote products derived 14 | * from this software without specific prior written permission. 15 | * 16 | * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 17 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 18 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 19 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 20 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 23 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 24 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 26 | * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | */ 28 | 29 | #ifndef _POWER_EVENT_HANDLER_H_ 30 | #define _POWER_EVENT_HANDLER_H_ 31 | 32 | #include 33 | 34 | class LocationApiService; 35 | 36 | class PowerEvtHandler 37 | { 38 | public: 39 | static PowerEvtHandler* getPwrEvtHandler(LocationApiService*); 40 | ~PowerEvtHandler(); 41 | static int pwrStateCb(power_state_t pwr_state); 42 | 43 | private: 44 | PowerEvtHandler(); 45 | static LocationApiService* mLocationApiService; 46 | }; 47 | 48 | #endif //_POWER_EVENT_HANDLER_H_ 49 | 50 | -------------------------------------------------------------------------------- /location/ntrip-client-integration-api/ntrip-client-integration-api-testlib.cpp: -------------------------------------------------------------------------------- 1 | /* Copyright (c) 2020, The Linux Foundation. All rights reserved. 2 | * 3 | * Redistribution and use in source and binary forms, with or without 4 | * modification, are permitted provided that the following conditions are 5 | * met: 6 | * * Redistributions of source code must retain the above copyright 7 | * notice, this list of conditions and the following disclaimer. 8 | * * Redistributions in binary form must reproduce the above 9 | * copyright notice, this list of conditions and the following 10 | * disclaimer in the documentation and/or other materials provided 11 | * with the distribution. 12 | * * Neither the name of The Linux Foundation nor the names of its 13 | * contributors may be used to endorse or promote products derived 14 | * from this software without specific prior written permission. 15 | * 16 | * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 17 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 18 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 19 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 20 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 23 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 24 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 26 | * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | */ 28 | 29 | #define LOG_TAG "NtripClientTestLib" 30 | 31 | #include 32 | #include 33 | #include 34 | #include 35 | #include 36 | #include 37 | #include 38 | #include "NtripClientIntegrationApi.h" 39 | 40 | void startCorrectionDataStreaming(CorrectionDataCb corrDataCb) 41 | { 42 | LOC_LOGi("Start correction data streaming\n"); 43 | } 44 | 45 | void stopCorrectionDataStreaming() 46 | { 47 | LOC_LOGi("Stop correction data streaming\n"); 48 | } 49 | -------------------------------------------------------------------------------- /location/loc_api/loc_api_v02/loc_api_v02_log.h: -------------------------------------------------------------------------------- 1 | /* Copyright (c) 2011, 2018 The Linux Foundation. All rights reserved. 2 | * 3 | * Redistribution and use in source and binary forms, with or without 4 | * modification, are permitted provided that the following conditions are 5 | * met: 6 | * * Redistributions of source code must retain the above copyright 7 | * notice, this list of conditions and the following disclaimer. 8 | * * Redistributions in binary form must reproduce the above 9 | * copyright notice, this list of conditions and the following 10 | * disclaimer in the documentation and/or other materials provided 11 | * with the distribution. 12 | * * Neither the name of The Linux Foundation nor the names of its 13 | * contributors may be used to endorse or promote products derived 14 | * from this software without specific prior written permission. 15 | * 16 | * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 17 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 18 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 19 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 20 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 23 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 24 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 26 | * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | * 28 | */ 29 | 30 | #ifndef LOC_API_V02_LOG_H 31 | #define LOC_API_V02_LOG_H 32 | 33 | #include 34 | #include 35 | 36 | #ifdef __cplusplus 37 | extern "C" 38 | { 39 | #endif 40 | 41 | const char* loc_get_v02_event_name(uint32_t event); 42 | const char* loc_get_v02_client_status_name(locClientStatusEnumType status); 43 | const char* loc_get_v02_qmi_status_name(qmiLocStatusEnumT_v02 status); 44 | const char* loc_get_v02_qmi_reg_mk_status_name(qmiLocRegisterMasterClientStatusEnumT_v02 status); 45 | 46 | 47 | #ifdef __cplusplus 48 | } 49 | #endif 50 | 51 | #endif /* LOC_API_V02_LOG_H */ 52 | -------------------------------------------------------------------------------- /location/gnsspps/configure.ac: -------------------------------------------------------------------------------- 1 | # configure.ac -- Autoconf script for gps lbs-core 2 | # 3 | # Process this file with autoconf to produce a configure script 4 | 5 | # Requires autoconf tool later than 2.61 6 | AC_PREREQ(2.61) 7 | # Initialize the gps lbs-core package version 1.0.0 8 | AC_INIT([gnsspps],1.0.0) 9 | # Does not strictly follow GNU Coding standards 10 | AM_INIT_AUTOMAKE([foreign subdir-objects]) 11 | # Disables auto rebuilding of configure, Makefile.ins 12 | AM_MAINTAINER_MODE 13 | # Verifies the --srcdir is correct by checking for the path 14 | AC_CONFIG_SRCDIR([Makefile.am]) 15 | # defines some macros variable to be included by source 16 | AC_CONFIG_HEADERS([config.h]) 17 | AC_CONFIG_MACRO_DIR([m4]) 18 | 19 | # Checks for programs. 20 | AC_PROG_LIBTOOL 21 | AC_PROG_CXX 22 | AC_PROG_CC 23 | AM_PROG_CC_C_O 24 | AC_PROG_AWK 25 | AC_PROG_CPP 26 | AC_PROG_INSTALL 27 | AC_PROG_LN_S 28 | AC_PROG_MAKE_SET 29 | PKG_PROG_PKG_CONFIG 30 | 31 | # Checks for libraries. 32 | PKG_CHECK_MODULES([GPSUTILS], [gps-utils]) 33 | AC_SUBST([GPSUTILS_CFLAGS]) 34 | AC_SUBST([GPSUTILS_LIBS]) 35 | 36 | AC_ARG_WITH([locpla_includes], 37 | AC_HELP_STRING([--with-locpla-includes=@<:@dir@:>@], 38 | [Specify the path to locpla-includes in loc-pla_git.bb]), 39 | [locpla_incdir=$withval], 40 | with_locpla_includes=no) 41 | 42 | if test "x${with_locpla_includes}" != "xno"; then 43 | AC_SUBST(LOCPLA_CFLAGS, "-I${locpla_incdir}") 44 | fi 45 | 46 | AC_ARG_WITH([glib], 47 | AC_HELP_STRING([--with-glib], 48 | [enable glib, building HLOS systems which use glib])) 49 | 50 | if (test "x${with_glib}" = "xyes"); then 51 | AC_DEFINE(ENABLE_USEGLIB, 1, [Define if HLOS systems uses glib]) 52 | PKG_CHECK_MODULES(GTHREAD, gthread-2.0 >= 2.16, dummy=yes, 53 | AC_MSG_ERROR(GThread >= 2.16 is required)) 54 | PKG_CHECK_MODULES(GLIB, glib-2.0 >= 2.16, dummy=yes, 55 | AC_MSG_ERROR(GLib >= 2.16 is required)) 56 | GLIB_CFLAGS="$GLIB_CFLAGS $GTHREAD_CFLAGS" 57 | GLIB_LIBS="$GLIB_LIBS $GTHREAD_LIBS" 58 | 59 | AC_SUBST(GLIB_CFLAGS) 60 | AC_SUBST(GLIB_LIBS) 61 | fi 62 | 63 | AM_CONDITIONAL(USE_GLIB, test "x${with_glib}" = "xyes") 64 | 65 | AC_CONFIG_FILES([ \ 66 | Makefile \ 67 | gnsspps.pc 68 | ]) 69 | 70 | AC_OUTPUT 71 | -------------------------------------------------------------------------------- /gps/utils/MsgTask.h: -------------------------------------------------------------------------------- 1 | /* Copyright (c) 2011-2013, 2015, 2020 The Linux Foundation. All rights reserved. 2 | * 3 | * Redistribution and use in source and binary forms, with or without 4 | * modification, are permitted provided that the following conditions are 5 | * met: 6 | * * Redistributions of source code must retain the above copyright 7 | * notice, this list of conditions and the following disclaimer. 8 | * * Redistributions in binary form must reproduce the above 9 | * copyright notice, this list of conditions and the following 10 | * disclaimer in the documentation and/or other materials provided 11 | * with the distribution. 12 | * * Neither the name of The Linux Foundation, nor the names of its 13 | * contributors may be used to endorse or promote products derived 14 | * from this software without specific prior written permission. 15 | * 16 | * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 17 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 18 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 19 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 20 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 23 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 24 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 26 | * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | * 28 | */ 29 | #ifndef __MSG_TASK__ 30 | #define __MSG_TASK__ 31 | 32 | #include 33 | #include 34 | 35 | namespace loc_util { 36 | 37 | struct LocMsg { 38 | inline LocMsg() {} 39 | inline virtual ~LocMsg() {} 40 | virtual void proc() const = 0; 41 | inline virtual void log() const {} 42 | }; 43 | 44 | class MsgTask { 45 | const void* mQ; 46 | LocThread mThread; 47 | public: 48 | ~MsgTask() = default; 49 | MsgTask(const char* threadName = NULL); 50 | void sendMsg(const LocMsg* msg) const; 51 | void sendMsg(const std::function runnable) const; 52 | }; 53 | 54 | } // 55 | 56 | #endif //__MSG_TASK__ 57 | -------------------------------------------------------------------------------- /rootdir/bin/init.qti.ims.sh: -------------------------------------------------------------------------------- 1 | #! /vendor/bin/sh 2 | 3 | # Copyright (c) 2014, The Linux Foundation. All rights reserved. 4 | # 5 | # Redistribution and use in source and binary forms, with or without 6 | # modification, are permitted provided that the following conditions are 7 | # met: 8 | # * Redistributions of source code must retain the above copyright 9 | # notice, this list of conditions and the following disclaimer. 10 | # * Redistributions in binary form must reproduce the above 11 | # copyright notice, this list of conditions and the following 12 | # disclaimer in the documentation and/or other materials provided 13 | # with the distribution. 14 | # * Neither the name of The Linux Foundation nor the names of its 15 | # contributors may be used to endorse or promote products derived 16 | # from this software without specific prior written permission. 17 | # 18 | # THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 19 | # WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 20 | # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 21 | # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 22 | # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 23 | # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 24 | # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 25 | # BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 26 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 27 | # OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 28 | # IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | # 30 | # 31 | 32 | dir0=/data 33 | trigger_file=$dir0/ims_disabled 34 | ims_disabled=`getprop persist.vendor.ims.disabled` 35 | target=`getprop ro.build.product` 36 | 37 | #if [ ! -e $trigger_file ]; then 38 | # for future use in doing conditional debugging 39 | #else 40 | # 41 | #fi 42 | echo "$ims_disabled" 43 | echo "$target" 44 | 45 | if [ "$ims_disabled" = "0" ]; then 46 | echo "ims will be enabled" 47 | setprop vendor.service.qti.ims.enabled 1 48 | exit 49 | fi 50 | 51 | if [ "$ims_disabled" = "1" ] || [ "$target" = "msm8909_512" ]; then 52 | echo "ims is disabled" 53 | setprop vendor.service.qti.ims.enabled 0 54 | else 55 | echo "ims is enabled" 56 | setprop vendor.service.qti.ims.enabled 1 57 | fi 58 | -------------------------------------------------------------------------------- /location/location_api_msg_proto/configure.ac: -------------------------------------------------------------------------------- 1 | # configure.ac -- Autoconf script for gps location-api-msg-proto 2 | # 3 | # Process this file with autoconf to produce a configure script 4 | 5 | # Requires autoconf tool later than 2.61 6 | AC_PREREQ(2.61) 7 | # Initialize the location-api-msg-proto package version 1.0.0 8 | AC_INIT([location-api-msg-proto],1.0.0) 9 | # Does not strictly follow GNU Coding standards 10 | AM_INIT_AUTOMAKE([foreign subdir-objects]) 11 | # Disables auto rebuilding of configure, Makefile.ins 12 | AM_MAINTAINER_MODE 13 | # Verifies the --srcdir is correct by checking for the path 14 | AC_CONFIG_SRCDIR([Makefile.am]) 15 | # defines some macros variable to be included by source 16 | AC_CONFIG_HEADERS([config.h]) 17 | AC_CONFIG_MACRO_DIR([m4]) 18 | 19 | # Checks for programs. 20 | AC_PROG_LIBTOOL 21 | AC_PROG_CXX 22 | AC_PROG_CC 23 | AM_PROG_CC_C_O 24 | AC_PROG_AWK 25 | AC_PROG_CPP 26 | AC_PROG_INSTALL 27 | AC_PROG_LN_S 28 | AC_PROG_MAKE_SET 29 | PKG_PROG_PKG_CONFIG 30 | 31 | AC_ARG_WITH([glib], 32 | AC_HELP_STRING([--with-glib], 33 | [enable glib, building HLOS systems which use glib])) 34 | 35 | PKG_CHECK_MODULES([GPSUTILS], [gps-utils]) 36 | AC_SUBST([GPSUTILS_CFLAGS]) 37 | AC_SUBST([GPSUTILS_LIBS]) 38 | 39 | AC_ARG_WITH([external_ap], 40 | AC_HELP_STRING([--with-external_ap=@<:@dir@:>@], 41 | [Using External Application Processor]), 42 | [], 43 | with_external_ap=no) 44 | 45 | if test "x$with_external_ap" != "xno"; then 46 | CPPFLAGS="${CPPFLAGS} -DFEATURE_EXTERNAL_AP" 47 | fi 48 | 49 | AM_CONDITIONAL(USE_EXTERNAL_AP, test "x${with_external_ap}" = "xyes") 50 | 51 | if (test "x${with_glib}" = "xyes"); then 52 | AC_DEFINE(ENABLE_USEGLIB, 1, [Define if HLOS systems uses glib]) 53 | PKG_CHECK_MODULES(GTHREAD, gthread-2.0 >= 2.16, dummy=yes, 54 | AC_MSG_ERROR(GThread >= 2.16 is required)) 55 | PKG_CHECK_MODULES(GLIB, glib-2.0 >= 2.16, dummy=yes, 56 | AC_MSG_ERROR(GLib >= 2.16 is required)) 57 | GLIB_CFLAGS="$GLIB_CFLAGS $GTHREAD_CFLAGS" 58 | GLIB_LIBS="$GLIB_LIBS $GTHREAD_LIBS" 59 | 60 | AC_SUBST(GLIB_CFLAGS) 61 | AC_SUBST(GLIB_LIBS) 62 | fi 63 | 64 | AM_CONDITIONAL(USE_GLIB, test "x${with_glib}" = "xyes") 65 | 66 | AC_CONFIG_FILES([ \ 67 | Makefile \ 68 | src/Makefile \ 69 | location-api-msg-proto.pc 70 | ]) 71 | 72 | AC_OUTPUT 73 | -------------------------------------------------------------------------------- /power-libperfmgr/aidl/Power.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2020 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 | #pragma once 18 | 19 | #include 20 | 21 | #include 22 | #include 23 | #include 24 | 25 | #include "disp-power/InteractionHandler.h" 26 | 27 | namespace aidl { 28 | namespace google { 29 | namespace hardware { 30 | namespace power { 31 | namespace impl { 32 | namespace pixel { 33 | 34 | using ::aidl::android::hardware::power::Boost; 35 | using ::aidl::android::hardware::power::IPowerHintSession; 36 | using ::aidl::android::hardware::power::Mode; 37 | 38 | class Power : public ::aidl::android::hardware::power::BnPower { 39 | public: 40 | Power(); 41 | ndk::ScopedAStatus setMode(Mode type, bool enabled) override; 42 | ndk::ScopedAStatus isModeSupported(Mode type, bool *_aidl_return) override; 43 | ndk::ScopedAStatus setBoost(Boost type, int32_t durationMs) override; 44 | ndk::ScopedAStatus isBoostSupported(Boost type, bool *_aidl_return) override; 45 | ndk::ScopedAStatus createHintSession(int32_t tgid, int32_t uid, 46 | const std::vector &threadIds, 47 | int64_t durationNanos, 48 | std::shared_ptr *_aidl_return) override; 49 | ndk::ScopedAStatus getHintSessionPreferredRate(int64_t *outNanoseconds) override; 50 | binder_status_t dump(int fd, const char **args, uint32_t numArgs) override; 51 | 52 | private: 53 | std::unique_ptr mInteractionHandler; 54 | std::atomic mSustainedPerfModeOn; 55 | }; 56 | 57 | } // namespace pixel 58 | } // namespace impl 59 | } // namespace power 60 | } // namespace hardware 61 | } // namespace google 62 | } // namespace aidl 63 | -------------------------------------------------------------------------------- /bootctrl/1.1/libboot_control_qti/libboot_control_qti.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2020, The Linux Foundation. All rights reserved. 3 | * 4 | * Redistribution and use in source and binary forms, with or without 5 | * modification, are permitted provided that the following conditions are 6 | * met: 7 | * * Redistributions of source code must retain the above copyright 8 | * notice, this list of conditions and the following disclaimer. 9 | * * Redistributions in binary form must reproduce the above 10 | * copyright notice, this list of conditions and the following 11 | * disclaimer in the documentation and/or other materials provided 12 | * with the distribution. 13 | * * Neither the name of The Linux Foundation nor the names of its 14 | * contributors may be used to endorse or promote products derived 15 | * from this software without specific prior written permission. 16 | * 17 | * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED 18 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 19 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT 20 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS 21 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 22 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 23 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 24 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 25 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 26 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 27 | * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 | */ 29 | 30 | #pragma once 31 | 32 | #include 33 | #include 34 | 35 | using MergeStatus = ::android::hardware::boot::V1_1::MergeStatus; 36 | 37 | // IBootControl 1.0 methods 38 | bool bootcontrol_init(); 39 | unsigned get_number_slots(); 40 | unsigned get_current_slot(); 41 | int mark_boot_successful(); 42 | int set_active_boot_slot(unsigned slot); 43 | int set_slot_as_unbootable(unsigned slot); 44 | int is_slot_bootable(unsigned slot); 45 | int is_slot_marked_successful(unsigned slot); 46 | const char* get_suffix(unsigned slot); 47 | 48 | // IBootControl 1.1 methods 49 | bool set_snapshot_merge_status(MergeStatus status); 50 | MergeStatus get_snapshot_merge_status(); 51 | --------------------------------------------------------------------------------