Snap for 9600182 from a91df91853 to udc-release

Change-Id: Ib0c9a9e55b16547f1099071f486469f0bebf7d97
This commit is contained in:
Android Build Coastguard Worker 2023-02-14 02:02:53 +00:00
commit f4ab352ec1
8 changed files with 58 additions and 0 deletions

View file

@ -3,3 +3,9 @@ echo "--- pcie0 dump ---"
cat /dev/logbuffer_pcie0
echo "--- pcie1 dump ---"
cat /dev/logbuffer_pcie1
echo "--- pcie link statistics ---"
for f in /sys/devices/platform/*.pcie/link_stats/*
do
echo "$f: `cat $f`"
done

View file

@ -1 +1,2 @@
type pcie_log_device, dev_type;
type sysfs_pcie, sysfs_type, fs_type;

View file

@ -2,3 +2,6 @@ pixel_bugreport(dump_pcie)
allow dump_pcie pcie_log_device:chr_file r_file_perms;
allow dump_pcie vendor_toolbox_exec:file execute_no_trans;
allow dump_pcie sysfs:dir r_dir_perms;
allow dump_pcie sysfs_pcie:file r_file_perms;

18
performance/Android.bp Normal file
View file

@ -0,0 +1,18 @@
package {
default_applicable_licenses: ["Android-Apache-2.0"],
}
cc_binary {
name: "dump_perf",
srcs: ["dump_perf.cpp"],
cflags: [
"-Wall",
"-Wextra",
"-Werror",
],
shared_libs: [
"libdump",
],
vendor: true,
relative_install_path: "dump",
}

22
performance/dump_perf.cpp Normal file
View file

@ -0,0 +1,22 @@
/*
* Copyright 2022 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 <dump/pixel_dump.h>
int main() {
dumpFileContent("VENDOR PROC DUMP", "/proc/vendor_sched/dump_task");
return 0;
}

3
performance/perf.mk Normal file
View file

@ -0,0 +1,3 @@
BOARD_VENDOR_SEPOLICY_DIRS += device/google/gs-common/performance/sepolicy
PRODUCT_PACKAGES += dump_perf

View file

@ -0,0 +1,3 @@
pixel_bugreport(dump_perf)
allow dump_perf proc_vendor_sched:file r_file_perms;

View file

@ -0,0 +1,2 @@
/vendor/bin/dump/dump_perf u:object_r:dump_perf_exec:s0