Home
last modified time | relevance | path

Searched refs:promise (Results 1 – 25 of 82) sorted by relevance

1234

/system/bt/main/shim/
Dconfig.cc38 std::promise<std::string> promise; in checksum_read() local
39 auto future = promise.get_future(); in checksum_read()
43 [](std::promise<std::string>* promise, std::string, in checksum_read()
44 std::string hash_value) { promise->set_value(hash_value); }, in checksum_read() argument
45 &promise), in checksum_read()
51 std::promise<bool> promise; in checksum_save() local
52 auto future = promise.get_future(); in checksum_save()
55 common::BindOnce([](std::promise<bool>* promise, std::string, in checksum_save()
56 bool success) { promise->set_value(success); }, in checksum_save() argument
57 &promise), in checksum_save()
[all …]
/system/bt/gd/common/
Dbidi_queue_unittest.cc71 std::promise<void>* Send(TA* value) { in Send()
72 std::promise<void>* promise = new std::promise<void>(); in Send() local
74 common::Unretained(promise))); in Send()
75 return promise; in Send()
78 std::promise<TB*>* Receive() { in Receive()
79 std::promise<TB*>* promise = new std::promise<TB*>(); in Receive() local
81 …&TestBidiQueueEnd<TA, TB>::handle_receive, common::Unretained(this), common::Unretained(promise))); in Receive()
83 return promise; in Receive()
86 void handle_send(TA* value, std::promise<void>* promise) { in handle_send() argument
88 common::Unretained(value), common::Unretained(promise))); in handle_send()
[all …]
/system/bt/gd/
Dstack_manager.cc39 std::promise<void> promise; in StartUp() local
40 auto future = promise.get_future(); in StartUp()
42 std::move(promise))); in StartUp()
50 …ckManager::handle_start_up(ModuleList* modules, Thread* stack_thread, std::promise<void> promise) { in handle_start_up() argument
52 promise.set_value(); in handle_start_up()
56 std::promise<void> promise; in ShutDown() local
57 auto future = promise.get_future(); in ShutDown()
58 …t(common::BindOnce(&StackManager::handle_shut_down, common::Unretained(this), std::move(promise))); in ShutDown()
69 void StackManager::handle_shut_down(std::promise<void> promise) { in handle_shut_down() argument
71 promise.set_value(); in handle_shut_down()
Dstack_manager.h40 void handle_start_up(ModuleList* modules, os::Thread* stack_thread, std::promise<void> promise);
41 void handle_shut_down(std::promise<void> promise);
/system/bt/common/
Donce_timer.cc68 std::promise<void> promise; in Cancel() local
69 CancelHelper(std::move(promise)); in Cancel()
74 std::promise<void> promise; in CancelAndWait() local
75 auto future = promise.get_future(); in CancelAndWait()
76 CancelHelper(std::move(promise)); in CancelAndWait()
81 void OnceTimer::CancelHelper(std::promise<void> promise) { in CancelHelper() argument
85 promise.set_value(); in CancelHelper()
89 CancelClosure(std::move(promise)); in CancelHelper()
94 base::Unretained(this), std::move(promise))); in CancelHelper()
98 void OnceTimer::CancelClosure(std::promise<void> promise) { in CancelClosure() argument
[all …]
Drepeating_timer.cc78 std::promise<void> promise; in Cancel() local
79 CancelHelper(std::move(promise)); in Cancel()
84 std::promise<void> promise; in CancelAndWait() local
85 auto future = promise.get_future(); in CancelAndWait()
86 CancelHelper(std::move(promise)); in CancelAndWait()
91 void RepeatingTimer::CancelHelper(std::promise<void> promise) { in CancelHelper() argument
95 promise.set_value(); in CancelHelper()
99 CancelClosure(std::move(promise)); in CancelHelper()
104 base::Unretained(this), std::move(promise))); in CancelHelper()
108 void RepeatingTimer::CancelClosure(std::promise<void> promise) { in CancelClosure() argument
[all …]
Drepeating_timer_unittest.cc39 void IncreaseTaskCounter(int scheduled_tasks, std::promise<void>* promise) { in IncreaseTaskCounter() argument
42 promise->set_value(); in IncreaseTaskCounter()
46 void GetName(std::string* name, std::promise<void>* promise) { in GetName() argument
50 promise->set_value(); in GetName()
53 void SleepAndIncreaseCounter(std::promise<void>* promise, int sleep_ms) { in SleepAndIncreaseCounter() argument
54 promise->set_value(); in SleepAndIncreaseCounter()
62 std::promise<void>* promise) { in VerifyDelayTimeAndSleep() argument
69 promise->set_value(); in VerifyDelayTimeAndSleep()
101 promise_ = new std::promise<void>(); in SetUp()
117 std::promise<void>* promise_;
Donce_timer.h81 void CancelHelper(std::promise<void> promise);
82 void CancelClosure(std::promise<void> promise);
Drepeating_timer.h82 void CancelHelper(std::promise<void> promise);
83 void CancelClosure(std::promise<void> promise);
Donce_timer_unittest.cc39 void IncreaseTaskCounter(int scheduled_tasks, std::promise<void>* promise) { in IncreaseTaskCounter() argument
42 promise->set_value(); in IncreaseTaskCounter()
46 void GetName(std::string* name, std::promise<void>* promise) { in GetName() argument
50 promise->set_value(); in GetName()
53 void SleepAndIncreaseCounter(std::promise<void>* promise, int sleep_ms) { in SleepAndIncreaseCounter() argument
54 promise->set_value(); in SleepAndIncreaseCounter()
66 promise_ = new std::promise<void>(); in SetUp()
82 std::promise<void>* promise_;
/system/bt/gd/os/linux_generic/
Drepeating_alarm_unittest.cc46 std::promise<void> promise; in VerifyMultipleDelayedTasks() local
47 auto future = promise.get_future(); in VerifyMultipleDelayedTasks()
52 … common::Unretained(&promise), task_length_ms, interval_between_tasks_ms), in VerifyMultipleDelayedTasks()
59 … std::promise<void>* promise, int task_length_ms, int interval_between_tasks_ms) { in verify_delayed_tasks() argument
64 promise->set_value(); in verify_delayed_tasks()
84 std::promise<void> promise; in TEST_F() local
85 auto future = promise.get_future(); in TEST_F()
88 alarm_->Schedule(common::Bind(&std::promise<void>::set_value, common::Unretained(&promise)), in TEST_F()
111 std::promise<void> promise; in TEST_F() local
112 auto future = promise.get_future(); in TEST_F()
[all …]
Dalarm_unittest.cc56 std::promise<void> promise; in TEST_F() local
57 auto future = promise.get_future(); in TEST_F()
61 alarm_->Schedule(BindOnce(&std::promise<void>::set_value, common::Unretained(&promise)), in TEST_F()
82 std::promise<void> promise; in TEST_F() local
83 auto future = promise.get_future(); in TEST_F()
84 alarm_->Schedule(BindOnce(&std::promise<void>::set_value, common::Unretained(&promise)), in TEST_F()
Dhandler_unittest.cc53 std::promise<void> closure_ran; in TEST_F()
56 [](int* val, std::promise<void> closure_ran) { in TEST_F()
69 std::promise<void> closure_started; in TEST_F()
71 std::promise<void> closure_can_continue; in TEST_F()
74 [](int* val, std::promise<void> closure_started, std::future<void> can_continue_future) { in TEST_F()
101 std::promise<void> promise; in TEST_F() local
102 auto future = promise.get_future(); in TEST_F()
103 …auto once_callback = common::BindOnce(&std::promise<void>::set_value, common::Unretained(&promise)… in TEST_F()
Dqueue_unittest.cc70 void RegisterEnqueue(std::unordered_map<int, std::promise<int>>* promise_map) { in RegisterEnqueue()
76 std::promise<void> promise; in UnregisterEnqueue() local
77 auto future = promise.get_future(); in UnregisterEnqueue()
80 …indOnce(&TestEnqueueEnd::handle_unregister_enqueue, common::Unretained(this), std::move(promise))); in UnregisterEnqueue()
115 std::unordered_map<int, std::promise<int>>* promise_map_;
122 void handle_unregister_enqueue(std::promise<void> promise) { in handle_unregister_enqueue() argument
124 promise.set_value(); in handle_unregister_enqueue()
135 void RegisterDequeue(std::unordered_map<int, std::promise<int>>* promise_map) { in RegisterDequeue()
141 std::promise<void> promise; in UnregisterDequeue() local
142 auto future = promise.get_future(); in UnregisterDequeue()
[all …]
/system/bt/gd/shim/
Ddumpsys.cc40 void Dump(int fd, std::promise<void> promise);
52 void Dumpsys::impl::Dump(int fd, std::promise<void> promise) { in Dump() argument
56 promise.set_value(); in Dump()
70 std::promise<void> promise; in Dump() local
71 auto future = promise.get_future(); in Dump()
72 …(common::BindOnce(&Dumpsys::impl::Dump, common::Unretained(pimpl_.get()), fd, std::move(promise))); in Dump()
Dl2cap_test.cc67 std::promise<void> connection_closed_promise_;
100 connected_promise_ = std::promise<void>(); in SetConnectionFuture()
109 register_promise_ = std::promise<void>(); in SetRegistrationFuture()
117 …nFail(l2cap::classic::DynamicChannelManager::ConnectionResult result, std::promise<void> promise) { in SetConnectionOnFail() argument
119 promise.set_value(); in SetConnectionOnFail()
122 …d SetConnectionOnOpen(std::unique_ptr<l2cap::DynamicChannel> channel, std::promise<void> promise) { in SetConnectionOnOpen() argument
124 promise.set_value(); in SetConnectionOnOpen()
135 std::promise<void> connected_promise_;
138 std::promise<void> register_promise_;
197 std::promise<uint16_t> promise; in CreateConnection() local
[all …]
/system/bt/gd/l2cap/classic/internal/
Dsignalling_manager_test.cc39 std::promise<void> promise; in SyncHandler() local
40 auto future = promise.get_future(); in SyncHandler()
41 handler->Post(common::BindOnce(&std::promise<void>::set_value, common::Unretained(&promise))); in SyncHandler()
Dfixed_channel_service_manager_test.cc60 std::promise<void> promise; in sync_user_handler() local
61 auto future = promise.get_future(); in sync_user_handler()
62 …user_handler_->Post(common::BindOnce(&std::promise<void>::set_value, common::Unretained(&promise))… in sync_user_handler()
/system/bt/test/headless/sdp/
Dsdp.cc33 auto promise = static_cast<std::promise<uint16_t>*>(user_data); in bta_jv_start_discovery_callback() local
34 promise->set_value(result); in bta_jv_start_discovery_callback()
92 std::promise<uint16_t> promise; in sdp_query_uuid() local
93 auto future = promise.get_future(); in sdp_query_uuid()
99 bta_jv_start_discovery_callback, (void*)&promise)) { in sdp_query_uuid()
/system/bt/gd/os/
Dqueue_benchmark.cc60 …EnqueueEnd(int64_t count, Queue<std::string>* queue, Handler* handler, std::promise<void>* promise) in TestEnqueueEnd() argument
61 : count_(count), handler_(handler), queue_(queue), promise_(promise) {} in TestEnqueueEnd()
100 std::promise<void>* promise_;
110 …DequeueEnd(int64_t count, Queue<std::string>* queue, Handler* handler, std::promise<void>* promise) in TestDequeueEnd() argument
111 : count_(count), handler_(handler), queue_(queue), promise_(promise) {} in TestDequeueEnd()
134 std::promise<void>* promise_;
147 std::promise<void> dequeue_promise; in BENCHMARK_DEFINE_F()
153 std::promise<void> enqueue_promise; in BENCHMARK_DEFINE_F()
181 std::promise<void> dequeue_promise; in BENCHMARK_DEFINE_F()
187 std::promise<void> enqueue_promise; in BENCHMARK_DEFINE_F()
/system/bt/common/benchmark/
Dthread_performance_benchmark.cc36 static std::unique_ptr<std::promise<void>> g_counter_promise = nullptr;
69 set_up_promise_ = std::make_unique<std::promise<void>>(); in SetUp()
81 std::unique_ptr<std::promise<void>> set_up_promise_;
99 FROM_HERE, base::BindOnce(&std::promise<void>::set_value, in RunMessageLoop()
137 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
151 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
184 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
198 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
229 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
243 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
[all …]
/system/security/keystore/
Dkeystore_client_impl.cpp183 android::sp<KeystoreResponsePromise> promise(new KeystoreResponsePromise()); in addRandomNumberGeneratorEntropy() local
184 auto future = promise->get_future(); in addRandomNumberGeneratorEntropy()
187 keystore_->addRngEntropy(promise, blob2hidlVec(entropy), flags, &error_code); in addRandomNumberGeneratorEntropy()
204 android::sp<KeyCharacteristicsPromise> promise(new KeyCharacteristicsPromise); in generateKey() local
205 auto future = promise->get_future(); in generateKey()
207 promise, key_name16, in generateKey()
231 android::sp<KeyCharacteristicsPromise> promise(new KeyCharacteristicsPromise); in getKeyCharacteristics() local
232 auto future = promise->get_future(); in getKeyCharacteristics()
234 promise, key_name16, android::security::keymaster::KeymasterBlob(), in getKeyCharacteristics()
259 android::sp<KeyCharacteristicsPromise> promise(new KeyCharacteristicsPromise); in importKey() local
[all …]
/system/bt/gd/l2cap/le/internal/
Dfixed_channel_service_manager_test.cc60 std::promise<void> promise; in sync_user_handler() local
61 auto future = promise.get_future(); in sync_user_handler()
62 …user_handler_->Post(common::BindOnce(&std::promise<void>::set_value, common::Unretained(&promise))… in sync_user_handler()
/system/security/keystore-engine/
Dkeystore_backend_binder.cpp141 sp<OperationResultPromise> promise(new OperationResultPromise()); in sign() local
142 auto future = promise->get_future(); in sign()
143 binder_result = service->begin(promise, token, key_name16, (int)KeyPurpose::SIGN, in sign()
166 promise = new OperationResultPromise(); in sign()
167 future = promise->get_future(); in sign()
168 binder_result = service->update(promise, handle, KeymasterArguments(params), in sign()
211 promise = new OperationResultPromise(); in sign()
212 future = promise->get_future(); in sign()
215 promise, handle, KeymasterArguments(params), std::vector<uint8_t>() /* input */, in sign()
257 android::sp<KeystoreExportPromise> promise(new KeystoreExportPromise); in get_pubkey() local
[all …]
/system/bt/btif/include/
Dbtif_a2dp_source.h42 std::promise<void> peer_ready_promise);
53 std::promise<void> peer_ready_promise);
93 std::promise<void> peer_ready_promise);

1234