[alsa-devel] [PATCH] ASoC: fsl_sai: mark regmap as fast_io
The regmap is only ever used to access MMIO registers, so it's fair to say that register access is fast.
Signed-off-by: Lucas Stach l.stach@pengutronix.de --- sound/soc/fsl/fsl_sai.c | 1 + 1 file changed, 1 insertion(+)
diff --git a/sound/soc/fsl/fsl_sai.c b/sound/soc/fsl/fsl_sai.c index 8593269156bd..812c94fbb160 100644 --- a/sound/soc/fsl/fsl_sai.c +++ b/sound/soc/fsl/fsl_sai.c @@ -771,6 +771,7 @@ static const struct regmap_config fsl_sai_regmap_config = { .reg_bits = 32, .reg_stride = 4, .val_bits = 32, + .fast_io = true,
.max_register = FSL_SAI_RMR, .reg_defaults = fsl_sai_reg_defaults,
On Wed, Jul 17, 2019 at 12:51:56PM +0200, Lucas Stach wrote:
The regmap is only ever used to access MMIO registers, so it's fair to say that register access is fast.
Are you sure there's no caches that try to do allocations at runtime? The main thing fast_io does is change the locking to spinlocks which means we shouldn't do any allocations under lock, such as when updating the cache.
Am Mittwoch, den 17.07.2019, 12:06 +0100 schrieb Mark Brown:
On Wed, Jul 17, 2019 at 12:51:56PM +0200, Lucas Stach wrote:
The regmap is only ever used to access MMIO registers, so it's fair to say that register access is fast.
Are you sure there's no caches that try to do allocations at runtime? The main thing fast_io does is change the locking to spinlocks which means we shouldn't do any allocations under lock, such as when updating the cache.
This driver is using REGCACHE_FLAT, which does its sole allocation on init and none at reg access time AFAICS. So this should be okay.
Regards, Lucas
The patch
ASoC: fsl_sai: mark regmap as fast_io
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.4
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks, Mark
From 41b59054dcccbc72fc17e3d6021a2bd650daf5c8 Mon Sep 17 00:00:00 2001
From: Lucas Stach l.stach@pengutronix.de Date: Wed, 17 Jul 2019 12:51:56 +0200 Subject: [PATCH] ASoC: fsl_sai: mark regmap as fast_io
The regmap is only ever used to access MMIO registers, so it's fair to say that register access is fast.
Signed-off-by: Lucas Stach l.stach@pengutronix.de Link: https://lore.kernel.org/r/20190717105156.15721-1-l.stach@pengutronix.de Signed-off-by: Mark Brown broonie@kernel.org --- sound/soc/fsl/fsl_sai.c | 1 + 1 file changed, 1 insertion(+)
diff --git a/sound/soc/fsl/fsl_sai.c b/sound/soc/fsl/fsl_sai.c index 1d1a447163e3..6d3c6c8d50ce 100644 --- a/sound/soc/fsl/fsl_sai.c +++ b/sound/soc/fsl/fsl_sai.c @@ -763,6 +763,7 @@ static const struct regmap_config fsl_sai_regmap_config = { .reg_bits = 32, .reg_stride = 4, .val_bits = 32, + .fast_io = true,
.max_register = FSL_SAI_RMR, .reg_defaults = fsl_sai_reg_defaults,
participants (2)
-
Lucas Stach
-
Mark Brown