/system/media/audio_utils/ |
D | tinysndfile.c | 75 SNDFILE *handle = (SNDFILE *) malloc(sizeof(SNDFILE)); in sf_open_read() local 76 handle->mode = SFM_READ; in sf_open_read() 77 handle->temp = NULL; in sf_open_read() 78 handle->stream = stream; in sf_open_read() 79 handle->info.format = SF_FORMAT_WAV; in sf_open_read() 209 handle->bytesPerFrame = bytesPerFrame; in sf_open_read() 210 handle->info.samplerate = samplerate; in sf_open_read() 211 handle->info.channels = channels; in sf_open_read() 214 handle->info.format |= SF_FORMAT_PCM_U8; in sf_open_read() 217 handle->info.format |= SF_FORMAT_PCM_16; in sf_open_read() [all …]
|
/system/bt/vendor_libs/test_vendor_lib/model/controller/ |
D | acl_connection_handler.cc | 30 bool AclConnectionHandler::HasHandle(uint16_t handle) const { in HasHandle() 31 if (acl_connections_.count(handle) == 0) { in HasHandle() 69 uint16_t handle = GetUnusedHandle(); in CreateConnection() local 70 acl_connections_.emplace(handle, addr); in CreateConnection() 71 SetConnected(handle, true); in CreateConnection() 72 return handle; in CreateConnection() 77 bool AclConnectionHandler::Disconnect(uint16_t handle) { in Disconnect() argument 78 return acl_connections_.erase(handle) > 0; in Disconnect() 90 const Address& AclConnectionHandler::GetAddress(uint16_t handle) const { in GetAddress() 91 CHECK(HasHandle(handle)) << "Handle unknown " << handle; in GetAddress() [all …]
|
/system/core/adb/client/ |
D | usb_windows.cpp | 91 int register_new_device(usb_handle* handle); 94 int recognized_device(usb_handle* handle); 114 int usb_write(usb_handle* handle, const void* data, int len); 117 int usb_read(usb_handle* handle, void* data, int len); 120 void usb_cleanup_handle(usb_handle* handle); 123 void usb_kick(usb_handle* handle); 126 int usb_close(usb_handle* handle); 153 int register_new_device(usb_handle* handle) { in register_new_device() argument 154 if (nullptr == handle) return 0; in register_new_device() 159 if (known_device_locked(handle->interface_name)) { in register_new_device() [all …]
|
D | usb_osx.cpp | 89 static void usb_kick_locked(usb_handle* handle); 102 static void AddDevice(std::unique_ptr<usb_handle> handle) { in AddDevice() argument 103 handle->mark = true; in AddDevice() 105 g_usb_handles.push_back(std::move(handle)); in AddDevice() 298 std::unique_ptr<usb_handle> handle = in AndroidInterfaceAdded() local 300 if (handle == nullptr) { in AndroidInterfaceAdded() 305 handle->devpath = devpath; in AndroidInterfaceAdded() 306 usb_handle* handle_p = handle.get(); in AndroidInterfaceAdded() 308 LOG(INFO) << "reported max packet size for " << serial << " is " << handle->max_packet_size; in AndroidInterfaceAdded() 309 AddDevice(std::move(handle)); in AndroidInterfaceAdded() [all …]
|
/system/bt/btif/src/ |
D | btif_sock_sdp.cc | 163 uint32_t handle = SDP_CreateRecord(); in add_sdp_by_uuid() local 164 if (handle == 0) { in add_sdp_by_uuid() 183 if (!create_base_record(handle, name, channel, false /* with_obex */)) in add_sdp_by_uuid() 193 if (!SDP_AddSequence(handle, (uint16_t)ATTR_ID_SERVICE_CLASS_ID_LIST, 1, in add_sdp_by_uuid() 199 __func__, name, handle); in add_sdp_by_uuid() 200 return handle; in add_sdp_by_uuid() 203 SDP_DeleteRecord(handle); in add_sdp_by_uuid() 214 uint32_t handle = SDP_CreateRecord(); in add_pbap_sdp() local 215 if (handle == 0) { in add_pbap_sdp() 227 if (!create_base_record(handle, name, channel, true /* with_obex */)) in add_pbap_sdp() [all …]
|
D | btif_avrcp_audio_track.cc | 78 void BtifAvrcpAudioTrackStart(void* handle) { in BtifAvrcpAudioTrackStart() argument 79 if (handle == NULL) { in BtifAvrcpAudioTrackStart() 83 BtifAvrcpAudioTrack* trackHolder = static_cast<BtifAvrcpAudioTrack*>(handle); in BtifAvrcpAudioTrackStart() 90 void BtifAvrcpAudioTrackStop(void* handle) { in BtifAvrcpAudioTrackStop() argument 91 if (handle == NULL) { in BtifAvrcpAudioTrackStop() 95 BtifAvrcpAudioTrack* trackHolder = static_cast<BtifAvrcpAudioTrack*>(handle); in BtifAvrcpAudioTrackStop() 102 void BtifAvrcpAudioTrackDelete(void* handle) { in BtifAvrcpAudioTrackDelete() argument 103 if (handle == NULL) { in BtifAvrcpAudioTrackDelete() 107 BtifAvrcpAudioTrack* trackHolder = static_cast<BtifAvrcpAudioTrack*>(handle); in BtifAvrcpAudioTrackDelete() 121 void BtifAvrcpAudioTrackPause(void* handle) { in BtifAvrcpAudioTrackPause() argument [all …]
|
/system/chre/core/ |
D | audio_request_manager.cc | 56 uint32_t handle, in configureSource() argument 61 return validateConfigureSourceArguments(handle, enable, bufferDuration, in configureSource() 63 && doConfigureSource(nanoapp->getInstanceId(), handle, enable, numSamples, in configureSource() 83 void AudioRequestManager::handleAudioAvailability(uint32_t handle, bool available) { in handleAudioAvailability() argument 85 uint32_t handle; in handleAudioAvailability() member 93 cbState->handle = handle; in handleAudioAvailability() 99 .handleAudioAvailabilitySync(state->handle, state->available); in handleAudioAvailability() 112 uint32_t handle = static_cast<uint32_t>(i); in logStateToBuffer() local 114 mPlatformAudio.getAudioSource(handle, &source); in logStateToBuffer() 118 handle, source.name, source.sampleRate, in logStateToBuffer() [all …]
|
/system/bt/stack/pan/ |
D | pan_main.cc | 90 void pan_conn_ind_cb(uint16_t handle, const RawAddress& p_bda, in pan_conn_ind_cb() argument 101 BNEP_ConnectResp(handle, BNEP_CONN_FAILED_SRC_UUID); in pan_conn_ind_cb() 107 BNEP_ConnectResp(handle, BNEP_CONN_FAILED_DST_UUID); in pan_conn_ind_cb() 117 __func__, handle, pan_cb.role, local_uuid16, remote_uuid16, in pan_conn_ind_cb() 125 BNEP_ConnectResp(handle, BNEP_CONN_FAILED_SRC_UUID); in pan_conn_ind_cb() 133 BNEP_ConnectResp(handle, BNEP_CONN_FAILED_DST_UUID); in pan_conn_ind_cb() 147 BNEP_ConnectResp(handle, BNEP_CONN_FAILED_DST_UUID); in pan_conn_ind_cb() 179 BNEP_ConnectResp(handle, BNEP_CONN_FAILED_SRC_UUID); in pan_conn_ind_cb() 195 tPAN_CONN* pcb = pan_get_pcb_by_handle(handle); in pan_conn_ind_cb() 204 BNEP_ConnectResp(handle, BNEP_CONN_FAILED_DST_UUID); in pan_conn_ind_cb() [all …]
|
/system/core/trusty/storage/tests/ |
D | main.cpp | 102 void WriteReadAtOffsetHelper(file_handle_t handle, size_t blk, size_t cnt, bool complete); 104 void WriteZeroChunk(file_handle_t handle, storage_off_t off, size_t chunk_len, bool complete ); 105 … void WritePatternChunk(file_handle_t handle, storage_off_t off, size_t chunk_len, bool complete); 106 …void WritePattern(file_handle_t handle, storage_off_t off, size_t data_len, size_t chunk_len, bool… 108 void ReadChunk(file_handle_t handle, storage_off_t off, size_t chunk_len, 110 void ReadPattern(file_handle_t handle, storage_off_t off, size_t data_len, size_t chunk_len); 111 void ReadPatternEOF(file_handle_t handle, storage_off_t off, size_t chunk_len, size_t exp_len); 125 void StorageServiceTest::WriteZeroChunk(file_handle_t handle, storage_off_t off, in WriteZeroChunk() argument 136 rc = storage_write(handle, off, data_buf, sizeof(data_buf), in WriteZeroChunk() 141 void StorageServiceTest::WritePatternChunk(file_handle_t handle, storage_off_t off, in WritePatternChunk() argument [all …]
|
/system/vold/bench/ |
D | benchgen.py | 69 handle = "t%sf%s" % (e.thread, fd) 70 return (fd, find_file(path), handle) 188 fd, f, handle = extract_file(e, e.ret) variable 190 active.add(handle) 191 if handle not in defined: 193 defined.add(handle) 199 % (handle, f.ident, e.args[2], create_mode) 202 fd, f, handle = extract_file(e, e.args[0]) variable 203 if handle in active: 204 active.remove(handle) [all …]
|
/system/core/fastboot/ |
D | usb_windows.cpp | 71 WindowsUsbTransport(std::unique_ptr<usb_handle> handle) : handle_(std::move(handle)) {} in WindowsUsbTransport() argument 89 int recognized_device(usb_handle* handle, ifc_match_func callback); 95 void usb_cleanup_handle(usb_handle* handle); 98 void usb_kick(usb_handle* handle); 228 void usb_cleanup_handle(usb_handle* handle) { in usb_cleanup_handle() argument 229 if (NULL != handle) { in usb_cleanup_handle() 230 if (NULL != handle->adb_write_pipe) in usb_cleanup_handle() 231 AdbCloseHandle(handle->adb_write_pipe); in usb_cleanup_handle() 232 if (NULL != handle->adb_read_pipe) in usb_cleanup_handle() 233 AdbCloseHandle(handle->adb_read_pipe); in usb_cleanup_handle() [all …]
|
D | usb_osx.cpp | 71 OsxUsbTransport(std::unique_ptr<usb_handle> handle, uint32_t ms_timeout = 0) in OsxUsbTransport() argument 72 : handle_(std::move(handle)), ms_timeout_(ms_timeout) {} in OsxUsbTransport() 89 static int try_interfaces(IOUSBDeviceInterface500** dev, usb_handle* handle) { in try_interfaces() argument 181 if ((*interface)->GetInterfaceClass(interface, &handle->info.ifc_class) != 0 || in try_interfaces() 182 (*interface)->GetInterfaceSubClass(interface, &handle->info.ifc_subclass) != 0 || in try_interfaces() 183 (*interface)->GetInterfaceProtocol(interface, &handle->info.ifc_protocol) != 0) in try_interfaces() 189 handle->info.has_bulk_in = 0; in try_interfaces() 190 handle->info.has_bulk_out = 0; in try_interfaces() 211 handle->info.has_bulk_in = 1; in try_interfaces() 212 handle->bulkIn = endpoint; in try_interfaces() [all …]
|
/system/core/libziparchive/ |
D | zip_archive_test.cc | 61 static int32_t OpenArchiveWrapper(const std::string& name, ZipArchiveHandle* handle) { in OpenArchiveWrapper() argument 63 return OpenArchive(abs_path.c_str(), handle); in OpenArchiveWrapper() 72 ZipArchiveHandle handle; in TEST() local 73 ASSERT_EQ(0, OpenArchiveWrapper(kValidZip, &handle)); in TEST() 74 CloseArchive(handle); in TEST() 76 ASSERT_EQ(-1, OpenArchiveWrapper(kBadFilenameZip, &handle)); in TEST() 77 CloseArchive(handle); in TEST() 81 ZipArchiveHandle handle; in TEST() local 82 ASSERT_EQ(-8, OpenArchiveWrapper(kCrashApk, &handle)); in TEST() 83 CloseArchive(handle); in TEST() [all …]
|
D | zip_writer_test.cc | 27 ZipArchiveHandle handle, 61 ZipArchiveHandle handle; in TEST_F() local 62 ASSERT_EQ(0, OpenArchiveFd(fd_, "temp", &handle, false)); in TEST_F() 65 ASSERT_EQ(0, FindEntry(handle, ZipString("file.txt"), &data)); in TEST_F() 70 ASSERT_TRUE(AssertFileEntryContentsEq(expected, handle, &data)); in TEST_F() 72 CloseArchive(handle); in TEST_F() 93 ZipArchiveHandle handle; in TEST_F() local 94 ASSERT_EQ(0, OpenArchiveFd(fd_, "temp", &handle, false)); in TEST_F() 98 ASSERT_EQ(0, FindEntry(handle, ZipString("file.txt"), &data)); in TEST_F() 102 ASSERT_TRUE(AssertFileEntryContentsEq("he", handle, &data)); in TEST_F() [all …]
|
/system/bt/bta/gatt/ |
D | database.cc | 38 bool HandleInRange(const Service& svc, uint16_t handle) { in HandleInRange() argument 39 return handle >= svc.handle && handle <= svc.end_handle; in HandleInRange() 43 Service* FindService(std::list<Service>& services, uint16_t handle) { in FindService() argument 45 if (handle >= service.handle && handle <= service.end_handle) in FindService() 56 tmp << "Service: handle=" << loghex(service.handle) in ToString() 61 tmp << "\t Included service: handle=" << loghex(is.handle) in ToString() 74 tmp << "\t\t Descriptor: handle=" << loghex(d.handle) in ToString() 89 nv_attr.push_back({service.handle, in Serialize() 97 nv_attr.push_back({p_isvc.handle, in Serialize() 99 {.included_service = {.handle = p_isvc.start_handle, in Serialize() [all …]
|
D | database_builder.cc | 30 void DatabaseBuilder::AddService(uint16_t handle, uint16_t end_handle, in AddService() argument 34 database.services.back().end_handle < handle) { in AddService() 35 database.services.emplace_back(Service{.handle = handle, in AddService() 44 vec.begin(), vec.end(), handle, in AddService() 45 [](Service s, uint16_t handle) { return s.end_handle < handle; }); in AddService() argument 48 vec.emplace(it, Service{.handle = handle, in AddService() 54 services_to_discover.insert({handle, end_handle}); in AddService() 57 void DatabaseBuilder::AddIncludedService(uint16_t handle, const Uuid& uuid, in AddIncludedService() argument 60 Service* service = FindService(database.services, handle); in AddIncludedService() 73 .handle = handle, in AddIncludedService() [all …]
|
/system/bt/bta/pan/ |
D | bta_pan_ci.cc | 54 void bta_pan_ci_tx_ready(uint16_t handle) { in bta_pan_ci_tx_ready() argument 57 p_buf->layer_specific = handle; in bta_pan_ci_tx_ready() 76 void bta_pan_ci_rx_ready(uint16_t handle) { in bta_pan_ci_rx_ready() argument 79 p_buf->layer_specific = handle; in bta_pan_ci_rx_ready() 100 void bta_pan_ci_tx_flow(uint16_t handle, bool enable) { in bta_pan_ci_tx_flow() argument 104 p_buf->hdr.layer_specific = handle; in bta_pan_ci_tx_flow() 123 void bta_pan_ci_rx_write(uint16_t handle, const RawAddress& dst, in bta_pan_ci_rx_write() argument 140 p_buf->layer_specific = handle; in bta_pan_ci_rx_write() 160 void bta_pan_ci_rx_writebuf(uint16_t handle, const RawAddress& dst, in bta_pan_ci_rx_writebuf() argument 169 p_buf->layer_specific = handle; in bta_pan_ci_rx_writebuf() [all …]
|
/system/bt/bta/jv/ |
D | bta_jv_api.cc | 73 bta_jv_cb.pm_cb[i].handle = BTA_JV_PM_HANDLE_CLEAR; in BTA_JvEnable() 224 tBTA_JV_STATUS BTA_JvDeleteRecord(uint32_t handle) { in BTA_JvDeleteRecord() argument 227 do_in_main_thread(FROM_HERE, Bind(&bta_jv_delete_record, handle)); in BTA_JvDeleteRecord() 290 tBTA_JV_STATUS BTA_JvL2capClose(uint32_t handle) { in BTA_JvL2capClose() argument 293 if (handle >= BTA_JV_MAX_L2C_CONN || !bta_jv_cb.l2c_cb[handle].p_cback) in BTA_JvL2capClose() 297 FROM_HERE, Bind(&bta_jv_l2cap_close, handle, &bta_jv_cb.l2c_cb[handle])); in BTA_JvL2capClose() 312 tBTA_JV_STATUS BTA_JvL2capCloseLE(uint32_t handle) { in BTA_JvL2capCloseLE() argument 315 do_in_main_thread(FROM_HERE, Bind(&bta_jv_l2cap_close_fixed, handle)); in BTA_JvL2capCloseLE() 421 tBTA_JV_STATUS BTA_JvL2capRead(uint32_t handle, uint32_t req_id, in BTA_JvL2capRead() argument 425 if (handle >= BTA_JV_MAX_L2C_CONN || !bta_jv_cb.l2c_cb[handle].p_cback) in BTA_JvL2capRead() [all …]
|
/system/bt/stack/rfcomm/ |
D | port_api.cc | 157 << ", port=" << std::to_string(p_port->handle); in RFCOMM_CreateConnection() 158 *p_handle = p_port->handle; in RFCOMM_CreateConnection() 173 *p_handle = p_port->handle; in RFCOMM_CreateConnection() 252 int RFCOMM_RemoveConnection(uint16_t handle) { in RFCOMM_RemoveConnection() argument 255 RFCOMM_TRACE_API("RFCOMM_RemoveConnection() handle:%d", handle); in RFCOMM_RemoveConnection() 258 if ((handle == 0) || (handle > MAX_RFC_PORTS)) { in RFCOMM_RemoveConnection() 259 RFCOMM_TRACE_ERROR("RFCOMM_RemoveConnection() BAD handle:%d", handle); in RFCOMM_RemoveConnection() 262 p_port = &rfc_cb.port.port[handle - 1]; in RFCOMM_RemoveConnection() 265 RFCOMM_TRACE_EVENT("RFCOMM_RemoveConnection() Not opened:%d", handle); in RFCOMM_RemoveConnection() 285 int RFCOMM_RemoveServer(uint16_t handle) { in RFCOMM_RemoveServer() argument [all …]
|
/system/core/libcutils/ |
D | native_handle.cpp | 31 native_handle_t* handle = (native_handle_t*) storage; in native_handle_init() local 32 handle->version = sizeof(native_handle_t); in native_handle_init() 33 handle->numFds = numFds; in native_handle_init() 34 handle->numInts = numInts; in native_handle_init() 35 return handle; in native_handle_init() 55 native_handle_t* native_handle_clone(const native_handle_t* handle) { in native_handle_clone() argument 56 native_handle_t* clone = native_handle_create(handle->numFds, handle->numInts); in native_handle_clone() 59 for (int i = 0; i < handle->numFds; i++) { in native_handle_clone() 60 clone->data[i] = dup(handle->data[i]); in native_handle_clone() 69 memcpy(&clone->data[handle->numFds], &handle->data[handle->numFds], in native_handle_clone() [all …]
|
/system/bt/btif/co/ |
D | bta_pan_co.cc | 75 void bta_pan_co_open(uint16_t handle, uint8_t app_id, tBTA_PAN_ROLE local_role, in bta_pan_co_open() argument 80 app_id, local_role, peer_role, handle); in bta_pan_co_open() 83 conn = btpan_new_conn(handle, peer_addr, local_role, peer_role); in bta_pan_co_open() 88 btpan_cb.tap_fd, btpan_cb.open_count, conn->handle, handle, in bta_pan_co_open() 93 conn->handle = handle; in bta_pan_co_open() 102 bta_pan_ci_rx_ready(handle); in bta_pan_co_open() 118 void bta_pan_co_close(uint16_t handle, uint8_t app_id) { in bta_pan_co_close() argument 119 BTIF_TRACE_API("bta_pan_co_close:app_id:%d, handle:%d", app_id, handle); in bta_pan_co_close() 120 btpan_conn_t* conn = btpan_find_conn_handle(handle); in bta_pan_co_close() 154 void bta_pan_co_tx_path(uint16_t handle, uint8_t app_id) { in bta_pan_co_tx_path() argument [all …]
|
/system/core/libion/tests/ |
D | allocate_test.cpp | 35 ion_user_handle_t handle = 0; in TEST_F() local 36 ASSERT_EQ(0, ion_alloc(m_ionFd, size, 0, heapMask, 0, &handle)); in TEST_F() 37 ASSERT_TRUE(handle != 0); in TEST_F() 38 ASSERT_EQ(0, ion_free(m_ionFd, handle)); in TEST_F() 50 ion_user_handle_t handle = 0; in TEST_F() local 51 ASSERT_EQ(0, ion_alloc(m_ionFd, size, 0, heapMask, ION_FLAG_CACHED, &handle)); in TEST_F() 52 ASSERT_TRUE(handle != 0); in TEST_F() 53 ASSERT_EQ(0, ion_free(m_ionFd, handle)); in TEST_F() 65 ion_user_handle_t handle = 0; in TEST_F() local 66 … ASSERT_EQ(0, ion_alloc(m_ionFd, size, 0, heapMask, ION_FLAG_CACHED_NEEDS_SYNC, &handle)); in TEST_F() [all …]
|
/system/bt/bta/ag/ |
D | bta_ag_api.cc | 112 void BTA_AgDeregister(uint16_t handle) { in BTA_AgDeregister() argument 114 FROM_HERE, base::Bind(&bta_ag_sm_execute_by_handle, handle, in BTA_AgDeregister() 131 void BTA_AgOpen(uint16_t handle, const RawAddress& bd_addr, tBTA_SEC sec_mask) { in BTA_AgOpen() argument 135 do_in_main_thread(FROM_HERE, base::Bind(&bta_ag_sm_execute_by_handle, handle, in BTA_AgOpen() 150 void BTA_AgClose(uint16_t handle) { in BTA_AgClose() argument 152 base::Bind(&bta_ag_sm_execute_by_handle, handle, in BTA_AgClose() 167 void BTA_AgAudioOpen(uint16_t handle) { in BTA_AgAudioOpen() argument 169 FROM_HERE, base::Bind(&bta_ag_sm_execute_by_handle, handle, in BTA_AgAudioOpen() 184 void BTA_AgAudioClose(uint16_t handle) { in BTA_AgAudioClose() argument 186 FROM_HERE, base::Bind(&bta_ag_sm_execute_by_handle, handle, in BTA_AgAudioClose() [all …]
|
/system/bt/profile/avrcp/ |
D | connection_handler.cc | 142 uint8_t handle = it->first; in DisconnectDevice() local 143 device_map_.erase(handle); in DisconnectDevice() 144 return avrc_->Close(handle) == AVRC_SUCCESS; in DisconnectDevice() 204 uint8_t handle = 0; in AvrcpConnect() local 205 uint16_t status = avrc_->Open(&handle, &open_cb, bdaddr); in AvrcpConnect() 206 LOG(INFO) << __PRETTY_FUNCTION__ << ": handle=" << loghex(handle) in AvrcpConnect() 211 void ConnectionHandler::InitiatorControlCb(uint8_t handle, uint8_t event, in InitiatorControlCb() argument 216 LOG(INFO) << __PRETTY_FUNCTION__ << ": handle=" << loghex(handle) in InitiatorControlCb() 234 avrc_->OpenBrowse(handle, AVCT_INT); in InitiatorControlCb() 242 base::Unretained(this), handle); in InitiatorControlCb() [all …]
|
/system/core/libion/ |
D | ion.c | 79 ion_user_handle_t* handle) { in ion_alloc() argument 82 if ((handle == NULL) || (!ion_is_legacy(fd))) return -EINVAL; in ion_alloc() 91 *handle = data.handle; in ion_alloc() 96 int ion_free(int fd, ion_user_handle_t handle) { in ion_free() argument 98 .handle = handle, in ion_free() 103 int ion_map(int fd, ion_user_handle_t handle, size_t length, int prot, int flags, off_t offset, in ion_map() argument 109 .handle = handle, in ion_map() 131 int ion_share(int fd, ion_user_handle_t handle, int* share_fd) { in ion_share() argument 134 .handle = handle, in ion_share() 152 ion_user_handle_t handle; in ion_alloc_fd() local [all …]
|