mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 10:31:46 +09:00
ASoC: rockchip: i2s: Use SNDRV_PCM_RATE_CONTINUOUS
Use SNDRV_PCM_RATE_CONTINUOUS to support continuous range sample rate, which can support any rate in range. e.g. 48048, 31000, 768000 SNDRV_PCM_RATE_CONTINUOUS means the hardware supports all rates in a specific interval. Sample rates are only restricted by the capabilities of the clock driver, so use SNDRV_PCM_RATE_CONTINUOUS instead of SNDRV_PCM_RATE_8000_384000. Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com> Change-Id: Ieeea4f9ae414f2fa6475fa5f6559162e15c688c9
This commit is contained in:
@@ -1054,7 +1054,7 @@ static int rockchip_i2s_init_dai(struct rk_i2s_dev *i2s, struct resource *res,
|
||||
dai->playback.stream_name = "Playback";
|
||||
dai->playback.channels_min = 2;
|
||||
dai->playback.channels_max = 8;
|
||||
dai->playback.rates = SNDRV_PCM_RATE_8000_192000;
|
||||
dai->playback.rates = SNDRV_PCM_RATE_CONTINUOUS;
|
||||
dai->playback.formats = SNDRV_PCM_FMTBIT_S8 |
|
||||
SNDRV_PCM_FMTBIT_S16_LE |
|
||||
SNDRV_PCM_FMTBIT_S20_3LE |
|
||||
@@ -1076,7 +1076,7 @@ static int rockchip_i2s_init_dai(struct rk_i2s_dev *i2s, struct resource *res,
|
||||
dai->capture.stream_name = "Capture";
|
||||
dai->capture.channels_min = 2;
|
||||
dai->capture.channels_max = 8;
|
||||
dai->capture.rates = SNDRV_PCM_RATE_8000_192000;
|
||||
dai->capture.rates = SNDRV_PCM_RATE_CONTINUOUS;
|
||||
dai->capture.formats = SNDRV_PCM_FMTBIT_S8 |
|
||||
SNDRV_PCM_FMTBIT_S16_LE |
|
||||
SNDRV_PCM_FMTBIT_S20_3LE |
|
||||
|
||||
Reference in New Issue
Block a user