Merge "Audio V4: dump effect HAL using the standard debug()" into pi-dev

This commit is contained in:
Eric Laurent 2018-04-23 23:09:10 +00:00 committed by Android (Google) Code Review
commit 8370b093bc
2 changed files with 7 additions and 1 deletions

View file

@ -46,7 +46,8 @@ struct EffectsFactory : public IEffectsFactory {
Return<void> getDescriptor(const Uuid& uid, getDescriptor_cb _hidl_cb) override;
Return<void> createEffect(const Uuid& uid, int32_t session, int32_t ioHandle,
createEffect_cb _hidl_cb) override;
Return<void> debugDump(const hidl_handle& fd);
Return<void> debugDump(const hidl_handle& fd); //< in V2_0::IEffectsFactory only, alias of debug
Return<void> debug(const hidl_handle& fd, const hidl_vec<hidl_string>& options) override;
private:
static sp<IEffect> dispatchEffectInstanceCreation(const effect_descriptor_t& halDescriptor,

View file

@ -172,6 +172,11 @@ Return<void> EffectsFactory::createEffect(const Uuid& uid, int32_t session, int3
}
Return<void> EffectsFactory::debugDump(const hidl_handle& fd) {
return debug(fd, {} /* options */);
}
Return<void> EffectsFactory::debug(const hidl_handle& fd,
const hidl_vec<hidl_string>& /* options */) {
if (fd.getNativeHandle() != nullptr && fd->numFds == 1) {
EffectDumpEffects(fd->data[0]);
}