hal: Add ABR enabled flag to LDAC config
Add a member to notify audio driver whether ABR
is enabled for LDAC codec.
Change-Id: I877c71da0ea71288812e773f1f2cf83bfecf9808
diff --git a/hal/audio_extn/a2dp.c b/hal/audio_extn/a2dp.c
index f3c6bb6..b5f4ace 100644
--- a/hal/audio_extn/a2dp.c
+++ b/hal/audio_extn/a2dp.c
@@ -304,6 +304,8 @@
struct quality_level_to_bitrate_info mapping_info;
/* Information to set up IMC between decoder and encoder */
struct imc_dec_enc_info imc_info;
+ /* Flag to indicate whether ABR is enabled */
+ bool is_abr_enabled;
} __attribute__ ((packed));
/* Structure to send configuration for decoder introduced
@@ -1574,6 +1576,7 @@
ldac_dsp_cfg.abr_cfg.imc_info.enable = IMC_ENABLE;
ldac_dsp_cfg.abr_cfg.imc_info.purpose = IMC_PURPOSE_ID_BT_INFO;
ldac_dsp_cfg.abr_cfg.imc_info.comm_instance = a2dp.abr_config.imc_instance;
+ ldac_dsp_cfg.abr_cfg.is_abr_enabled = ldac_bt_cfg->is_abr_enabled;
}
ret = mixer_ctl_set_array(ldac_enc_data, (void *)&ldac_dsp_cfg,