Merge Android U (ab/10368041)
Bug: 291102124 Merged-In: Ie863d49988d64a802606027f4f660d5de66bd4d8 Change-Id: I35f3b7cf68f5c6c5fc094580f3a4c0c2b72604ef
This commit is contained in:
commit
cce8b1fc17
87 changed files with 962 additions and 11292 deletions
|
@ -34,3 +34,11 @@ license {
|
|||
"NOTICE",
|
||||
],
|
||||
}
|
||||
|
||||
prebuilt_etc {
|
||||
name: "preinstalled-packages-product-gs101-device-debug.xml",
|
||||
src: "preinstalled-packages-product-gs101-device-debug.xml",
|
||||
product_specific: true,
|
||||
sub_dir: "sysconfig",
|
||||
filename_from_src: true,
|
||||
}
|
||||
|
|
|
@ -169,6 +169,7 @@ BOARD_USE_ENC_SW_CSC := true
|
|||
BOARD_SUPPORT_MFC_ENC_RGB := true
|
||||
BOARD_USE_BLOB_ALLOCATOR := false
|
||||
BOARD_SUPPORT_MFC_ENC_BT2020 := true
|
||||
BOARD_SUPPORT_FLEXIBLE_P010 := true
|
||||
|
||||
########################
|
||||
|
||||
|
@ -220,12 +221,15 @@ $(call soong_config_set,haptics,actuator_model,$(ACTUATOR_MODEL))
|
|||
# SoundTriggerHAL Configuration
|
||||
#BOARD_USE_SOUNDTRIGGER_HAL := false
|
||||
|
||||
# Vibrator HAL actuator model and adaptive haptics configuration
|
||||
$(call soong_config_set,haptics,actuator_model,$(ACTUATOR_MODEL))
|
||||
$(call soong_config_set,haptics,adaptive_haptics_feature,$(ADAPTIVE_HAPTICS_FEATURE))
|
||||
|
||||
# HWComposer
|
||||
BOARD_HWC_VERSION := libhwc2.1
|
||||
TARGET_RUNNING_WITHOUT_SYNC_FRAMEWORK := false
|
||||
BOARD_HDMI_INCAPABLE := true
|
||||
TARGET_USES_HWC2 := true
|
||||
HWC_SKIP_VALIDATE := true
|
||||
HWC_SUPPORT_RENDER_INTENT := true
|
||||
HWC_SUPPORT_COLOR_TRANSFORM := true
|
||||
#BOARD_USES_DISPLAYPORT := true
|
||||
|
@ -368,11 +372,11 @@ BOARD_VENDOR_RAMDISK_KERNEL_MODULES_LOAD += $(BOARD_VENDOR_RAMDISK_KERNEL_MODULE
|
|||
BOARD_VENDOR_RAMDISK_KERNEL_MODULES := $(addprefix $(KERNEL_MODULE_DIR)/, $(BOARD_VENDOR_RAMDISK_KERNEL_MODULES_LOAD_EXTRA))
|
||||
BOARD_VENDOR_RAMDISK_KERNEL_MODULES += $(addprefix $(KERNEL_MODULE_DIR)/, $(notdir $(BOARD_VENDOR_RAMDISK_KERNEL_MODULES_LOAD_FILE)))
|
||||
|
||||
BOARD_VENDOR_KERNEL_MODULES_LOAD := $(strip $(shell cat $(KERNEL_MODULE_DIR)/vendor_dlkm.modules.load))
|
||||
BOARD_VENDOR_KERNEL_MODULES_LOAD += $(strip $(shell cat $(KERNEL_MODULE_DIR)/vendor_dlkm.modules.load))
|
||||
ifndef BOARD_VENDOR_KERNEL_MODULES_LOAD
|
||||
$(error vendor_dlkm.modules.load not found or empty)
|
||||
endif
|
||||
BOARD_VENDOR_KERNEL_MODULES := $(KERNEL_MODULES)
|
||||
BOARD_VENDOR_KERNEL_MODULES += $(KERNEL_MODULES)
|
||||
|
||||
# Using BUILD_COPY_HEADERS
|
||||
BUILD_BROKEN_USES_BUILD_COPY_HEADERS := true
|
||||
|
|
3
OWNERS
3
OWNERS
|
@ -1,2 +1,5 @@
|
|||
per-file powerhint.json = wvw@google.com,joaodias@google.com,jenhaochen@google.com,rkganesh@google.com,jychen@google.com
|
||||
per-file powerhint.json = wvw@google.com,joaodias@google.com,jenhaochen@google.com,rkganesh@google.com,jychen@google.com
|
||||
|
||||
# per-file for Pixel device makefiles, see go/pixel-device-mk-owner-checklist for details.
|
||||
per-file *.mk=file:device/google/gs-common:master:/OWNERS
|
||||
|
|
|
@ -53,3 +53,7 @@ $(call inherit-product, $(SRC_TARGET_DIR)/product/telephony_vendor.mk)
|
|||
|
||||
# TODO: fix
|
||||
# PRODUCT_RESTRICT_VENDOR_FILES := all
|
||||
|
||||
# Exclude features that are not available on AOSP devices.
|
||||
PRODUCT_COPY_FILES += \
|
||||
frameworks/native/data/etc/aosp_excluded_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/aosp_excluded_hardware.xml
|
|
@ -1,4 +0,0 @@
|
|||
PRODUCT_PACKAGES += \
|
||||
android.hardware.bluetooth@1.1-service.bcmbtlinux
|
||||
|
||||
BOARD_SEPOLICY_DIRS += device/google/gs101-sepolicy/bluetooth
|
|
@ -1 +0,0 @@
|
|||
# AoC firmware will be loaded by Daemon
|
|
@ -1,3 +0,0 @@
|
|||
# Load AoC firmware and boot
|
||||
on property:vendor.all.modules.ready=1
|
||||
write /sys/devices/platform/19000000.aoc/firmware aoc.bin
|
|
@ -61,6 +61,14 @@ on init
|
|||
chown system system /sys/devices/system/cpu/cpufreq/policy6/sched_pixel/spc_threshold
|
||||
chown system system /sys/devices/system/cpu/cpufreq/policy6/sched_pixel/limit_frequency
|
||||
chown system system /sys/devices/system/cpu/cpufreq/policy6/sched_pixel/pmu_limit_enable
|
||||
chown system system /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu0_memlat@17000010/memlat_cpuidle_state_aware
|
||||
chown system system /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu1_memlat@17000010/memlat_cpuidle_state_aware
|
||||
chown system system /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu2_memlat@17000010/memlat_cpuidle_state_aware
|
||||
chown system system /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu3_memlat@17000010/memlat_cpuidle_state_aware
|
||||
chown system system /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu4_memlat@17000010/memlat_cpuidle_state_aware
|
||||
chown system system /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu5_memlat@17000010/memlat_cpuidle_state_aware
|
||||
chown system system /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu6_memlat@17000010/memlat_cpuidle_state_aware
|
||||
chown system system /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu7_memlat@17000010/memlat_cpuidle_state_aware
|
||||
|
||||
chmod 0220 /proc/vendor_sched/set_task_group_bg
|
||||
chmod 0220 /proc/vendor_sched/set_task_group_cam
|
||||
|
@ -170,6 +178,16 @@ on init
|
|||
write /sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/up_rate_limit_us 500
|
||||
write /sys/devices/system/cpu/cpu6/cpufreq/sched_pixel/down_rate_limit_us 20000
|
||||
|
||||
# memlat cpuidle awareness setting
|
||||
write /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu0_memlat@17000010/memlat_cpuidle_state_aware 2
|
||||
write /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu1_memlat@17000010/memlat_cpuidle_state_aware 2
|
||||
write /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu2_memlat@17000010/memlat_cpuidle_state_aware 2
|
||||
write /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu3_memlat@17000010/memlat_cpuidle_state_aware 2
|
||||
write /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu4_memlat@17000010/memlat_cpuidle_state_aware 2
|
||||
write /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu5_memlat@17000010/memlat_cpuidle_state_aware 2
|
||||
write /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu6_memlat@17000010/memlat_cpuidle_state_aware 2
|
||||
write /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu7_memlat@17000010/memlat_cpuidle_state_aware 2
|
||||
|
||||
# RT uclamp setting
|
||||
write /proc/sys/kernel/sched_util_clamp_min_rt_default 0
|
||||
|
||||
|
@ -243,8 +261,8 @@ on init
|
|||
# Modem temperature driver
|
||||
chown radio system /sys/devices/platform/cp-tm1/cp_temp
|
||||
|
||||
# Loading common kernel modules in background
|
||||
start insmod_sh_common
|
||||
# insert display module
|
||||
start init_display
|
||||
|
||||
# Charge stats (write 0)
|
||||
chown system system /sys/class/power_supply/battery/charge_stats
|
||||
|
@ -321,9 +339,6 @@ on init
|
|||
# Power Stats HAL
|
||||
chown system system /dev/bbd_pwrstat
|
||||
|
||||
# start watchdogd
|
||||
start watchdogd
|
||||
|
||||
# Add a boost for NNAPI HAL
|
||||
write /proc/vendor_sched/nnapi_prefer_idle 0
|
||||
write /proc/vendor_sched/nnapi_uclamp_min 512
|
||||
|
@ -346,6 +361,9 @@ on init
|
|||
write /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu6_memlat@17000010/mem_latency/ratio_ceil 3200
|
||||
write /sys/class/devfreq/gs_memlat_devfreq:devfreq_mif_cpu7_memlat@17000010/mem_latency/ratio_ceil 3200
|
||||
|
||||
# Set boost_adpf_prio, -1 by default
|
||||
write /proc/vendor_sched/boost_adpf_prio ${persist.device_config.vendor_system_native_boot.boost_adpf_prio:--1}
|
||||
|
||||
on init && property:ro.boot.hw.soc.rev=0
|
||||
setprop vendor.powerhal.config powerhint_a0.json
|
||||
|
||||
|
@ -409,7 +427,6 @@ on post-fs-data
|
|||
chmod 0664 /sys/devices/platform/1c2c0000.drmdsim/hs_clock
|
||||
chmod 0664 /sys/devices/platform/1c2d0000.drmdsim/hs_clock
|
||||
|
||||
setprop vold.post_fs_data_done 1
|
||||
setprop wifi.direct.interface p2p-dev-wlan0
|
||||
setprop wifi.aware.interface aware_nmi0
|
||||
|
||||
|
@ -641,38 +658,6 @@ service abox /vendor/bin/main_abox 17c50000.abox
|
|||
group audioserver
|
||||
seclabel u:r:abox:s0
|
||||
|
||||
# GPS
|
||||
service lhd /vendor/bin/hw/lhd /vendor/etc/gnss/lhd.conf
|
||||
class main
|
||||
user gps
|
||||
group system inet net_raw sdcard_rw
|
||||
ioprio be 0
|
||||
|
||||
service gpsd /vendor/bin/hw/gpsd -c /vendor/etc/gnss/gps.xml
|
||||
class main
|
||||
user gps
|
||||
group system gps radio inet wakelock sdcard_rw net_raw
|
||||
ioprio be 0
|
||||
|
||||
service scd /vendor/bin/hw/scd /vendor/etc/gnss/scd.conf
|
||||
class main
|
||||
user gps
|
||||
group system inet net_raw wakelock
|
||||
ioprio be 0
|
||||
|
||||
service gnss_service /vendor/bin/hw/android.hardware.gnss@2.1-service-brcm
|
||||
class hal
|
||||
user gps
|
||||
group system gps radio
|
||||
ioprio be 0
|
||||
priority -1
|
||||
|
||||
# disable gps service if no gps h/w
|
||||
on property:vendor.ril.cbd.svc=0
|
||||
stop gpsd
|
||||
stop lhd
|
||||
stop scd
|
||||
|
||||
# on userdebug and eng builds, enable kgdb on the serial console
|
||||
on property:ro.debuggable=1
|
||||
write /sys/module/kgdboc/parameters/kgdboc ttyFIQ1
|
||||
|
@ -734,6 +719,9 @@ on property:sys.boot_completed=1
|
|||
swapon_all /vendor/etc/fstab.${ro.board.platform}
|
||||
write /proc/sys/vm/swappiness 100
|
||||
|
||||
# Force empty CMA
|
||||
write /sys/kernel/vendor_mm/cma/farawimg/force_empty 1
|
||||
|
||||
# Back to default VM settings
|
||||
write /proc/sys/vm/dirty_expire_centisecs 3000
|
||||
write /proc/sys/vm/dirty_background_ratio 10
|
||||
|
@ -748,7 +736,7 @@ on property:sys.boot_completed=1
|
|||
# Setup final cpuset
|
||||
write /dev/cpuset/top-app/cpus ${persist.device_config.vendor_system_native.top-app_cpuset:-0-7}
|
||||
write /dev/cpuset/foreground/cpus ${persist.device_config.vendor_system_native.foreground_cpuset:-0-3,4-5}
|
||||
write /dev/cpuset/background/cpus ${persist.device_config.vendor_system_native.background_cpuset:-0-1}
|
||||
write /dev/cpuset/background/cpus ${persist.device_config.vendor_system_native.background_cpuset:-0-3}
|
||||
write /dev/cpuset/system-background/cpus ${persist.device_config.vendor_system_native.system-background_cpuset:-0-3}
|
||||
write /dev/cpuset/restricted/cpus ${persist.device_config.vendor_system_native.restricted_cpuset:-0-3}
|
||||
write /dev/cpuset/camera-daemon/cpus ${persist.device_config.vendor_system_native.camera-daemon_cpuset:-0-7}
|
||||
|
@ -758,15 +746,22 @@ on property:sys.boot_completed=1
|
|||
write /proc/vendor_sched/ta_uclamp_min 1
|
||||
write /proc/vendor_sched/fg_uclamp_min 0
|
||||
write /proc/vendor_sched/sys_prefer_idle 0
|
||||
# cfs_rq clamp is using tg->uclamp setting
|
||||
# align it with the vendor_group setting
|
||||
|
||||
# Set ug group
|
||||
write /proc/vendor_sched/bg_ug 0
|
||||
write /proc/vendor_sched/sysbg_ug 0
|
||||
write /proc/vendor_sched/ota_ug 0
|
||||
write /proc/vendor_sched/dex2oat_ug 1
|
||||
write /proc/vendor_sched/ta_ug 1
|
||||
|
||||
# Set bg group throttle
|
||||
write /proc/vendor_sched/ug_bg_group_throttle ${persist.device_config.vendor_system_native.ug_bg_group_throttle:-308}
|
||||
|
||||
# Set uclamp.max for some groups, which could indicate cpu importance used in scheduling
|
||||
write /proc/vendor_sched/bg_uclamp_max 512
|
||||
write /dev/cpuctl/background/cpu.uclamp.max 50
|
||||
write /proc/vendor_sched/sysbg_uclamp_max 512
|
||||
write /dev/cpuctl/system-background/cpu.uclamp.max 50
|
||||
write /proc/vendor_sched/ota_uclamp_max 512
|
||||
write /proc/vendor_sched/dex2oat_uclamp_max 615
|
||||
write /dev/cpuctl/dex2oat/cpu.uclamp.max 60
|
||||
write /proc/vendor_sched/ota_uclamp_max 410
|
||||
|
||||
# Set PMU freq limit parameters
|
||||
write /sys/devices/system/cpu/cpufreq/policy0/sched_pixel/lcpi_threshold 2
|
||||
|
@ -786,12 +781,6 @@ on property:sys.boot_completed=1
|
|||
write /sys/devices/system/cpu/cpufreq/policy6/sched_pixel/pmu_limit_enable 1
|
||||
write /proc/vendor_sched/pmu_poll_enable 0
|
||||
|
||||
# Setup groups for SF (RT used for SF RE, SF used for SF main)
|
||||
write /proc/vendor_sched/rt_uclamp_min 161
|
||||
write /proc/vendor_sched/rt_prefer_idle 1
|
||||
write /proc/vendor_sched/sf_uclamp_min 39
|
||||
write /proc/vendor_sched/sf_prefer_idle 1
|
||||
|
||||
# Setup cpu.shares to throttle background groups (bg ~ 5% sysbg ~ 5% dex2oat ~2.5%)
|
||||
write /dev/cpuctl/background/cpu.shares 1024
|
||||
write /dev/cpuctl/system-background/cpu.shares 1024
|
||||
|
@ -841,19 +830,13 @@ on property:persist.sys.test_harness=1 && property:persist.vendor.testing_batte
|
|||
on property:persist.vendor.adaptive.charge.soc=*
|
||||
write /sys/class/power_supply/battery/charge_limit ${persist.vendor.adaptive.charge.soc}
|
||||
|
||||
service insmod_sh_common /vendor/bin/init.insmod.sh /vendor/etc/init.insmod.gs101.cfg
|
||||
service init_display /vendor/bin/init.display.sh
|
||||
class main
|
||||
user root
|
||||
group root system
|
||||
disabled
|
||||
oneshot
|
||||
|
||||
# Set watchdog timer to 30 seconds and pet it every 10 seconds to get a 20 second margin
|
||||
service watchdogd /system/bin/watchdogd 10 20
|
||||
class core
|
||||
oneshot
|
||||
seclabel u:r:watchdogd:s0
|
||||
|
||||
# bugreport is triggered by holding down volume down, volume up and power
|
||||
service bugreport /system/bin/dumpstate -d -p -z
|
||||
class main
|
||||
|
@ -871,6 +854,7 @@ on post-fs-data
|
|||
symlink /mnt/vendor/persist/ss /data/vendor/ss/persist
|
||||
chown root system /data/vendor/ss/persist
|
||||
chmod 0770 /data/vendor/ss/persist
|
||||
chown system system /data/vendor/ss/persist/nsp
|
||||
|
||||
restart storageproxyd
|
||||
|
||||
|
@ -913,6 +897,9 @@ on fs
|
|||
on post-fs-data
|
||||
mkdir /data/vendor/powerstats 0771 system system
|
||||
chown system system /data/vendor/powerstats
|
||||
# Thermal Residency Stats (write 1 to reset)
|
||||
chown system system /sys/kernel/metrics/thermal/tr_by_group/tmu/stats_reset
|
||||
chown system system /sys/kernel/metrics/thermal/tr_by_group/spmic/stats_reset
|
||||
|
||||
on property:vendor.thermal.link_ready=1
|
||||
# BCL
|
||||
|
@ -973,14 +960,23 @@ on property:vendor.thermal.link_ready=1
|
|||
chown system system /dev/thermal/tz-by-name/usb_pwr_therm2/trip_point_0_temp
|
||||
chown system system /dev/thermal/tz-by-name/usb_pwr_therm2/trip_point_0_hyst
|
||||
chown system system /dev/thermal/tz-by-name/usb_pwr_therm2/emul_temp
|
||||
chmod 664 /dev/thermal/cdev-by-name/thermal-cpufreq-0/user_vote
|
||||
chown system system /dev/thermal/cdev-by-name/thermal-cpufreq-0/user_vote
|
||||
chmod 664 /dev/thermal/cdev-by-name/thermal-cpufreq-1/user_vote
|
||||
chown system system /dev/thermal/cdev-by-name/thermal-cpufreq-1/user_vote
|
||||
chmod 664 /dev/thermal/cdev-by-name/thermal-cpufreq-2/user_vote
|
||||
chown system system /dev/thermal/cdev-by-name/thermal-cpufreq-2/user_vote
|
||||
chmod 664 /dev/thermal/cdev-by-name/thermal-gpufreq-0/user_vote
|
||||
chown system system /dev/thermal/cdev-by-name/thermal-gpufreq-0/user_vote
|
||||
chmod 664 /dev/thermal/cdev-by-name/tpu_cooling/user_vote
|
||||
chown system system /dev/thermal/cdev-by-name/tpu_cooling/user_vote
|
||||
chmod 664 /dev/thermal/cdev-by-name/fcc/cur_state
|
||||
chown system system /dev/thermal/cdev-by-name/fcc/cur_state
|
||||
chmod 664 /dev/thermal/cdev-by-name/dc_icl/cur_state
|
||||
chown system system /dev/thermal/cdev-by-name/dc_icl/cur_state
|
||||
chmod 664 /dev/thermal/cdev-by-name/wlc_fcc/cur_state
|
||||
chown system system /dev/thermal/cdev-by-name/wlc_fcc/cur_state
|
||||
chmod 664 /dev/thermal/cdev-by-name/usbc-port/cur_state
|
||||
chown system system /dev/thermal/cdev-by-name/usbc-port/cur_state
|
||||
|
||||
on charger
|
||||
|
@ -1018,10 +1014,14 @@ on property:persist.device_config.vendor_system_native.top-app_cpuset=*
|
|||
on property:persist.device_config.vendor_system_native.foreground_cpuset=*
|
||||
write /dev/cpuset/foreground/cpus ${persist.device_config.vendor_system_native.foreground_cpuset:-0-3,4-5}
|
||||
on property:persist.device_config.vendor_system_native.background_cpuset=*
|
||||
write /dev/cpuset/background/cpus ${persist.device_config.vendor_system_native.background_cpuset:-0-1}
|
||||
write /dev/cpuset/background/cpus ${persist.device_config.vendor_system_native.background_cpuset:-0-3}
|
||||
on property:persist.device_config.vendor_system_native.system-background_cpuset=*
|
||||
write /dev/cpuset/system-background/cpus ${persist.device_config.vendor_system_native.system-background_cpuset:-0-3}
|
||||
on property:persist.device_config.vendor_system_native.restricted_cpuset=*
|
||||
write /dev/cpuset/restricted/cpus ${persist.device_config.vendor_system_native.restricted_cpuset:-0-3}
|
||||
on property:persist.device_config.vendor_system_native.camera-daemon_cpuset=*
|
||||
write /dev/cpuset/camera-daemon/cpus ${persist.device_config.vendor_system_native.camera-daemon_cpuset:-0-7}
|
||||
|
||||
# Set esim property for LPA
|
||||
on property:persist.vendor.modem.esim_profiles_exist=*
|
||||
setprop persist.modem.esim_profiles_exist ${persist.vendor.modem.esim_profiles_exist}
|
||||
|
|
|
@ -71,6 +71,45 @@ on early-boot
|
|||
# acm function for uwb
|
||||
mkdir /config/usb_gadget/g1/functions/acm.uwb0
|
||||
|
||||
# uvc function
|
||||
mkdir /config/usb_gadget/g1/functions/uvc.0
|
||||
write /config/usb_gadget/g1/functions/uvc.0/function_name "Android Webcam"
|
||||
write /config/usb_gadget/g1/functions/uvc.0/streaming_maxpacket 3072
|
||||
# write /config/usb_gadget/g1/functions/uvc.0/streaming_maxburst 5
|
||||
# write /config/usb_gadget/g1/functions/uvc.0/streaming_interval 2
|
||||
# setup control params
|
||||
mkdir /config/usb_gadget/g1/functions/uvc.0/control/header/h
|
||||
symlink /config/usb_gadget/g1/functions/uvc.0/control/header/h /config/usb_gadget/g1/functions/uvc.0/control/class/fs/h
|
||||
symlink /config/usb_gadget/g1/functions/uvc.0/control/header/h /config/usb_gadget/g1/functions/uvc.0/control/class/ss/h
|
||||
# advertise 720p resolution for webcam encoded as mjpeg
|
||||
mkdir /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m
|
||||
mkdir /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p
|
||||
write /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/wHeight 720
|
||||
write /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/wWidth 1280
|
||||
write /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/dwMaxVideoFrameBufferSize 1843200
|
||||
write /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/dwDefaultFrameInterval 333333
|
||||
write /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/dwFrameInterval "166666
|
||||
333333
|
||||
416666
|
||||
666666"
|
||||
# advertise 1080p resolution for webcam encoded as mjpeg
|
||||
mkdir /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p
|
||||
write /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/wHeight 1080
|
||||
write /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/wWidth 1920
|
||||
write /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/dwMaxVideoFrameBufferSize 4147200
|
||||
write /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/dwDefaultFrameInterval 333333
|
||||
write /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/dwFrameInterval "166666
|
||||
333333
|
||||
416666
|
||||
666666"
|
||||
# TODO: Add uncompressed streams
|
||||
# setup streaming params
|
||||
mkdir /config/usb_gadget/g1/functions/uvc.0/streaming/header/h
|
||||
symlink /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m /config/usb_gadget/g1/functions/uvc.0/streaming/header/h/m
|
||||
symlink /config/usb_gadget/g1/functions/uvc.0/streaming/header/h /config/usb_gadget/g1/functions/uvc.0/streaming/class/fs/h
|
||||
symlink /config/usb_gadget/g1/functions/uvc.0/streaming/header/h /config/usb_gadget/g1/functions/uvc.0/streaming/class/hs/h
|
||||
symlink /config/usb_gadget/g1/functions/uvc.0/streaming/header/h /config/usb_gadget/g1/functions/uvc.0/streaming/class/ss/h
|
||||
|
||||
# chown file/folder permission
|
||||
chown system system /config/usb_gadget/
|
||||
chown system system /config/usb_gadget/g1
|
||||
|
@ -135,6 +174,99 @@ on early-boot
|
|||
chown system system /config/usb_gadget/g1/functions/rndis.gs4/protocol
|
||||
chown system system /config/usb_gadget/g1/functions/rndis.gs4/qmult
|
||||
chown system system /config/usb_gadget/g1/functions/rndis.gs4/subclass
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/bInterfaceNumber
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/class
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/class/fs
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/class/fs/h
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/class/ss
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/class/ss/h
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/header
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/header/h
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/header/h/bcdUVC
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/header/h/dwClockFrequency
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/processing
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/processing/default
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/processing/default/bmControls
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/processing/default/bSourceID
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/processing/default/bUnitID
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/processing/default/iProcessing
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/processing/default/wMaxMultiplier
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/camera
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/camera/default
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/camera/default/bAssocTerminal
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/camera/default/bmControls
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/camera/default/bTerminalID
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/camera/default/iTerminal
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/camera/default/wObjectiveFocalLengthMax
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/camera/default/wObjectiveFocalLengthMin
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/camera/default/wOcularFocalLength
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/camera/default/wTerminalType
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/output
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/output/default
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/output/default/bAssocTerminal
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/output/default/bSourceID
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/output/default/bTerminalID
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/output/default/iTerminal
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/control/terminal/output/default/wTerminalType
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/function_name
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming_interval
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming_maxburst
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming_maxpacket
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/bInterfaceNumber
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/class
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/class/fs
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/class/fs/h
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/class/hs
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/class/hs/h
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/class/ss
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/class/ss/h
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/color_matching
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/color_matching/default
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/color_matching/default/bColorPrimaries
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/color_matching/default/bMatrixCoefficients
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/color_matching/default/bTransferCharacteristics
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/header
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/header/h
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/header/h/bmInfo
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/header/h/bStillCaptureMethod
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/header/h/bTerminalLink
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/header/h/bTriggerSupport
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/header/h/bTriggerUsage
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/header/h/m
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/bFrameIndex
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/bmCapabilities
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/dwDefaultFrameInterval
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/dwFrameInterval
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/dwMaxBitRate
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/dwMaxVideoFrameBufferSize
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/dwMinBitRate
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/wHeight
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/1080p/wWidth
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/bFrameIndex
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/bmCapabilities
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/dwDefaultFrameInterval
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/dwFrameInterval
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/dwMaxBitRate
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/dwMaxVideoFrameBufferSize
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/dwMinBitRate
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/wHeight
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/720p/wWidth
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/bAspectRatioX
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/bAspectRatioY
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/bDefaultFrameIndex
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/bFormatIndex
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/bmaControls
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/bmFlags
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/mjpeg/m/bmInterlaceFlags
|
||||
chown system system /config/usb_gadget/g1/functions/uvc.0/streaming/uncompressed
|
||||
chown system system /config/usb_gadget/g1/idProduct
|
||||
chown system system /config/usb_gadget/g1/idVendor
|
||||
chown system system /config/usb_gadget/g1/max_speed
|
||||
|
|
|
@ -75,8 +75,8 @@
|
|||
/dev/hdcp2 0660 media media
|
||||
|
||||
# jpeg
|
||||
/dev/m2m1shot_jpeg 0660 media media
|
||||
/dev/video12 0660 cameraserver media
|
||||
/dev/m2m1shot_jpeg 0660 media media
|
||||
/dev/video12 0660 system system
|
||||
|
||||
# audio
|
||||
/dev/seiren 0660 system audio
|
||||
|
@ -214,3 +214,9 @@
|
|||
# Raw HID devices
|
||||
/dev/hidraw* 0660 system system
|
||||
|
||||
# sysfs LED nodes for external USB devices
|
||||
/sys/devices/platform/11110000.usb/11110000.dwc3/xhci-hcd-exynos.5.auto/usb2/2-1/*/*/leds/* brightness 0664 system system
|
||||
/sys/devices/platform/11110000.usb/11110000.dwc3/xhci-hcd-exynos.5.auto/usb2/2-1/*/*/leds/* multi_intensity 0664 system system
|
||||
/sys/devices/platform/11110000.usb/11110000.dwc3/xhci-hcd-exynos.4.auto/usb2/2-1/*/*/leds/* brightness 0664 system system
|
||||
/sys/devices/platform/11110000.usb/11110000.dwc3/xhci-hcd-exynos.4.auto/usb2/2-1/*/*/leds/* multi_intensity 0664 system system
|
||||
|
||||
|
|
|
@ -82,8 +82,6 @@
|
|||
<permission name="android.permission.READ_CALL_LOG" fixed="false"/>
|
||||
<permission name="android.permission.WRITE_CALL_LOG" fixed="false"/>
|
||||
<!-- Used to set up a Wi-Fi P2P network -->
|
||||
<!-- TODO(b/231966826): Remove the location permission after Restore targets to T. -->
|
||||
<permission name="android.permission.ACCESS_FINE_LOCATION" fixed="false"/>
|
||||
<permission name="android.permission.NEARBY_WIFI_DEVICES" fixed="false"/>
|
||||
<!-- Notifications -->
|
||||
<permission name="android.permission.POST_NOTIFICATIONS" fixed="false"/>
|
||||
|
|
215
device.mk
215
device.mk
|
@ -15,6 +15,22 @@
|
|||
#
|
||||
|
||||
include device/google/gs-common/device.mk
|
||||
include device/google/gs-common/gs_watchdogd/watchdog.mk
|
||||
include device/google/gs-common/ramdump/ramdump.mk
|
||||
include device/google/gs-common/soc/soc.mk
|
||||
include device/google/gs-common/soc/freq.mk
|
||||
include device/google/gs-common/modem/modem.mk
|
||||
include device/google/gs-common/aoc/aoc.mk
|
||||
include device/google/gs-common/thermal/thermal.mk
|
||||
include device/google/gs-common/pixel_metrics/pixel_metrics.mk
|
||||
include device/google/gs-common/performance/perf.mk
|
||||
include device/google/gs-common/display/dump.mk
|
||||
include device/google/gs101/dumpstate/item.mk
|
||||
include device/google/gs-common/radio/dump.mk
|
||||
include device/google/gs-common/gear/dumpstate/aidl.mk
|
||||
include device/google/gs-common/camera/dump.mk
|
||||
include device/google/gs-common/gps/dump/log.mk
|
||||
include device/google/gs-common/widevine/widevine.mk
|
||||
|
||||
TARGET_BOARD_PLATFORM := gs101
|
||||
DEVICE_IS_64BIT_ONLY ?= $(if $(filter %_64,$(TARGET_PRODUCT)),true,false)
|
||||
|
@ -35,25 +51,18 @@ VENDOR_SECURITY_PATCH = $(PLATFORM_SECURITY_PATCH)
|
|||
# Set boot SPL
|
||||
BOOT_SECURITY_PATCH = $(PLATFORM_SECURITY_PATCH)
|
||||
|
||||
# TODO(b/207450311): Remove this flag once implemented
|
||||
USE_PIXEL_GRALLOC := false
|
||||
ifeq ($(USE_PIXEL_GRALLOC),true)
|
||||
PRODUCT_SOONG_NAMESPACES += hardware/google/gchips/GrallocHAL
|
||||
else
|
||||
PRODUCT_SOONG_NAMESPACES += hardware/google/gchips/gralloc4
|
||||
endif
|
||||
|
||||
PRODUCT_SOONG_NAMESPACES += \
|
||||
hardware/google/av \
|
||||
hardware/google/gchips \
|
||||
hardware/google/graphics/common \
|
||||
hardware/google/gchips/gralloc4 \
|
||||
hardware/google/graphics/gs101 \
|
||||
hardware/google/interfaces \
|
||||
hardware/google/pixel \
|
||||
device/google/gs101 \
|
||||
device/google/gs101/powerstats \
|
||||
system/chre/host/hal_generic \
|
||||
vendor/google/whitechapel/tools \
|
||||
vendor/broadcom/bluetooth \
|
||||
vendor/google/camera \
|
||||
vendor/google/interfaces \
|
||||
vendor/google_devices/common/proprietary/confirmatioui_hal \
|
||||
|
@ -106,8 +115,8 @@ endif
|
|||
# From system.property
|
||||
PRODUCT_PROPERTY_OVERRIDES += \
|
||||
ro.telephony.default_network=27 \
|
||||
persist.vendor.ril.use.iccid_to_plmn=1 \
|
||||
persist.vendor.ril.emergencynumber.mode=5
|
||||
persist.vendor.ril.db_ecc.use.iccid_to_plmn=1 \
|
||||
persist.vendor.ril.db_ecc.id.type=5
|
||||
#rild.libpath=/system/lib64/libsec-ril.so \
|
||||
#rild.libargs=-d /dev/umts_ipc0
|
||||
|
||||
|
@ -169,13 +178,10 @@ USES_LASSEN_MODEM := true
|
|||
ifeq ($(USES_GOOGLE_DIALER_CARRIER_SETTINGS),true)
|
||||
USE_GOOGLE_DIALER := true
|
||||
USE_GOOGLE_CARRIER_SETTINGS := true
|
||||
USES_GAUDIO := true
|
||||
endif
|
||||
|
||||
ifeq (,$(filter aosp_%,$(TARGET_PRODUCT)))
|
||||
# Audio client implementation for RIL
|
||||
USES_GAUDIO := true
|
||||
endif
|
||||
|
||||
# ######################
|
||||
# GRAPHICS - GPU (begin)
|
||||
|
@ -205,6 +211,14 @@ PRODUCT_VENDOR_PROPERTIES += \
|
|||
PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \
|
||||
debug.mali.disable_backend_affinity=true
|
||||
|
||||
# Mali Configuration Properties
|
||||
PRODUCT_VENDOR_PROPERTIES += \
|
||||
vendor.mali.platform.config=/vendor/etc/mali/platform.config \
|
||||
vendor.mali.debug.config=/vendor/etc/mali/debug.config \
|
||||
vendor.mali.base_protected_max_core_count=3 \
|
||||
vendor.mali.base_protected_tls_max=67108864 \
|
||||
vendor.mali.platform_agt_frequency_khz=24576
|
||||
|
||||
ifeq ($(USE_SWIFTSHADER),true)
|
||||
PRODUCT_PACKAGES += \
|
||||
libGLESv1_CM_swiftshader \
|
||||
|
@ -217,8 +231,8 @@ PRODUCT_COPY_FILES += \
|
|||
frameworks/native/data/etc/android.hardware.vulkan.version-1_3.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.version.xml \
|
||||
frameworks/native/data/etc/android.hardware.vulkan.level-1.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.level.xml \
|
||||
frameworks/native/data/etc/android.hardware.vulkan.compute-0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.compute.xml \
|
||||
frameworks/native/data/etc/android.software.vulkan.deqp.level-2022-03-01.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.vulkan.deqp.level.xml \
|
||||
frameworks/native/data/etc/android.software.opengles.deqp.level-2022-03-01.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.opengles.deqp.level.xml
|
||||
frameworks/native/data/etc/android.software.vulkan.deqp.level-2023-03-01.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.vulkan.deqp.level.xml \
|
||||
frameworks/native/data/etc/android.software.opengles.deqp.level-2023-03-01.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.opengles.deqp.level.xml
|
||||
|
||||
ifeq ($(USE_SWIFTSHADER),true)
|
||||
PRODUCT_VENDOR_PROPERTIES += \
|
||||
|
@ -228,6 +242,11 @@ PRODUCT_VENDOR_PROPERTIES += \
|
|||
ro.hardware.egl = mali
|
||||
endif
|
||||
|
||||
# Configure EGL blobcache
|
||||
PRODUCT_VENDOR_PROPERTIES += \
|
||||
ro.egl.blobcache.multifile=true \
|
||||
ro.egl.blobcache.multifile_limit=134217728 \
|
||||
|
||||
PRODUCT_VENDOR_PROPERTIES += \
|
||||
ro.opengles.version=196610 \
|
||||
graphics.gpu.profiler.support=true \
|
||||
|
@ -278,15 +297,6 @@ PRODUCT_COPY_FILES += \
|
|||
device/google/gs101/conf/init.debug.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/init.debug.rc
|
||||
endif
|
||||
|
||||
# If AoC Daemon is not present on this build, load firmware at boot via rc
|
||||
ifeq ($(wildcard vendor/google/whitechapel/aoc/aocd),)
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/google/gs101/conf/init.aoc.nodaemon.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.aoc.rc
|
||||
else
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/google/gs101/conf/init.aoc.daemon.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.aoc.rc
|
||||
endif
|
||||
|
||||
# Recovery files
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/google/gs101/conf/init.recovery.device.rc:$(TARGET_COPY_OUT_RECOVERY)/root/init.recovery.gs101.rc
|
||||
|
@ -308,12 +318,10 @@ PRODUCT_COPY_FILES += \
|
|||
|
||||
# Shell scripts
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/google/gs101/init.insmod.sh:$(TARGET_COPY_OUT_VENDOR)/bin/init.insmod.sh \
|
||||
device/google/gs101/init.display.sh:$(TARGET_COPY_OUT_VENDOR)/bin/init.display.sh \
|
||||
device/google/gs101/disable_contaminant_detection.sh:$(TARGET_COPY_OUT_VENDOR)/bin/hw/disable_contaminant_detection.sh
|
||||
|
||||
# insmod files
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/google/gs101/init.insmod.gs101.cfg:$(TARGET_COPY_OUT_VENDOR)/etc/init.insmod.gs101.cfg
|
||||
include device/google/gs-common/insmod/insmod.mk
|
||||
|
||||
# For creating dtbo image
|
||||
PRODUCT_HOST_PACKAGES += \
|
||||
|
@ -418,8 +426,8 @@ PRODUCT_COPY_FILES += \
|
|||
frameworks/native/data/etc/android.hardware.sensor.stepdetector.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.stepdetector.xml
|
||||
endif
|
||||
|
||||
# Add sensor HAL 2.1 product packages
|
||||
PRODUCT_PACKAGES += android.hardware.sensors@2.1-service.multihal
|
||||
# Add sensor HAL AIDL product packages
|
||||
PRODUCT_PACKAGES += android.hardware.sensors-service.multihal
|
||||
|
||||
# USB HAL
|
||||
PRODUCT_PACKAGES += \
|
||||
|
@ -454,21 +462,6 @@ include hardware/google/pixel/rebalance_interrupts/rebalance_interrupts.mk
|
|||
PRODUCT_PACKAGES += \
|
||||
android.hardware.power.stats-service.pixel
|
||||
|
||||
# dumpstate HAL
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.dumpstate@1.1-service.gs101
|
||||
|
||||
# AoC support
|
||||
PRODUCT_PACKAGES += \
|
||||
aocd
|
||||
|
||||
# AoC debug support
|
||||
PRODUCT_PACKAGES_DEBUG += \
|
||||
aocdump \
|
||||
aocutil \
|
||||
aoc_audio_cfg \
|
||||
vp_util
|
||||
|
||||
#
|
||||
# Audio HALs
|
||||
#
|
||||
|
@ -527,11 +520,7 @@ PRODUCT_PACKAGES += \
|
|||
|
||||
# WideVine modules
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.drm-service.clearkey \
|
||||
android.hardware.drm-service.widevine \
|
||||
liboemcrypto \
|
||||
|
||||
|
||||
liboemcrypto
|
||||
|
||||
$(call soong_config_set,google3a_config,soc,gs101)
|
||||
$(call soong_config_set,google3a_config,gcam_awb,true)
|
||||
|
@ -558,7 +547,7 @@ endif
|
|||
|
||||
# WiFi
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.wifi@1.0-service \
|
||||
android.hardware.wifi-service \
|
||||
wificond \
|
||||
libwpa_client \
|
||||
WifiOverlay \
|
||||
|
@ -573,6 +562,9 @@ PRODUCT_PACKAGES_DEBUG += \
|
|||
f2fs.fibmap \
|
||||
dump.f2fs
|
||||
|
||||
# Storage dump
|
||||
include device/google/gs-common/storage/storage.mk
|
||||
|
||||
# Storage health HAL
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.health.storage-service.default
|
||||
|
@ -584,12 +576,19 @@ PRODUCT_PACKAGES += \
|
|||
$(call inherit-product, $(SRC_TARGET_DIR)/product/emulated_storage.mk)
|
||||
|
||||
$(call inherit-product, $(SRC_TARGET_DIR)/product/virtual_ab_ota/compression_with_xor.mk)
|
||||
|
||||
# Enable usage of io_uring in fastbootd
|
||||
PRODUCT_VENDOR_PROPERTIES += sys.usb.ffs.io_uring_enabled=true
|
||||
|
||||
# Enforce generic ramdisk allow list
|
||||
$(call inherit-product, $(SRC_TARGET_DIR)/product/generic_ramdisk.mk)
|
||||
|
||||
# Titan-M
|
||||
ifeq (,$(filter true, $(BOARD_WITHOUT_DTLS)))
|
||||
include hardware/google/pixel/dauntless/dauntless.mk
|
||||
include device/google/gs-common/dauntless/gsc.mk
|
||||
else
|
||||
# include dauntless sepolicy to avoid compile error on devices without dauntless
|
||||
BOARD_VENDOR_SEPOLICY_DIRS += device/google/gs-common/dauntless/sepolicy
|
||||
endif
|
||||
|
||||
# Copy Camera HFD Setfiles
|
||||
|
@ -623,7 +622,6 @@ PRODUCT_COPY_FILES += \
|
|||
frameworks/native/data/etc/android.hardware.camera.full.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.full.xml\
|
||||
frameworks/native/data/etc/android.hardware.camera.raw.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.raw.xml\
|
||||
vendor/google/services/LyricCameraHAL/src/vendor.android.hardware.camera.preview-dis.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/vendor.android.hardware.camera.preview-dis.xml\
|
||||
vendor/google/services/LyricCameraHAL/src/vendor.android.hardware.camera.stream-usecase.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/vendor.android.hardware.camera.stream-usecase.xml\
|
||||
|
||||
#PRODUCT_COPY_FILES += \
|
||||
frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml \
|
||||
|
@ -804,15 +802,28 @@ PRODUCT_PACKAGES += \
|
|||
libopenvx-opencl
|
||||
endif
|
||||
|
||||
# GPS HAL
|
||||
# Location
|
||||
ifeq (,$(filter tangor citron,$(subst _, ,$(TARGET_PRODUCT))))
|
||||
include device/google/gs101/gnss/device-gnss.mk
|
||||
include device/google/gs-common/gps/brcm/device.mk
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/google/gs101/location/gps.cer:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.cer
|
||||
ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/google/gs101/location/lhd.conf:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/lhd.conf \
|
||||
device/google/gs101/location/scd.conf:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/scd.conf
|
||||
else
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/google/gs101/location/lhd_user.conf:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/lhd.conf \
|
||||
device/google/gs101/location/scd_user.conf:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/scd.conf
|
||||
endif
|
||||
endif
|
||||
|
||||
# Trusty (KM, GK, Storage)
|
||||
$(call inherit-product, system/core/trusty/trusty-storage.mk)
|
||||
$(call inherit-product, system/core/trusty/trusty-base.mk)
|
||||
|
||||
# Trusty dump
|
||||
include device/google/gs-common/trusty/trusty.mk
|
||||
|
||||
# Trusty unit test tool
|
||||
PRODUCT_PACKAGES_DEBUG += trusty-ut-ctrl
|
||||
|
||||
|
@ -828,11 +839,6 @@ PRODUCT_PACKAGES += \
|
|||
PRODUCT_PROPERTY_OVERRIDES += \
|
||||
ro.frp.pst=/dev/block/by-name/frp
|
||||
|
||||
# Bluetooth
|
||||
PRODUCT_COPY_FILES += \
|
||||
frameworks/native/data/etc/android.hardware.bluetooth.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.bluetooth.xml \
|
||||
frameworks/native/data/etc/android.hardware.bluetooth_le.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.bluetooth_le.xml
|
||||
|
||||
# System props to enable Bluetooth Quality Report (BQR) feature
|
||||
ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
|
||||
PRODUCT_PRODUCT_PROPERTIES += \
|
||||
|
@ -860,7 +866,7 @@ PRODUCT_PRODUCT_PROPERTIES += \
|
|||
|
||||
# Use FUSE BPF
|
||||
PRODUCT_PRODUCT_PROPERTIES += \
|
||||
ro.fuse.bpf.enabled=false
|
||||
ro.fuse.bpf.enabled=true
|
||||
|
||||
# Use /product/etc/fstab.postinstall to mount system_other
|
||||
PRODUCT_PRODUCT_PROPERTIES += \
|
||||
|
@ -906,6 +912,7 @@ $(call inherit-product-if-exists, vendor/samsung_slsi/telephony/$(BOARD_USES_SHA
|
|||
|
||||
#RCS Test Messaging App
|
||||
PRODUCT_PACKAGES_DEBUG += \
|
||||
preinstalled-packages-product-gs101-device-debug.xml \
|
||||
TestRcsApp
|
||||
|
||||
PRODUCT_PACKAGES += ShannonRcs
|
||||
|
@ -924,6 +931,8 @@ SUPPORT_MULTI_SIM := true
|
|||
SUPPORT_NR := true
|
||||
# Using IRadio 1.6
|
||||
USE_RADIO_HAL_1_6 := true
|
||||
# Support SecureElement HAL for HIDL
|
||||
USE_SE_HIDL := true
|
||||
|
||||
#$(call inherit-product, vendor/google_devices/telephony/common/device-vendor.mk)
|
||||
#$(call inherit-product, vendor/google_devices/gs101/proprietary/device-vendor.mk)
|
||||
|
@ -941,11 +950,7 @@ endif
|
|||
#$(call inherit-product-if-exists, hardware/google_devices/gs101/gs101.mk)
|
||||
#$(call inherit-product-if-exists, vendor/google_devices/common/exynos-vendor.mk)
|
||||
#$(call inherit-product-if-exists, hardware/broadcom/wlan/bcmdhd/firmware/bcm4375/device-bcm.mk)
|
||||
ifeq ($(wildcard vendor/google/sensors/usf),)
|
||||
$(call inherit-product-if-exists, vendor/google_devices/gs101/proprietary/usf/usf_product.mk)
|
||||
else
|
||||
$(call inherit-product-if-exists, vendor/google/sensors/usf/android/usf_efw_product.mk)
|
||||
endif
|
||||
include device/google/gs-common/sensors/sensors.mk
|
||||
$(call inherit-product-if-exists, vendor/google/services/LyricCameraHAL/src/build/device-vendor.mk)
|
||||
$(call inherit-product-if-exists, vendor/google/camera/devices/whi/device-vendor.mk)
|
||||
|
||||
|
@ -999,61 +1004,7 @@ PRODUCT_PACKAGES += \
|
|||
|
||||
# Audio
|
||||
# Audio HAL Server & Default Implementations
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.audio.service \
|
||||
android.hardware.audio@7.1-impl \
|
||||
android.hardware.audio.effect@7.0-impl \
|
||||
android.hardware.bluetooth.audio-impl \
|
||||
android.hardware.soundtrigger@2.3-impl \
|
||||
vendor.google.whitechapel.audio.audioext@4.0-impl
|
||||
|
||||
#Audio HAL libraries
|
||||
PRODUCT_PACKAGES += \
|
||||
audio.primary.$(TARGET_BOARD_PLATFORM) \
|
||||
audio.platform.aoc \
|
||||
sound_trigger.primary.$(TARGET_BOARD_PLATFORM) \
|
||||
audio_bt_aoc \
|
||||
audio_tunnel_aoc \
|
||||
aoc_aud_ext \
|
||||
libaoctuningdecoder \
|
||||
libaoc_waves \
|
||||
liboffloadeffect \
|
||||
audio_waves_aoc \
|
||||
audio_fortemedia_aoc \
|
||||
audio_bluenote_aoc \
|
||||
audio_usb_aoc \
|
||||
audio_spk_35l41 \
|
||||
audio.usb.default \
|
||||
audio.usbv2.default \
|
||||
audio.bluetooth.default \
|
||||
audio.r_submix.default \
|
||||
libamcsextfile \
|
||||
audio_amcs_ext \
|
||||
|
||||
|
||||
#Audio Vendor libraries
|
||||
PRODUCT_PACKAGES += \
|
||||
libfvsam_prm_parser \
|
||||
libmahalcontroller \
|
||||
libAlgFx_HiFi3z
|
||||
|
||||
# AudioHAL Configurations
|
||||
PRODUCT_COPY_FILES += \
|
||||
frameworks/av/services/audiopolicy/config/a2dp_audio_policy_configuration_7_0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/a2dp_audio_policy_configuration_7_0.xml \
|
||||
frameworks/av/services/audiopolicy/config/a2dp_in_audio_policy_configuration_7_0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/a2dp_in_audio_policy_configuration_7_0.xml \
|
||||
frameworks/av/services/audiopolicy/config/bluetooth_audio_policy_configuration_7_0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_audio_policy_configuration_7_0.xml \
|
||||
frameworks/av/services/audiopolicy/config/hearing_aid_audio_policy_configuration_7_0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/hearing_aid_audio_policy_configuration_7_0.xml \
|
||||
frameworks/av/services/audiopolicy/config/r_submix_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/r_submix_audio_policy_configuration.xml \
|
||||
frameworks/av/services/audiopolicy/config/usb_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/usb_audio_policy_configuration.xml \
|
||||
frameworks/av/services/audiopolicy/config/audio_policy_volumes.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_volumes.xml \
|
||||
frameworks/av/services/audiopolicy/config/default_volume_tables.xml:$(TARGET_COPY_OUT_VENDOR)/etc/default_volume_tables.xml \
|
||||
|
||||
#Audio soong
|
||||
PRODUCT_SOONG_NAMESPACES += \
|
||||
vendor/google/whitechapel/audio/hal \
|
||||
vendor/google/whitechapel/audio/interfaces
|
||||
|
||||
$(call soong_config_set,aoc_audio_board,platform,$(TARGET_BOARD_PLATFORM))
|
||||
include device/google/gs-common/audio/hidl_gs101.mk
|
||||
|
||||
## AoC soong
|
||||
PRODUCT_SOONG_NAMESPACES += \
|
||||
|
@ -1075,12 +1026,6 @@ PRODUCT_PROPERTY_OVERRIDES += \
|
|||
# PRODUCT_PROPERTY_OVERRIDES += \
|
||||
# ro.audio.spatializer_enabled=true
|
||||
|
||||
ifeq (,$(filter aosp_%,$(TARGET_PRODUCT)))
|
||||
# IAudioMetricExt HIDL
|
||||
PRODUCT_PACKAGES += \
|
||||
vendor.google.audiometricext@1.0-service-vendor
|
||||
endif
|
||||
|
||||
# vndservicemanager and vndservice no longer included in API 30+, however needed by vendor code.
|
||||
# See b/148807371 for reference
|
||||
PRODUCT_PACKAGES += vndservicemanager
|
||||
|
@ -1115,7 +1060,12 @@ PRODUCT_PACKAGES += \
|
|||
include hardware/google/pixel/thermal/device.mk
|
||||
PRODUCT_PROPERTY_OVERRIDES += persist.vendor.enable.thermal.genl=true
|
||||
|
||||
include device/google/gs101/edgetpu/edgetpu.mk
|
||||
# EdgeTPU
|
||||
include device/google/gs-common/edgetpu/edgetpu.mk
|
||||
# Config variables for TPU chip on device.
|
||||
$(call soong_config_set,edgetpu_config,chip,abrolhos)
|
||||
# TPU firmware
|
||||
PRODUCT_PACKAGES += edgetpu-abrolhos.fw
|
||||
|
||||
# Connectivity Thermal Power Manager
|
||||
PRODUCT_PACKAGES += \
|
||||
|
@ -1179,7 +1129,7 @@ PRODUCT_PACKAGES_DEBUG += BatteryStatsViewer
|
|||
# Install product specific framework compatibility matrix
|
||||
# (TODO: b/169535506) This includes the FCM for system_ext and product partition.
|
||||
# It must be split into the FCM of each partition.
|
||||
DEVICE_PRODUCT_COMPATIBILITY_MATRIX_FILE := device/google/gs101/device_framework_matrix_product.xml
|
||||
DEVICE_PRODUCT_COMPATIBILITY_MATRIX_FILE += device/google/gs101/device_framework_matrix_product.xml
|
||||
|
||||
# Preopt SystemUI
|
||||
PRODUCT_DEXPREOPT_SPEED_APPS += SystemUIGoogle # For internal
|
||||
|
@ -1200,3 +1150,6 @@ PRODUCT_PROPERTY_OVERRIDES += \
|
|||
|
||||
# Call deleteAllKeys if vold detects a factory reset
|
||||
PRODUCT_VENDOR_PROPERTIES += ro.crypto.metadata_init_delete_all_keys.enabled=true
|
||||
|
||||
# Hardware Info Collection
|
||||
include hardware/google/pixel/HardwareInfo/HardwareInfo.mk
|
||||
|
|
|
@ -47,6 +47,10 @@
|
|||
<name>IDebugHost</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<interface>
|
||||
<name>IDebugManager</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="aidl" optional="true">
|
||||
<name>com.google.edgetpu</name>
|
||||
|
@ -56,9 +60,17 @@
|
|||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="aidl" optional="true">
|
||||
<name>com.google.edgetpu.dba</name>
|
||||
<version>2</version>
|
||||
<interface>
|
||||
<name>IDevice</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="aidl" optional="true">
|
||||
<name>com.google.hardware.pixel.display</name>
|
||||
<version>7</version>
|
||||
<version>8</version>
|
||||
<interface>
|
||||
<name>IDisplay</name>
|
||||
<instance>default</instance>
|
||||
|
@ -66,44 +78,12 @@
|
|||
</hal>
|
||||
<hal format="aidl" optional="true">
|
||||
<name>com.google.input</name>
|
||||
<version>2</version>
|
||||
<interface>
|
||||
<name>ITouchContextService</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl" optional="true">
|
||||
<name>hardware.google.bluetooth.bt_channel_avoidance</name>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IBTChannelAvoidance</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl" optional="true">
|
||||
<name>hardware.google.bluetooth.sar</name>
|
||||
<version>1.1</version>
|
||||
<interface>
|
||||
<name>IBluetoothSar</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl" optional="true">
|
||||
<name>hardware.google.bluetooth.ext</name>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IBluetoothExt</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl" optional="true">
|
||||
<name>hardware.google.bluetooth.ccc</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.1</version>
|
||||
<interface>
|
||||
<name>IBluetoothCcc</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="aidl" optional="true">
|
||||
<name>hardware.qorvo.uwb</name>
|
||||
<version>2</version>
|
||||
|
@ -136,17 +116,9 @@
|
|||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.google.whitechapel.audio.audioext</name>
|
||||
<version>4.0</version>
|
||||
<interface>
|
||||
<name>IAudioExt</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl" optional="true">
|
||||
<hal format="aidl" optional="true">
|
||||
<name>vendor.google.wifi_ext</name>
|
||||
<version>1.3</version>
|
||||
<version>1</version>
|
||||
<interface>
|
||||
<name>IWifiExt</name>
|
||||
<instance>default</instance>
|
||||
|
@ -170,12 +142,4 @@
|
|||
<instance>rilExternal</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.google.audiometricext</name>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IAudioMetricExt</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
</compatibility-matrix>
|
||||
|
|
|
@ -1,10 +0,0 @@
|
|||
<compatibility-matrix version="1.0" type="framework" level="6">
|
||||
<hal format="hidl" optional="true">
|
||||
<name>vendor.google.wireless_charger</name>
|
||||
<version>1.3</version>
|
||||
<interface>
|
||||
<name>IWirelessCharger</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
</compatibility-matrix>
|
11
dumpstate/Android.bp
Normal file
11
dumpstate/Android.bp
Normal file
|
@ -0,0 +1,11 @@
|
|||
package {
|
||||
default_applicable_licenses: ["Android-Apache-2.0"],
|
||||
}
|
||||
|
||||
sh_binary {
|
||||
name: "dump_gs101.sh",
|
||||
src: "dump_gs101.sh",
|
||||
vendor: true,
|
||||
sub_dir: "dump",
|
||||
}
|
||||
|
|
@ -1,47 +0,0 @@
|
|||
#
|
||||
# Copyright 2016 The Android Open Source Project
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
LOCAL_PATH:= $(call my-dir)
|
||||
include $(CLEAR_VARS)
|
||||
LOCAL_MODULE := android.hardware.dumpstate@1.1-service.gs101
|
||||
LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0
|
||||
LOCAL_LICENSE_CONDITIONS := notice
|
||||
LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../NOTICE
|
||||
LOCAL_INIT_RC := android.hardware.dumpstate@1.1-service.gs101.rc
|
||||
LOCAL_MODULE_RELATIVE_PATH := hw
|
||||
|
||||
LOCAL_SRC_FILES := \
|
||||
DumpstateDevice.cpp \
|
||||
service.cpp
|
||||
|
||||
LOCAL_SHARED_LIBRARIES := \
|
||||
android.hardware.dumpstate@1.0 \
|
||||
android.hardware.dumpstate@1.1 \
|
||||
libbase \
|
||||
libcutils \
|
||||
libdumpstateutil \
|
||||
libhidlbase \
|
||||
libhidltransport \
|
||||
libhwbinder \
|
||||
liblog \
|
||||
libutils
|
||||
|
||||
LOCAL_CFLAGS := -Werror -Wall
|
||||
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_PROPRIETARY_MODULE := true
|
||||
|
||||
include $(BUILD_EXECUTABLE)
|
File diff suppressed because it is too large
Load diff
|
@ -1,91 +0,0 @@
|
|||
/*
|
||||
* Copyright (C) 2016 The Android Open Source Project
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
#ifndef ANDROID_HARDWARE_DUMPSTATE_V1_1_DUMPSTATEDEVICE_H
|
||||
#define ANDROID_HARDWARE_DUMPSTATE_V1_1_DUMPSTATEDEVICE_H
|
||||
|
||||
#include <android/hardware/dumpstate/1.1/IDumpstateDevice.h>
|
||||
#include <hidl/MQDescriptor.h>
|
||||
#include <hidl/Status.h>
|
||||
#include <string>
|
||||
|
||||
namespace android {
|
||||
namespace hardware {
|
||||
namespace dumpstate {
|
||||
namespace V1_1 {
|
||||
namespace implementation {
|
||||
|
||||
using ::android::hardware::dumpstate::V1_1::DumpstateMode;
|
||||
using ::android::hardware::dumpstate::V1_1::DumpstateStatus;
|
||||
using ::android::hardware::dumpstate::V1_1::IDumpstateDevice;
|
||||
using ::android::hardware::hidl_handle;
|
||||
using ::android::hardware::hidl_string;
|
||||
using ::android::hardware::hidl_vec;
|
||||
using ::android::hardware::Return;
|
||||
|
||||
struct DumpstateDevice : public IDumpstateDevice {
|
||||
public:
|
||||
DumpstateDevice();
|
||||
|
||||
// Methods from ::android::hardware::dumpstate::V1_0::IDumpstateDevice follow.
|
||||
Return<void> dumpstateBoard(const hidl_handle& h) override;
|
||||
|
||||
// Methods from ::android::hardware::dumpstate::V1_1::IDumpstateDevice follow.
|
||||
Return<DumpstateStatus> dumpstateBoard_1_1(const hidl_handle& h,
|
||||
const DumpstateMode mode,
|
||||
const uint64_t timeoutMillis) override;
|
||||
Return<void> setVerboseLoggingEnabled(const bool enable) override;
|
||||
Return<bool> getVerboseLoggingEnabled() override;
|
||||
|
||||
// Methods from ::android::hidl::base::V1_0::IBase follow.
|
||||
Return<void> debug(const hidl_handle &fd, const hidl_vec<hidl_string> &args) override;
|
||||
|
||||
private:
|
||||
const std::string kAllSections = "all";
|
||||
|
||||
std::vector<std::pair<std::string, std::function<void(int)>>> mTextSections;
|
||||
|
||||
void dumpTextSection(int fd, std::string const& sectionName);
|
||||
|
||||
// Text sections that can be dumped individually on the command line in
|
||||
// addition to being included in full dumps
|
||||
void dumpPowerSection(int fd);
|
||||
void dumpThermalSection(int fd);
|
||||
void dumpPreTouchSection(int fd);
|
||||
void dumpTouchSection(int fd);
|
||||
void dumpSocSection(int fd);
|
||||
void dumpCpuSection(int fd);
|
||||
void dumpDevfreqSection(int fd);
|
||||
void dumpMemorySection(int fd);
|
||||
void dumpStorageSection(int fd);
|
||||
void dumpDisplaySection(int fd);
|
||||
void dumpSensorsUSFSection(int fd);
|
||||
void dumpAoCSection(int fd);
|
||||
void dumpRamdumpSection(int fd);
|
||||
void dumpMiscSection(int fd);
|
||||
void dumpGscSection(int fd);
|
||||
void dumpCameraSection(int fd);
|
||||
void dumpTrustySection(int fd);
|
||||
void dumpModemSection(int fd);
|
||||
void dumpPerfMetricsSection(int fd);
|
||||
};
|
||||
|
||||
} // namespace implementation
|
||||
} // namespace V1_0
|
||||
} // namespace dumpstate
|
||||
} // namespace hardware
|
||||
} // namespace android
|
||||
|
||||
#endif // ANDROID_HARDWARE_DUMPSTATE_V1_1_DUMPSTATEDEVICE_H
|
|
@ -7,4 +7,4 @@ cyanhsieh@google.com
|
|||
rogerliao@google.com
|
||||
cyuanjen@google.com
|
||||
robinpeng@google.com
|
||||
|
||||
pattjin@google.com
|
||||
|
|
|
@ -1,6 +0,0 @@
|
|||
service vendor.dumpstate-1-1 /vendor/bin/hw/android.hardware.dumpstate@1.1-service.gs101
|
||||
class hal
|
||||
user system
|
||||
group system
|
||||
interface android.hardware.dumpstate@1.0::IDumpstateDevice default
|
||||
interface android.hardware.dumpstate@1.1::IDumpstateDevice default
|
311
dumpstate/dump_gs101.sh
Normal file
311
dumpstate/dump_gs101.sh
Normal file
|
@ -0,0 +1,311 @@
|
|||
#!/vendor/bin/sh
|
||||
echo "------ Camera HAL Graph State Dump ------"
|
||||
for f in $(ls -t /data/vendor/camera/hal_graph_state*.txt |head -1); do
|
||||
echo $f
|
||||
cat $f
|
||||
done
|
||||
|
||||
build_type="$(getprop ro.build.type)"
|
||||
|
||||
echo "\n------ Power Stats Times ------"
|
||||
echo -n "Boot: " && /vendor/bin/uptime -s && echo -n "Now: " && date;
|
||||
|
||||
echo "\n------ ACPM stats ------"
|
||||
for f in /sys/devices/platform/acpm_stats/*_stats ; do
|
||||
echo "\n\n$f"
|
||||
cat $f
|
||||
done
|
||||
|
||||
echo "\n------ CPU PM stats ------"
|
||||
cat "/sys/devices/system/cpu/cpupm/cpupm/time_in_state"
|
||||
|
||||
echo "\n------ GENPD summary ------"
|
||||
cat "/d/pm_genpd/pm_genpd_summary"
|
||||
|
||||
echo "\n------ Power supply property battery ------"
|
||||
cat "/sys/class/power_supply/battery/uevent"
|
||||
echo "\n------ Power supply property dc ------"
|
||||
cat "/sys/class/power_supply/dc/uevent"
|
||||
echo "\n------ Power supply property gcpm ------"
|
||||
cat "/sys/class/power_supply/gcpm/uevent"
|
||||
echo "\n------ Power supply property gcpm_pps ------"
|
||||
cat "/sys/class/power_supply/gcpm_pps/uevent"
|
||||
echo "\n------ Power supply property main-charger ------"
|
||||
cat "/sys/class/power_supply/main-charger/uevent"
|
||||
echo "\n------ Power supply property pca9486-mains ------"
|
||||
cat "/sys/class/power_supply/pca9468-mains/uevent"
|
||||
echo "\n------ Power supply property tcpm ------"
|
||||
cat "/sys/class/power_supply/tcpm-source-psy-i2c-max77759tcpc/uevent"
|
||||
echo "\n------ Power supply property usb ------"
|
||||
cat "/sys/class/power_supply/usb/uevent"
|
||||
echo "\n------ Power supply property wireless ------"
|
||||
cat "/sys/class/power_supply/wireless/uevent"
|
||||
|
||||
if [ -d "/sys/class/power_supply/maxfg" ]
|
||||
then
|
||||
echo "\n------ Power supply property maxfg ------"
|
||||
cat "/sys/class/power_supply/maxfg/uevent"
|
||||
echo "\n------ m5_state ------"
|
||||
cat "/sys/class/power_supply/maxfg/m5_model_state"
|
||||
echo "\n------ maxfg ------"
|
||||
cat "/dev/logbuffer_maxfg"
|
||||
echo "\n------ maxfg ------"
|
||||
cat "/dev/logbuffer_maxfg_monitor"
|
||||
else
|
||||
echo "\n------ Power supply property maxfg_base ------"
|
||||
cat "/sys/class/power_supply/maxfg_base/uevent"
|
||||
echo "\n------ Power supply property maxfg_flip ------"
|
||||
cat "/sys/class/power_supply/maxfg_flip/uevent"
|
||||
echo "\n------ m5_state ------"
|
||||
cat "/sys/class/power_supply/maxfg_base/m5_model_state"
|
||||
echo "\n------ maxfg_base ------"
|
||||
cat "/dev/logbuffer_maxfg_base"
|
||||
echo "\n------ maxfg_flip ------"
|
||||
cat "/dev/logbuffer_maxfg_flip"
|
||||
echo "\n------ maxfg_base ------"
|
||||
cat "/dev/logbuffer_maxfg_base_monitor"
|
||||
echo "\n------ maxfg_flip ------"
|
||||
cat "/dev/logbuffer_maxfg_flip_monitor"
|
||||
fi
|
||||
|
||||
if [ -d "/sys/class/power_supply/dock" ]
|
||||
then
|
||||
echo "\n------ Power supply property dock ------"
|
||||
cat "/sys/class/power_supply/dock/uevent"
|
||||
fi
|
||||
|
||||
if [ -e "/dev/logbuffer_tcpm" ]
|
||||
then
|
||||
echo "\n------ Logbuffer TCPM ------"
|
||||
cat "/dev/logbuffer_tcpm"
|
||||
if [ -d "/sys/kernel/debug/tcpm" ]
|
||||
then
|
||||
echo "\n------ TCPM logs ------"
|
||||
cat /sys/kernel/debug/tcpm/*
|
||||
else
|
||||
echo "\n------ TCPM logs ------"
|
||||
cat /sys/kernel/debug/usb/tcpm*
|
||||
fi
|
||||
fi
|
||||
|
||||
echo "\n------ TCPC ------"
|
||||
for f in /sys/devices/platform/10d50000.hsi2c/i2c-*/i2c-max77759tcpc
|
||||
do
|
||||
echo "registers:"
|
||||
cat $f/registers
|
||||
echo "frs:"
|
||||
cat $f/frs
|
||||
echo "auto_discharge:"
|
||||
cat $f/auto_discharge
|
||||
echo "bc12_enabled:"
|
||||
cat $f/bc12_enabled
|
||||
echo "cc_toggle_enable:"
|
||||
cat $f/cc_toggle_enable
|
||||
echo "contaminant_detection:"
|
||||
cat $f/contaminant_detection
|
||||
echo "contaminant_detection_status:"
|
||||
cat $f/contaminant_detection_status
|
||||
done
|
||||
|
||||
echo "\n------ PD Engine ------"
|
||||
cat "/dev/logbuffer_usbpd"
|
||||
echo "\n------ POGO Transport ------"
|
||||
cat "/dev/logbuffer_pogo_transport"
|
||||
echo "\n------ PPS-google_cpm ------"
|
||||
cat "/dev/logbuffer_cpm"
|
||||
echo "\n------ PPS-dc ------"
|
||||
cat "/dev/logbuffer_pca9468"
|
||||
|
||||
echo "\n------ Battery Health ------"
|
||||
cat "/sys/class/power_supply/battery/health_index_stats"
|
||||
echo "\n------ BMS ------"
|
||||
cat "/dev/logbuffer_ssoc"
|
||||
echo "\n------ TTF ------"
|
||||
cat "/dev/logbuffer_ttf"
|
||||
echo "\n------ TTF details ------"
|
||||
cat "/sys/class/power_supply/battery/ttf_details"
|
||||
echo "\n------ TTF stats ------"
|
||||
cat "/sys/class/power_supply/battery/ttf_stats"
|
||||
echo "\n------ maxq ------"
|
||||
cat "/dev/logbuffer_maxq"
|
||||
echo "\n------ aacr_state ------"
|
||||
cat "/sys/class/power_supply/battery/aacr_state"
|
||||
echo "\n------ TEMP/DOCK-DEFEND ------"
|
||||
cat "/dev/logbuffer_bd"
|
||||
|
||||
echo "\n------ TRICKLE-DEFEND Config ------"
|
||||
cd /sys/devices/platform/google,battery/power_supply/battery/
|
||||
for f in `ls bd_*`
|
||||
do
|
||||
echo $f: `cat $f`
|
||||
done
|
||||
|
||||
echo "\n------ DWELL-DEFEND Config ------"
|
||||
cd /sys/devices/platform/google,charger/
|
||||
for f in `ls charge_s*`
|
||||
do
|
||||
echo "$f: `cat $f`"
|
||||
done
|
||||
|
||||
echo "\n------ TEMP-DEFEND Config ------"
|
||||
cd /sys/devices/platform/google,charger/
|
||||
for f in `ls bd_*`
|
||||
do
|
||||
echo "$f: `cat $f`"
|
||||
done
|
||||
|
||||
if [ $build_type = "userdebug" ]
|
||||
then
|
||||
echo "\n------ DC_registers dump ------"
|
||||
cat "/sys/class/power_supply/pca9468-mains/device/registers_dump"
|
||||
echo "\n------ max77759_chg registers dump ------"
|
||||
cat "/d/max77759_chg/registers"
|
||||
echo "\n------ max77729_pmic registers dump ------"
|
||||
cat "/d/max77729_pmic/registers"
|
||||
echo "\n------ Charging table dump ------"
|
||||
cat "/d/google_battery/chg_raw_profile"
|
||||
|
||||
echo "\n------ fg_model ------"
|
||||
for f in /d/maxfg*
|
||||
do
|
||||
regs=`cat $f/fg_model`
|
||||
echo $f:
|
||||
echo "$regs"
|
||||
done
|
||||
|
||||
echo "\n------ fg_alo_ver ------"
|
||||
for f in /d/maxfg*
|
||||
do
|
||||
regs=`cat $f/algo_ver`
|
||||
echo $f:
|
||||
echo "$regs"
|
||||
done
|
||||
|
||||
echo "\n------ fg_model_ok ------"
|
||||
for f in /d/maxfg*
|
||||
do
|
||||
regs=`cat $f/model_ok`
|
||||
echo $f:
|
||||
echo "$regs"
|
||||
done
|
||||
|
||||
echo "\n------ fg registers ------"
|
||||
for f in /d/maxfg*
|
||||
do
|
||||
regs=`cat $f/registers`
|
||||
echo $f:
|
||||
echo "$regs"
|
||||
done
|
||||
fi
|
||||
|
||||
echo "\n------ Battery EEPROM ------"
|
||||
if [ -e "/sys/devices/platform/10970000.hsi2c/i2c-4/4-0050/eeprom" ]
|
||||
then
|
||||
xxd /sys/devices/platform/10970000.hsi2c/i2c-4/4-0050/eeprom
|
||||
fi
|
||||
|
||||
if [ -e "/sys/devices/platform/10970000.hsi2c/i2c-5/5-0050/eeprom" ]
|
||||
then
|
||||
xxd /sys/devices/platform/10970000.hsi2c/i2c-5/5-0050/eeprom
|
||||
fi
|
||||
|
||||
if [ -e "/sys/devices/platform/10970000.hsi2c/i2c-6/6-0050/eeprom" ]
|
||||
then
|
||||
xxd /sys/devices/platform/10970000.hsi2c/i2c-6/6-0050/eeprom
|
||||
fi
|
||||
|
||||
if [ -e "/sys/devices/platform/10970000.hsi2c/i2c-7/7-0050/eeprom" ]
|
||||
then
|
||||
xxd /sys/devices/platform/10970000.hsi2c/i2c-7/7-0050/eeprom
|
||||
fi
|
||||
|
||||
if [ -e "/sys/devices/platform/10970000.hsi2c/i2c-7/7-0050/eeprom" ]
|
||||
then
|
||||
xxd /sys/devices/platform/10970000.hsi2c/i2c-7/7-0050/eeprom
|
||||
fi
|
||||
|
||||
echo "\n------ Charger Stats ------"
|
||||
cat "/sys/class/power_supply/battery/charge_details"
|
||||
if [ $build_type = "userdebug" ]
|
||||
then
|
||||
echo "\n------ Google Charger ------"
|
||||
cd /sys/kernel/debug/google_charger/
|
||||
for f in `ls pps_*`
|
||||
do
|
||||
echo "$f: `cat $f`"
|
||||
done
|
||||
echo "\n------ Google Battery ------"
|
||||
cd /sys/kernel/debug/google_battery/
|
||||
for f in `ls ssoc_*`
|
||||
do
|
||||
echo "$f: `cat $f`"
|
||||
done
|
||||
fi
|
||||
|
||||
echo "\n------ WLC logs ------"
|
||||
cat "/dev/logbuffer_wireless"
|
||||
echo "\n------ WLC VER ------"
|
||||
cat "/sys/class/power_supply/wireless/device/version"
|
||||
echo "\n------ WLC STATUS ------"
|
||||
cat "/sys/class/power_supply/wireless/device/status"
|
||||
echo "\n------ WLC FW Version ------"
|
||||
cat "/sys/class/power_supply/wireless/device/fw_rev"
|
||||
echo "\n------ RTX ------"
|
||||
cat "/dev/logbuffer_rtx"
|
||||
|
||||
if [ $build_type = "userdebug" ]
|
||||
then
|
||||
echo "\n------ gvotables ------"
|
||||
cat /sys/kernel/debug/gvotables/*/status
|
||||
fi
|
||||
|
||||
echo "\n------ Mitigation Stats ------"
|
||||
echo "Source\t\tCount\tSOC\tTime\tVoltage"
|
||||
for f in `ls /sys/devices/virtual/pmic/mitigation/last_triggered_count/*`
|
||||
do
|
||||
count=`cat $f`
|
||||
a=${f/\/sys\/devices\/virtual\/pmic\/mitigation\/last_triggered_count\//}
|
||||
b=${f/last_triggered_count/last_triggered_capacity}
|
||||
c=${f/last_triggered_count/last_triggered_timestamp/}
|
||||
d=${f/last_triggered_count/last_triggered_voltage/}
|
||||
cnt=`cat $f`
|
||||
cap=`cat ${b/count/cap}`
|
||||
ti=`cat ${c/count/time}`
|
||||
volt=`cat ${d/count/volt}`
|
||||
echo "${a/_count/} \t$cnt\t$cap\t$ti\t$volt"
|
||||
done
|
||||
|
||||
echo "\n------ Clock Divider Ratio ------"
|
||||
echo \"Source\t\tRatio\"
|
||||
for f in `ls /sys/devices/virtual/pmic/mitigation/clock_ratio/*`
|
||||
do ratio=`cat $f`
|
||||
a=${f/\/sys\/devices\/virtual\/pmic\/mitigation\/clock_ratio\//}
|
||||
echo "${a/_ratio/} \t$ratio"
|
||||
done
|
||||
|
||||
echo "\n------ Clock Stats ------"
|
||||
echo "Source\t\tStats"
|
||||
for f in `ls /sys/devices/virtual/pmic/mitigation/clock_stats/*`
|
||||
do
|
||||
stats=`cat $f`
|
||||
a=${f/\/sys\/devices\/virtual\/pmic\/mitigation\/clock_stats\//};
|
||||
echo "${a/_stats/} \t$stats"
|
||||
done
|
||||
|
||||
echo "\n------ Triggered Level ------"
|
||||
echo "Source\t\tLevel"
|
||||
for f in `ls /sys/devices/virtual/pmic/mitigation/triggered_lvl/*`
|
||||
do
|
||||
lvl=`cat $f`
|
||||
a=${f/\/sys\/devices\/virtual\/pmic\/mitigation\/triggered_lvl\//}
|
||||
echo "${a/_lvl/} \t$lvl"
|
||||
done
|
||||
|
||||
echo "\n------ Instruction ------"
|
||||
for f in `ls /sys/devices/virtual/pmic/mitigation/instruction/*`
|
||||
do
|
||||
val=`cat $f`
|
||||
a=${f/\/sys\/devices\/virtual\/pmic\/mitigation\/instruction\//}
|
||||
echo "$a=$val"
|
||||
done
|
||||
|
2
dumpstate/item.mk
Normal file
2
dumpstate/item.mk
Normal file
|
@ -0,0 +1,2 @@
|
|||
PRODUCT_PACKAGES += dump_gs101.sh
|
||||
|
|
@ -1,43 +0,0 @@
|
|||
/*
|
||||
* Copyright (C) 2016 The Android Open Source Project
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
#define LOG_TAG "android.hardware.dumpstate@1.0-service.gs101"
|
||||
|
||||
#include <hidl/HidlSupport.h>
|
||||
#include <hidl/HidlTransportSupport.h>
|
||||
|
||||
#include "DumpstateDevice.h"
|
||||
|
||||
using ::android::hardware::configureRpcThreadpool;
|
||||
using ::android::hardware::dumpstate::V1_1::IDumpstateDevice;
|
||||
using ::android::hardware::dumpstate::V1_1::implementation::DumpstateDevice;
|
||||
using ::android::hardware::joinRpcThreadpool;
|
||||
using ::android::sp;
|
||||
|
||||
|
||||
int main(int /* argc */, char* /* argv */ []) {
|
||||
sp<IDumpstateDevice> dumpstate = new DumpstateDevice;
|
||||
configureRpcThreadpool(1, true);
|
||||
|
||||
android::status_t status = dumpstate->registerAsService();
|
||||
|
||||
if (status != android::OK)
|
||||
{
|
||||
ALOGE("Could not register DumpstateDevice service (%d).", status);
|
||||
return -1;
|
||||
}
|
||||
|
||||
joinRpcThreadpool();
|
||||
}
|
|
@ -1,6 +0,0 @@
|
|||
# Devs who work on EdgeTPU on Android.
|
||||
hsuy@google.com
|
||||
yuchicheng@google.com
|
||||
iayara@google.com
|
||||
qinyiyan@google.com
|
||||
macwang@google.com
|
|
@ -1,32 +0,0 @@
|
|||
# Config variables for TPU chip on device.
|
||||
$(call soong_config_set,edgetpu_config,chip,abrolhos)
|
||||
|
||||
# TPU logging service
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.edgetpu.logging@service-edgetpu-logging
|
||||
|
||||
# TPU firmware
|
||||
PRODUCT_PACKAGES += \
|
||||
edgetpu-abrolhos.fw
|
||||
|
||||
# TPU NN AIDL HAL
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.neuralnetworks@service-darwinn-aidl
|
||||
|
||||
# TPU application service
|
||||
PRODUCT_PACKAGES += \
|
||||
vendor.google.edgetpu_app_service@1.0-service
|
||||
|
||||
# TPU vendor service
|
||||
PRODUCT_PACKAGES += \
|
||||
vendor.google.edgetpu_vendor_service@1.0-service
|
||||
|
||||
# TPU HAL client library
|
||||
PRODUCT_PACKAGES += \
|
||||
libedgetpu_client.google
|
||||
|
||||
# TPU metrics logger library
|
||||
PRODUCT_PACKAGES += \
|
||||
libmetrics_logger
|
||||
|
||||
BOARD_VENDOR_SEPOLICY_DIRS += device/google/gs101-sepolicy/edgetpu/
|
|
@ -8,7 +8,7 @@ package {
|
|||
}
|
||||
|
||||
sh_binary {
|
||||
name: "fingerprint.extension",
|
||||
name: "fingerprint.extension.sh",
|
||||
init_rc: ["init.fingerprint.extension.rc"],
|
||||
src: "fingerprint.extension.sh",
|
||||
system_ext_specific: true,
|
||||
|
|
|
@ -1,10 +1,14 @@
|
|||
# Fingerprint extension feature
|
||||
ifneq (,$(filter userdebug, $(TARGET_BUILD_VARIANT)))
|
||||
$(call soong_config_set,fp_hal_feature,report_bug_support,true)
|
||||
BOARD_SEPOLICY_DIRS += hardware/google/pixel-sepolicy/fingerprint-extension/vendor/
|
||||
SYSTEM_EXT_PUBLIC_SEPOLICY_DIRS += hardware/google/pixel-sepolicy/fingerprint-extension/system_ext/public/
|
||||
SYSTEM_EXT_PRIVATE_SEPOLICY_DIRS += hardware/google/pixel-sepolicy/fingerprint-extension/system_ext/private/
|
||||
PRODUCT_PACKAGES += \
|
||||
fps_ext_bug_lib \
|
||||
fingerprint.extension
|
||||
ifneq (,$(filter aosp% factory%, $(TARGET_PRODUCT)))
|
||||
# Skip if device is AOSP or factory build
|
||||
else
|
||||
ifneq (,$(filter userdebug, $(TARGET_BUILD_VARIANT)))
|
||||
$(call soong_config_set,fp_hal_feature,report_bug_support,true)
|
||||
BOARD_SEPOLICY_DIRS += hardware/google/pixel-sepolicy/fingerprint-extension/vendor/
|
||||
SYSTEM_EXT_PUBLIC_SEPOLICY_DIRS += hardware/google/pixel-sepolicy/fingerprint-extension/system_ext/public/
|
||||
SYSTEM_EXT_PRIVATE_SEPOLICY_DIRS += hardware/google/pixel-sepolicy/fingerprint-extension/system_ext/private/
|
||||
PRODUCT_PACKAGES += \
|
||||
fps_ext_bug_lib \
|
||||
fingerprint.extension.sh
|
||||
endif
|
||||
endif
|
||||
|
|
|
@ -1,18 +1,18 @@
|
|||
# init-fingerprint-extension-sh is to send intent command to app
|
||||
# for tracking fingerprint issue.
|
||||
service fingerprint-extension-bug-latency /system_ext/bin/fingerprint.extension latency
|
||||
service fingerprint-extension-bug-latency /system_ext/bin/fingerprint.extension.sh latency
|
||||
group shell
|
||||
user shell
|
||||
disabled
|
||||
oneshot
|
||||
|
||||
service fingerprint-extension-bug-lockout /system_ext/bin/fingerprint.extension lockout
|
||||
service fingerprint-extension-bug-lockout /system_ext/bin/fingerprint.extension.sh lockout
|
||||
group shell
|
||||
user shell
|
||||
disabled
|
||||
oneshot
|
||||
|
||||
service fingerprint-extension-bug-auth /system_ext/bin/fingerprint.extension auth
|
||||
service fingerprint-extension-bug-auth /system_ext/bin/fingerprint.extension.sh auth
|
||||
group shell
|
||||
user shell
|
||||
disabled
|
||||
|
|
|
@ -14,9 +14,6 @@
|
|||
# limitations under the License.
|
||||
#
|
||||
|
||||
PRODUCT_COPY_FILES += \
|
||||
frameworks/native/data/etc/android.hardware.fingerprint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.fingerprint.xml
|
||||
|
||||
# Fingerprint manifest
|
||||
ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
|
||||
DEVICE_MANIFEST_FILE += \
|
||||
|
|
|
@ -14,5 +14,8 @@
|
|||
# limitations under the License.
|
||||
#
|
||||
|
||||
PRODUCT_COPY_FILES += \
|
||||
frameworks/native/data/etc/android.hardware.fingerprint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.fingerprint.xml
|
||||
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.biometrics.fingerprint-service.goodix
|
||||
|
|
|
@ -1,232 +0,0 @@
|
|||
// Copyright (C) 2020 The Android Open Source Project
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
soong_namespace {
|
||||
}
|
||||
|
||||
package {
|
||||
// See: http://go/android-license-faq
|
||||
// A large-scale-change added 'default_applicable_licenses' to import
|
||||
// all of the 'license_kinds' from "//device/google/gs101:device_google_gs101_license"
|
||||
// to get the below license kinds:
|
||||
// SPDX-license-identifier-Apache-2.0
|
||||
default_applicable_licenses: [
|
||||
"//device/google/gs101:device_google_gs101_license",
|
||||
],
|
||||
}
|
||||
|
||||
cc_prebuilt_library_shared {
|
||||
name: "android.hardware.gnss@2.1-impl-google",
|
||||
arch: {
|
||||
arm64: {
|
||||
srcs: ["bin/android.hardware.gnss@2.1-impl-google.so"],
|
||||
shared_libs: [
|
||||
"liblog",
|
||||
"libhidlbase",
|
||||
// "libhidltransport",
|
||||
"libutils",
|
||||
"android.hardware.gnss@1.0",
|
||||
"android.hardware.gnss@1.1",
|
||||
"android.hardware.gnss@2.0",
|
||||
"android.hardware.gnss@2.1",
|
||||
"android.hardware.gnss.measurement_corrections@1.0",
|
||||
"android.hardware.gnss.visibility_control@1.0",
|
||||
"android.hardware.gnss-V2-ndk",
|
||||
"libhardware",
|
||||
"libc++",
|
||||
"libc",
|
||||
"libm",
|
||||
"libdl",
|
||||
],
|
||||
},
|
||||
},
|
||||
compile_multilib: "64",
|
||||
vendor: true,
|
||||
relative_install_path: "hw",
|
||||
strip: {
|
||||
none: true,
|
||||
},
|
||||
// Bypass because libhidltransport is deprecated
|
||||
check_elf_files: false,
|
||||
}
|
||||
|
||||
cc_prebuilt_binary {
|
||||
name: "android.hardware.gnss@2.1-service-brcm",
|
||||
arch: {
|
||||
arm64: {
|
||||
srcs: ["bin/android.hardware.gnss@2.1-service-brcm"],
|
||||
shared_libs: [
|
||||
"liblog",
|
||||
"libutils",
|
||||
"libhardware",
|
||||
"android.hardware.gnss@1.0",
|
||||
"libhidlbase",
|
||||
// "libhidltransport",
|
||||
// "libhwbinder",
|
||||
"android.hardware.gnss@1.1",
|
||||
"android.hardware.gnss@2.0",
|
||||
"android.hardware.gnss@2.1",
|
||||
"android.hardware.gnss-V2-ndk",
|
||||
"libc++",
|
||||
"libc",
|
||||
"libm",
|
||||
"libdl",
|
||||
],
|
||||
},
|
||||
},
|
||||
compile_multilib: "64",
|
||||
vendor: true,
|
||||
relative_install_path: "hw",
|
||||
strip: {
|
||||
none: true,
|
||||
},
|
||||
// Bypass because libhidltransport is deprecated
|
||||
// Bypass because libhwbinder is deprecated
|
||||
check_elf_files: false,
|
||||
vintf_fragments: ["android.hardware.gnss@2.1-service-brcm.xml"]
|
||||
}
|
||||
|
||||
cc_prebuilt_library_shared {
|
||||
name: "flp.default",
|
||||
arch: {
|
||||
arm64: {
|
||||
srcs: ["bin/flp.default.so"],
|
||||
shared_libs: [
|
||||
"liblog",
|
||||
"libcutils",
|
||||
"libutils",
|
||||
"libc++",
|
||||
"libc",
|
||||
"libm",
|
||||
"libdl",
|
||||
],
|
||||
},
|
||||
},
|
||||
compile_multilib: "64",
|
||||
vendor: true,
|
||||
relative_install_path: "hw",
|
||||
strip: {
|
||||
none: true,
|
||||
},
|
||||
// Bypass because soname mismatch
|
||||
check_elf_files: false,
|
||||
}
|
||||
|
||||
cc_prebuilt_binary {
|
||||
name: "gpsd",
|
||||
arch: {
|
||||
arm64: {
|
||||
srcs: ["bin/gpsd"],
|
||||
shared_libs: [
|
||||
"liblog",
|
||||
"libutils",
|
||||
"libhardware_legacy",
|
||||
"libcutils",
|
||||
"libssl",
|
||||
"libcrypto",
|
||||
// "libsitril-gps",
|
||||
"android.frameworks.sensorservice@1.0",
|
||||
"libhidlbase",
|
||||
"libandroid_net",
|
||||
"libc++",
|
||||
"libc",
|
||||
"libm",
|
||||
"libdl",
|
||||
],
|
||||
},
|
||||
},
|
||||
compile_multilib: "64",
|
||||
vendor: true,
|
||||
relative_install_path: "hw",
|
||||
strip: {
|
||||
none: true,
|
||||
},
|
||||
// Bypass because libsitril-gps is Android.mk module
|
||||
check_elf_files: false,
|
||||
}
|
||||
|
||||
cc_prebuilt_library_shared {
|
||||
name: "gps.default",
|
||||
arch: {
|
||||
arm64: {
|
||||
srcs: ["bin/gps.default.so"],
|
||||
shared_libs: [
|
||||
"liblog",
|
||||
"libcutils",
|
||||
"libutils",
|
||||
"libc++",
|
||||
"libc",
|
||||
"libm",
|
||||
"libdl",
|
||||
],
|
||||
},
|
||||
},
|
||||
compile_multilib: "64",
|
||||
vendor: true,
|
||||
relative_install_path: "hw",
|
||||
strip: {
|
||||
none: true,
|
||||
},
|
||||
// Bypass because soname mismatch
|
||||
check_elf_files: false,
|
||||
}
|
||||
|
||||
cc_prebuilt_binary {
|
||||
name: "lhd",
|
||||
arch: {
|
||||
arm64: {
|
||||
srcs: ["bin/lhd"],
|
||||
shared_libs: [
|
||||
"liblog",
|
||||
"libutils",
|
||||
"libhardware_legacy",
|
||||
"libc++",
|
||||
"libc",
|
||||
"libm",
|
||||
"libz",
|
||||
"android.hardware.contexthub@1.0",
|
||||
"libhidlbase",
|
||||
"libdl",
|
||||
],
|
||||
},
|
||||
},
|
||||
compile_multilib: "64",
|
||||
vendor: true,
|
||||
relative_install_path: "hw",
|
||||
strip: {
|
||||
none: true,
|
||||
},
|
||||
}
|
||||
|
||||
cc_prebuilt_binary {
|
||||
name: "scd",
|
||||
arch: {
|
||||
arm64: {
|
||||
srcs: ["bin/scd"],
|
||||
shared_libs: [
|
||||
"liblog",
|
||||
"libutils",
|
||||
"libssl",
|
||||
"libcrypto",
|
||||
"libandroid_net",
|
||||
],
|
||||
},
|
||||
},
|
||||
compile_multilib: "64",
|
||||
vendor: true,
|
||||
relative_install_path: "hw",
|
||||
strip: {
|
||||
none: true,
|
||||
},
|
||||
}
|
|
@ -1,7 +0,0 @@
|
|||
<manifest version="1.0" type="device">
|
||||
<hal format="aidl">
|
||||
<name>android.hardware.gnss</name>
|
||||
<version>2</version>
|
||||
<fqname>IGnss/default</fqname>
|
||||
</hal>
|
||||
</manifest>
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -1,99 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<glgps xmlns="http://www.glpals.com/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.glpals.com/ glconfig.xsd" >
|
||||
<hal
|
||||
PortName="/dev/ttyBCM"
|
||||
BaudRate="921600"
|
||||
GpioNStdbyPath="/sys/devices/platform/10940000.spi/spi_master/spi5/spi5.0/nstandby"
|
||||
CustGpioDelayMs="250"
|
||||
LogEnabled="true"
|
||||
Log="JAVA"
|
||||
SecondaryConfigPath="/data/vendor/gps/overlay/gps_overlay.xml"
|
||||
LogDirectory="/sdcard/gps/broadcom/storage/"
|
||||
CtrlPipe="/data/vendor/gps/glgpsctrl"
|
||||
NmeaOutName="/data/vendor/gps/nmea_out"
|
||||
|
||||
acSuplServer="supl.google.com"
|
||||
SuplPort="7275"
|
||||
SuplLogEnable="true"
|
||||
SuplLogFullName="/data/vendor/gps/suplflow.txt"
|
||||
tlsEnable="true"
|
||||
|
||||
SuplSslMethod="SSLv23_NO_TLSv1_2"
|
||||
SuplEnable="true"
|
||||
SuplUseApn="false"
|
||||
SuplUseApnNI="true"
|
||||
SuplDummyCellInfo="true"
|
||||
SuplUseFwCellInfo="false"
|
||||
SuplTlsCertDirPath="/etc/security/cacerts"
|
||||
SuplTlsCertPath="/vendor/etc/gnss/gps.cer"
|
||||
SuplUT1Seconds="20"
|
||||
SuplUT2Seconds="20"
|
||||
SuplUT3Seconds="20"
|
||||
TcpConnectionTimeout="20"
|
||||
SuplLppCapable="true"
|
||||
SuplEcidCapable="true"
|
||||
SuplVersion="2"
|
||||
SuplMinorVersion="0"
|
||||
SuplOtdoaCapable="true"
|
||||
SuplOtdoaCapable2="true"
|
||||
SuplGlonassCapable = "true"
|
||||
SuplGalileoCapable = "true"
|
||||
SuplBdsCapable = "true"
|
||||
SuplMgpsCapable = "true"
|
||||
|
||||
RtoEnable="true"
|
||||
RtiEnable="true"
|
||||
HttpSyncLto="true"
|
||||
LtoFileName="lto2.dat"
|
||||
LtoDir="/data/vendor/gps/"
|
||||
LtoSyncThresholdDays="1"
|
||||
|
||||
GnssYearOfHardware="2020"
|
||||
CpGuardTimeSec="1"
|
||||
CpLppGuardTimeSec="1"
|
||||
IgnoreInjectedSystemTime="true"
|
||||
|
||||
AttributionAppPkgName="com.google.android.carrierlocation"
|
||||
|
||||
AssertEnabled="true"
|
||||
CpLppeCancelDbhOnAgnssProvideLoc="true"
|
||||
CpLppeUseAgnssLocForEmptyDbh="true"
|
||||
ReAidingOnHotStart="false"
|
||||
ReAidingIntervalSec="1200"
|
||||
PpsDevice="/sys/class/pps/pps0/assert_elapsed"
|
||||
/>
|
||||
|
||||
<gll
|
||||
PpsEnable="true"
|
||||
LogPriMask="LOG_INFO"
|
||||
LogFacMask="LOG_NMEA | LOG_GLLIOS | LOG_GLLAPI"
|
||||
FrqPlan="FRQ_PLAN_26MHZ_2PPM_49_152MHZ_300PPB"
|
||||
MultiCarrRFMode="GL_MULTI_CARR_RF_MODE_L1_L5"
|
||||
MultiCarrLnaMask="L1_EXT_ON|L5_EXT_ON"
|
||||
RfType="GL_RF_4776_BRCM"
|
||||
ExtL5Bias="13.0"
|
||||
EnableFilteringForLTEB13="true"
|
||||
|
||||
WarmStandbyTimeout1Seconds="10"
|
||||
WarmStandbyTimeout2Seconds="15"
|
||||
|
||||
EnableGnssPropagateInStandby="true"
|
||||
|
||||
RfPathLossDb_Ap="3.5"
|
||||
RfPathLossDb_Cp="3.5"
|
||||
RfPathLossDb_Ap_L5="3.5"
|
||||
RfPathLossDb_Cp_L5="3.5"
|
||||
OnChipGpsCarrierType="3,2,3,3,2,3,2,3,3,3,1,2,1,3,2,1,2,3,1,1,1,1,3,3,3,3,3,1,2,3,2,3"
|
||||
|
||||
EnableOnChipStopNotification="2"
|
||||
PowerMode="3"
|
||||
MinGpsWeekNumber="2216"
|
||||
/>
|
||||
|
||||
<gll_features
|
||||
EnableNicAutoSwitch="true"
|
||||
EnableNavic="true"
|
||||
/>
|
||||
|
||||
</glgps>
|
||||
|
|
@ -1,99 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<glgps xmlns="http://www.glpals.com/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.glpals.com/ glconfig.xsd" >
|
||||
<hal
|
||||
PortName="/dev/ttyBCM"
|
||||
BaudRate="921600"
|
||||
GpioNStdbyPath="/sys/devices/platform/10940000.spi/spi_master/spi5/spi5.0/nstandby"
|
||||
CustGpioDelayMs="250"
|
||||
LogEnabled="true"
|
||||
Log="JAVA"
|
||||
SecondaryConfigPath="/data/vendor/gps/overlay/gps_overlay.xml"
|
||||
LogDirectory="/sdcard/gps/broadcom/storage/"
|
||||
CtrlPipe="/data/vendor/gps/glgpsctrl"
|
||||
NmeaOutName="/data/vendor/gps/nmea_out"
|
||||
|
||||
acSuplServer="supl.google.com"
|
||||
SuplPort="7275"
|
||||
SuplLogEnable="true"
|
||||
SuplLogFullName="/data/vendor/gps/suplflow.txt"
|
||||
tlsEnable="true"
|
||||
|
||||
SuplSslMethod="SSLv23_NO_TLSv1_2"
|
||||
SuplEnable="true"
|
||||
SuplUseApn="false"
|
||||
SuplUseApnNI="true"
|
||||
SuplDummyCellInfo="true"
|
||||
SuplUseFwCellInfo="false"
|
||||
SuplTlsCertDirPath="/etc/security/cacerts"
|
||||
SuplTlsCertPath="/vendor/etc/gnss/gps.cer"
|
||||
SuplUT1Seconds="20"
|
||||
SuplUT2Seconds="20"
|
||||
SuplUT3Seconds="20"
|
||||
TcpConnectionTimeout="20"
|
||||
SuplLppCapable="true"
|
||||
SuplEcidCapable="true"
|
||||
SuplVersion="2"
|
||||
SuplMinorVersion="0"
|
||||
SuplOtdoaCapable="true"
|
||||
SuplOtdoaCapable2="true"
|
||||
SuplGlonassCapable = "true"
|
||||
SuplGalileoCapable = "true"
|
||||
SuplBdsCapable = "true"
|
||||
SuplMgpsCapable = "true"
|
||||
|
||||
RtoEnable="true"
|
||||
RtiEnable="true"
|
||||
HttpSyncLto="true"
|
||||
LtoFileName="lto2.dat"
|
||||
LtoDir="/data/vendor/gps/"
|
||||
LtoSyncThresholdDays="1"
|
||||
|
||||
GnssYearOfHardware="2020"
|
||||
CpGuardTimeSec="1"
|
||||
CpLppGuardTimeSec="1"
|
||||
IgnoreInjectedSystemTime="true"
|
||||
|
||||
AttributionAppPkgName="com.google.android.carrierlocation"
|
||||
|
||||
AssertEnabled="true"
|
||||
CpLppeCancelDbhOnAgnssProvideLoc="true"
|
||||
CpLppeUseAgnssLocForEmptyDbh="true"
|
||||
ReAidingOnHotStart="false"
|
||||
ReAidingIntervalSec="1200"
|
||||
PpsDevice="/sys/class/pps/pps0/assert_elapsed"
|
||||
/>
|
||||
|
||||
<gll
|
||||
PpsEnable="true"
|
||||
LogPriMask="LOG_INFO"
|
||||
LogFacMask="LOG_NMEA | LOG_GLLIOS | LOG_GLLAPI"
|
||||
FrqPlan="FRQ_PLAN_26MHZ_2PPM_49_152MHZ_300PPB"
|
||||
MultiCarrRFMode="GL_MULTI_CARR_RF_MODE_L1_L5"
|
||||
MultiCarrLnaMask="L1_EXT_ON|L5_EXT_ON"
|
||||
RfType="GL_RF_4776_BRCM"
|
||||
ExtL5Bias="9.3"
|
||||
EnableFilteringForLTEB13="true"
|
||||
|
||||
WarmStandbyTimeout1Seconds="10"
|
||||
WarmStandbyTimeout2Seconds="15"
|
||||
|
||||
EnableGnssPropagateInStandby="true"
|
||||
|
||||
RfPathLossDb_Ap="4.2"
|
||||
RfPathLossDb_Cp="4.2"
|
||||
RfPathLossDb_Ap_L5="4.1"
|
||||
RfPathLossDb_Cp_L5="4.1"
|
||||
OnChipGpsCarrierType="3,2,3,3,2,3,2,3,3,3,1,2,1,3,2,1,2,3,1,1,1,1,3,3,3,3,3,1,2,3,2,3"
|
||||
|
||||
EnableOnChipStopNotification="2"
|
||||
PowerMode="3"
|
||||
MinGpsWeekNumber="2216"
|
||||
/>
|
||||
|
||||
<gll_features
|
||||
EnableNicAutoSwitch="true"
|
||||
EnableNavic="true"
|
||||
/>
|
||||
|
||||
</glgps>
|
||||
|
|
@ -1,99 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<glgps xmlns="http://www.glpals.com/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.glpals.com/ glconfig.xsd" >
|
||||
<hal
|
||||
PortName="/dev/ttyBCM"
|
||||
BaudRate="921600"
|
||||
GpioNStdbyPath="/sys/devices/platform/10940000.spi/spi_master/spi5/spi5.0/nstandby"
|
||||
CustGpioDelayMs="250"
|
||||
LogEnabled="true"
|
||||
Log="JAVA"
|
||||
SecondaryConfigPath="/data/vendor/gps/overlay/gps_overlay.xml"
|
||||
LogDirectory="/sdcard/gps/broadcom/storage/"
|
||||
CtrlPipe="/data/vendor/gps/glgpsctrl"
|
||||
NmeaOutName="/data/vendor/gps/nmea_out"
|
||||
|
||||
acSuplServer="supl.google.com"
|
||||
SuplPort="7275"
|
||||
SuplLogEnable="true"
|
||||
SuplLogFullName="/data/vendor/gps/suplflow.txt"
|
||||
tlsEnable="true"
|
||||
|
||||
SuplSslMethod="SSLv23_NO_TLSv1_2"
|
||||
SuplEnable="true"
|
||||
SuplUseApn="false"
|
||||
SuplUseApnNI="true"
|
||||
SuplDummyCellInfo="true"
|
||||
SuplUseFwCellInfo="false"
|
||||
SuplTlsCertDirPath="/etc/security/cacerts"
|
||||
SuplTlsCertPath="/vendor/etc/gnss/gps.cer"
|
||||
SuplUT1Seconds="20"
|
||||
SuplUT2Seconds="20"
|
||||
SuplUT3Seconds="20"
|
||||
TcpConnectionTimeout="20"
|
||||
SuplLppCapable="true"
|
||||
SuplEcidCapable="true"
|
||||
SuplVersion="2"
|
||||
SuplMinorVersion="0"
|
||||
SuplOtdoaCapable="true"
|
||||
SuplOtdoaCapable2="true"
|
||||
SuplGlonassCapable = "true"
|
||||
SuplGalileoCapable = "true"
|
||||
SuplBdsCapable = "true"
|
||||
SuplMgpsCapable = "true"
|
||||
|
||||
RtoEnable="true"
|
||||
RtiEnable="true"
|
||||
HttpSyncLto="true"
|
||||
LtoFileName="lto2.dat"
|
||||
LtoDir="/data/vendor/gps/"
|
||||
LtoSyncThresholdDays="1"
|
||||
|
||||
GnssYearOfHardware="2020"
|
||||
CpGuardTimeSec="1"
|
||||
CpLppGuardTimeSec="1"
|
||||
IgnoreInjectedSystemTime="true"
|
||||
|
||||
AttributionAppPkgName="com.google.android.carrierlocation"
|
||||
|
||||
AssertEnabled="true"
|
||||
CpLppeCancelDbhOnAgnssProvideLoc="true"
|
||||
CpLppeUseAgnssLocForEmptyDbh="true"
|
||||
ReAidingOnHotStart="false"
|
||||
ReAidingIntervalSec="1200"
|
||||
PpsDevice="/sys/class/pps/pps0/assert_elapsed"
|
||||
/>
|
||||
|
||||
<gll
|
||||
PpsEnable="true"
|
||||
LogPriMask="LOG_INFO"
|
||||
LogFacMask="LOG_NMEA | LOG_GLLIOS | LOG_GLLAPI"
|
||||
FrqPlan="FRQ_PLAN_26MHZ_2PPM_49_152MHZ_300PPB"
|
||||
MultiCarrRFMode="GL_MULTI_CARR_RF_MODE_L1_L5"
|
||||
MultiCarrLnaMask="L1_EXT_ON|L5_EXT_ON"
|
||||
RfType="GL_RF_4776_BRCM"
|
||||
ExtL5Bias="10.6"
|
||||
EnableFilteringForLTEB13="true"
|
||||
|
||||
WarmStandbyTimeout1Seconds="10"
|
||||
WarmStandbyTimeout2Seconds="15"
|
||||
|
||||
EnableGnssPropagateInStandby="true"
|
||||
|
||||
RfPathLossDb_Ap="4.1"
|
||||
RfPathLossDb_Cp="4.1"
|
||||
RfPathLossDb_Ap_L5="4"
|
||||
RfPathLossDb_Cp_L5="4"
|
||||
OnChipGpsCarrierType="3,2,3,3,2,3,2,3,3,3,1,2,1,3,2,1,2,3,1,1,1,1,3,3,3,3,3,1,2,3,2,3"
|
||||
|
||||
EnableOnChipStopNotification="2"
|
||||
PowerMode="3"
|
||||
MinGpsWeekNumber="2216"
|
||||
/>
|
||||
|
||||
<gll_features
|
||||
EnableNicAutoSwitch="true"
|
||||
EnableNavic="true"
|
||||
/>
|
||||
|
||||
</glgps>
|
||||
|
|
@ -1,98 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<glgps xmlns="http://www.glpals.com/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.glpals.com/ glconfig.xsd" >
|
||||
<hal
|
||||
PortName="/dev/ttyBCM"
|
||||
BaudRate="921600"
|
||||
GpioNStdbyPath="/sys/devices/platform/10940000.spi/spi_master/spi5/spi5.0/nstandby"
|
||||
CustGpioDelayMs="250"
|
||||
LogEnabled="false"
|
||||
Log="JAVA"
|
||||
LogDirectory="/sdcard/gps/broadcom/storage/"
|
||||
CtrlPipe="/data/vendor/gps/glgpsctrl"
|
||||
NmeaOutName="/data/vendor/gps/nmea_out"
|
||||
|
||||
acSuplServer="supl.google.com"
|
||||
SuplPort="7275"
|
||||
SuplLogEnable="false"
|
||||
SuplLogFullName="/data/vendor/gps/suplflow.txt"
|
||||
tlsEnable="true"
|
||||
|
||||
SuplSslMethod="SSLv23_NO_TLSv1_2"
|
||||
SuplEnable="true"
|
||||
SuplUseApn="false"
|
||||
SuplUseApnNI="true"
|
||||
SuplDummyCellInfo="true"
|
||||
SuplUseFwCellInfo="false"
|
||||
SuplTlsCertDirPath="/etc/security/cacerts"
|
||||
SuplTlsCertPath="/vendor/etc/gnss/gps.cer"
|
||||
SuplUT1Seconds="20"
|
||||
SuplUT2Seconds="20"
|
||||
SuplUT3Seconds="20"
|
||||
TcpConnectionTimeout="20"
|
||||
SuplLppCapable="true"
|
||||
SuplEcidCapable="true"
|
||||
SuplVersion="2"
|
||||
SuplMinorVersion="0"
|
||||
SuplOtdoaCapable="true"
|
||||
SuplOtdoaCapable2="true"
|
||||
SuplGlonassCapable = "true"
|
||||
SuplGalileoCapable = "true"
|
||||
SuplBdsCapable = "true"
|
||||
SuplMgpsCapable = "true"
|
||||
|
||||
RtoEnable="true"
|
||||
RtiEnable="true"
|
||||
HttpSyncLto="true"
|
||||
LtoFileName="lto2.dat"
|
||||
LtoDir="/data/vendor/gps/"
|
||||
LtoSyncThresholdDays="1"
|
||||
|
||||
GnssYearOfHardware="2020"
|
||||
CpGuardTimeSec="1"
|
||||
CpLppGuardTimeSec="1"
|
||||
IgnoreInjectedSystemTime="true"
|
||||
|
||||
AttributionAppPkgName="com.google.android.carrierlocation"
|
||||
|
||||
AssertEnabled="false"
|
||||
CpLppeCancelDbhOnAgnssProvideLoc="true"
|
||||
CpLppeUseAgnssLocForEmptyDbh="true"
|
||||
ReAidingOnHotStart="false"
|
||||
ReAidingIntervalSec="1200"
|
||||
PpsDevice="/sys/class/pps/pps0/assert_elapsed"
|
||||
/>
|
||||
|
||||
<gll
|
||||
PpsEnable="true"
|
||||
LogPriMask="LOG_INFO"
|
||||
LogFacMask="LOG_NMEA | LOG_GLLIOS | LOG_GLLAPI"
|
||||
FrqPlan="FRQ_PLAN_26MHZ_2PPM_49_152MHZ_300PPB"
|
||||
MultiCarrRFMode="GL_MULTI_CARR_RF_MODE_L1_L5"
|
||||
MultiCarrLnaMask="L1_EXT_ON|L5_EXT_ON"
|
||||
RfType="GL_RF_4776_BRCM"
|
||||
ExtL5Bias="13.0"
|
||||
EnableFilteringForLTEB13="true"
|
||||
|
||||
WarmStandbyTimeout1Seconds="10"
|
||||
WarmStandbyTimeout2Seconds="15"
|
||||
|
||||
EnableGnssPropagateInStandby="true"
|
||||
|
||||
RfPathLossDb_Ap="3.5"
|
||||
RfPathLossDb_Cp="3.5"
|
||||
RfPathLossDb_Ap_L5="3.5"
|
||||
RfPathLossDb_Cp_L5="3.5"
|
||||
OnChipGpsCarrierType="3,2,3,3,2,3,2,3,3,3,1,2,1,3,2,1,2,3,1,1,1,1,3,3,3,3,3,1,2,3,2,3"
|
||||
|
||||
EnableOnChipStopNotification="false"
|
||||
PowerMode="3"
|
||||
MinGpsWeekNumber="2216"
|
||||
/>
|
||||
|
||||
<gll_features
|
||||
EnableNicAutoSwitch="true"
|
||||
EnableNavic="true"
|
||||
/>
|
||||
|
||||
</glgps>
|
||||
|
|
@ -1,98 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<glgps xmlns="http://www.glpals.com/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.glpals.com/ glconfig.xsd" >
|
||||
<hal
|
||||
PortName="/dev/ttyBCM"
|
||||
BaudRate="921600"
|
||||
GpioNStdbyPath="/sys/devices/platform/10940000.spi/spi_master/spi5/spi5.0/nstandby"
|
||||
CustGpioDelayMs="250"
|
||||
LogEnabled="false"
|
||||
Log="JAVA"
|
||||
LogDirectory="/sdcard/gps/broadcom/storage/"
|
||||
CtrlPipe="/data/vendor/gps/glgpsctrl"
|
||||
NmeaOutName="/data/vendor/gps/nmea_out"
|
||||
|
||||
acSuplServer="supl.google.com"
|
||||
SuplPort="7275"
|
||||
SuplLogEnable="false"
|
||||
SuplLogFullName="/data/vendor/gps/suplflow.txt"
|
||||
tlsEnable="true"
|
||||
|
||||
SuplSslMethod="SSLv23_NO_TLSv1_2"
|
||||
SuplEnable="true"
|
||||
SuplUseApn="false"
|
||||
SuplUseApnNI="true"
|
||||
SuplDummyCellInfo="true"
|
||||
SuplUseFwCellInfo="false"
|
||||
SuplTlsCertDirPath="/etc/security/cacerts"
|
||||
SuplTlsCertPath="/vendor/etc/gnss/gps.cer"
|
||||
SuplUT1Seconds="20"
|
||||
SuplUT2Seconds="20"
|
||||
SuplUT3Seconds="20"
|
||||
TcpConnectionTimeout="20"
|
||||
SuplLppCapable="true"
|
||||
SuplEcidCapable="true"
|
||||
SuplVersion="2"
|
||||
SuplMinorVersion="0"
|
||||
SuplOtdoaCapable="true"
|
||||
SuplOtdoaCapable2="true"
|
||||
SuplGlonassCapable = "true"
|
||||
SuplGalileoCapable = "true"
|
||||
SuplBdsCapable = "true"
|
||||
SuplMgpsCapable = "true"
|
||||
|
||||
RtoEnable="true"
|
||||
RtiEnable="true"
|
||||
HttpSyncLto="true"
|
||||
LtoFileName="lto2.dat"
|
||||
LtoDir="/data/vendor/gps/"
|
||||
LtoSyncThresholdDays="1"
|
||||
|
||||
GnssYearOfHardware="2020"
|
||||
CpGuardTimeSec="1"
|
||||
CpLppGuardTimeSec="1"
|
||||
IgnoreInjectedSystemTime="true"
|
||||
|
||||
AttributionAppPkgName="com.google.android.carrierlocation"
|
||||
|
||||
AssertEnabled="false"
|
||||
CpLppeCancelDbhOnAgnssProvideLoc="true"
|
||||
CpLppeUseAgnssLocForEmptyDbh="true"
|
||||
ReAidingOnHotStart="false"
|
||||
ReAidingIntervalSec="1200"
|
||||
PpsDevice="/sys/class/pps/pps0/assert_elapsed"
|
||||
/>
|
||||
|
||||
<gll
|
||||
PpsEnable="true"
|
||||
LogPriMask="LOG_INFO"
|
||||
LogFacMask="LOG_NMEA | LOG_GLLIOS | LOG_GLLAPI"
|
||||
FrqPlan="FRQ_PLAN_26MHZ_2PPM_49_152MHZ_300PPB"
|
||||
MultiCarrRFMode="GL_MULTI_CARR_RF_MODE_L1_L5"
|
||||
MultiCarrLnaMask="L1_EXT_ON|L5_EXT_ON"
|
||||
RfType="GL_RF_4776_BRCM"
|
||||
ExtL5Bias="9.3"
|
||||
EnableFilteringForLTEB13="true"
|
||||
|
||||
WarmStandbyTimeout1Seconds="10"
|
||||
WarmStandbyTimeout2Seconds="15"
|
||||
|
||||
EnableGnssPropagateInStandby="true"
|
||||
|
||||
RfPathLossDb_Ap="4.2"
|
||||
RfPathLossDb_Cp="4.2"
|
||||
RfPathLossDb_Ap_L5="4.1"
|
||||
RfPathLossDb_Cp_L5="4.1"
|
||||
OnChipGpsCarrierType="3,2,3,3,2,3,2,3,3,3,1,2,1,3,2,1,2,3,1,1,1,1,3,3,3,3,3,1,2,3,2,3"
|
||||
|
||||
EnableOnChipStopNotification="false"
|
||||
PowerMode="3"
|
||||
MinGpsWeekNumber="2216"
|
||||
/>
|
||||
|
||||
<gll_features
|
||||
EnableNicAutoSwitch="true"
|
||||
EnableNavic="true"
|
||||
/>
|
||||
|
||||
</glgps>
|
||||
|
|
@ -1,98 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<glgps xmlns="http://www.glpals.com/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.glpals.com/ glconfig.xsd" >
|
||||
<hal
|
||||
PortName="/dev/ttyBCM"
|
||||
BaudRate="921600"
|
||||
GpioNStdbyPath="/sys/devices/platform/10940000.spi/spi_master/spi5/spi5.0/nstandby"
|
||||
CustGpioDelayMs="250"
|
||||
LogEnabled="false"
|
||||
Log="JAVA"
|
||||
LogDirectory="/sdcard/gps/broadcom/storage/"
|
||||
CtrlPipe="/data/vendor/gps/glgpsctrl"
|
||||
NmeaOutName="/data/vendor/gps/nmea_out"
|
||||
|
||||
acSuplServer="supl.google.com"
|
||||
SuplPort="7275"
|
||||
SuplLogEnable="false"
|
||||
SuplLogFullName="/data/vendor/gps/suplflow.txt"
|
||||
tlsEnable="true"
|
||||
|
||||
SuplSslMethod="SSLv23_NO_TLSv1_2"
|
||||
SuplEnable="true"
|
||||
SuplUseApn="false"
|
||||
SuplUseApnNI="true"
|
||||
SuplDummyCellInfo="true"
|
||||
SuplUseFwCellInfo="false"
|
||||
SuplTlsCertDirPath="/etc/security/cacerts"
|
||||
SuplTlsCertPath="/vendor/etc/gnss/gps.cer"
|
||||
SuplUT1Seconds="20"
|
||||
SuplUT2Seconds="20"
|
||||
SuplUT3Seconds="20"
|
||||
TcpConnectionTimeout="20"
|
||||
SuplLppCapable="true"
|
||||
SuplEcidCapable="true"
|
||||
SuplVersion="2"
|
||||
SuplMinorVersion="0"
|
||||
SuplOtdoaCapable="true"
|
||||
SuplOtdoaCapable2="true"
|
||||
SuplGlonassCapable = "true"
|
||||
SuplGalileoCapable = "true"
|
||||
SuplBdsCapable = "true"
|
||||
SuplMgpsCapable = "true"
|
||||
|
||||
RtoEnable="true"
|
||||
RtiEnable="true"
|
||||
HttpSyncLto="true"
|
||||
LtoFileName="lto2.dat"
|
||||
LtoDir="/data/vendor/gps/"
|
||||
LtoSyncThresholdDays="1"
|
||||
|
||||
GnssYearOfHardware="2020"
|
||||
CpGuardTimeSec="1"
|
||||
CpLppGuardTimeSec="1"
|
||||
IgnoreInjectedSystemTime="true"
|
||||
|
||||
AttributionAppPkgName="com.google.android.carrierlocation"
|
||||
|
||||
AssertEnabled="false"
|
||||
CpLppeCancelDbhOnAgnssProvideLoc="true"
|
||||
CpLppeUseAgnssLocForEmptyDbh="true"
|
||||
ReAidingOnHotStart="false"
|
||||
ReAidingIntervalSec="1200"
|
||||
PpsDevice="/sys/class/pps/pps0/assert_elapsed"
|
||||
/>
|
||||
|
||||
<gll
|
||||
PpsEnable="true"
|
||||
LogPriMask="LOG_INFO"
|
||||
LogFacMask="LOG_NMEA | LOG_GLLIOS | LOG_GLLAPI"
|
||||
FrqPlan="FRQ_PLAN_26MHZ_2PPM_49_152MHZ_300PPB"
|
||||
MultiCarrRFMode="GL_MULTI_CARR_RF_MODE_L1_L5"
|
||||
MultiCarrLnaMask="L1_EXT_ON|L5_EXT_ON"
|
||||
RfType="GL_RF_4776_BRCM"
|
||||
ExtL5Bias="10.6"
|
||||
EnableFilteringForLTEB13="true"
|
||||
|
||||
WarmStandbyTimeout1Seconds="10"
|
||||
WarmStandbyTimeout2Seconds="15"
|
||||
|
||||
EnableGnssPropagateInStandby="true"
|
||||
|
||||
RfPathLossDb_Ap="4.1"
|
||||
RfPathLossDb_Cp="4.1"
|
||||
RfPathLossDb_Ap_L5="4"
|
||||
RfPathLossDb_Cp_L5="4"
|
||||
OnChipGpsCarrierType="3,2,3,3,2,3,2,3,3,3,1,2,1,3,2,1,2,3,1,1,1,1,3,3,3,3,3,1,2,3,2,3"
|
||||
|
||||
EnableOnChipStopNotification="false"
|
||||
PowerMode="3"
|
||||
MinGpsWeekNumber="2216"
|
||||
/>
|
||||
|
||||
<gll_features
|
||||
EnableNicAutoSwitch="true"
|
||||
EnableNavic="true"
|
||||
/>
|
||||
|
||||
</glgps>
|
||||
|
File diff suppressed because it is too large
Load diff
|
@ -1,40 +0,0 @@
|
|||
# Copyright (C) 2010 The Android Open Source Project
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
|
||||
# We're moving the emulator-specific platform libs to
|
||||
# development.git/tools/emulator/. The following test is to ensure
|
||||
# smooth builds even if the tree contains both versions.
|
||||
#
|
||||
|
||||
ifeq ($(BOARD_USES_EXYNOS_GNSS_DUMMY), true)
|
||||
|
||||
LOCAL_PATH := $(call my-dir)
|
||||
|
||||
# HAL module implemenation stored in
|
||||
# hw/<GPS_HARDWARE_MODULE_ID>.<ro.hardware>.so
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
LOCAL_MODULE_RELATIVE_PATH := hw
|
||||
LOCAL_SHARED_LIBRARIES := liblog libcutils libhardware
|
||||
LOCAL_SRC_FILES := gps_dummy.c
|
||||
LOCAL_MODULE := gps.$(TARGET_BOARD_PLATFORM)
|
||||
LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0
|
||||
LOCAL_LICENSE_CONDITIONS := notice
|
||||
LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../NOTICE
|
||||
LOCAL_PROPRIETARY_MODULE := true
|
||||
|
||||
include $(BUILD_SHARED_LIBRARY)
|
||||
|
||||
endif
|
|
@ -1,49 +0,0 @@
|
|||
PRODUCT_COPY_FILES += \
|
||||
frameworks/native/data/etc/android.hardware.location.gps.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.location.gps.xml \
|
||||
device/google/gs101/gnss/47765/config/gps.cer:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.cer \
|
||||
device/google/gs101/gnss/47765/firmware/SensorHub.patch:$(TARGET_COPY_OUT_VENDOR)/firmware/SensorHub.patch
|
||||
|
||||
ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/google/gs101/gnss/47765/config/lhd.conf:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/lhd.conf \
|
||||
device/google/gs101/gnss/47765/config/scd.conf:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/scd.conf
|
||||
else
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/google/gs101/gnss/47765/config/lhd_user.conf:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/lhd.conf \
|
||||
device/google/gs101/gnss/47765/config/scd_user.conf:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/scd.conf
|
||||
endif
|
||||
|
||||
ifneq (,$(filter raven, $(subst _, ,$(TARGET_PRODUCT))))
|
||||
ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
|
||||
PRODUCT_COPY_FILES += device/google/gs101/gnss/47765/config/gps.xml.raven:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml
|
||||
else
|
||||
PRODUCT_COPY_FILES += device/google/gs101/gnss/47765/config/gps_user.xml.raven:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml
|
||||
endif
|
||||
else ifneq (,$(filter oriole, $(subst _, ,$(TARGET_PRODUCT))))
|
||||
ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
|
||||
PRODUCT_COPY_FILES += device/google/gs101/gnss/47765/config/gps.xml.oriole:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml
|
||||
else
|
||||
PRODUCT_COPY_FILES += device/google/gs101/gnss/47765/config/gps_user.xml.oriole:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml
|
||||
endif
|
||||
else ifneq (,$(filter slider whitefin, $(subst _, ,$(TARGET_PRODUCT))))
|
||||
ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
|
||||
PRODUCT_COPY_FILES += device/google/gs101/gnss/47765/config/gps.xml:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml
|
||||
else
|
||||
PRODUCT_COPY_FILES += device/google/gs101/gnss/47765/config/gps_user.xml:$(TARGET_COPY_OUT_VENDOR)/etc/gnss/gps.xml
|
||||
endif
|
||||
endif
|
||||
|
||||
PRODUCT_SOONG_NAMESPACES += \
|
||||
device/google/gs101/gnss/47765
|
||||
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.gnss@2.1-impl-google \
|
||||
gps.default \
|
||||
flp.default \
|
||||
gpsd \
|
||||
lhd \
|
||||
scd \
|
||||
android.hardware.gnss@2.1-service-brcm
|
||||
|
||||
PRODUCT_PACKAGES_DEBUG += \
|
||||
init.gps_log.rc
|
158
gnss/gps_dummy.c
158
gnss/gps_dummy.c
|
@ -1,158 +0,0 @@
|
|||
/*
|
||||
* Copyright (C) 2010 The Android Open Source Project
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* this implements a GPS hardware library for the Android emulator.
|
||||
* the following code should be built as a shared library that will be
|
||||
* placed into /system/lib/hw/gps.goldfish.so
|
||||
*
|
||||
* it will be loaded by the code in hardware/libhardware/hardware.c
|
||||
* which is itself called from android_location_GpsLocationProvider.cpp
|
||||
*/
|
||||
|
||||
|
||||
#include <errno.h>
|
||||
#include <pthread.h>
|
||||
#include <fcntl.h>
|
||||
#include <sys/epoll.h>
|
||||
#include <math.h>
|
||||
#include <time.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#define LOG_TAG "gps_dummy"
|
||||
#include <log/log.h>
|
||||
//#include <cutils/sockets.h>
|
||||
#include <hardware/gps.h>
|
||||
|
||||
#define GPS_DEBUG 0
|
||||
|
||||
#if GPS_DEBUG
|
||||
# define D(...) ALOGD(__VA_ARGS__)
|
||||
#else
|
||||
# define D(...) ((void)0)
|
||||
#endif
|
||||
|
||||
static int
|
||||
dummy_gps_init(GpsCallbacks* callbacks)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void
|
||||
dummy_gps_cleanup(void)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
static int
|
||||
dummy_gps_start()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
static int
|
||||
dummy_gps_stop()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
static int
|
||||
dummy_gps_inject_time(GpsUtcTime __unused time,
|
||||
int64_t __unused timeReference,
|
||||
int __unused uncertainty)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int
|
||||
dummy_gps_inject_location(double __unused latitude,
|
||||
double __unused longitude,
|
||||
float __unused accuracy)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void
|
||||
dummy_gps_delete_aiding_data(GpsAidingData __unused flags)
|
||||
{
|
||||
}
|
||||
|
||||
static int dummy_gps_set_position_mode(GpsPositionMode __unused mode,
|
||||
GpsPositionRecurrence __unused recurrence,
|
||||
uint32_t __unused min_interval,
|
||||
uint32_t __unused preferred_accuracy,
|
||||
uint32_t __unused preferred_time)
|
||||
{
|
||||
// FIXME - support fix_frequency
|
||||
return 0;
|
||||
}
|
||||
|
||||
static const void*
|
||||
dummy_gps_get_extension(const char* __unused name)
|
||||
{
|
||||
// no extensions supported
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static const GpsInterface dummyGpsInterface = {
|
||||
sizeof(GpsInterface),
|
||||
dummy_gps_init,
|
||||
dummy_gps_start,
|
||||
dummy_gps_stop,
|
||||
dummy_gps_cleanup,
|
||||
dummy_gps_inject_time,
|
||||
dummy_gps_inject_location,
|
||||
dummy_gps_delete_aiding_data,
|
||||
dummy_gps_set_position_mode,
|
||||
dummy_gps_get_extension,
|
||||
};
|
||||
|
||||
const GpsInterface* gps__get_gps_interface(struct gps_device_t* __unused dev)
|
||||
{
|
||||
return &dummyGpsInterface;
|
||||
}
|
||||
|
||||
static int open_gps(const struct hw_module_t* module,
|
||||
char const* __unused name,
|
||||
struct hw_device_t** device)
|
||||
{
|
||||
struct gps_device_t *dev = (struct gps_device_t *)malloc(sizeof(struct gps_device_t));
|
||||
memset(dev, 0, sizeof(*dev));
|
||||
|
||||
dev->common.tag = HARDWARE_DEVICE_TAG;
|
||||
dev->common.version = 0;
|
||||
dev->common.module = (struct hw_module_t*)module;
|
||||
dev->get_gps_interface = gps__get_gps_interface;
|
||||
|
||||
*device = (struct hw_device_t*)dev;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct hw_module_methods_t gps_module_methods = {
|
||||
.open = open_gps
|
||||
};
|
||||
|
||||
struct hw_module_t HAL_MODULE_INFO_SYM = {
|
||||
.tag = HARDWARE_MODULE_TAG,
|
||||
.version_major = 1,
|
||||
.version_minor = 0,
|
||||
.id = GPS_HARDWARE_MODULE_ID,
|
||||
.name = "Dummy GPS Module",
|
||||
.author = "The Android Open Source Project",
|
||||
.methods = &gps_module_methods,
|
||||
};
|
22
init.display.sh
Executable file
22
init.display.sh
Executable file
|
@ -0,0 +1,22 @@
|
|||
#!/vendor/bin/sh
|
||||
modules_dir=
|
||||
|
||||
for f in /vendor/lib/modules/*/modules.dep /vendor/lib/modules/modules.dep; do
|
||||
if [[ -f "$f" ]]; then
|
||||
modules_dir="$(dirname "$f")"
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if [[ -z "${modules_dir}" ]]; then
|
||||
echo "Unable to locate kernel modules directory" 2>&1
|
||||
exit 1
|
||||
fi
|
||||
|
||||
panel_drv=`getprop ro.boot.primary_panel_drv`
|
||||
if [[ -z "$panel_drv" ]]; then
|
||||
panel_drv="panel-samsung-emul"
|
||||
fi
|
||||
modprobe -d "${modules_dir}" exynos-drm.ko
|
||||
modprobe -d "${modules_dir}" $panel_drv.ko
|
||||
|
|
@ -1,12 +0,0 @@
|
|||
####################################################
|
||||
# init.insmod.common.cfg #
|
||||
# This file contains common kernel modules to load #
|
||||
# at init time by init.insmod.sh script #
|
||||
####################################################
|
||||
|
||||
# Load common kernel modules
|
||||
# Modules here will be loaded *before* device specific modules
|
||||
install_display_drivers
|
||||
modprobe|-b *
|
||||
# All common modules loaded
|
||||
setprop|vendor.common.modules.ready
|
|
@ -1,78 +0,0 @@
|
|||
#!/vendor/bin/sh
|
||||
|
||||
#############################################################
|
||||
### init.insmod.cfg format: ###
|
||||
### ----------------------------------------------------- ###
|
||||
### [insmod|setprop|enable/moprobe|wait] [path|prop name] ###
|
||||
### ... ###
|
||||
#############################################################
|
||||
|
||||
modules_dir=
|
||||
|
||||
for f in /vendor/lib/modules/*/modules.dep /vendor/lib/modules/modules.dep; do
|
||||
if [[ -f "$f" ]]; then
|
||||
modules_dir="$(dirname "$f")"
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if [[ -z "${modules_dir}" ]]; then
|
||||
echo "Unable to locate kernel modules directory" 2>&1
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# imitates wait_for_file() in init
|
||||
wait_for_file()
|
||||
{
|
||||
filename="${1}"
|
||||
timeout="${2:-5}"
|
||||
|
||||
expiry=$(($(date "+%s")+timeout))
|
||||
while [[ ! -e "${filename}" ]] && [[ "$(date "+%s")" -le "${expiry}" ]]
|
||||
do
|
||||
sleep 0.01
|
||||
done
|
||||
}
|
||||
|
||||
install_display_drivers()
|
||||
{
|
||||
panel_drv=`getprop ro.boot.primary_panel_drv`
|
||||
if [[ -z "$panel_drv" ]]; then
|
||||
panel_drv="panel-samsung-emul"
|
||||
fi
|
||||
modprobe -d "${modules_dir}" exynos-drm.ko
|
||||
modprobe -d "${modules_dir}" $panel_drv.ko
|
||||
}
|
||||
|
||||
if [ $# -eq 1 ]; then
|
||||
cfg_file=$1
|
||||
else
|
||||
# Set property even if there is no insmod config
|
||||
# to unblock early-boot trigger
|
||||
setprop vendor.common.modules.ready
|
||||
setprop vendor.device.modules.ready
|
||||
setprop vendor.all.modules.ready
|
||||
setprop vendor.all.devices.ready
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -f $cfg_file ]; then
|
||||
while IFS="|" read -r action arg
|
||||
do
|
||||
case $action in
|
||||
"insmod") insmod $arg ;;
|
||||
"setprop") setprop $arg 1 ;;
|
||||
"enable") echo 1 > $arg ;;
|
||||
"modprobe")
|
||||
case ${arg} in
|
||||
"-b *" | "-b")
|
||||
arg="-b --all=${modules_dir}/modules.load" ;;
|
||||
"*" | "")
|
||||
arg="--all=${modules_dir}/modules.load" ;;
|
||||
esac
|
||||
modprobe -a -d "${modules_dir}" $arg ;;
|
||||
"wait") wait_for_file $arg ;;
|
||||
"install_display_drivers") install_display_drivers ;;
|
||||
esac
|
||||
done < $cfg_file
|
||||
fi
|
100
manifest.xml
100
manifest.xml
|
@ -1,31 +1,4 @@
|
|||
<manifest version="1.0" type="device" target-level="6">
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.audio</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>7.1</version>
|
||||
<interface>
|
||||
<name>IDevicesFactory</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.audio.effect</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>7.0</version>
|
||||
<interface>
|
||||
<name>IEffectsFactory</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.soundtrigger</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>2.3</version>
|
||||
<interface>
|
||||
<name>ISoundTriggerHw</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.media.omx</name>
|
||||
<transport>hwbinder</transport>
|
||||
|
@ -57,24 +30,6 @@
|
|||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format = "hidl">
|
||||
<name>android.hardware.dumpstate</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.1</version>
|
||||
<interface>
|
||||
<name>IDumpstateDevice</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.bluetooth</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.1</version>
|
||||
<interface>
|
||||
<name>IBluetoothHci</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.boot</name>
|
||||
<transport>hwbinder</transport>
|
||||
|
@ -92,64 +47,11 @@
|
|||
</hal>
|
||||
<hal format="aidl">
|
||||
<name>com.google.input</name>
|
||||
<version>2</version>
|
||||
<interface>
|
||||
<name>ITouchContextService</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>hardware.google.bluetooth.bt_channel_avoidance</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IBTChannelAvoidance</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>hardware.google.bluetooth.ext</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IBluetoothExt</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>hardware.google.bluetooth.sar</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.1</version>
|
||||
<interface>
|
||||
<name>IBluetoothSar</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>hardware.google.bluetooth.ccc</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.1</version>
|
||||
<interface>
|
||||
<name>IBluetoothCcc</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.google.whitechapel.audio.audioext</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>4.0</version>
|
||||
<interface>
|
||||
<name>IAudioExt</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.google.audiometricext</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IAudioMetricExt</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<kernel target-level="6"/>
|
||||
</manifest>
|
||||
|
|
|
@ -1,31 +1,4 @@
|
|||
<manifest version="1.0" type="device" target-level="5">
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.audio</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>7.1</version>
|
||||
<interface>
|
||||
<name>IDevicesFactory</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.audio.effect</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>7.0</version>
|
||||
<interface>
|
||||
<name>IEffectsFactory</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.soundtrigger</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>2.3</version>
|
||||
<interface>
|
||||
<name>ISoundTriggerHw</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.graphics.mapper</name>
|
||||
<transport arch="32+64">passthrough</transport>
|
||||
|
@ -44,24 +17,6 @@
|
|||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format = "hidl">
|
||||
<name>android.hardware.dumpstate</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.1</version>
|
||||
<interface>
|
||||
<name>IDumpstateDevice</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.bluetooth</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.1</version>
|
||||
<interface>
|
||||
<name>IBluetoothHci</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.boot</name>
|
||||
<transport>hwbinder</transport>
|
||||
|
@ -84,55 +39,11 @@
|
|||
</hal>
|
||||
<hal format="aidl">
|
||||
<name>com.google.input</name>
|
||||
<version>2</version>
|
||||
<interface>
|
||||
<name>ITouchContextService</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>hardware.google.bluetooth.bt_channel_avoidance</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IBTChannelAvoidance</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>hardware.google.bluetooth.sar</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.1</version>
|
||||
<interface>
|
||||
<name>IBluetoothSar</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>hardware.google.bluetooth.ccc</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.1</version>
|
||||
<interface>
|
||||
<name>IBluetoothCcc</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.google.whitechapel.audio.audioext</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>4.0</version>
|
||||
<interface>
|
||||
<name>IAudioExt</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.google.audiometricext</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IAudioMetricExt</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<kernel target-level="6"/>
|
||||
</manifest>
|
||||
|
|
|
@ -47,11 +47,11 @@
|
|||
<Feature name="can-swap-width-height" value="1" />
|
||||
</MediaCodec>
|
||||
<MediaCodec name="c2.exynos.hevc.decoder" type="video/hevc" >
|
||||
<Limit name="size" min="64x64" max="3840x2160" />
|
||||
<Limit name="size" min="64x64" max="3840x2176" />
|
||||
<Limit name="alignment" value="2x2" />
|
||||
<Limit name="block-size" value="16x16" />
|
||||
<Limit name="block-count" range="1-32400" />
|
||||
<Limit name="blocks-per-second" min="1" max="3888000" />
|
||||
<Limit name="block-count" range="1-32640" />
|
||||
<Limit name="blocks-per-second" min="1" max="3916800" />
|
||||
<Limit name="bitrate" range="1-120000000" />
|
||||
<Limit name="performance-point-1280x720" range="240" />
|
||||
<Limit name="performance-point-3840x2160" range="120" />
|
||||
|
@ -166,10 +166,11 @@
|
|||
<Limit name="performance-point-1280x720" range="240" />
|
||||
<Limit name="performance-point-3840x2160" range="120" />
|
||||
<Limit name="concurrent-instances" max="16" />
|
||||
<Limit name="quality" range="0-100" default="57" />
|
||||
<Feature name="can-swap-width-height" value="1" />
|
||||
<Feature name="vq-minimum-quality"/>
|
||||
<Feature name="qp-bounds"/>
|
||||
<Feature name="bitrate-modes" value="VBR,CBR,CBR-FD" />
|
||||
<Feature name="bitrate-modes" value="VBR,CBR,CQ,CBR-FD" />
|
||||
</MediaCodec>
|
||||
<MediaCodec name="c2.exynos.mpeg4.encoder" type="video/mp4v-es">
|
||||
<Limit name="size" min="32x32" max="2048x2048" />
|
||||
|
|
|
@ -142,38 +142,37 @@
|
|||
<Limit name="measured-frame-rate-1920x1080" range="38-41" /> <!-- v90%=1.0 -->
|
||||
</MediaCodec>
|
||||
<MediaCodec name="c2.android.vp9.decoder" type="video/x-vnd.on2.vp9" update="true">
|
||||
<!-- measured 90%:440-463 med:441 N=2 -->
|
||||
<Limit name="measured-frame-rate-320x180" range="440-452" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:232-234 med:233 N=2 -->
|
||||
<Limit name="measured-frame-rate-640x360" range="232-233" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:63-64 med:63 N=2 -->
|
||||
<Limit name="measured-frame-rate-1280x720" range="63-63" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:39-40 med:39 N=2 -->
|
||||
<Limit name="measured-frame-rate-1920x1080" range="39-40" /> <!-- v90%=1.0 -->
|
||||
<Limit name="measured-frame-rate-320x180" range="951-1032" />
|
||||
<Limit name="measured-frame-rate-640x360" range="324-374" />
|
||||
<Limit name="measured-frame-rate-1280x720" range="128-131" />
|
||||
<Limit name="measured-frame-rate-1920x1080" range="65-75" />
|
||||
</MediaCodec>
|
||||
<MediaCodec name="c2.google.av1.decoder" type="video/av01" update="true">
|
||||
<!-- measured 90%:295-301 med:296 N=2 -->
|
||||
<Limit name="measured-frame-rate-352x288" range="295-298" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:196-207 med:196 N=2 -->
|
||||
<Limit name="measured-frame-rate-640x360" range="196-201" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:177-180 med:178 N=2 -->
|
||||
<Limit name="measured-frame-rate-720x480" range="177-178" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:81-82 med:82 N=2 -->
|
||||
<Limit name="measured-frame-rate-1280x720" range="81-82" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:45-47 med:46 N=2 -->
|
||||
<Limit name="measured-frame-rate-1920x1080" range="45-46" /> <!-- v90%=1.0 -->
|
||||
<Limit name="measured-frame-rate-352x288" range="410-416" /> <!-- N=20 v90%=1.7 -->
|
||||
<!-- measured 90%:251-660 med:361 SLOW -->
|
||||
<Limit name="measured-frame-rate-640x360" range="361-407" /> <!-- N=20 v90%=1.6 -->
|
||||
<!-- measured 90%:250-684 med:366 SLOW -->
|
||||
<Limit name="measured-frame-rate-720x480" range="366-414" /> <!-- N=20 v90%=1.7 -->
|
||||
<Limit name="measured-frame-rate-1280x720" range="252-259" /> <!-- N=22 v90%=1.1 -->
|
||||
<Limit name="measured-frame-rate-1920x1080" range="210-213" /> <!-- N=20 v90%=1.1 -->
|
||||
</MediaCodec>
|
||||
<MediaCodec name="c2.google.av1.decoder.secure" type="video/av01" update="true">
|
||||
<!-- measured 90%:295-301 med:296 N=2 -->
|
||||
<Limit name="measured-frame-rate-352x288" range="295-298" /> <!-- v90%=1.0 -->
|
||||
<Limit name="measured-frame-rate-352x288" range="410-416" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:196-207 med:196 N=2 -->
|
||||
<Limit name="measured-frame-rate-640x360" range="196-201" /> <!-- v90%=1.0 -->
|
||||
<Limit name="measured-frame-rate-640x360" range="361-407" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:177-180 med:178 N=2 -->
|
||||
<Limit name="measured-frame-rate-720x480" range="177-178" /> <!-- v90%=1.0 -->
|
||||
<Limit name="measured-frame-rate-720x480" range="366-414" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:81-82 med:82 N=2 -->
|
||||
<Limit name="measured-frame-rate-1280x720" range="81-82" /> <!-- v90%=1.0 -->
|
||||
<Limit name="measured-frame-rate-1280x720" range="252-259" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:45-47 med:46 N=2 -->
|
||||
<Limit name="measured-frame-rate-1920x1080" range="45-46" /> <!-- v90%=1.0 -->
|
||||
<Limit name="measured-frame-rate-1920x1080" range="210-213" /> <!-- v90%=1.0 -->
|
||||
</MediaCodec>
|
||||
<MediaCodec name="c2.android.av1.decoder" type="video/av01" update="true">
|
||||
<Limit name="measured-frame-rate-352x288" range="353-362" />
|
||||
<Limit name="measured-frame-rate-640x360" range="178-210" />
|
||||
<Limit name="measured-frame-rate-720x480" range="101-129" />
|
||||
<Limit name="measured-frame-rate-1280x720" range="38-40" />
|
||||
</MediaCodec>
|
||||
</Decoders>
|
||||
|
||||
|
@ -250,5 +249,13 @@
|
|||
<Limit name="measured-frame-rate-640x360" range="64-97" />
|
||||
<Limit name="measured-frame-rate-1280x720" range="16-24" />
|
||||
</MediaCodec>
|
||||
<MediaCodec name="c2.android.av1.encoder" type="video/av01" update="true">
|
||||
<!-- measured 90%:297-298 med:298 N=2 -->
|
||||
<Limit name="measured-frame-rate-320x240" range="297-298" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:65-66 med:66 N=2 -->
|
||||
<Limit name="measured-frame-rate-720x480" range="65-66" /> <!-- v90%=1.0 -->
|
||||
<!-- measured 90%:24-25 med:25 N=2 -->
|
||||
<Limit name="measured-frame-rate-1280x720" range="24-25" /> <!-- v90%=1.0 -->
|
||||
</MediaCodec>
|
||||
</Encoders>
|
||||
</MediaCodecs>
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
<!-- Doze: does this device support STATE_DOZE_SUSPEND? -->
|
||||
<bool name="doze_suspend_display_state_supported">false</bool>
|
||||
|
||||
<string name="config_rounded_mask">M21,0C19.94,0.01 18.83,0.04 17.73,0.11C16.91,0.17 16.09,0.25 15.3,0.36C14.5,0.48 13.72,0.62 12.95,0.81C11.42,1.19 9.97,1.72 8.65,2.43C7.32,3.14 6.12,4.02 5.08,5.07C4.04,6.11 3.15,7.31 2.44,8.64C1.73,9.97 1.19,11.42 0.82,12.94C0.63,13.7 0.48,14.49 0.37,15.29C0.25,16.09 0.17,16.9 0.12,17.72C0.05,18.82 0.02,19.93 0.01,21.55</string>
|
||||
<string name="config_rounded_mask" translatable="false">M21,0C19.94,0.01 18.83,0.04 17.73,0.11C16.91,0.17 16.09,0.25 15.3,0.36C14.5,0.48 13.72,0.62 12.95,0.81C11.42,1.19 9.97,1.72 8.65,2.43C7.32,3.14 6.12,4.02 5.08,5.07C4.04,6.11 3.15,7.31 2.44,8.64C1.73,9.97 1.19,11.42 0.82,12.94C0.63,13.7 0.48,14.49 0.37,15.29C0.25,16.09 0.17,16.9 0.12,17.72C0.05,18.82 0.02,19.93 0.01,21.55</string>
|
||||
|
||||
<!-- Override value to use for proximity sensor. -->
|
||||
<string name="proximity_sensor_type" translatable="false">android.sensor.light</string>
|
||||
|
|
|
@ -57,12 +57,20 @@ const struct SysfsCollector::SysfsPaths sysfs_paths = {
|
|||
UFS_ERR_PATH(auto_hibern8_err_count)
|
||||
},
|
||||
.AmsRatePath = "/sys/devices/platform/audiometrics/ams_rate_read_once",
|
||||
.TempResidencyPath = "/sys/kernel/metrics/temp_residency/temp_residency_all/stats",
|
||||
.TempResidencyAndResetPaths = {
|
||||
{
|
||||
"/sys/kernel/metrics/thermal/tr_by_group/tmu/stats",
|
||||
"/sys/kernel/metrics/thermal/tr_by_group/tmu/stats_reset"
|
||||
},
|
||||
{
|
||||
"/sys/kernel/metrics/thermal/tr_by_group/spmic/stats",
|
||||
"/sys/kernel/metrics/thermal/tr_by_group/spmic/stats_reset"
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
const struct UeventListener::UeventPaths ueventPaths = {
|
||||
.AudioUevent = "/devices/virtual/amcs/amcs",
|
||||
.WirelessChargerPtmcPath = "/sys/class/power_supply/wireless/device/ptmc_id",
|
||||
.TypeCPartnerUevent = "PRODUCT_TYPE="};
|
||||
|
||||
int main() {
|
||||
|
|
35
preinstalled-packages-product-gs101-device-debug.xml
Normal file
35
preinstalled-packages-product-gs101-device-debug.xml
Normal file
|
@ -0,0 +1,35 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Copyright 2023 The Android Open Source Project
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
-->
|
||||
<!-- System packages to preinstall on gs101 debug devices, per user type.
|
||||
Documentation at frameworks/base/data/etc/preinstalled-packages-platform.xml
|
||||
-->
|
||||
<config>
|
||||
<!-- Battery Stats Viewer (BatteryStatsViewer) -->
|
||||
<install-in-user-type package="com.android.frameworks.core.batterystatsviewer">
|
||||
<install-in user-type="FULL" />
|
||||
<install-in user-type="PROFILE" />
|
||||
<do-not-install-in user-type="android.os.usertype.profile.CLONE" />
|
||||
</install-in-user-type>
|
||||
|
||||
<!-- RCS - Rich Communication Services (TestRcsApp)
|
||||
TODO(b/259401601): Check if this should be preinstalled for SYSTEM user -->
|
||||
<install-in-user-type package="com.google.android.sample.rcsclient">
|
||||
<install-in user-type="SYSTEM" />
|
||||
<install-in user-type="FULL" />
|
||||
<install-in user-type="PROFILE" />
|
||||
<do-not-install-in user-type="android.os.usertype.profile.CLONE" />
|
||||
</install-in-user-type>
|
||||
</config>
|
|
@ -1 +1 @@
|
|||
modem_logging_control START -o /data/vendor/radio/logs/always-on -n 10 -s 20 -m /vendor/etc/modem/default.cfg --enable_exmetric --enable_exmetric_internal
|
||||
modem_logging_control START -o /data/vendor/radio/logs/always-on -n 50 -s 50 -m /vendor/etc/modem/default.cfg --enable_exmetric --enable_exmetric_internal
|
|
@ -56,6 +56,7 @@
|
|||
|
||||
<!-- True if the firmware supports connected MAC randomization -->
|
||||
<bool name="config_wifi_connected_mac_randomization_supported">true</bool>
|
||||
<bool name="config_wifiAllowNonPersistentMacRandomizationOnOpenSsids">true</bool>
|
||||
|
||||
<!-- True if the firmware supports p2p MAC randomization -->
|
||||
<bool name="config_wifi_p2p_mac_randomization_supported">true</bool>
|
||||
|
@ -144,4 +145,18 @@
|
|||
|
||||
<!-- Enable WPA2 to WPA3 auto-upgrade offload to capable Driver/Firmware -->
|
||||
<bool translatable="false" name="config_wifiSaeUpgradeOffloadEnabled">true</bool>
|
||||
|
||||
<!-- Boolean indicating whether DTIM multiplier configuration is enabled. DTIM multiplier value
|
||||
is when the system is in the suspended mode -->
|
||||
<bool translatable="false" name="config_wifiDtimMultiplierConfigEnabled">true</bool>
|
||||
|
||||
<!-- Enable the feature of adjusting link layer stats polling interval based on
|
||||
device mobility state and client mode RSSI monitoring. -->
|
||||
<bool translatable="false" name="config_wifiAdjustPollRssiIntervalEnabled">true</bool>
|
||||
|
||||
<!-- Boolean indicating whether the framework updates country from scan results when there is
|
||||
no telephony country code. This is applied to all generic cases and might require the
|
||||
regulatory approval (for example, FCC pre-approval is required according to "594280 D01
|
||||
Software Configuration Control v02r01").-->
|
||||
<bool translatable="false" name ="config_wifiUpdateCountryCodeFromScanResultGeneric">true</bool>
|
||||
</resources>
|
||||
|
|
|
@ -1,578 +0,0 @@
|
|||
/*
|
||||
* Copyright (C) 2016 The Android Open Source Project
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "sensorlist.h"
|
||||
|
||||
#include <math.h>
|
||||
|
||||
#include "hubdefs.h"
|
||||
|
||||
using namespace android;
|
||||
|
||||
const int kVersion = 1;
|
||||
|
||||
const float kMinSampleRateHzAccel = 6.250f;
|
||||
const float kMaxSampleRateHzAccel = 400.0f;
|
||||
const float kAccelRangeG = 16.0f;
|
||||
extern const float kScaleAccel = (kAccelRangeG * 9.81f / 32768.0f);
|
||||
|
||||
const float kMinSampleRateHzGyro = 6.250f;
|
||||
const float kMaxSampleRateHzGyro = 400.0f;
|
||||
|
||||
const float kMinSampleRateHzMag = 3.125f;
|
||||
const float kMaxSampleRateHzMag = 50.0f;
|
||||
extern const float kScaleMag = 0.15f;
|
||||
|
||||
const float kMinSampleRateHzPolling = 0.1f;
|
||||
const float kMaxSampleRateHzPolling = 25.0f;
|
||||
|
||||
const float kMinSampleRateHzPressure = 0.1f;
|
||||
const float kMaxSampleRateHzPressure = 10.0f;
|
||||
|
||||
const float kMinSampleRateHzTemperature = kMinSampleRateHzPolling;
|
||||
const float kMaxSampleRateHzTemperature = kMaxSampleRateHzPolling;
|
||||
|
||||
const float kMinSampleRateHzProximity = kMinSampleRateHzPolling;
|
||||
const float kMaxSampleRateHzProximity = 5.0;
|
||||
|
||||
const float kMinSampleRateHzLight = kMinSampleRateHzPolling;
|
||||
const float kMaxSampleRateHzLight = 5.0;
|
||||
|
||||
const float kMinSampleRateHzOrientation = 12.5f;
|
||||
const float kMaxSampleRateHzOrientation = 200.0f;
|
||||
|
||||
#ifdef DIRECT_REPORT_ENABLED
|
||||
constexpr uint32_t kDirectReportFlagAccel = (
|
||||
// support up to rate level fast (nominal 200Hz);
|
||||
(SENSOR_DIRECT_RATE_FAST << SENSOR_FLAG_SHIFT_DIRECT_REPORT)
|
||||
// support ashmem and gralloc direct channel
|
||||
| SENSOR_FLAG_DIRECT_CHANNEL_ASHMEM
|
||||
| SENSOR_FLAG_DIRECT_CHANNEL_GRALLOC);
|
||||
constexpr uint32_t kDirectReportFlagGyro = (
|
||||
// support up to rate level fast (nominal 200Hz);
|
||||
(SENSOR_DIRECT_RATE_FAST << SENSOR_FLAG_SHIFT_DIRECT_REPORT)
|
||||
// support ashmem and gralloc direct channel
|
||||
| SENSOR_FLAG_DIRECT_CHANNEL_ASHMEM
|
||||
| SENSOR_FLAG_DIRECT_CHANNEL_GRALLOC);
|
||||
constexpr uint32_t kDirectReportFlagMag = (
|
||||
// support up to rate level normal (nominal 50Hz);
|
||||
(SENSOR_DIRECT_RATE_NORMAL << SENSOR_FLAG_SHIFT_DIRECT_REPORT)
|
||||
// support ashmem and gralloc direct channel
|
||||
| SENSOR_FLAG_DIRECT_CHANNEL_ASHMEM
|
||||
| SENSOR_FLAG_DIRECT_CHANNEL_GRALLOC);
|
||||
#else
|
||||
constexpr uint32_t kDirectReportFlagAccel = 0;
|
||||
constexpr uint32_t kDirectReportFlagGyro = 0;
|
||||
constexpr uint32_t kDirectReportFlagMag = 0;
|
||||
#endif
|
||||
|
||||
/*
|
||||
* The fowllowing max count is determined by the total number of blocks
|
||||
* avaliable in the shared nanohub buffer and number of samples each type of
|
||||
* event can hold within a buffer block.
|
||||
* For marlin's case, there are 239 blocks in the shared sensor buffer and
|
||||
* each block can hold 30 OneAxis Samples, 15 ThreeAxis Samples or 24
|
||||
* RawThreeAxies Samples.
|
||||
*/
|
||||
const int kMaxOneAxisEventCount = 7170;
|
||||
const int kMaxThreeAxisEventCount = 3585;
|
||||
const int kMaxRawThreeAxisEventCount = 5736;
|
||||
|
||||
const int kMinFifoReservedEventCount = 20;
|
||||
|
||||
const char SENSOR_STRING_TYPE_INTERNAL_TEMPERATURE[] =
|
||||
"com.google.sensor.internal_temperature";
|
||||
const char SENSOR_STRING_TYPE_SYNC[] =
|
||||
"com.google.sensor.sync";
|
||||
const char SENSOR_STRING_TYPE_DOUBLE_TWIST[] =
|
||||
"com.google.sensor.double_twist";
|
||||
const char SENSOR_STRING_TYPE_DOUBLE_TAP[] =
|
||||
"com.google.sensor.double_tap";
|
||||
const char SENSOR_STRING_TYPE_DOUBLE_TOUCH[] =
|
||||
"com.google.sensor.double_touch";
|
||||
|
||||
extern const sensor_t kSensorList[] = {
|
||||
{
|
||||
"TMD4903 Proximity Sensor",
|
||||
"AMS",
|
||||
kVersion,
|
||||
COMMS_SENSOR_PROXIMITY,
|
||||
SENSOR_TYPE_PROXIMITY,
|
||||
5.0f, // maxRange (cm)
|
||||
1.0f, // resolution (cm)
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzProximity), // minDelay
|
||||
300, // XXX fifoReservedEventCount
|
||||
kMaxOneAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_PROXIMITY,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzProximity), // maxDelay
|
||||
SENSOR_FLAG_WAKE_UP | SENSOR_FLAG_ON_CHANGE_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"TMD4903 Light Sensor",
|
||||
"AMS",
|
||||
kVersion,
|
||||
COMMS_SENSOR_LIGHT,
|
||||
SENSOR_TYPE_LIGHT,
|
||||
43000.0f, // maxRange (lx)
|
||||
10.0f, // XXX resolution (lx)
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzLight), // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxOneAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_LIGHT,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzLight), // maxDelay
|
||||
SENSOR_FLAG_ON_CHANGE_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"BMI160 accelerometer",
|
||||
"Bosch",
|
||||
kVersion,
|
||||
COMMS_SENSOR_ACCEL,
|
||||
SENSOR_TYPE_ACCELEROMETER,
|
||||
GRAVITY_EARTH * kAccelRangeG, // maxRange
|
||||
GRAVITY_EARTH * kAccelRangeG / 32768.0f, // resolution
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzAccel), // minDelay
|
||||
3000, // XXX fifoReservedEventCount
|
||||
kMaxRawThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_ACCELEROMETER,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzAccel), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE | kDirectReportFlagAccel,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"BMI160 gyroscope",
|
||||
"Bosch",
|
||||
kVersion,
|
||||
COMMS_SENSOR_GYRO,
|
||||
SENSOR_TYPE_GYROSCOPE,
|
||||
1000.0f * M_PI / 180.0f, // maxRange
|
||||
1000.0f * M_PI / (180.0f * 32768.0f), // resolution
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzGyro), // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_GYROSCOPE,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzGyro), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE | kDirectReportFlagGyro,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"BMI160 gyroscope (uncalibrated)",
|
||||
"Bosch",
|
||||
kVersion,
|
||||
COMMS_SENSOR_GYRO_UNCALIBRATED,
|
||||
SENSOR_TYPE_GYROSCOPE_UNCALIBRATED,
|
||||
1000.0f * M_PI / 180.0f, // maxRange
|
||||
1000.0f * M_PI / (180.0f * 32768.0f), // resolution
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzGyro), // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_GYROSCOPE_UNCALIBRATED,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzGyro), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE | kDirectReportFlagGyro,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"AK09915 magnetometer",
|
||||
"AKM",
|
||||
kVersion,
|
||||
COMMS_SENSOR_MAG,
|
||||
SENSOR_TYPE_MAGNETIC_FIELD,
|
||||
1300.0f, // XXX maxRange
|
||||
0.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzMag), // minDelay
|
||||
600, // XXX fifoReservedEventCount
|
||||
kMaxThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_MAGNETIC_FIELD,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzMag), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE | kDirectReportFlagMag,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"AK09915 magnetometer (uncalibrated)",
|
||||
"AKM",
|
||||
kVersion,
|
||||
COMMS_SENSOR_MAG_UNCALIBRATED,
|
||||
SENSOR_TYPE_MAGNETIC_FIELD_UNCALIBRATED,
|
||||
1300.0f, // XXX maxRange
|
||||
0.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzMag), // minDelay
|
||||
600, // XXX fifoReservedEventCount
|
||||
kMaxThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_MAGNETIC_FIELD_UNCALIBRATED,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzMag), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE | kDirectReportFlagMag,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"BMP285 pressure",
|
||||
"Bosch",
|
||||
kVersion,
|
||||
COMMS_SENSOR_PRESSURE,
|
||||
SENSOR_TYPE_PRESSURE,
|
||||
1100.0f, // maxRange (hPa)
|
||||
0.005f, // resolution (hPa)
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzPressure), // minDelay
|
||||
300, // XXX fifoReservedEventCount
|
||||
kMaxOneAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_PRESSURE,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzPressure), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"BMP285 temperature",
|
||||
"Bosch",
|
||||
kVersion,
|
||||
COMMS_SENSOR_TEMPERATURE,
|
||||
SENSOR_TYPE_INTERNAL_TEMPERATURE,
|
||||
85.0f, // maxRange (degC)
|
||||
0.01, // resolution (degC)
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzTemperature), // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxOneAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_INTERNAL_TEMPERATURE,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzTemperature), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Orientation",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_ORIENTATION,
|
||||
SENSOR_TYPE_ORIENTATION,
|
||||
360.0f, // maxRange (deg)
|
||||
1.0f, // XXX resolution (deg)
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzOrientation), // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_ORIENTATION,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzOrientation), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"BMI160 Step detector",
|
||||
"Bosch",
|
||||
kVersion,
|
||||
COMMS_SENSOR_STEP_DETECTOR,
|
||||
SENSOR_TYPE_STEP_DETECTOR,
|
||||
1.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
0, // minDelay
|
||||
100, // XXX fifoReservedEventCount
|
||||
kMaxOneAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_STEP_DETECTOR,
|
||||
"", // requiredPermission
|
||||
0, // maxDelay
|
||||
SENSOR_FLAG_SPECIAL_REPORTING_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"BMI160 Step counter",
|
||||
"Bosch",
|
||||
kVersion,
|
||||
COMMS_SENSOR_STEP_COUNTER,
|
||||
SENSOR_TYPE_STEP_COUNTER,
|
||||
1.0f, // XXX maxRange
|
||||
1.0f, // resolution
|
||||
0.0f, // XXX power
|
||||
0, // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxOneAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_STEP_COUNTER,
|
||||
"", // requiredPermission
|
||||
0, // maxDelay
|
||||
SENSOR_FLAG_ON_CHANGE_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Significant motion",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_SIGNIFICANT_MOTION,
|
||||
SENSOR_TYPE_SIGNIFICANT_MOTION,
|
||||
1.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
-1, // minDelay
|
||||
0, // XXX fifoReservedEventCount
|
||||
0, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_SIGNIFICANT_MOTION,
|
||||
"", // requiredPermission
|
||||
0, // maxDelay
|
||||
SENSOR_FLAG_WAKE_UP | SENSOR_FLAG_ONE_SHOT_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Gravity",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_GRAVITY,
|
||||
SENSOR_TYPE_GRAVITY,
|
||||
1000.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzOrientation), // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_GRAVITY,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzOrientation), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Linear Acceleration",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_LINEAR_ACCEL,
|
||||
SENSOR_TYPE_LINEAR_ACCELERATION,
|
||||
1000.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzOrientation), // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_LINEAR_ACCELERATION,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzOrientation), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Rotation Vector",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_ROTATION_VECTOR,
|
||||
SENSOR_TYPE_ROTATION_VECTOR,
|
||||
1000.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzOrientation), // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_ROTATION_VECTOR,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzOrientation), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Geomagnetic Rotation Vector",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_GEO_MAG,
|
||||
SENSOR_TYPE_GEOMAGNETIC_ROTATION_VECTOR,
|
||||
1000.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzOrientation), // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_GEOMAGNETIC_ROTATION_VECTOR,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzOrientation), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Game Rotation Vector",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_GAME_ROTATION_VECTOR,
|
||||
SENSOR_TYPE_GAME_ROTATION_VECTOR,
|
||||
1000.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzOrientation), // minDelay
|
||||
300, // XXX fifoReservedEventCount
|
||||
kMaxThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_GAME_ROTATION_VECTOR,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzOrientation), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Tilt Detector",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_TILT,
|
||||
SENSOR_TYPE_TILT_DETECTOR,
|
||||
1.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
0, // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxOneAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_TILT_DETECTOR,
|
||||
"", // requiredPermission
|
||||
0, // maxDelay
|
||||
SENSOR_FLAG_WAKE_UP | SENSOR_FLAG_SPECIAL_REPORTING_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Pickup Gesture",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_GESTURE,
|
||||
SENSOR_TYPE_PICK_UP_GESTURE,
|
||||
1.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
-1, // minDelay
|
||||
0, // XXX fifoReservedEventCount
|
||||
0, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_PICK_UP_GESTURE,
|
||||
"", // requiredPermission
|
||||
0, // maxDelay
|
||||
SENSOR_FLAG_WAKE_UP | SENSOR_FLAG_ONE_SHOT_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Sensors Sync",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_SYNC,
|
||||
SENSOR_TYPE_SYNC,
|
||||
1.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.1f, // XXX power
|
||||
0, // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxOneAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_SYNC,
|
||||
"", // requiredPermission
|
||||
0, // maxDelay
|
||||
SENSOR_FLAG_SPECIAL_REPORTING_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Double Twist",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_DOUBLE_TWIST,
|
||||
SENSOR_TYPE_DOUBLE_TWIST,
|
||||
1.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.1f, // XXX power
|
||||
0, // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxOneAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_DOUBLE_TWIST,
|
||||
"", // requiredPermission
|
||||
0, // maxDelay
|
||||
SENSOR_FLAG_WAKE_UP | SENSOR_FLAG_SPECIAL_REPORTING_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Double Tap",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_DOUBLE_TAP,
|
||||
SENSOR_TYPE_DOUBLE_TAP,
|
||||
1.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.1f, // XXX power
|
||||
0, // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxOneAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_DOUBLE_TAP,
|
||||
"", // requiredPermission
|
||||
0, // maxDelay
|
||||
SENSOR_FLAG_SPECIAL_REPORTING_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Device Orientation",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_WINDOW_ORIENTATION,
|
||||
SENSOR_TYPE_DEVICE_ORIENTATION,
|
||||
3.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.1f, // XXX power
|
||||
0, // minDelay
|
||||
kMinFifoReservedEventCount, // XXX fifoReservedEventCount
|
||||
kMaxOneAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_DEVICE_ORIENTATION,
|
||||
"", // requiredPermission
|
||||
0, // maxDelay
|
||||
SENSOR_FLAG_ON_CHANGE_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"Double Touch",
|
||||
"Google",
|
||||
kVersion,
|
||||
COMMS_SENSOR_DOUBLE_TOUCH,
|
||||
SENSOR_TYPE_DOUBLE_TOUCH,
|
||||
1.0f, // maxRange
|
||||
1.0f, // XXX resolution
|
||||
0.0f, // XXX power
|
||||
-1, // minDelay
|
||||
0, // XXX fifoReservedEventCount
|
||||
0, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_DOUBLE_TOUCH,
|
||||
"", // requiredPermission
|
||||
0, // maxDelay
|
||||
SENSOR_FLAG_WAKE_UP | SENSOR_FLAG_ONE_SHOT_MODE,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
{
|
||||
"BMI160 accelerometer (uncalibrated)",
|
||||
"Bosch",
|
||||
kVersion,
|
||||
COMMS_SENSOR_ACCEL_UNCALIBRATED,
|
||||
SENSOR_TYPE_ACCELEROMETER_UNCALIBRATED,
|
||||
GRAVITY_EARTH * kAccelRangeG, // maxRange
|
||||
GRAVITY_EARTH * kAccelRangeG / 32768.0f, // resolution
|
||||
0.0f, // XXX power
|
||||
(int32_t)(1.0E6f / kMaxSampleRateHzAccel), // minDelay
|
||||
3000, // XXX fifoReservedEventCount
|
||||
kMaxRawThreeAxisEventCount, // XXX fifoMaxEventCount
|
||||
SENSOR_STRING_TYPE_ACCELEROMETER_UNCALIBRATED,
|
||||
"", // requiredPermission
|
||||
(long)(1.0E6f / kMinSampleRateHzAccel), // maxDelay
|
||||
SENSOR_FLAG_CONTINUOUS_MODE | kDirectReportFlagAccel,
|
||||
{ NULL, NULL }
|
||||
},
|
||||
};
|
||||
|
||||
extern const size_t kSensorCount = sizeof(kSensorList) / sizeof(sensor_t);
|
|
@ -1,34 +0,0 @@
|
|||
# Copyright (C) 2009 The Android Open Source Project
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
ifeq ($(BOARD_USES_EXYNOS_SENSORS_DUMMY), true)
|
||||
|
||||
LOCAL_PATH := $(call my-dir)
|
||||
|
||||
# HAL module implemenation stored in
|
||||
# hw/<SENSORS_HARDWARE_MODULE_ID>.<ro.hardware>.so
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
LOCAL_MODULE_RELATIVE_PATH := hw
|
||||
LOCAL_SHARED_LIBRARIES := liblog libcutils libhardware
|
||||
LOCAL_SRC_FILES := sensors_dummy.c
|
||||
LOCAL_MODULE := sensors.gs101
|
||||
LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0
|
||||
LOCAL_LICENSE_CONDITIONS := notice
|
||||
LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../NOTICE
|
||||
LOCAL_PROPRIETARY_MODULE := true
|
||||
|
||||
include $(BUILD_SHARED_LIBRARY)
|
||||
|
||||
endif
|
|
@ -1,409 +0,0 @@
|
|||
/*
|
||||
* Copyright (C) 2009 The Android Open Source Project
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* this implements a sensors hardware library for the Android emulator.
|
||||
* the following code should be built as a shared library that will be
|
||||
* placed into /system/lib/hw/sensors.goldfish.so
|
||||
*
|
||||
* it will be loaded by the code in hardware/libhardware/hardware.c
|
||||
* which is itself called from com_android_server_SensorService.cpp
|
||||
*/
|
||||
|
||||
#define SENSORS_SERVICE_NAME "sensors"
|
||||
|
||||
#define LOG_TAG "Dummy_Sensors"
|
||||
|
||||
#include <unistd.h>
|
||||
#include <fcntl.h>
|
||||
#include <errno.h>
|
||||
#include <string.h>
|
||||
#include <log/log.h>
|
||||
#include <cutils/sockets.h>
|
||||
#include <hardware/sensors.h>
|
||||
#include <pthread.h>
|
||||
|
||||
#if 0
|
||||
#define D(...) ALOGD(__VA_ARGS__)
|
||||
#else
|
||||
#define D(...) ((void)0)
|
||||
#endif
|
||||
|
||||
#define E(...) ALOGE(__VA_ARGS__)
|
||||
|
||||
/** SENSOR IDS AND NAMES
|
||||
**/
|
||||
|
||||
#define MAX_NUM_SENSORS 8
|
||||
|
||||
#define SUPPORTED_SENSORS ((1<<MAX_NUM_SENSORS)-1)
|
||||
|
||||
#define ID_BASE SENSORS_HANDLE_BASE
|
||||
#define ID_ACCELERATION (ID_BASE+0)
|
||||
#define ID_MAGNETIC_FIELD (ID_BASE+1)
|
||||
#define ID_ORIENTATION (ID_BASE+2)
|
||||
#define ID_TEMPERATURE (ID_BASE+3)
|
||||
#define ID_PROXIMITY (ID_BASE+4)
|
||||
#define ID_LIGHT (ID_BASE+5)
|
||||
#define ID_PRESSURE (ID_BASE+6)
|
||||
#define ID_HUMIDITY (ID_BASE+7)
|
||||
|
||||
#define SENSORS_ACCELERATION (1 << ID_ACCELERATION)
|
||||
#define SENSORS_MAGNETIC_FIELD (1 << ID_MAGNETIC_FIELD)
|
||||
#define SENSORS_ORIENTATION (1 << ID_ORIENTATION)
|
||||
#define SENSORS_TEMPERATURE (1 << ID_TEMPERATURE)
|
||||
#define SENSORS_PROXIMITY (1 << ID_PROXIMITY)
|
||||
#define SENSORS_LIGHT (1 << ID_LIGHT)
|
||||
#define SENSORS_PRESSURE (1 << ID_PRESSURE)
|
||||
#define SENSORS_HUMIDITY (1 << ID_HUMIDITY)
|
||||
|
||||
#define ID_CHECK(x) ((unsigned)((x) - ID_BASE) < MAX_NUM_SENSORS)
|
||||
|
||||
#define SENSORS_LIST \
|
||||
SENSOR_(ACCELERATION,"acceleration") \
|
||||
SENSOR_(MAGNETIC_FIELD,"magnetic-field") \
|
||||
SENSOR_(ORIENTATION,"orientation") \
|
||||
SENSOR_(TEMPERATURE,"temperature") \
|
||||
SENSOR_(PROXIMITY,"proximity") \
|
||||
SENSOR_(LIGHT, "light") \
|
||||
SENSOR_(PRESSURE, "pressure") \
|
||||
SENSOR_(HUMIDITY, "humidity")
|
||||
|
||||
static const struct {
|
||||
const char* name;
|
||||
int id; } _sensorIds[MAX_NUM_SENSORS] =
|
||||
{
|
||||
#define SENSOR_(x,y) { y, ID_##x },
|
||||
SENSORS_LIST
|
||||
#undef SENSOR_
|
||||
};
|
||||
|
||||
static const char*
|
||||
_sensorIdToName( int id )
|
||||
{
|
||||
int nn;
|
||||
for (nn = 0; nn < MAX_NUM_SENSORS; nn++)
|
||||
if (id == _sensorIds[nn].id)
|
||||
return _sensorIds[nn].name;
|
||||
return "<UNKNOWN>";
|
||||
}
|
||||
|
||||
static int
|
||||
_sensorIdFromName( const char* name )
|
||||
{
|
||||
int nn;
|
||||
|
||||
if (name == NULL)
|
||||
return -1;
|
||||
|
||||
for (nn = 0; nn < MAX_NUM_SENSORS; nn++)
|
||||
if (!strcmp(name, _sensorIds[nn].name))
|
||||
return _sensorIds[nn].id;
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* return the current time in nanoseconds */
|
||||
static int64_t now_ns(void) {
|
||||
struct timespec ts;
|
||||
clock_gettime(CLOCK_MONOTONIC, &ts);
|
||||
return (int64_t)ts.tv_sec * 1000000000 + ts.tv_nsec;
|
||||
}
|
||||
|
||||
/** SENSORS POLL DEVICE
|
||||
**
|
||||
** This one is used to read sensor data from the hardware.
|
||||
** We implement this by simply reading the data from the
|
||||
** emulator through the QEMUD channel.
|
||||
**/
|
||||
|
||||
typedef struct SensorDevice {
|
||||
struct sensors_poll_device_1 device;
|
||||
sensors_event_t sensors[MAX_NUM_SENSORS];
|
||||
uint32_t pendingSensors;
|
||||
int64_t timeStart;
|
||||
int64_t timeOffset;
|
||||
uint32_t active_sensors;
|
||||
int fd;
|
||||
pthread_mutex_t lock;
|
||||
} SensorDevice;
|
||||
|
||||
/* Grab the file descriptor to the emulator's sensors service pipe.
|
||||
* This function returns a file descriptor on success, or -errno on
|
||||
* failure, and assumes the SensorDevice instance's lock is held.
|
||||
*
|
||||
* This is needed because set_delay(), poll() and activate() can be called
|
||||
* from different threads, and poll() is blocking.
|
||||
*
|
||||
* 1) On a first thread, de-activate() all sensors first, then call poll(),
|
||||
* which results in the thread blocking.
|
||||
*
|
||||
* 2) On a second thread, slightly later, call set_delay() then activate()
|
||||
* to enable the acceleration sensor.
|
||||
*
|
||||
* The system expects this to unblock the first thread which will receive
|
||||
* new sensor events after the activate() call in 2).
|
||||
*
|
||||
* This cannot work if both threads don't use the same connection.
|
||||
*
|
||||
* TODO(digit): This protocol is brittle, implement another control channel
|
||||
* for set_delay()/activate()/batch() when supporting HAL 1.3
|
||||
*/
|
||||
static int sensor_device_get_fd_locked(SensorDevice* dev) {
|
||||
/* Create connection to service on first call */
|
||||
if (dev->fd < 0) {
|
||||
int ret = -errno;
|
||||
E("%s: Could not open connection to service: %s", __FUNCTION__,
|
||||
strerror(-ret));
|
||||
return ret;
|
||||
}
|
||||
return dev->fd;
|
||||
}
|
||||
|
||||
/* Pick up one pending sensor event. On success, this returns the sensor
|
||||
* id, and sets |*event| accordingly. On failure, i.e. if there are no
|
||||
* pending events, return -EINVAL.
|
||||
*
|
||||
* Note: The device's lock must be acquired.
|
||||
*/
|
||||
static int sensor_device_pick_pending_event_locked(SensorDevice* d,
|
||||
sensors_event_t* event)
|
||||
{
|
||||
uint32_t mask = SUPPORTED_SENSORS & d->pendingSensors;
|
||||
|
||||
if (mask) {
|
||||
uint32_t i = 31 - __builtin_clz(mask);
|
||||
|
||||
pthread_mutex_lock(&d->lock);
|
||||
d->pendingSensors &= ~(1U << i);
|
||||
*event = d->sensors[i];
|
||||
event->sensor = i;
|
||||
event->version = sizeof(*event);
|
||||
pthread_mutex_unlock(&d->lock);
|
||||
D("%s: %d [%f, %f, %f]", __FUNCTION__,
|
||||
i,
|
||||
event->data[0],
|
||||
event->data[1],
|
||||
event->data[2]);
|
||||
return i;
|
||||
}
|
||||
E("No sensor to return!!! pendingSensors=0x%08x", d->pendingSensors);
|
||||
// we may end-up in a busy loop, slow things down, just in case.
|
||||
usleep(1000);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
static int sensor_device_close(struct hw_device_t* dev0)
|
||||
{
|
||||
SensorDevice* dev = (void*)dev0;
|
||||
// Assume that there are no other threads blocked on poll()
|
||||
if (dev->fd >= 0) {
|
||||
close(dev->fd);
|
||||
dev->fd = -1;
|
||||
}
|
||||
pthread_mutex_destroy(&dev->lock);
|
||||
free(dev);
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* Return an array of sensor data. This function blocks until there is sensor
|
||||
* related events to report. On success, it will write the events into the
|
||||
* |data| array, which contains |count| items. The function returns the number
|
||||
* of events written into the array, which shall never be greater than |count|.
|
||||
* On error, return -errno code.
|
||||
*
|
||||
* Note that according to the sensor HAL [1], it shall never return 0!
|
||||
*
|
||||
* [1] http://source.android.com/devices/sensors/hal-interface.html
|
||||
*/
|
||||
static int sensor_device_poll(struct sensors_poll_device_t *dev0,
|
||||
sensors_event_t* data, int count)
|
||||
{
|
||||
return -EIO;
|
||||
}
|
||||
|
||||
static int sensor_device_activate(struct sensors_poll_device_t *dev0,
|
||||
int handle,
|
||||
int enabled)
|
||||
{
|
||||
SensorDevice* dev = (void*)dev0;
|
||||
|
||||
D("%s: handle=%s (%d) enabled=%d", __FUNCTION__,
|
||||
_sensorIdToName(handle), handle, enabled);
|
||||
|
||||
/* Sanity check */
|
||||
if (!ID_CHECK(handle)) {
|
||||
E("%s: bad handle ID", __FUNCTION__);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
/* Exit early if sensor is already enabled/disabled. */
|
||||
uint32_t mask = (1U << handle);
|
||||
uint32_t sensors = enabled ? mask : 0;
|
||||
|
||||
pthread_mutex_lock(&dev->lock);
|
||||
|
||||
uint32_t active = dev->active_sensors;
|
||||
uint32_t new_sensors = (active & ~mask) | (sensors & mask);
|
||||
uint32_t changed = active ^ new_sensors;
|
||||
|
||||
if (changed)
|
||||
dev->active_sensors = new_sensors;
|
||||
|
||||
pthread_mutex_unlock(&dev->lock);
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int sensor_device_default_flush(
|
||||
struct sensors_poll_device_1* dev0,
|
||||
int handle) {
|
||||
|
||||
SensorDevice* dev = (void*)dev0;
|
||||
|
||||
D("%s: handle=%s (%d)", __FUNCTION__,
|
||||
_sensorIdToName(handle), handle);
|
||||
|
||||
/* Sanity check */
|
||||
if (!ID_CHECK(handle)) {
|
||||
E("%s: bad handle ID", __FUNCTION__);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
pthread_mutex_lock(&dev->lock);
|
||||
dev->sensors[handle].version = META_DATA_VERSION;
|
||||
dev->sensors[handle].type = SENSOR_TYPE_META_DATA;
|
||||
dev->sensors[handle].sensor = 0;
|
||||
dev->sensors[handle].timestamp = 0;
|
||||
dev->sensors[handle].meta_data.what = META_DATA_FLUSH_COMPLETE;
|
||||
dev->pendingSensors |= (1U << handle);
|
||||
pthread_mutex_unlock(&dev->lock);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int sensor_device_set_delay(struct sensors_poll_device_t *dev0,
|
||||
int handle __unused,
|
||||
int64_t ns)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int sensor_device_default_batch(
|
||||
struct sensors_poll_device_1* dev,
|
||||
int sensor_handle,
|
||||
int flags,
|
||||
int64_t sampling_period_ns,
|
||||
int64_t max_report_latency_ns) {
|
||||
return sensor_device_set_delay(dev, sensor_handle, sampling_period_ns);
|
||||
}
|
||||
|
||||
/** MODULE REGISTRATION SUPPORT
|
||||
**
|
||||
** This is required so that hardware/libhardware/hardware.c
|
||||
** will dlopen() this library appropriately.
|
||||
**/
|
||||
|
||||
/*
|
||||
* the following is the list of all supported sensors.
|
||||
* this table is used to build sSensorList declared below
|
||||
* according to which hardware sensors are reported as
|
||||
* available from the emulator (see get_sensors_list below)
|
||||
*
|
||||
* note: numerical values for maxRange/resolution/power for
|
||||
* all sensors but light, pressure and humidity were
|
||||
* taken from the reference AK8976A implementation
|
||||
*/
|
||||
static const struct sensor_t sSensorListInit[] = {
|
||||
{ .name = "Accelerometer",
|
||||
.vendor = "The Android Open Source Project",
|
||||
.version = 1,
|
||||
.handle = ID_ACCELERATION,
|
||||
.type = SENSOR_TYPE_ACCELEROMETER,
|
||||
.maxRange = 2.8f,
|
||||
.resolution = 1.0f/4032.0f,
|
||||
.power = 3.0f,
|
||||
.minDelay = 10000,
|
||||
.maxDelay = 60 * 1000 * 1000,
|
||||
.fifoReservedEventCount = 0,
|
||||
.fifoMaxEventCount = 0,
|
||||
.stringType = 0,
|
||||
.requiredPermission = 0,
|
||||
.flags = SENSOR_FLAG_CONTINUOUS_MODE,
|
||||
.reserved = {}
|
||||
},
|
||||
};
|
||||
|
||||
static struct sensor_t sSensorList[1];
|
||||
|
||||
static int sensors__get_sensors_list(struct sensors_module_t* module __unused,
|
||||
struct sensor_t const** list)
|
||||
{
|
||||
*list = sSensorList;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int
|
||||
open_sensors(const struct hw_module_t* module,
|
||||
const char* name,
|
||||
struct hw_device_t* *device)
|
||||
{
|
||||
int status = -EINVAL;
|
||||
|
||||
D("%s: name=%s", __FUNCTION__, name);
|
||||
|
||||
if (!strcmp(name, SENSORS_HARDWARE_POLL)) {
|
||||
SensorDevice *dev = malloc(sizeof(*dev));
|
||||
|
||||
memset(dev, 0, sizeof(*dev));
|
||||
|
||||
dev->device.common.tag = HARDWARE_DEVICE_TAG;
|
||||
dev->device.common.version = SENSORS_DEVICE_API_VERSION_1_3;
|
||||
dev->device.common.module = (struct hw_module_t*) module;
|
||||
dev->device.common.close = sensor_device_close;
|
||||
dev->device.poll = sensor_device_poll;
|
||||
dev->device.activate = sensor_device_activate;
|
||||
dev->device.setDelay = sensor_device_set_delay;
|
||||
|
||||
// Version 1.3-specific functions
|
||||
dev->device.batch = sensor_device_default_batch;
|
||||
dev->device.flush = sensor_device_default_flush;
|
||||
|
||||
dev->fd = -1;
|
||||
pthread_mutex_init(&dev->lock, NULL);
|
||||
|
||||
*device = &dev->device.common;
|
||||
status = 0;
|
||||
}
|
||||
return status;
|
||||
}
|
||||
|
||||
|
||||
static struct hw_module_methods_t sensors_module_methods = {
|
||||
.open = open_sensors
|
||||
};
|
||||
|
||||
struct sensors_module_t HAL_MODULE_INFO_SYM = {
|
||||
.common = {
|
||||
.tag = HARDWARE_MODULE_TAG,
|
||||
.version_major = 1,
|
||||
.version_minor = 0,
|
||||
.id = SENSORS_HARDWARE_MODULE_ID,
|
||||
.name = "Dummy SENSORS Module",
|
||||
.author = "The Android Open Source Project",
|
||||
.methods = &sensors_module_methods,
|
||||
},
|
||||
.get_sensors_list = sensors__get_sensors_list
|
||||
};
|
|
@ -287,7 +287,7 @@
|
|||
},
|
||||
{
|
||||
"Name": "OtaProfiles",
|
||||
"Profiles": [ "OtaPerformance", "ServiceCapacityLow", "LowIoPriority", "TimerSlackHigh" ]
|
||||
"Profiles": [ "OtaPerformance", "ProcessCapacityNormal", "LowIoPriority", "TimerSlackHigh" ]
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -15,8 +15,8 @@
|
|||
|
||||
# Voice packs for Text-To-Speech
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/google/gs101/tts/ja-jp/ja-jp-x-multi-r34.zvoice:product/tts/google/ja-jp/ja-jp-x-multi-r34.zvoice\
|
||||
device/google/gs101/tts/fr-fr/fr-fr-x-multi-r35.zvoice:product/tts/google/fr-fr/fr-fr-x-multi-r35.zvoice\
|
||||
device/google/gs101/tts/de-de/de-de-x-multi-r35.zvoice:product/tts/google/de-de/de-de-x-multi-r35.zvoice\
|
||||
device/google/gs101/tts/it-it/it-it-x-multi-r32.zvoice:product/tts/google/it-it/it-it-x-multi-r32.zvoice\
|
||||
device/google/gs101/tts/es-es/es-es-x-multi-r35.zvoice:product/tts/google/es-es/es-es-x-multi-r35.zvoice
|
||||
device/google/gs101/tts/ja-jp/ja-jp-x-multi-r42.zvoice:product/tts/google/ja-jp/ja-jp-x-multi-r42.zvoice\
|
||||
device/google/gs101/tts/fr-fr/fr-fr-x-multi-r44.zvoice:product/tts/google/fr-fr/fr-fr-x-multi-r44.zvoice\
|
||||
device/google/gs101/tts/de-de/de-de-x-multi-r43.zvoice:product/tts/google/de-de/de-de-x-multi-r43.zvoice\
|
||||
device/google/gs101/tts/it-it/it-it-x-multi-r40.zvoice:product/tts/google/it-it/it-it-x-multi-r40.zvoice\
|
||||
device/google/gs101/tts/es-es/es-es-x-multi-r43.zvoice:product/tts/google/es-es/es-es-x-multi-r43.zvoice
|
||||
|
|
|
@ -44,7 +44,7 @@ cc_binary {
|
|||
"libbinder_ndk",
|
||||
],
|
||||
static_libs: [
|
||||
"libpixelusb",
|
||||
"libpixelusb-aidl",
|
||||
],
|
||||
proprietary: true,
|
||||
export_shared_lib_headers: [
|
||||
|
|
|
@ -26,6 +26,8 @@
|
|||
#include <sys/types.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include <android-base/properties.h>
|
||||
|
||||
#include <aidl/android/frameworks/stats/IStats.h>
|
||||
|
||||
namespace aidl {
|
||||
|
@ -40,6 +42,9 @@ constexpr char kI2CPath[] = "/sys/devices/platform/10d50000.hsi2c/i2c-";
|
|||
constexpr char kAccessoryLimitCurrent[] = "i2c-max77759tcpc/usb_limit_accessory_current";
|
||||
constexpr char kAccessoryLimitCurrentEnable[] = "i2c-max77759tcpc/usb_limit_accessory_enable";
|
||||
|
||||
using ::android::base::GetBoolProperty;
|
||||
using ::android::hardware::google::pixel::usb::kUvcEnabled;
|
||||
|
||||
UsbGadget::UsbGadget() : mGadgetIrqPath("") {
|
||||
if (access(OS_DESC_PATH, R_OK) != 0) {
|
||||
ALOGE("configfs setup not done yet");
|
||||
|
@ -154,8 +159,8 @@ Status UsbGadget::tearDownGadget() {
|
|||
return Status::SUCCESS;
|
||||
}
|
||||
|
||||
static Status validateAndSetVidPid(uint64_t functions) {
|
||||
Status ret = Status::SUCCESS;
|
||||
static Status validateAndSetVidPid(int64_t functions) {
|
||||
Status ret;
|
||||
std::string vendorFunctions = getVendorFunctions();
|
||||
|
||||
switch (functions) {
|
||||
|
@ -302,6 +307,28 @@ static Status validateAndSetVidPid(uint64_t functions) {
|
|||
ret = Status(setVidPid("0x18d1", "0x4eec"));
|
||||
}
|
||||
break;
|
||||
case GadgetFunction::UVC:
|
||||
if (!(vendorFunctions == "user" || vendorFunctions == "")) {
|
||||
ALOGE("Invalid vendorFunctions set: %s", vendorFunctions.c_str());
|
||||
ret = Status::CONFIGURATION_NOT_SUPPORTED;
|
||||
} else if (!GetBoolProperty(kUvcEnabled, false)) {
|
||||
ALOGE("UVC function not enabled by config");
|
||||
ret = Status::CONFIGURATION_NOT_SUPPORTED;
|
||||
} else {
|
||||
ret = Status(setVidPid("0x18d1", "0x4eed"));
|
||||
}
|
||||
break;
|
||||
case GadgetFunction::ADB | GadgetFunction::UVC:
|
||||
if (!(vendorFunctions == "user" || vendorFunctions == "")) {
|
||||
ALOGE("Invalid vendorFunctions set: %s", vendorFunctions.c_str());
|
||||
ret = Status::CONFIGURATION_NOT_SUPPORTED;
|
||||
} else if (!GetBoolProperty(kUvcEnabled, false)) {
|
||||
ALOGE("UVC function not enabled by config");
|
||||
ret = Status::CONFIGURATION_NOT_SUPPORTED;
|
||||
} else {
|
||||
ret = Status(setVidPid("0x18d1", "0x4eee"));
|
||||
}
|
||||
break;
|
||||
default:
|
||||
ALOGE("Combination not supported");
|
||||
ret = Status::CONFIGURATION_NOT_SUPPORTED;
|
||||
|
@ -309,11 +336,14 @@ static Status validateAndSetVidPid(uint64_t functions) {
|
|||
return ret;
|
||||
}
|
||||
|
||||
ScopedAStatus UsbGadget::reset() {
|
||||
ScopedAStatus UsbGadget::reset(const shared_ptr<IUsbGadgetCallback> &callback,
|
||||
int64_t in_transactionId) {
|
||||
ALOGI("USB Gadget reset");
|
||||
|
||||
if (!WriteStringToFile("none", PULLUP_PATH)) {
|
||||
ALOGI("Gadget cannot be pulled down");
|
||||
if (callback)
|
||||
callback->resetCb(Status::ERROR, in_transactionId);
|
||||
return ScopedAStatus::fromServiceSpecificErrorWithMessage(
|
||||
-1, "Gadget cannot be pulled down");
|
||||
}
|
||||
|
@ -322,9 +352,13 @@ ScopedAStatus UsbGadget::reset() {
|
|||
|
||||
if (!WriteStringToFile(kGadgetName, PULLUP_PATH)) {
|
||||
ALOGI("Gadget cannot be pulled up");
|
||||
if (callback)
|
||||
callback->resetCb(Status::ERROR, in_transactionId);
|
||||
return ScopedAStatus::fromServiceSpecificErrorWithMessage(
|
||||
-1, "Gadget cannot be pulled up");
|
||||
}
|
||||
if (callback)
|
||||
callback->resetCb(Status::SUCCESS, in_transactionId);
|
||||
|
||||
return ScopedAStatus::ok();
|
||||
}
|
||||
|
@ -519,9 +553,7 @@ ScopedAStatus UsbGadget::setCurrentUsbFunctions(long functions,
|
|||
}
|
||||
|
||||
ALOGI("Usb Gadget setcurrent functions called successfully");
|
||||
return ScopedAStatus::fromServiceSpecificErrorWithMessage(
|
||||
-1, "Usb Gadget setcurrent functions called successfully");
|
||||
|
||||
return ScopedAStatus::ok();
|
||||
|
||||
error:
|
||||
ALOGI("Usb Gadget setcurrent functions failed");
|
||||
|
|
|
@ -107,7 +107,8 @@ struct UsbGadget : public BnUsbGadget {
|
|||
ScopedAStatus getCurrentUsbFunctions(const shared_ptr<IUsbGadgetCallback> &callback,
|
||||
int64_t in_transactionId) override;
|
||||
|
||||
ScopedAStatus reset() override;
|
||||
ScopedAStatus reset(const shared_ptr<IUsbGadgetCallback> &callback,
|
||||
int64_t in_transactionId) override;
|
||||
|
||||
ScopedAStatus getUsbSpeed(const shared_ptr<IUsbGadgetCallback> &callback,
|
||||
int64_t in_transactionId) override;
|
||||
|
|
|
@ -1,8 +1,7 @@
|
|||
service vendor.usb-gadget-hal /vendor/bin/hw/android.hardware.usb.gadget-service.gs101
|
||||
class hal
|
||||
user system
|
||||
group system shell mtp wakelock
|
||||
capabilities WAKE_ALARM BLOCK_SUSPEND
|
||||
group system shell mtp
|
||||
|
||||
on post-fs
|
||||
chown root system /sys/class/typec/port0/power_role
|
||||
|
|
|
@ -42,8 +42,9 @@ cc_binary {
|
|||
"libhardware",
|
||||
"android.hardware.thermal@1.0",
|
||||
"android.hardware.thermal@2.0",
|
||||
"android.hardware.usb.gadget@1.0",
|
||||
"android.hardware.usb-V1-ndk",
|
||||
"android.hardware.thermal-V1-ndk",
|
||||
"android.hardware.usb.gadget@1.0",
|
||||
"android.hardware.usb-V2-ndk",
|
||||
"libcutils",
|
||||
"android.frameworks.stats-V1-ndk",
|
||||
"pixelatoms-cpp",
|
||||
|
@ -53,6 +54,7 @@ cc_binary {
|
|||
static_libs: [
|
||||
"libpixelusb",
|
||||
"libpixelstats",
|
||||
"libthermalutils",
|
||||
],
|
||||
export_shared_lib_headers: [
|
||||
"android.frameworks.stats-V1-ndk",
|
||||
|
|
|
@ -44,6 +44,7 @@
|
|||
|
||||
using aidl::android::frameworks::stats::IStats;
|
||||
using android::base::GetProperty;
|
||||
using android::base::Tokenize;
|
||||
using android::base::Trim;
|
||||
using android::hardware::google::pixel::getStatsService;
|
||||
using android::hardware::google::pixel::PixelAtoms::VendorUsbPortOverheat;
|
||||
|
@ -59,6 +60,11 @@ volatile bool destroyThread;
|
|||
string enabledPath;
|
||||
constexpr char kHsi2cPath[] = "/sys/devices/platform/10d50000.hsi2c";
|
||||
constexpr char kI2CPath[] = "/sys/devices/platform/10d50000.hsi2c/i2c-";
|
||||
constexpr char kComplianceWarningsPath[] = "device/non_compliant_reasons";
|
||||
constexpr char kComplianceWarningBC12[] = "bc12";
|
||||
constexpr char kComplianceWarningDebugAccessory[] = "debug-accessory";
|
||||
constexpr char kComplianceWarningMissingRp[] = "missing_rp";
|
||||
constexpr char kComplianceWarningOther[] = "other";
|
||||
constexpr char kContaminantDetectionPath[] = "i2c-max77759tcpc/contaminant_detection";
|
||||
constexpr char kStatusPath[] = "i2c-max77759tcpc/contaminant_detection_status";
|
||||
constexpr char kSinkLimitEnable[] = "i2c-max77759tcpc/usb_limit_sink_enable";
|
||||
|
@ -275,6 +281,49 @@ Status queryMoistureDetectionStatus(std::vector<PortStatus> *currentPortStatus)
|
|||
return Status::SUCCESS;
|
||||
}
|
||||
|
||||
Status queryNonCompliantChargerStatus(std::vector<PortStatus> *currentPortStatus) {
|
||||
string reasons, path;
|
||||
|
||||
for (int i = 0; i < currentPortStatus->size(); i++) {
|
||||
(*currentPortStatus)[i].supportsComplianceWarnings = true;
|
||||
path = string(kTypecPath) + "/" + (*currentPortStatus)[i].portName + "/" +
|
||||
string(kComplianceWarningsPath);
|
||||
if (ReadFileToString(path.c_str(), &reasons)) {
|
||||
std::vector<string> reasonsList = Tokenize(reasons.c_str(), "[], \n\0");
|
||||
for (string reason : reasonsList) {
|
||||
if (!strncmp(reason.c_str(), kComplianceWarningDebugAccessory,
|
||||
strlen(kComplianceWarningDebugAccessory))) {
|
||||
(*currentPortStatus)[i].complianceWarnings.push_back(ComplianceWarning::DEBUG_ACCESSORY);
|
||||
continue;
|
||||
}
|
||||
if (!strncmp(reason.c_str(), kComplianceWarningBC12,
|
||||
strlen(kComplianceWarningBC12))) {
|
||||
(*currentPortStatus)[i].complianceWarnings.push_back(ComplianceWarning::BC_1_2);
|
||||
continue;
|
||||
}
|
||||
if (!strncmp(reason.c_str(), kComplianceWarningMissingRp,
|
||||
strlen(kComplianceWarningMissingRp))) {
|
||||
(*currentPortStatus)[i].complianceWarnings.push_back(ComplianceWarning::MISSING_RP);
|
||||
continue;
|
||||
}
|
||||
if (!strncmp(reason.c_str(), kComplianceWarningOther,
|
||||
strlen(kComplianceWarningOther))) {
|
||||
(*currentPortStatus)[i].complianceWarnings.push_back(ComplianceWarning::OTHER);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
if ((*currentPortStatus)[i].complianceWarnings.size() > 0 &&
|
||||
(*currentPortStatus)[i].currentPowerRole == PortPowerRole::NONE) {
|
||||
(*currentPortStatus)[i].currentMode = PortMode::UFP;
|
||||
(*currentPortStatus)[i].currentPowerRole = PortPowerRole::SINK;
|
||||
(*currentPortStatus)[i].currentDataRole = PortDataRole::NONE;
|
||||
(*currentPortStatus)[i].powerBrickStatus = PowerBrickStatus::CONNECTED;
|
||||
}
|
||||
}
|
||||
}
|
||||
return Status::SUCCESS;
|
||||
}
|
||||
|
||||
string appendRoleNodeHelper(const string &portName, PortRole::Tag tag) {
|
||||
string node("/sys/class/typec/" + portName);
|
||||
|
||||
|
@ -771,6 +820,7 @@ void queryVersionHelper(android::hardware::usb::Usb *usb,
|
|||
status = getPortStatusHelper(usb, currentPortStatus);
|
||||
queryMoistureDetectionStatus(currentPortStatus);
|
||||
queryPowerTransferStatus(currentPortStatus);
|
||||
queryNonCompliantChargerStatus(currentPortStatus);
|
||||
if (usb->mCallback != NULL) {
|
||||
ScopedAStatus ret = usb->mCallback->notifyPortStatusChange(*currentPortStatus,
|
||||
status);
|
||||
|
|
|
@ -8,30 +8,66 @@ on post-fs
|
|||
chown root system /sys/class/typec/port0/power_role
|
||||
chown root system /sys/class/typec/port0/data_role
|
||||
chown root system /sys/class/typec/port0/port_type
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/contaminant_detection
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/contaminant_detection
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/contaminant_detection
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/contaminant_detection
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/contaminant_detection
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/contaminant_detection
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/contaminant_detection
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/contaminant_detection
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/contaminant_detection
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/contaminant_detection
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chown root system /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chown root system /sys/devices/platform/11110000.usb/dwc3_exynos_otg_b_sess
|
||||
chown root system /sys/devices/platform/11110000.usb/dwc3_exynos_otg_id
|
||||
chown root system /sys/devices/platform/11110000.usb/usb_data_enabled
|
||||
|
@ -42,28 +78,64 @@ on post-fs
|
|||
chmod 664 /sys/devices/platform/11110000.usb/dwc3_exynos_otg_b_sess
|
||||
chmod 664 /sys/devices/platform/11110000.usb/dwc3_exynos_otg_id
|
||||
chmod 664 /sys/devices/platform/11110000.usb/usb_data_enabled
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/contaminant_detection
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/contaminant_detection
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/contaminant_detection
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/contaminant_detection
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/contaminant_detection
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/contaminant_detection
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/contaminant_detection
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/contaminant_detection
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/contaminant_detection
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/contaminant_detection
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/usb_limit_accessory_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/usb_limit_accessory_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/usb_limit_sink_current
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/usb_limit_sink_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-0/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-1/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-2/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-3/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-4/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-5/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-6/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-7/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-8/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chmod 664 /sys/devices/platform/10d50000.hsi2c/i2c-9/i2c-max77759tcpc/usb_limit_source_enable
|
||||
chmod 664 /sys/devices/platform/google,pogo/move_data_to_usb
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<manifest version="1.0" type="device">
|
||||
<hal format="aidl">
|
||||
<name>android.hardware.usb</name>
|
||||
<version>1</version>
|
||||
<version>2</version>
|
||||
<interface>
|
||||
<name>IUsb</name>
|
||||
<instance>default</instance>
|
||||
|
|
|
@ -8,3 +8,4 @@ p2p_add_cli_chan=1
|
|||
disable_scan_offload=1
|
||||
p2p_go_vht=1
|
||||
p2p_pref_chan=124:149, 115:36
|
||||
p2p_6ghz_disable=1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue