mirror of
https://github.com/torvalds/linux.git
synced 2026-09-23 13:14:02 +02:00
ASoC: SDCA: export sdca_asoc_populate_rate_format() helper
Export populate_rate_format() as sdca_asoc_populate_rate_format() so that it can be used by codec drivers. The codec driver could get rate and format information for the IT/OT entity. Signed-off-by: Shuming Fan <shumingf@realtek.com> Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://patch.msgid.link/20260729032237.3750805-1-shumingf@realtek.com Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
c24f4797d8
commit
772e340996
|
|
@ -25,6 +25,8 @@ struct snd_soc_dai_driver;
|
|||
struct snd_soc_dai_ops;
|
||||
struct snd_soc_dapm_route;
|
||||
struct snd_soc_dapm_widget;
|
||||
struct snd_soc_pcm_stream;
|
||||
struct sdca_entity;
|
||||
|
||||
/* convenient macro to handle the mono volume in 7.8 fixed format representation */
|
||||
#define SDCA_SINGLE_Q78_TLV(xname, xreg, xmin, xmax, xstep, tlv_array) \
|
||||
|
|
@ -82,6 +84,11 @@ int sdca_asoc_populate_component(struct device *dev,
|
|||
struct snd_soc_dai_driver **dai_drv, int *num_dai_drv,
|
||||
const struct snd_soc_dai_ops *ops);
|
||||
|
||||
int sdca_asoc_populate_rate_format(struct device *dev,
|
||||
struct sdca_function_data *function,
|
||||
struct sdca_entity *entity,
|
||||
struct snd_soc_pcm_stream *stream);
|
||||
|
||||
int sdca_asoc_set_constraints(struct device *dev, struct regmap *regmap,
|
||||
struct sdca_function_data *function,
|
||||
struct snd_pcm_substream *substream,
|
||||
|
|
|
|||
|
|
@ -1231,7 +1231,7 @@ static u64 width_find_mask(unsigned int bits)
|
|||
}
|
||||
}
|
||||
|
||||
static int populate_rate_format(struct device *dev,
|
||||
int sdca_asoc_populate_rate_format(struct device *dev,
|
||||
struct sdca_function_data *function,
|
||||
struct sdca_entity *entity,
|
||||
struct snd_soc_pcm_stream *stream)
|
||||
|
|
@ -1292,6 +1292,7 @@ static int populate_rate_format(struct device *dev,
|
|||
|
||||
return 0;
|
||||
}
|
||||
EXPORT_SYMBOL_NS(sdca_asoc_populate_rate_format, "SND_SOC_SDCA");
|
||||
|
||||
/**
|
||||
* sdca_asoc_populate_dais - fill in an array of DAI drivers for a Function
|
||||
|
|
@ -1344,7 +1345,7 @@ int sdca_asoc_populate_dais(struct device *dev, struct sdca_function_data *funct
|
|||
stream->channels_min = 1;
|
||||
stream->channels_max = SDCA_MAX_CHANNEL_COUNT;
|
||||
|
||||
ret = populate_rate_format(dev, function, entity, stream);
|
||||
ret = sdca_asoc_populate_rate_format(dev, function, entity, stream);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user