Skip to content

Commit 63157d9

Browse files
committed
ASoC: mt8365: Make non-exported functions static
The compilers warn if functions without a prototype are not static so add appropriate static declarations. Reported-by: Nathan Chancellor <nathan@kernel.org> Reviewed-by: Alexandre Mergnat <amergnat@baylibre.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Tested-by: Nathan Chancellor <nathan@kernel.org> # build Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://patch.msgid.link/20240907-asoc-fix-mt8365-build-v1-4-7ad0bac20161@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 3e61df7 commit 63157d9

2 files changed

Lines changed: 8 additions & 8 deletions

File tree

sound/soc/mediatek/mt8365/mt8365-afe-clk.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ int mt8365_afe_disable_afe_on(struct mtk_base_afe *afe)
295295
return 0;
296296
}
297297

298-
int mt8365_afe_hd_engen_enable(struct mtk_base_afe *afe, bool apll1)
298+
static int mt8365_afe_hd_engen_enable(struct mtk_base_afe *afe, bool apll1)
299299
{
300300
if (apll1)
301301
regmap_update_bits(afe->regmap, AFE_HD_ENGEN_ENABLE,
@@ -307,7 +307,7 @@ int mt8365_afe_hd_engen_enable(struct mtk_base_afe *afe, bool apll1)
307307
return 0;
308308
}
309309

310-
int mt8365_afe_hd_engen_disable(struct mtk_base_afe *afe, bool apll1)
310+
static int mt8365_afe_hd_engen_disable(struct mtk_base_afe *afe, bool apll1)
311311
{
312312
if (apll1)
313313
regmap_update_bits(afe->regmap, AFE_HD_ENGEN_ENABLE,

sound/soc/mediatek/mt8365/mt8365-afe-pcm.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ bool mt8365_afe_channel_supported(unsigned int channel, unsigned int id)
170170
return false;
171171
}
172172

173-
bool mt8365_afe_clk_group_44k(int sample_rate)
173+
static bool mt8365_afe_clk_group_44k(int sample_rate)
174174
{
175175
if (sample_rate == 11025 ||
176176
sample_rate == 22050 ||
@@ -182,7 +182,7 @@ bool mt8365_afe_clk_group_44k(int sample_rate)
182182
return false;
183183
}
184184

185-
bool mt8365_afe_clk_group_48k(int sample_rate)
185+
static bool mt8365_afe_clk_group_48k(int sample_rate)
186186
{
187187
return (!mt8365_afe_clk_group_44k(sample_rate));
188188
}
@@ -496,8 +496,8 @@ static int mt8365_afe_configure_cm(struct mtk_base_afe *afe,
496496
return 0;
497497
}
498498

499-
int mt8365_afe_fe_startup(struct snd_pcm_substream *substream,
500-
struct snd_soc_dai *dai)
499+
static int mt8365_afe_fe_startup(struct snd_pcm_substream *substream,
500+
struct snd_soc_dai *dai)
501501
{
502502
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
503503
struct mtk_base_afe *afe = snd_soc_dai_get_drvdata(dai);
@@ -714,8 +714,8 @@ static int mt8365_afe_fe_prepare(struct snd_pcm_substream *substream,
714714
return 0;
715715
}
716716

717-
int mt8365_afe_fe_trigger(struct snd_pcm_substream *substream, int cmd,
718-
struct snd_soc_dai *dai)
717+
static int mt8365_afe_fe_trigger(struct snd_pcm_substream *substream, int cmd,
718+
struct snd_soc_dai *dai)
719719
{
720720
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
721721
struct mtk_base_afe *afe = snd_soc_dai_get_drvdata(dai);

0 commit comments

Comments
 (0)