Searched refs:halPort (Results 1 – 5 of 5) sorted by relevance
/hardware/interfaces/audio/common/all-versions/default/ |
D | HidlUtils.cpp | 258 status_t HidlUtils::audioPortFromHal(const struct audio_port& halPort, AudioPort* port) { in audioPortFromHal() argument 259 port->id = halPort.id; in audioPortFromHal() 260 port->role = AudioPortRole(halPort.role); in audioPortFromHal() 261 port->type = AudioPortType(halPort.type); in audioPortFromHal() 262 port->name.setToExternal(halPort.name, strlen(halPort.name)); in audioPortFromHal() 263 port->sampleRates.resize(halPort.num_sample_rates); in audioPortFromHal() 264 for (size_t i = 0; i < halPort.num_sample_rates; ++i) { in audioPortFromHal() 265 port->sampleRates[i] = halPort.sample_rates[i]; in audioPortFromHal() 267 port->channelMasks.resize(halPort.num_channel_masks); in audioPortFromHal() 268 for (size_t i = 0; i < halPort.num_channel_masks; ++i) { in audioPortFromHal() [all …]
|
D | HidlUtils.h | 72 static status_t audioPortFromHal(const struct audio_port& halPort, AudioPort* port); 73 static status_t audioPortToHal(const AudioPort& port, struct audio_port* halPort); 115 static status_t audioPortFromHal(const struct audio_port_v7& halPort, AudioPort* port); 116 static status_t audioPortToHal(const AudioPort& port, struct audio_port_v7* halPort); 131 static status_t audioTransportsFromHal(const struct audio_port_v7& halPort, bool isInput,
|
/hardware/interfaces/audio/common/all-versions/default/7.0/ |
D | HidlUtils.cpp | 743 status_t HidlUtils::audioPortFromHal(const struct audio_port& halPort, AudioPort* port) { in audioUsageFromHal() argument 745 audio_populate_audio_port_v7(&halPort, &halPortV7); in audioUsageFromHal() 749 status_t HidlUtils::audioPortToHal(const AudioPort& port, struct audio_port* halPort) { in audioUsageFromHal() argument 753 if (!audio_populate_audio_port(&halPortV7, halPort)) { in audioUsageFromHal() 759 status_t HidlUtils::audioPortFromHal(const struct audio_port_v7& halPort, AudioPort* port) { in audioUsageFromHal() argument 762 port->id = halPort.id; in audioUsageFromHal() 763 port->name.setToExternal(halPort.name, strlen(halPort.name)); in audioUsageFromHal() 769 switch (halPort.type) { in audioUsageFromHal() 773 halDevice.type = halPort.ext.device.type; in audioUsageFromHal() 774 memcpy(halDevice.address, halPort.ext.device.address, AUDIO_DEVICE_MAX_ADDRESS_LEN); in audioUsageFromHal() [all …]
|
/hardware/interfaces/audio/core/all-versions/default/ |
D | Device.cpp | 407 HalPort halPort; in openOutputStreamImpl() local 408 if (status_t status = HidlUtils::audioPortToHal(port, &halPort); status != NO_ERROR) { in openOutputStreamImpl() 412 Result retval = analyzeStatus(halGetterName, halGetter(mDevice, &halPort)); in openOutputStreamImpl() 415 if (status_t status = HidlUtils::audioPortFromHal(halPort, &resultPort); in openOutputStreamImpl() 616 audio_port_v7 halPort; in openOutputStreamImpl() local 617 if (status_t status = HidlUtils::audioPortToHal(devicePort, &halPort); status != NO_ERROR) { in openOutputStreamImpl() 621 mDevice->set_device_connected_state_v7(mDevice, &halPort, connected)); in openOutputStreamImpl()
|
/hardware/interfaces/audio/common/all-versions/default/tests/ |
D | hidlutils_tests.cpp | 1020 struct audio_port_v7 halPort; in TEST() local 1021 EXPECT_EQ(NO_ERROR, HidlUtils::audioTransportsToHal(transports, &halPort)); in TEST() 1024 HidlUtils::audioTransportsFromHal(halPort, false /*isInput*/, &transportsBack)); in TEST() 1068 struct audio_port_v7 halPort; in TEST() local 1069 EXPECT_EQ(NO_ERROR, HidlUtils::audioPortToHal(port, &halPort)); in TEST() 1071 EXPECT_EQ(NO_ERROR, HidlUtils::audioPortFromHal(halPort, &portBack)); in TEST() 1075 EXPECT_TRUE(audio_ports_v7_are_equal(&halPort, &halPortBack)); in TEST()
|