Home
last modified time | relevance | path

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

12345678910>>...21

/system/vold/
Dvdc.cpp75 std::vector<std::string> args(argv + 1, argv + argc); in main() local
77 if (args.size() > 0 && args[0] == "--wait") { in main()
79 args.erase(args.begin()); in main()
82 if (args.size() < 2) { in main()
93 if (args[0] == "cryptfs" && args[1] == "enablefilecrypto") { in main()
94 checkStatus(args, vold->fbeEnable()); in main()
95 } else if (args[0] == "cryptfs" && args[1] == "init_user0") { in main()
96 checkStatus(args, vold->initUser0()); in main()
97 } else if (args[0] == "cryptfs" && args[1] == "enablecrypto") { in main()
100 checkStatus(args, vold->fdeEnable(passwordType, "", encryptionFlags)); in main()
[all …]
/system/bt/vendor_libs/test_vendor_lib/model/controller/
Ddual_mode_controller.h63 virtual void Initialize(const std::vector<std::string>& args) override;
110 void Inquiry(CommandView args);
113 void InquiryCancel(CommandView args);
116 void CreateConnection(CommandView args);
119 void Disconnect(CommandView args);
122 void CreateConnectionCancel(CommandView args);
125 void AcceptConnectionRequest(CommandView args);
128 void RejectConnectionRequest(CommandView args);
131 void LinkKeyRequestReply(CommandView args);
134 void LinkKeyRequestNegativeReply(CommandView args);
[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/core/init/
Dcheck_builtins.cpp44 for (const auto& arg : args) { \
53 Result<void> check_chown(const BuiltinArguments& args) { in check_chown() argument
54 if (!args[1].empty()) { in check_chown()
55 auto uid = DecodeUid(args[1]); in check_chown()
57 return Error() << "Unable to decode UID for '" << args[1] << "': " << uid.error(); in check_chown()
62 if (args.size() == 4 && !args[2].empty()) { in check_chown()
63 auto gid = DecodeUid(args[2]); in check_chown()
65 return Error() << "Unable to decode GID for '" << args[2] << "': " << gid.error(); in check_chown()
72 Result<void> check_exec(const BuiltinArguments& args) { in check_exec() argument
75 auto result = Service::MakeTemporaryOneshotService(args.args); in check_exec()
[all …]
Dcheck_builtins.h25 Result<void> check_chown(const BuiltinArguments& args);
26 Result<void> check_exec(const BuiltinArguments& args);
27 Result<void> check_exec_background(const BuiltinArguments& args);
28 Result<void> check_exec_reboot_on_failure(const BuiltinArguments& args);
29 Result<void> check_interface_restart(const BuiltinArguments& args);
30 Result<void> check_interface_start(const BuiltinArguments& args);
31 Result<void> check_interface_stop(const BuiltinArguments& args);
32 Result<void> check_load_system_props(const BuiltinArguments& args);
33 Result<void> check_loglevel(const BuiltinArguments& args);
34 Result<void> check_mkdir(const BuiltinArguments& args);
[all …]
Dservice_parser.cpp53 Result<void> ServiceParser::ParseCapabilities(std::vector<std::string>&& args) { in ParseCapabilities() argument
66 for (size_t i = 1; i < args.size(); i++) { in ParseCapabilities()
67 const std::string& arg = args[i]; in ParseCapabilities()
81 Result<void> ServiceParser::ParseClass(std::vector<std::string>&& args) { in ParseClass() argument
82 service_->classnames_ = std::set<std::string>(args.begin() + 1, args.end()); in ParseClass()
86 Result<void> ServiceParser::ParseConsole(std::vector<std::string>&& args) { in ParseConsole() argument
91 service_->proc_attr_.console = args.size() > 1 ? "/dev/" + args[1] : ""; in ParseConsole()
95 Result<void> ServiceParser::ParseCritical(std::vector<std::string>&& args) { in ParseCritical() argument
99 for (auto it = args.begin() + 1; it != args.end(); ++it) { in ParseCritical()
133 Result<void> ServiceParser::ParseDisabled(std::vector<std::string>&& args) { in ParseDisabled() argument
[all …]
Dservice_parser.h41 Result<void> ParseSection(std::vector<std::string>&& args, const std::string& filename,
43 Result<void> ParseLineSection(std::vector<std::string>&& args, int line) override;
48 using OptionParser = Result<void> (ServiceParser::*)(std::vector<std::string>&& args);
51 Result<void> ParseCapabilities(std::vector<std::string>&& args);
52 Result<void> ParseClass(std::vector<std::string>&& args);
53 Result<void> ParseConsole(std::vector<std::string>&& args);
54 Result<void> ParseCritical(std::vector<std::string>&& args);
55 Result<void> ParseDisabled(std::vector<std::string>&& args);
56 Result<void> ParseEnterNamespace(std::vector<std::string>&& args);
57 Result<void> ParseGroup(std::vector<std::string>&& 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) { in ParseExternalFirmwareHandlerLine()
[all …]
Dbuiltins.cpp161 static Result<void> do_class_start(const BuiltinArguments& args) { in do_class_start() argument
163 if (android::base::GetBoolProperty("persist.init.dont_start_class." + args[1], false)) in do_class_start()
168 if (service->classnames().count(args[1])) { in do_class_start()
171 << "' as part of class '" << args[1] << "': " << result.error(); in do_class_start()
178 static Result<void> do_class_start_post_data(const BuiltinArguments& args) { in do_class_start_post_data() argument
179 if (args.context != kInitContext) { in do_class_start_post_data()
190 if (service->classnames().count(args[1])) { in do_class_start_post_data()
193 << "' as part of class '" << args[1] << "': " << result.error(); in do_class_start_post_data()
200 static Result<void> do_class_stop(const BuiltinArguments& args) { in do_class_stop() argument
201 ForEachServiceInClass(args[1], &Service::Stop); in do_class_stop()
[all …]
Drlimit_parser.cpp31 Result<std::pair<int, rlimit>> ParseRlimit(const std::vector<std::string>& args) { in ParseRlimit() argument
41 if (ParseInt(args[1], &resource)) { in ParseRlimit()
43 return Error() << "Resource '" << args[1] << "' over the maximum resource value '" in ParseRlimit()
46 return Error() << "Resource '" << args[1] << "' below the minimum resource value '0'"; in ParseRlimit()
50 if (StartsWith(args[1], "RLIM_")) { in ParseRlimit()
51 resource_string = args[1].substr(5); in ParseRlimit()
53 resource_string = args[1]; in ParseRlimit()
61 return Error() << "Could not parse resource '" << args[1] << "'"; in ParseRlimit()
68 if (args[2] == "-1" || args[2] == "unlimited") { in ParseRlimit()
70 } else if (!ParseUint(args[2], &limit.rlim_cur)) { in ParseRlimit()
[all …]
/system/tools/mkbootimg/
Dmkbootimg.py95 def get_recovery_dtbo_offset(args): argument
98 num_kernel_pages = get_number_of_pages(filesize(args.kernel), args.pagesize)
99 num_ramdisk_pages = get_number_of_pages(filesize(args.ramdisk),
100 args.pagesize)
101 num_second_pages = get_number_of_pages(filesize(args.second), args.pagesize)
102 dtbo_offset = args.pagesize * (num_header_pages + num_kernel_pages +
107 def write_header_v3_and_above(args): argument
108 if args.header_version > 3:
113 args.output.write(pack(f'{BOOT_MAGIC_SIZE}s', BOOT_MAGIC.encode()))
115 args.output.write(pack('I', filesize(args.kernel)))
[all …]
Dunpack_bootimg.py131 args = []
132 args.extend(['--header_version', str(self.header_version)])
133 args.extend(['--os_version', self.os_version])
134 args.extend(['--os_patch_level', self.os_patch_level])
136 args.extend(['--kernel', os.path.join(self.image_dir, 'kernel')])
137 args.extend(['--ramdisk', os.path.join(self.image_dir, 'ramdisk')])
141 args.extend(['--second',
144 args.extend(['--recovery_dtbo',
147 args.extend(['--dtb', os.path.join(self.image_dir, 'dtb')])
149 args.extend(['--pagesize', f'{self.page_size:#010x}'])
[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/extras/simpleperf/
Dprofcollect.cpp40 std::vector<std::string> args; in Record() local
41 args.push_back("-a"); in Record()
42 args.insert(args.end(), {"-e", event_name}); in Record()
43 args.insert(args.end(), {"--duration", std::to_string(duration)}); in Record()
44 args.insert(args.end(), {"-o", output}); in Record()
45 return recordCmd->Run(args); in Record()
50 std::vector<std::string> args; in Inject() local
51 args.insert(args.end(), {"-i", traceInput}); in Inject()
52 args.insert(args.end(), {"-o", profileOutput}); in Inject()
53 args.insert(args.end(), {"--output", "branch-list"}); in Inject()
[all …]
/system/apex/apexer/
Dapexer.py259 def ValidateArgs(args): argument
262 if args.build_info is not None:
263 if not os.path.exists(args.build_info):
264 print("Build info file '" + args.build_info + "' does not exist")
266 with open(args.build_info) as buildInfoFile:
270 if not os.path.exists(args.manifest):
271 print("Manifest file '" + args.manifest + "' does not exist")
274 if not os.path.isfile(args.manifest):
275 print("Manifest file '" + args.manifest + "' is not a file")
278 if args.android_manifest is not None:
[all …]
/system/bt/vendor_libs/test_vendor_lib/model/setup/
Dtest_command_handler.cc91 void TestCommandHandler::HandleCommand(const std::string& name, const vector<std::string>& args) { in HandleCommand() argument
97 active_commands_[name](args); in HandleCommand()
125 void TestCommandHandler::Add(const vector<std::string>& args) { in Add() argument
126 if (args.size() < 1) { in Add()
131 std::shared_ptr<Device> new_dev = DeviceBoutique::Create(args); in Add()
134 response_string_ = "TestCommandHandler 'add' " + args[0] + " failed!"; in Add()
146 void TestCommandHandler::AddRemote(const vector<std::string>& args) { in AddRemote() argument
147 if (args.size() < 3) { in AddRemote()
153 size_t port = std::stoi(args[1]); in AddRemote()
155 if ("LOW_ENERGY" == args[2]) { in AddRemote()
[all …]
/system/bt/vendor_libs/test_vendor_lib/scripts/
Dtest_channel.py99 def send_command(self, name, args): argument
101 args_size = len(args)
102 self.lint_command(name, args, name_size, args_size)
104 encoded_args = chr(args_size) + ''.join(chr(len(arg)) + arg for arg in args)
125 def lint_command(self, name, args, name_size, args_size): argument
126 assert name_size == len(name) and args_size == len(args)
129 for arg in args:
136 for arg in args:
157 def do_add(self, args): argument
161 self._test_channel.send_command('add', args.split())
[all …]
/system/sepolicy/build/
Dbuild_sepolicy.py33 def run_host_command(args, **kwargs): argument
36 command_log = args
38 command_log = ' '.join(args) # For args as a sequence.
41 subprocess.check_call(args, **kwargs)
49 def do_build_cil(args): argument
59 input_file_name = os.path.splitext(args.input_policy_conf)[0]
63 checkpolicy_cmd = [args.checkpolicy_env]
64 checkpolicy_cmd += [os.path.join(args.android_host_path, 'checkpolicy'),
65 '-C', '-M', '-c', args.policy_vers,
66 '-o', raw_cil_file, args.input_policy_conf]
[all …]
/system/extras/simpleperf/scripts/inferno/
Dinferno.py51 def collect_data(args): argument
54 if args.app:
55 app_profiler_args += ["-p", args.app]
56 elif args.native_program:
57 app_profiler_args += ["-np", args.native_program]
58 elif args.pid != -1:
59 app_profiler_args += ['--pid', str(args.pid)]
60 elif args.system_wide:
64 if args.compile_java_code:
66 if args.disable_adb_root:
[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/sepolicy/tests/
Dsearchpolicy.py25 args = parser.parse_args() variable
27 if not args.tertypes:
30 if not args.policy:
32 if not args.libpath:
35 if not (args.source or args.target or args.tclass or args.perms):
38 pol = policy.Policy(args.policy, None, args.libpath)
40 if args.source:
41 scontext = {args.source}
44 if args.target:
45 tcontext = {args.target}
[all …]
/system/libvintf/analyze_matrix/
Dhals_for_release.py72 args = parser.parse_args()
74 if args.verbose:
77 if not args.deprecated and not args.unchanged and not args.introduced:
78 args.deprecated = args.introduced = True
81 if host_out and not args.analyze_matrix:
84 args.analyze_matrix = analyze_matrix
85 if not args.analyze_matrix:
86 args.analyze_matrix = "analyze_matrix"
89 if top and not args.input:
90 args.input = os.path.join(top, "hardware", "interfaces", "compatibility_matrices")
[all …]
/system/chre/host/common/test/power_test/
Dchre_power_test_client.cc457 bool isTcmArgSpecified(std::vector<string> &args) { in isTcmArgSpecified() argument
458 return !args.empty() && args[0] == "tcm"; in isTcmArgSpecified()
461 inline uint64_t getId(std::vector<string> &args) { in getId() argument
462 return isTcmArgSpecified(args) ? kPowerTestTcmAppId : kPowerTestAppId; in getId()
486 inline const string getPath(std::vector<string> &args) { in getPath() argument
487 if (args.empty()) { in getPath()
490 if (args[0] == "tcm") { in getPath()
491 if (args.size() > 1) { in getPath()
492 return args[1]; in getPath()
496 return args[0]; in getPath()
[all …]

12345678910>>...21