ASoC: rsnd: don't use prohibited number to PDMACHCRn.SRS
Subsystems (3)
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): redmine.journal-15067.20160506054720.3b77f16f74f4a481@lm.renesas.com
A message that is not in the archive (sent off-list or not yet received): SG2PR06MB0919A44CF28F2DF04C86AC5BD87D0@SG2PR06MB0919.apcprd06.prod.outlook.com
A message that is not in the archive (sent off-list or not yet received): 87vb2o3vfz.wl%[email protected]
A message that is not in the archive (sent off-list or not yet received): SG2PR06MB0919D3DF5F99C6A52D51DC77D8710@SG2PR06MB0919.apcprd06.prod.outlook.com
PATCH 1/1 ASoC: rsnd: don't use prohibited number to PDMACHCRn.SRS
From: Kuninori Morimoto <[email protected]>
Current rsnd_dmapp_get_id() returns 0xFF as error code if system used strange connection. It will be used as PDMACHCRn.SRS, but 0xFF is prohibited number.
In order not to use prohibited number, this patch indicates error message and returns 0x00 (same as SSI00) in error case.
Special thanks to Dung-san.
--- sound/soc/sh/rcar/dma.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-)
sound/soc/sh/rcar/dma.c +8 -4
@@ -316,11 +316,15 @@ static u32 rsnd_dmapp_get_id(struct rsnd_dai_stream *io, size =ARRAY_SIZE (gen2_id_table_cmd); } -if (!entry) -return 0xFF ; +if ((!entry) || (size <= id)) { +struct device *dev =rsnd_priv_to_dev (rsnd_io_to_priv (io)); -if (size <= id) -return 0xFF ; +dev_err (dev,"unknown connection (%s[%d])\n" , +rsnd_mod_name (mod),rsnd_mod_id (mod)); + +/* use non-prohibited SRS number as error */ +return 0x00 ;/* SSI00 */ + }return entry[id]; }
Signature · 1 line
1.9.1
Mark Brown
maintainerApplied "ASoC: rsnd: don't use prohibited number to PDMACHCRn.SRS" to the asoc tree
The patch
ASoC: rsnd: don't use prohibited number to PDMACHCRn.SRS
has been applied to the asoc tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
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
Quoted 1 line
From
ee057d2ee73259f455cfbb7a4db808fc6b6405ddMon Sep 17 00:00:00 2001
From: Kuninori Morimoto <[email protected]>
Date: Tue, 10 May 2016 02:22:37 +0000
Subject: [PATCH] ASoC: rsnd: don't use prohibited number to PDMACHCRn.SRS
Current rsnd_dmapp_get_id() returns 0xFF as error code if system used strange connection. It will be used as PDMACHCRn.SRS, but 0xFF is prohibited number.
In order not to use prohibited number, this patch indicates error message and returns 0x00 (same as SSI00) in error case.
Special thanks to Dung-san.
--- sound/soc/sh/rcar/dma.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-)
sound/soc/sh/rcar/dma.c +8 -4
@@ -316,11 +316,15 @@ static u32 rsnd_dmapp_get_id(struct rsnd_dai_stream *io, size =ARRAY_SIZE (gen2_id_table_cmd); } -if (!entry) -return 0xFF ; +if ((!entry) || (size <= id)) { +struct device *dev =rsnd_priv_to_dev (rsnd_io_to_priv (io)); -if (size <= id) -return 0xFF ; +dev_err (dev,"unknown connection (%s[%d])\n" , +rsnd_mod_name (mod),rsnd_mod_id (mod)); + +/* use non-prohibited SRS number as error */ +return 0x00 ;/* SSI00 */ + }return entry[id]; }
Signature · 1 line
2.8.1