Use HAL-provided config for getInputBufferSize
Since getInputBufferSize is essentially the same
operation as opening a stream, it can also suggest
a config if the provided one is not supported.
Modify AudioFlinger::getInputBufferSize implementation
to retry with HAL-provided config.
Bug: 318423731
Test: run `atest audioeffect_tests` on cf_x86_64_auto-trunk_staging-userdebug
Change-Id: I0eb14966ce816674d631bfef097d243a0445c83b
diff --git a/media/libaudiohal/impl/DeviceHalAidl.h b/media/libaudiohal/impl/DeviceHalAidl.h
index 9493e47..6f8afe5 100644
--- a/media/libaudiohal/impl/DeviceHalAidl.h
+++ b/media/libaudiohal/impl/DeviceHalAidl.h
@@ -113,7 +113,7 @@
status_t getParameters(const String8& keys, String8 *values) override;
// Returns audio input buffer size according to parameters passed.
- status_t getInputBufferSize(const struct audio_config* config, size_t* size) override;
+ status_t getInputBufferSize(struct audio_config* config, size_t* size) override;
// Creates and opens the audio hardware output stream. The stream is closed
// by releasing all references to the returned object.