• Home
  • Raw
  • Download

Lines Matching refs:my_data

169 static struct ma_platform_data *my_data = NULL;  variable
175 return platform_set_parameters(my_data->platform, in set_audio_cal()
182 return my_data->ma_set_lr_swap(g_ma_audio_cal_handle, in ma_set_lr_swap_l()
189 return my_data->ma_set_orientation(g_ma_audio_cal_handle, in ma_set_orientation_l()
196 return my_data->ma_set_sound_mode(g_ma_audio_cal_handle, in ma_set_sound_mode_l()
203 return my_data->ma_set_volume(g_ma_audio_cal_handle, audio_cal_settings, in ma_set_volume_l()
211 return my_data->ma_set_volume_table(g_ma_audio_cal_handle, in ma_set_volume_table_l()
220 return my_data->ma_set_param(g_ma_audio_cal_handle, in ma_set_param_l()
338 ret = ma_set_orientation_l(&ma_cal, my_data->dispaly_orientation); in check_and_send_all_audio_cal()
341 my_data->dispaly_orientation); in check_and_send_all_audio_cal()
344 my_data->dispaly_orientation); in check_and_send_all_audio_cal()
464 if (my_data) { free(my_data); } in audio_extn_ma_init()
465 my_data = calloc(1, sizeof(struct ma_platform_data)); in audio_extn_ma_init()
466 if (my_data == NULL) { in audio_extn_ma_init()
471 pthread_mutex_init(&my_data->lock, NULL); in audio_extn_ma_init()
473 my_data->platform = platform; in audio_extn_ma_init()
480 my_data->waves_handle = dlopen(lib_path, RTLD_NOW); in audio_extn_ma_init()
481 if (my_data->waves_handle == NULL) { in audio_extn_ma_init()
487 my_data->ma_param_init = (ma_param_init_t)dlsym(my_data->waves_handle, in audio_extn_ma_init()
489 if (!my_data->ma_param_init) { in audio_extn_ma_init()
494 my_data->ma_param_deinit = (ma_param_deinit_t)dlsym( in audio_extn_ma_init()
495 my_data->waves_handle, MA_QDSP_PARAM_DEINIT); in audio_extn_ma_init()
496 if (!my_data->ma_param_deinit) { in audio_extn_ma_init()
501 my_data->ma_is_feature_used = (ma_is_feature_used_t)dlsym(my_data->waves_handle, in audio_extn_ma_init()
503 if (!my_data->ma_is_feature_used) { in audio_extn_ma_init()
507 my_data->ma_set_orientation = (ma_set_orientation_t)dlsym(my_data->waves_handle, in audio_extn_ma_init()
509 if (!my_data->ma_set_orientation) { in audio_extn_ma_init()
513 my_data->ma_set_lr_swap = (ma_set_lr_swap_t)dlsym(my_data->waves_handle, in audio_extn_ma_init()
515 if (!my_data->ma_set_lr_swap) { in audio_extn_ma_init()
520 my_data->ma_set_sound_mode = (ma_set_sound_mode_t)dlsym( in audio_extn_ma_init()
521 my_data->waves_handle, MA_QDSP_SET_MODE); in audio_extn_ma_init()
522 if (!my_data->ma_set_sound_mode) { in audio_extn_ma_init()
527 my_data->ma_set_volume = (ma_set_volume_t)dlsym(my_data->waves_handle, in audio_extn_ma_init()
529 if (!my_data->ma_set_volume) { in audio_extn_ma_init()
534 my_data->ma_set_volume_table = (ma_set_volume_table_t)dlsym( in audio_extn_ma_init()
535 my_data->waves_handle, MA_QDSP_SET_VOLT); in audio_extn_ma_init()
536 if (!my_data->ma_set_volume_table) { in audio_extn_ma_init()
541 my_data->ma_set_param = (ma_set_param_t)dlsym( in audio_extn_ma_init()
542 my_data->waves_handle, MA_QDSP_SET_PARAM); in audio_extn_ma_init()
543 if (!my_data->ma_set_param) { in audio_extn_ma_init()
588 if (my_data->ma_param_init(&g_ma_audio_cal_handle, in audio_extn_ma_init()
595 my_data->ma_param_deinit(&g_ma_audio_cal_handle); in audio_extn_ma_init()
610 my_data->speaker_lr_swap = false; in audio_extn_ma_init()
611 my_data->orientation_used = false; in audio_extn_ma_init()
612 my_data->dispaly_orientation = 0; in audio_extn_ma_init()
614 if (g_ma_audio_cal_handle && my_data->ma_is_feature_used) { in audio_extn_ma_init()
615 my_data->orientation_used = my_data->ma_is_feature_used( in audio_extn_ma_init()
622 if (my_data) { free(my_data); } in audio_extn_ma_init()
623 my_data = NULL; in audio_extn_ma_init()
629 if (my_data) { in audio_extn_ma_deinit()
631 if (my_data->ma_param_deinit && in audio_extn_ma_deinit()
632 my_data->ma_param_deinit(&g_ma_audio_cal_handle)) in audio_extn_ma_deinit()
637 pthread_mutex_destroy(&my_data->lock); in audio_extn_ma_deinit()
638 free(my_data); in audio_extn_ma_deinit()
639 my_data = NULL; in audio_extn_ma_deinit()
656 if (!my_data) { in audio_extn_ma_set_state()
670 pthread_mutex_lock(&my_data->lock); in audio_extn_ma_set_state()
677 pthread_mutex_unlock(&my_data->lock); in audio_extn_ma_set_state()
690 if (!my_data) { in audio_extn_ma_set_device()
709 pthread_mutex_lock(&my_data->lock); in audio_extn_ma_set_device()
714 if (my_data->orientation_used) in audio_extn_ma_set_device()
716 my_data->dispaly_orientation); in audio_extn_ma_set_device()
718 ma_set_swap_l(usecase->stream.out->dev, my_data->speaker_lr_swap); in audio_extn_ma_set_device()
720 if (my_data->orientation_used) in audio_extn_ma_set_device()
735 pthread_mutex_unlock(&my_data->lock); in audio_extn_ma_set_device()
749 if (!my_data) { in audio_extn_ma_set_parameters()
756 my_data->speaker_lr_swap = true; in audio_extn_ma_set_parameters()
761 my_data->speaker_lr_swap = false; in audio_extn_ma_set_parameters()
764 my_data->dispaly_orientation = val; in audio_extn_ma_set_parameters()
766 if (my_data->orientation_used) in audio_extn_ma_set_parameters()
767 ma_set_rotation_l(adev, my_data->dispaly_orientation); in audio_extn_ma_set_parameters()
769 ma_set_swap_l(adev, my_data->speaker_lr_swap); in audio_extn_ma_set_parameters()