Home
last modified time | relevance | path

Searched refs:args (Results 1 – 25 of 469) sorted by relevance

12345678910>>...19

/system/vold/
Dvdc.cpp69 static void bindkeys(std::vector<std::string>& args, const android::sp<android::os::IVold>& vold) { in bindkeys() argument
86 checkStatus(args, vold->setStorageBindingSeed(seed)); in bindkeys()
89 static void mountFstab(std::vector<std::string>& args, in mountFstab() argument
91 auto isZoned = android::base::ParseBool(args[4]); in mountFstab()
95 if (args[5] != "") { in mountFstab()
96 userDevices = android::base::Split(args[5], " "); in mountFstab()
98 checkStatus(args, in mountFstab()
99 vold->mountFstab(args[2], args[3], isZoned == android::base::ParseBoolResult::kTrue, in mountFstab()
103 static void encryptFstab(std::vector<std::string>& args, in encryptFstab() argument
105 auto shouldFormat = android::base::ParseBool(args[4]); in encryptFstab()
[all …]
/system/extras/ext4_utils/
Dtest_mkuserimg_mke2fs.py37 args = mkuserimg_mke2fs.ParseArguments(args_list)
39 self.assertEqual("source_directory", args.src_dir)
40 self.assertEqual("output_file", args.output_file)
41 self.assertEqual("ext4", args.ext_variant)
42 self.assertEqual("data", args.mount_point)
43 self.assertEqual("8192", args.fs_size)
45 self.assertFalse(args.android_sparse)
46 self.assertEqual("10", args.journal_size)
47 self.assertEqual("1230768000.0", args.timestamp)
48 self.assertEqual("fs_config", args.fs_config)
[all …]
Dmkuserimg_mke2fs.py117 args, remainder = parser.parse_known_args(argv)
122 args.file_contexts = remainder[0]
127 return args
130 def ConstructE2fsCommands(args): argument
145 if args.android_sparse:
149 if args.timestamp:
150 e2fsdroid_opts += ["-T", args.timestamp]
151 if args.fs_config:
152 e2fsdroid_opts += ["-C", args.fs_config]
153 if args.product_out:
[all …]
/system/tools/mkbootimg/
Dmkbootimg.py96 def get_recovery_dtbo_offset(args): argument
99 num_kernel_pages = get_number_of_pages(filesize(args.kernel), args.pagesize)
100 num_ramdisk_pages = get_number_of_pages(filesize(args.ramdisk),
101 args.pagesize)
102 num_second_pages = get_number_of_pages(filesize(args.second), args.pagesize)
103 dtbo_offset = args.pagesize * (num_header_pages + num_kernel_pages +
108 def should_add_legacy_gki_boot_signature(args): argument
109 if args.gki_signing_key and args.gki_signing_algorithm:
114 def write_header_v3_and_above(args): argument
115 if args.header_version > 3:
[all …]
/system/core/init/
Dcheck_builtins.cpp47 for (const auto& arg : args) { \
70 static Result<void> check_stub(const BuiltinArguments& args) { in check_stub() argument
76 Result<void> check_chown(const BuiltinArguments& args) { in check_chown() argument
77 if (!args[1].empty()) { in check_chown()
78 auto uid = DecodeUid(args[1]); in check_chown()
80 return Error() << "Unable to decode UID for '" << args[1] << "': " << uid.error(); in check_chown()
85 if (args.size() == 4 && !args[2].empty()) { in check_chown()
86 auto gid = DecodeUid(args[2]); in check_chown()
88 return Error() << "Unable to decode GID for '" << args[2] << "': " << gid.error(); in check_chown()
95 Result<void> check_exec(const BuiltinArguments& args) { in check_exec() argument
[all …]
Dservice_parser.cpp67 Result<void> ServiceParser::ParseCapabilities(std::vector<std::string>&& args) { in ParseCapabilities() argument
80 for (size_t i = 1; i < args.size(); i++) { in ParseCapabilities()
81 const std::string& arg = args[i]; in ParseCapabilities()
95 Result<void> ServiceParser::ParseClass(std::vector<std::string>&& args) { in ParseClass() argument
96 service_->classnames_ = std::set<std::string>(args.begin() + 1, args.end()); in ParseClass()
100 Result<void> ServiceParser::ParseConsole(std::vector<std::string>&& args) { in ParseConsole() argument
105 service_->proc_attr_.console = args.size() > 1 ? "/dev/" + args[1] : ""; in ParseConsole()
109 Result<void> ServiceParser::ParseCritical(std::vector<std::string>&& args) { in ParseCritical() argument
113 for (auto it = args.begin() + 1; it != args.end(); ++it) { in ParseCritical()
147 Result<void> ServiceParser::ParseDisabled(std::vector<std::string>&& args) { in ParseDisabled() argument
[all …]
Dcheck_builtins.h29 Result<void> check_chown(const BuiltinArguments& args);
30 Result<void> check_exec(const BuiltinArguments& args);
31 Result<void> check_exec_background(const BuiltinArguments& args);
32 Result<void> check_exec_reboot_on_failure(const BuiltinArguments& args);
33 Result<void> check_interface_restart(const BuiltinArguments& args);
34 Result<void> check_interface_start(const BuiltinArguments& args);
35 Result<void> check_interface_stop(const BuiltinArguments& args);
36 Result<void> check_load_system_props(const BuiltinArguments& args);
37 Result<void> check_loglevel(const BuiltinArguments& args);
38 Result<void> check_mkdir(const BuiltinArguments& args);
[all …]
Dueventd_parser.cpp33 Result<void> ParsePermissionsLine(std::vector<std::string>&& args, in ParsePermissionsLine() argument
37 if (is_sysfs && !(args.size() == 5 || args.size() == 6)) { in ParsePermissionsLine()
41 if (!is_sysfs && !(args.size() == 4 || args.size() == 5)) { in ParsePermissionsLine()
45 auto it = args.begin(); in ParsePermissionsLine()
74 if (it != args.end()) { in ParsePermissionsLine()
90 Result<void> ParseFirmwareDirectoriesLine(std::vector<std::string>&& args, in ParseFirmwareDirectoriesLine() argument
92 if (args.size() < 2) { in ParseFirmwareDirectoriesLine()
96 std::move(std::next(args.begin()), args.end(), std::back_inserter(*firmware_directories)); in ParseFirmwareDirectoriesLine()
102 std::vector<std::string>&& args, in ParseExternalFirmwareHandlerLine() argument
104 if (args.size() != 4 && args.size() != 5) { in ParseExternalFirmwareHandlerLine()
[all …]
Dbuiltins.cpp166 static Result<void> do_class_start(const BuiltinArguments& args) { in do_class_start() argument
168 if (android::base::GetBoolProperty("persist.init.dont_start_class." + args[1], false)) in do_class_start()
173 if (service->classnames().count(args[1])) { in do_class_start()
176 << "' as part of class '" << args[1] << "': " << result.error(); in do_class_start()
183 static Result<void> do_class_stop(const BuiltinArguments& args) { in do_class_stop() argument
184 ForEachServiceInClass(args[1], &Service::Stop); in do_class_stop()
188 static Result<void> do_class_reset(const BuiltinArguments& args) { in do_class_reset() argument
189 ForEachServiceInClass(args[1], &Service::Reset); in do_class_reset()
193 static Result<void> do_class_restart(const BuiltinArguments& args) { in do_class_restart() argument
195 if (android::base::GetBoolProperty("persist.init.dont_start_class." + args[1], false)) in do_class_restart()
[all …]
Dservice_parser.h39 Result<void> ParseSection(std::vector<std::string>&& args, const std::string& filename,
41 Result<void> ParseLineSection(std::vector<std::string>&& args, int line) override;
46 using OptionParser = Result<void> (ServiceParser::*)(std::vector<std::string>&& args);
49 Result<void> ParseCapabilities(std::vector<std::string>&& args);
50 Result<void> ParseClass(std::vector<std::string>&& args);
51 Result<void> ParseConsole(std::vector<std::string>&& args);
52 Result<void> ParseCritical(std::vector<std::string>&& args);
53 Result<void> ParseDisabled(std::vector<std::string>&& args);
54 Result<void> ParseEnterNamespace(std::vector<std::string>&& args);
55 Result<void> ParseGroup(std::vector<std::string>&& args);
[all …]
Drlimit_parser.cpp31 Result<std::pair<int, rlimit>> ParseRlimit(const std::vector<std::string>& args) { in ParseRlimit() argument
45 if (ParseInt(args[1], &resource)) { in ParseRlimit()
47 return Error() << "Resource '" << args[1] << "' over the maximum resource value '" in ParseRlimit()
50 return Error() << "Resource '" << args[1] << "' below the minimum resource value '0'"; in ParseRlimit()
54 if (StartsWith(args[1], "RLIM_")) { in ParseRlimit()
55 resource_string = args[1].substr(5); in ParseRlimit()
56 } else if (StartsWith(args[1], "RLIMIT_")) { in ParseRlimit()
57 resource_string = args[1].substr(7); in ParseRlimit()
59 resource_string = args[1]; in ParseRlimit()
67 return Error() << "Could not parse resource '" << args[1] << "'"; in ParseRlimit()
[all …]
/system/update_engine/scripts/
Dpaycheck.py44 def CheckApplyPayload(args): argument
54 return args.dst_part_paths is not None
56 def ApplyPayload(args): argument
66 return CheckApplyPayload(args) or args.out_dst_part_paths is not None
145 args = parser.parse_args(argv)
148 args.check = (args.check or args.report or args.assert_type or
149 args.block_size or args.allow_unhashed or
150 args.disabled_tests or args.meta_sig or args.key or
151 args.part_sizes is not None or args.metadata_size)
157 if getattr(args, arg) is None:
[all …]
/system/keymaster/android_keymaster/
Dlogger.cpp25 int Logger::Log(LogLevel level, const char* fmt, va_list args) { in Log() argument
27 return instance_->log_msg(level, fmt, args); in Log()
33 va_list args; in Log() local
34 va_start(args, fmt); in Log()
35 int result = Log(level, fmt, args); in Log()
36 va_end(args); in Log()
43 va_list args; in Debug() local
44 va_start(args, fmt); in Debug()
45 int result = Log(DEBUG_LVL, fmt, args); in Debug()
46 va_end(args); in Debug()
[all …]
/system/unwinding/libunwindstack/
DLogAndroid.cpp38 static void LogWithPriority(int priority, uint8_t indent, const char* format, va_list args) { in LogWithPriority() argument
45 LOG_PRI_VA(priority, LOG_TAG, real_format.c_str(), args); in LogWithPriority()
49 va_list args; in Info() local
50 va_start(args, format); in Info()
51 LogWithPriority(ANDROID_LOG_INFO, 0, format, args); in Info()
52 va_end(args); in Info()
56 va_list args; in Info() local
57 va_start(args, format); in Info()
58 LogWithPriority(ANDROID_LOG_INFO, indent, format, args); in Info()
59 va_end(args); in Info()
[all …]
DLogStdout.cpp31 static void PrintToStdout(uint8_t indent, const char* format, va_list args) { in PrintToStdout() argument
40 vprintf(real_format.c_str(), args); in PrintToStdout()
44 va_list args; in Info() local
45 va_start(args, format); in Info()
46 PrintToStdout(0, format, args); in Info()
47 va_end(args); in Info()
51 va_list args; in Info() local
52 va_start(args, format); in Info()
53 PrintToStdout(indent, format, args); in Info()
54 va_end(args); in Info()
[all …]
/system/apex/apexer/
Dapexer.py285 def ValidateArgs(args): argument
288 if args.build_info is not None:
289 if not os.path.exists(args.build_info):
290 print("Build info file '" + args.build_info + "' does not exist")
292 with open(args.build_info, 'rb') as buildInfoFile:
296 if not os.path.exists(args.manifest):
297 print("Manifest file '" + args.manifest + "' does not exist")
300 if not os.path.isfile(args.manifest):
301 print("Manifest file '" + args.manifest + "' is not a file")
304 if args.android_manifest is not None:
[all …]
/system/extras/simpleperf/scripts/inferno/
Dinferno.py53 def collect_data(args): argument
56 if args.app:
57 app_profiler_args += ["-p", args.app]
58 elif args.native_program:
59 app_profiler_args += ["-np", args.native_program]
60 elif args.pid != -1:
61 app_profiler_args += ['--pid', str(args.pid)]
62 elif args.system_wide:
66 if args.compile_java_code:
68 if args.disable_adb_root:
[all …]
/system/sepolicy/build/
Dbuild_sepolicy.py35 def run_host_command(args, **kwargs): argument
38 command_log = args
40 command_log = ' '.join(args) # For args as a sequence.
43 subprocess.check_call(args, **kwargs)
51 def do_build_cil(args): argument
61 input_file_name = os.path.splitext(args.input_policy_conf)[0]
65 checkpolicy_cmd = [args.checkpolicy_env]
66 checkpolicy_cmd += [os.path.join(args.android_host_path, 'checkpolicy'),
67 '-C', '-M', '-c', args.policy_vers,
68 '-o', raw_cil_file, args.input_policy_conf]
[all …]
/system/extras/simpleperf/scripts/
Dipc.py44 def start_profiling(adb, args, target_args): argument
47 '-e', 'instructions', '--interval', str(args.interval * 1000),
48 '--duration', str(args.duration)]
54 def capture_stats(adb, args, stat_subproc): argument
61 if args.cpu == None:
65 if args.cpu == int(columns[0]):
71 if args.cpu == None:
73 elif args.cpu == int(columns[0]):
95 def capture_ipc(args): argument
103 if args.pid:
[all …]
Dapp_profiler.py195 def __init__(self, args): argument
196 self.args = args
197 self.adb = AdbHelper(enable_switch_to_root=not args.disable_adb_root)
221 if self.args.native_lib_dir:
230 downloader = NativeLibDownloader(self.args.ndk_path, self.device_arch, self.adb)
231 downloader.collect_native_libs_on_host(self.args.native_lib_dir)
240 args = ['/data/local/tmp/simpleperf', 'record', '-o', '/data/local/tmp/perf.data',
241 self.args.record_options]
243 args += ['--symfs', NATIVE_LIBS_DIR_ON_DEVICE]
244 args += ['--log', self.args.log]
[all …]
/system/chre/host/common/test/power_test/
Dchre_power_test_client.cc473 bool isTcmArgSpecified(std::vector<string> &args) { in isTcmArgSpecified() argument
474 return !args.empty() && args[0] == "tcm"; in isTcmArgSpecified()
477 inline uint64_t getId(std::vector<string> &args) { in getId() argument
478 return isTcmArgSpecified(args) ? kPowerTestTcmAppId : kPowerTestAppId; in getId()
502 inline const string getPath(std::vector<string> &args) { in getPath() argument
503 if (args.empty()) { in getPath()
506 if (args[0] == "tcm") { in getPath()
507 if (args.size() > 1) { in getPath()
508 return args[1]; in getPath()
512 return args[0]; in getPath()
[all …]
/system/extras/simpleperf/
Dcommand.cpp34 bool Command::NextArgumentOrError(const std::vector<std::string>& args, size_t* pi) { in NextArgumentOrError() argument
35 if (*pi + 1 == args.size()) { in NextArgumentOrError()
36 LOG(ERROR) << "No argument following " << args[*pi] << " option. Try `simpleperf help " << name_ in NextArgumentOrError()
44 bool ConvertArgsToOptions(const std::vector<std::string>& args, in ConvertArgsToOptions() argument
52 for (i = 0; i < args.size() && !args[i].empty() && args[i][0] == '-'; i++) { in ConvertArgsToOptions()
53 auto it = option_formats.find(args[i]); in ConvertArgsToOptions()
55 if (args[i] == "--") { in ConvertArgsToOptions()
59 LOG(ERROR) << "Unknown option " << args[i] << "." << help_msg; in ConvertArgsToOptions()
67 if (i + 1 == args.size()) { in ConvertArgsToOptions()
78 value.str_value = &args[++i]; in ConvertArgsToOptions()
[all …]
/system/extras/perf2cfg/
Dperf2cfg.py77 args = parser.parse_args()
79 if not args.output_file:
80 root, ext = os.path.splitext(args.cfg)
81 args.output_file = f'{root}-annotated{ext}'
83 return args
86 def analyze_record_files(args: argparse.Namespace) -> analyze.RecordAnalyzer:
95 analyzer = analyze.RecordAnalyzer(args.events)
96 for record_file in args.perf_data:
103 args: argparse.Namespace) -> None:
114 if args.primary_event not in analyzer.event_counts:
[all …]
/system/netd/server/
DWakeupController.cpp53 static void extractIpPorts(WakeupController::ReportArgs& args, Slice payload) { in extractIpPorts() argument
54 switch (args.ipNextHeader) { in extractIpPorts()
60 args.srcPort = ntohs(header.th_sport); in extractIpPorts()
61 args.dstPort = ntohs(header.th_dport); in extractIpPorts()
69 args.srcPort = ntohs(header.uh_sport); in extractIpPorts()
70 args.dstPort = ntohs(header.uh_dport); in extractIpPorts()
78 static void extractIpHeader(WakeupController::ReportArgs& args, Slice payload) { in extractIpHeader() argument
79 switch (args.ethertype) { in extractIpHeader()
85 args.ipNextHeader = header.protocol; in extractIpHeader()
88 args.srcIp = addr; in extractIpHeader()
[all …]
/system/sepolicy/tests/
Dsearchpolicy.py39 args = parser.parse_args() variable
41 if not args.tertypes:
44 if not args.policy:
46 if not args.libpath:
49 if not (args.source or args.target or args.tclass or args.perms):
52 pol = policy.Policy(args.policy, None, args.libpath)
54 if args.source:
55 scontext = {args.source}
58 if args.target:
59 tcontext = {args.target}
[all …]

12345678910>>...19