Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ASoC: codecs/hdmi-codec: merge DAI call back functions into ops

ALSA SoC merges DAI call backs into .ops.
This patch merge these into one.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87edkd9m4t.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Kuninori Morimoto and committed by
Mark Brown
2edc4a2c 878b5fee

+22 -22
+22 -22
sound/soc/codecs/hdmi-codec.c
··· 723 723 SND_SOC_POSSIBLE_DAIFMT_LEFT_J | 724 724 SND_SOC_POSSIBLE_DAIFMT_AC97; 725 725 726 - static const struct snd_soc_dai_ops hdmi_codec_i2s_dai_ops = { 727 - .startup = hdmi_codec_startup, 728 - .shutdown = hdmi_codec_shutdown, 729 - .hw_params = hdmi_codec_hw_params, 730 - .prepare = hdmi_codec_prepare, 731 - .set_fmt = hdmi_codec_i2s_set_fmt, 732 - .mute_stream = hdmi_codec_mute, 733 - .auto_selectable_formats = &hdmi_codec_formats, 734 - .num_auto_selectable_formats = 1, 735 - }; 736 - 737 - static const struct snd_soc_dai_ops hdmi_codec_spdif_dai_ops = { 738 - .startup = hdmi_codec_startup, 739 - .shutdown = hdmi_codec_shutdown, 740 - .hw_params = hdmi_codec_hw_params, 741 - .mute_stream = hdmi_codec_mute, 742 - }; 743 - 744 726 #define HDMI_RATES (SNDRV_PCM_RATE_32000 | SNDRV_PCM_RATE_44100 |\ 745 727 SNDRV_PCM_RATE_48000 | SNDRV_PCM_RATE_88200 |\ 746 728 SNDRV_PCM_RATE_96000 | SNDRV_PCM_RATE_176400 |\ ··· 903 921 return 0; 904 922 } 905 923 924 + static const struct snd_soc_dai_ops hdmi_codec_i2s_dai_ops = { 925 + .probe = hdmi_dai_probe, 926 + .startup = hdmi_codec_startup, 927 + .shutdown = hdmi_codec_shutdown, 928 + .hw_params = hdmi_codec_hw_params, 929 + .prepare = hdmi_codec_prepare, 930 + .set_fmt = hdmi_codec_i2s_set_fmt, 931 + .mute_stream = hdmi_codec_mute, 932 + .pcm_new = hdmi_codec_pcm_new, 933 + .auto_selectable_formats = &hdmi_codec_formats, 934 + .num_auto_selectable_formats = 1, 935 + }; 936 + 937 + static const struct snd_soc_dai_ops hdmi_codec_spdif_dai_ops = { 938 + .probe = hdmi_dai_spdif_probe, 939 + .startup = hdmi_codec_startup, 940 + .shutdown = hdmi_codec_shutdown, 941 + .hw_params = hdmi_codec_hw_params, 942 + .mute_stream = hdmi_codec_mute, 943 + .pcm_new = hdmi_codec_pcm_new, 944 + }; 945 + 906 946 static const struct snd_soc_dai_driver hdmi_i2s_dai = { 907 947 .name = "i2s-hifi", 908 948 .id = DAI_ID_I2S, 909 - .probe = hdmi_dai_probe, 910 949 .playback = { 911 950 .stream_name = "I2S Playback", 912 951 .channels_min = 2, ··· 945 942 .sig_bits = 24, 946 943 }, 947 944 .ops = &hdmi_codec_i2s_dai_ops, 948 - .pcm_new = hdmi_codec_pcm_new, 949 945 }; 950 946 951 947 static const struct snd_soc_dai_driver hdmi_spdif_dai = { 952 948 .name = "spdif-hifi", 953 949 .id = DAI_ID_SPDIF, 954 - .probe = hdmi_dai_spdif_probe, 955 950 .playback = { 956 951 .stream_name = "SPDIF Playback", 957 952 .channels_min = 2, ··· 965 964 .formats = SPDIF_FORMATS, 966 965 }, 967 966 .ops = &hdmi_codec_spdif_dai_ops, 968 - .pcm_new = hdmi_codec_pcm_new, 969 967 }; 970 968 971 969 static int hdmi_of_xlate_dai_id(struct snd_soc_component *component,