Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a3565b3b authored by Dhananjay Kumar's avatar Dhananjay Kumar Committed by Haynes Mathew George
Browse files

hal: use updated acdb_init to pass ds1 license info

Use updated acdb_init to pass ds1 license info

Change-Id: I5155b60fa39511b30b7fa63382891088034fdcc6
CRs-Fixed: 761339
parent 68bb271f
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -119,7 +119,7 @@ struct audio_block_header

/* Audio calibration related functions */
typedef void (*acdb_deallocate_t)();
typedef int  (*acdb_init_t)(char *, char *);
typedef int  (*acdb_init_t)(char *, char *, int);
typedef void (*acdb_send_audio_cal_t)(int, int, int, int);
typedef void (*acdb_send_voice_cal_t)(int, int);
typedef int (*acdb_reload_vocvoltable_t)(int);
@@ -890,7 +890,7 @@ void *platform_init(struct audio_device *adev)
    char baseband[PROPERTY_VALUE_MAX];
    char value[PROPERTY_VALUE_MAX];
    struct platform_data *my_data = NULL;
    int retry_num = 0, snd_card_num = 0;
    int retry_num = 0, snd_card_num = 0, key = 0;
    const char *snd_card_name;
    char mixer_xml_path[100],ffspEnable[PROPERTY_VALUE_MAX];
    char *cvd_version = NULL;
@@ -1001,6 +1001,9 @@ void *platform_init(struct audio_device *adev)
        acdb_device_table[SND_DEVICE_OUT_SPEAKER_AND_HDMI] = 131;
        acdb_device_table[SND_DEVICE_OUT_SPEAKER_AND_USB_HEADSET] = 131;
    }
    property_get("audio.ds1.metainfo.key",value,"0");
    key = atoi(value);

    my_data->voice_feature_set = VOICE_FEATURE_SET_DEFAULT;
    my_data->acdb_handle = dlopen(LIB_ACDB_LOADER, RTLD_NOW);
    if (my_data->acdb_handle == NULL) {
+5 −3
Original line number Diff line number Diff line
@@ -148,7 +148,7 @@ typedef struct acdb_audio_cal_cfg {

/* Audio calibration related functions */
typedef void (*acdb_deallocate_t)();
typedef int  (*acdb_init_t)(const char *, char *);
typedef int  (*acdb_init_t)(const char *, char *, int);
typedef void (*acdb_send_audio_cal_t)(int, int, int , int);
typedef void (*acdb_send_voice_cal_t)(int, int);
typedef int (*acdb_reload_vocvoltable_t)(int);
@@ -979,7 +979,7 @@ void *platform_init(struct audio_device *adev)
    char baseband[PROPERTY_VALUE_MAX];
    char value[PROPERTY_VALUE_MAX];
    struct platform_data *my_data = NULL;
    int retry_num = 0, snd_card_num = 0;
    int retry_num = 0, snd_card_num = 0, key = 0;
    const char *snd_card_name;
    char *cvd_version = NULL;

@@ -1093,6 +1093,8 @@ void *platform_init(struct audio_device *adev)
            my_data->fluence_mode = FLUENCE_BROADSIDE;
        }
    }
    property_get("audio.ds1.metainfo.key",value,"0");
    key = atoi(value);

    my_data->voice_feature_set = VOICE_FEATURE_SET_DEFAULT;
    my_data->acdb_handle = dlopen(LIB_ACDB_LOADER, RTLD_NOW);
@@ -1156,7 +1158,7 @@ void *platform_init(struct audio_device *adev)
        else
            get_cvd_version(cvd_version, adev);

        my_data->acdb_init(snd_card_name, cvd_version);
        my_data->acdb_init(snd_card_name, cvd_version, key);
        if (cvd_version)
            free(cvd_version);
    }