【Android Audio】audio hal hidl通信

tech2024-01-28  117

audio hal hidl通信

Hal audio系统上下文

Hal audio

第一步AudioFlinger (audioserver进程eg: AudioFlinger::PatchPanel::createAudioPatch frameworks/av/services/audioflinger/PatchPanel.cpp /system/lib/ibaudioflinger.so

第二步libaudiohal(audioserver进程eg: DeviceHalHidl::createAudioPatch Android P: frameworks/av/media/libaudiohal/4.0/DeviceHalHidl.cpp /system/lib/libaudiohal@4.0.so Android Q: frameworks/av/media/libaudiohal/impl/DeviceHalHidl.cpp /system/lib/libaudiohal@5.0.so

第三步device impl (android.hardware.audio@2.0-service-droidlogic进程eg: Device::createAudioPatch Android P: hardware/interfaces/audio/core/all-versions/default/include/core/all-versions/default/Device.impl.h /vendor/lib/hw/android.hardware.audio@4.0-impl.so Android Q: hardware/interfaces/audio/core/all-versions/default/Device.cpp /vendor/lib/hw/android.hardware.audio@5.0-impl.so

第四步 audio hal (android.hardware.audio@2.0-service-droidlogic进程eg: audio_hw.c create_audio_patch /vendor/lib/hw/audio.primary.xxx.so

系统上下文

audioserver和android.hardware.audio@2.0-service-droidlogic两个进程之间调用,之间通过vndbinder通信,system分区调用vendor分区。

最新回复(0)