Snap for 9121979 from f1dc3132704ae179153670a88e85d70e9b3cbe88 to udc-release
Change-Id: I95dbcbb0e578d17457f3ba56f29017a87ea93714
This commit is contained in:
commit
f868489a17
@ -21,9 +21,3 @@ PRODUCT_SOONG_NAMESPACES += \
|
||||
PRODUCT_PROPERTY_OVERRIDES += \
|
||||
vendor.media.omx=0
|
||||
|
||||
# Platform watchdogd
|
||||
PRODUCT_PACKAGES += gs_watchdogd
|
||||
PRODUCT_SOONG_NAMESPACES += \
|
||||
device/google/gs-common/gs_watchdogd
|
||||
SYSTEM_EXT_PRIVATE_SEPOLICY_DIRS += \
|
||||
hardware/google/pixel-sepolicy/gs_watchdogd
|
||||
|
5
gs_watchdogd/sepolicy/file_contexts
Normal file
5
gs_watchdogd/sepolicy/file_contexts
Normal file
@ -0,0 +1,5 @@
|
||||
# Platform watchdogd
|
||||
/system_ext/bin/gs_watchdogd u:object_r:gs_watchdogd_exec:s0
|
||||
|
||||
# Devices
|
||||
/dev/watchdog[0-9] u:object_r:watchdog_device:s0
|
9
gs_watchdogd/sepolicy/gs_watchdogd.te
Normal file
9
gs_watchdogd/sepolicy/gs_watchdogd.te
Normal file
@ -0,0 +1,9 @@
|
||||
# gs_watchdogd seclabel is specified in init.<board>.rc
|
||||
type gs_watchdogd, domain, coredomain;
|
||||
type gs_watchdogd_exec, system_file_type, exec_type, file_type;
|
||||
|
||||
init_daemon_domain(gs_watchdogd)
|
||||
|
||||
allow gs_watchdogd watchdog_device:chr_file rw_file_perms;
|
||||
allow gs_watchdogd kmsg_device:chr_file rw_file_perms;
|
||||
allow gs_watchdogd sysfs:dir r_dir_perms;
|
6
gs_watchdogd/watchdog.mk
Normal file
6
gs_watchdogd/watchdog.mk
Normal file
@ -0,0 +1,6 @@
|
||||
# Platform watchdogd
|
||||
PRODUCT_PACKAGES += gs_watchdogd
|
||||
PRODUCT_SOONG_NAMESPACES += \
|
||||
device/google/gs-common/gs_watchdogd
|
||||
SYSTEM_EXT_PRIVATE_SEPOLICY_DIRS += \
|
||||
device/google/gs-common/gs_watchdogd/sepolicy
|
@ -8,3 +8,61 @@ echo "\n--- F2FS - fsck time (ms) ---"
|
||||
getprop ro.boottime.init.fsck.data
|
||||
echo "\n--- F2FS - checkpoint=disable time (ms) ---"
|
||||
getprop ro.boottime.init.mount.data
|
||||
|
||||
# UFS
|
||||
echo "\n------ UFS model (/sys/block/sda/device/model) ------"
|
||||
cat "/sys/block/sda/device/model"
|
||||
echo "\n------ UFS rev (/sys/block/sda/device/rev) ------"
|
||||
cat "/sys/block/sda/device/rev"
|
||||
echo "\n------ UFS size (/sys/block/sda/size) ------"
|
||||
cat "/sys/block/sda/size"
|
||||
|
||||
echo "\n------ UFS Slow IO Read (/dev/sys/block/bootdevice/slowio_read_cnt) ------"
|
||||
cat "/dev/sys/block/bootdevice/slowio_read_cnt"
|
||||
echo "\n------ UFS Slow IO Write (/dev/sys/block/bootdevice/slowio_write_cnt) ------"
|
||||
cat "/dev/sys/block/bootdevice/slowio_write_cnt"
|
||||
echo "\n------ UFS Slow IO Unmap (/dev/sys/block/bootdevice/slowio_unmap_cnt) ------"
|
||||
cat "/dev/sys/block/bootdevice/slowio_unmap_cnt"
|
||||
echo "\n------ UFS Slow IO Sync (/dev/sys/block/bootdevice/slowio_sync_cnt) ------"
|
||||
cat "/dev/sys/block/bootdevice/slowio_sync_cnt"
|
||||
|
||||
echo "\n------ UFS err_stats ------"
|
||||
path="/dev/sys/block/bootdevice/err_stats";
|
||||
for node in `ls $path/* | grep -v reset_err_status`
|
||||
do
|
||||
printf "%s:%d\n" $(basename $node) $(cat $node)
|
||||
done
|
||||
|
||||
|
||||
echo "\n------ UFS io_stats ------"
|
||||
path="/dev/sys/block/bootdevice/io_stats"
|
||||
printf "\t\t%-12s %-12s %-12s %-12s %-12s %-12s\n" ReadCnt ReadBytes WriteCnt WriteBytes RWCnt RWBytes
|
||||
str=$(cat $path/*_start); arr=($str);
|
||||
printf "Started: \t%-12s %-12s %-12s %-12s %-12s %-12s\n" ${arr[1]} ${arr[0]} ${arr[5]} ${arr[4]} ${arr[3]} ${arr[2]}
|
||||
str=$(cat $path/*_complete); arr=($str);
|
||||
printf "Completed: \t%-12s %-12s %-12s %-12s %-12s %-12s\n" ${arr[1]} ${arr[0]} ${arr[5]} ${arr[4]} ${arr[3]} ${arr[2]}
|
||||
str=$(cat $path/*_maxdiff); arr=($str);
|
||||
printf "MaxDiff: \t%-12s %-12s %-12s %-12s %-12s %-12s\n\n" ${arr[1]} ${arr[0]} ${arr[5]} ${arr[4]} ${arr[3]} ${arr[2]}
|
||||
|
||||
echo "\n------ UFS req_stats ------"
|
||||
path="/dev/sys/block/bootdevice/req_stats"
|
||||
printf "\t%-12s %-12s %-12s %-12s %-12s %-12s\n" All Write Read Security Flush Discard
|
||||
str=$(cat $path/*_min); arr=($str);
|
||||
printf "Min:\t%-12s %-12s %-12s %-12s %-12s %-12s\n" ${arr[0]} ${arr[5]} ${arr[3]} ${arr[4]} ${arr[2]} ${arr[1]}
|
||||
str=$(cat $path/*_max); arr=($str);
|
||||
printf "Max:\t%-12s %-12s %-12s %-12s %-12s %-12s\n" ${arr[0]} ${arr[5]} ${arr[3]} ${arr[4]} ${arr[2]} ${arr[1]}
|
||||
str=$(cat $path/*_avg); arr=($str);
|
||||
printf "Avg.:\t%-12s %-12s %-12s %-12s %-12s %-12s\n" ${arr[0]} ${arr[5]} ${arr[3]} ${arr[4]} ${arr[2]} ${arr[1]}
|
||||
str=$(cat $path/*_sum); arr=($str);
|
||||
printf "Count:\t%-12s %-12s %-12s %-12s %-12s %-12s\n\n" ${arr[0]} ${arr[5]} ${arr[3]} ${arr[4]} ${arr[2]} ${arr[1]}
|
||||
|
||||
echo "\n------ UFS health ------"
|
||||
for f in $(find /dev/sys/block/bootdevice/health_descriptor -type f)
|
||||
do
|
||||
if [[ -r $f && -f $f ]]; then
|
||||
echo --- $f
|
||||
cat $f
|
||||
echo ''
|
||||
fi
|
||||
done
|
||||
|
||||
|
@ -1,6 +1,8 @@
|
||||
pixel_bugreport(dump_storage)
|
||||
|
||||
allow dump_storage vendor_toolbox_exec:file execute_no_trans;
|
||||
allow dump_storage sysfs_scsi_devices_0000:dir r_dir_perms;
|
||||
allow dump_storage sysfs_scsi_devices_0000:file r_file_perms;
|
||||
|
||||
userdebug_or_eng(`
|
||||
allow dump_storage debugfs_f2fs:dir r_dir_perms;
|
||||
|
Loading…
x
Reference in New Issue
Block a user