Home
last modified time | relevance | path

Searched refs:Duration (Results 1 – 25 of 34) sorted by relevance

12

/system/bt/gd/rust/common/src/
Dtime.rs5 use std::time::Duration;
21 pub fn reset(&mut self, duration: Duration) { in reset() argument
30 self.reset(Duration::from_millis(0)); in cancel()
50 pub fn interval(period: Duration) -> Interval { in interval()
86 use std::time::{Duration, Instant};
94 alarm.reset(Duration::from_millis(10)); in alarm_simple_case()
109 alarm.reset(Duration::from_millis(10)); in alarm_clear_ready_after_expired()
112 tokio::time::sleep(Duration::from_millis(10)).await; in alarm_clear_ready_after_expired()
126 interval(Duration::from_millis(10)); in interval_schedule_and_then_drop()
135 let mut interval = interval(Duration::from_millis(10)); in interval_simple_case()
/system/security/keystore2/src/
Dasync_task.rs22 use std::{any::Any, any::TypeId, time::Duration};
92 timeout: Duration,
112 Self::new(Duration::from_secs(30)) in default()
118 pub fn new(timeout: Duration) -> Self { in new()
267 use std::time::Duration;
392 let at = AsyncTask::new(Duration::from_secs(3)); in test_async_task_idle()
402 std::thread::sleep(Duration::from_millis(500)); in test_async_task_idle()
405 std::thread::sleep(Duration::from_millis(500)); in test_async_task_idle()
416 idle_done_receiver.recv_timeout(Duration::from_secs(1)), in test_async_task_idle()
420 idle_done_receiver.recv_timeout(Duration::from_millis(1)).unwrap(); in test_async_task_idle()
[all …]
Dwatchdog.rs29 time::{Duration, Instant},
67 timeout: Duration,
74 fn update_overdue_and_find_next_timeout(&mut self) -> (bool, Option<Duration>) { in update_overdue_and_find_next_timeout() argument
76 let mut next_timeout: Option<Duration> = None; in update_overdue_and_find_next_timeout()
80 if timeout == Duration::new(0, 0) { in update_overdue_and_find_next_timeout()
118 if r.deadline.saturating_duration_since(now) == Duration::new(0, 0) { in log_report()
166 const NOISY_REPORT_TIMEOUT: Duration = Duration::from_secs(1);
171 pub fn new(timeout: Duration) -> Arc<Self> { in new()
191 timeout: Duration, in watch_with_optional() argument
209 timeout: Duration, in watch_with() argument
[all …]
Did_rotation.rs27 use std::time::Duration;
29 const ID_ROTATION_PERIOD: Duration = Duration::from_secs(30 * 24 * 60 * 60); // Thirty days.
Dapc.rs37 use std::time::{Duration, Instant};
135 const ONE_DAY: Duration = Duration::from_secs(60u64 * 60u64 * 24u64);
137 fn get_remaining_back_off(&self) -> Option<Duration> { in get_remaining_back_off() argument
142 3..=5 => Duration::from_secs(30), in get_remaining_back_off()
145 6..=16 => Duration::from_secs(60) in get_remaining_back_off()
Dentropy.rs19 use std::time::{Duration, Instant};
36 Some(last) => now.duration_since(last) > Duration::from_secs(MIN_FEED_INTERVAL_SECS), in register_feeder()
Dutils.rs244 use std::time::Duration;
248 static ref WD: Arc<Watchdog> = Watchdog::new(Duration::from_secs(10));
253 Watchdog::watch(&WD, id, Duration::from_millis(millis)) in watch_millis()
263 Watchdog::watch_with(&WD, id, Duration::from_millis(millis), callback) in watch_millis_with()
Dshared_secret_negotiation.rs27 use std::time::Duration;
240 std::thread::sleep(Duration::from_millis(1000)); in connect_participants()
262 std::thread::sleep(Duration::from_millis(1000)); in negotiate_shared_secret()
Doperation.rs144 time::Duration,
670 age: Duration, in prune()
679 .unwrap_or_else(|| Duration::new(0, 0)); in prune()
/system/apex/tests/src/com/android/tests/apex/
DApexdHostTest.java41 import java.time.Duration;
87 getDevice().waitForBootComplete(Duration.ofMinutes(2).toMillis())).isTrue(); in testOrphanedApexIsNotActivated()
93 Duration.ofMinutes(3)); in testOrphanedApexIsNotActivated()
108 getDevice().waitForBootComplete(Duration.ofMinutes(2).toMillis())).isTrue(); in testApexWithoutPbIsNotActivated()
114 Duration.ofMinutes(3)); in testApexWithoutPbIsNotActivated()
128 getDevice().waitForBootComplete(Duration.ofMinutes(3).toMillis()); in testRemountApex()
139 Thread.sleep(Duration.ofSeconds(15).toMillis()); in testRemountApex()
160 getDevice().waitForBootComplete(Duration.ofMinutes(2).toMillis())).isTrue(); in testApexWithoutPbIsNotActivated_ProductPartitionHasOlderVersion()
170 getDevice().waitForBootComplete(Duration.ofMinutes(2).toMillis())).isTrue(); in testApexWithoutPbIsNotActivated_ProductPartitionHasOlderVersion()
180 Duration.ofMinutes(3)); in testApexWithoutPbIsNotActivated_ProductPartitionHasOlderVersion()
[all …]
DApexE2EBaseHostTest.java41 import java.time.Duration;
52 private static final Duration BOOT_COMPLETE_TIMEOUT = Duration.ofMinutes(2);
DApexRollbackTests.java41 import java.time.Duration;
272 getDevice().waitForBootComplete(Duration.ofMinutes(1).toMillis())).isTrue(); in testApexdDoesNotBootLoopDeviceIfThereIsNothingToRevert()
385 getDevice().waitForBootComplete(Duration.ofMinutes(2).toMillis())).isTrue(); in testBootCompletedCleanupHappensEvenWhenThereIsCrashingProcess()
394 Duration.ofMinutes(3)); in testBootCompletedCleanupHappensEvenWhenThereIsCrashingProcess()
/system/extras/profcollectd/libprofcollectd/
Dconfig.rs27 use std::time::Duration;
54 pub collection_interval: Duration,
56 pub sampling_period: Duration,
67 collection_interval: Duration::from_secs(get_device_config( in from_env()
71 sampling_period: Duration::from_millis(get_device_config("sampling_period", 500)?), in from_env()
Dtrace_provider.rs23 use std::time::Duration;
29 fn trace(&self, trace_dir: &Path, tag: &str, sampling_period: &Duration); in trace() argument
Dsimpleperf_etm_trace_provider.rs22 use std::time::Duration;
37 fn trace(&self, trace_dir: &Path, tag: &str, sampling_period: &Duration) { in trace() argument
Dreport.rs26 use std::time::{Duration, SystemTime};
92 Ok(SystemTime::UNIX_EPOCH + Duration::new(uuid_ts.0, uuid_ts.1)) in get_report_ts()
Dservice.rs28 use std::time::Duration;
177 if report_age > Duration::from_secs(REPORT_RETENTION_SECS) { in new()
/system/extras/simpleperf/rust/
Dlib.rs22 use std::time::Duration;
44 pub fn record(trace_file: &Path, duration: &Duration, scope: RecordScope) { in record() argument
/system/bt/gd/rust/shim/src/
Dmessage_loop_thread.rs6 use std::time::Duration;
77 tokio::time::sleep(Duration::from_millis(delay_ms.try_into().unwrap_or(0))).await; in main_message_loop_thread_do_delayed()
/system/security/keystore2/legacykeystore/
Dlib.rs71 std::thread::sleep(std::time::Duration::from_micros(500)); in with_transaction()
526 use std::time::Duration;
642 if Instant::now().duration_since(test_begin) >= Duration::from_secs(15) { in concurrent_legacy_keystore_entry_test()
656 if Instant::now().duration_since(test_begin) >= Duration::from_secs(40) { in concurrent_legacy_keystore_entry_test()
665 if Instant::now().duration_since(test_begin) >= Duration::from_secs(40) { in concurrent_legacy_keystore_entry_test()
679 if Instant::now().duration_since(test_begin) >= Duration::from_secs(40) { in concurrent_legacy_keystore_entry_test()
692 if Instant::now().duration_since(test_begin) >= Duration::from_secs(40) { in concurrent_legacy_keystore_entry_test()
707 if Instant::now().duration_since(test_begin) >= Duration::from_secs(40) { in concurrent_legacy_keystore_entry_test()
/system/bt/gd/rust/linux/adapter/src/
Dmain.rs8 use std::time::Duration;
148 sleep(Duration::from_millis(5000)).await; in mainloop()
/system/core/debuggerd/client/
Ddebuggerd_client.cpp65 template <typename Duration>
66 static void populate_timeval(struct timeval* tv, const Duration& duration) { in populate_timeval()
/system/bt/gd/rust/hci/src/
Dlib.rs30 use std::time::Duration;
239 hci_timeout.reset(Duration::from_secs(2)); in dispatch()
/system/hardware/interfaces/suspend/1.0/default/
DSuspendProperties.sysprop45 # Duration in milliseconds below which a given suspend is considered a short suspend
/system/apex/tests/src/com/android/tests/apex/host/
DApexCompressionTests.java43 import java.time.Duration;
344 getDevice().waitForBootComplete(Duration.ofMinutes(2).toMillis())).isTrue(); in testFailsToActivateApexOnDataFallbacksToPreInstalled()

12