ASoC: simple-card-utils fixups
Kuninori Morimoto
maintainerv3 cover ASoC: simple-card-utils fixups
Hi Mark
linus/master includes my patch (419d1918105e) which uses __free() in simple-card-utils. But because of it, it has of_node_put() count underrun issue. This patch will solve it.
[1/2] is for asoc/for-6.14.
My previous v2 patch had extra cleanup patch, but I will post it again to avoid confusion.
You will get conflict if you merges asoc/for-6.14 and asoc/for-6.15 after [1/2] was applied on for-6.14 branch.
I have created conflict fixup patch, too. I hope [2/2] can clean conflict.
apply [1/2] to asoc/for-6.14
> git checkout asoc/for-6.14 > git am [1/2].patch
merge asoc-6.14 into asoc-6.15
> git checkout asoc/for-6.15
> git merge asoc/for-6.14
# get conflict
use [2/2] to fix conflict
> patch -p1 < [2/2].patch > git commit -as
I will post extra cleanup patch if asoc/for-6.15 was updated.
v2 -> v3
- based on asoc/for-6.14
v1 -> v2
- Separate patches
sound/soc/generic/simple-card-utils.c | 29 ++++++++++++--------------- 1 file changed, 13 insertions(+), 16 deletions(-)
Signature · 11 lines
2.43.0 Thank you for your help !! Best regards --- Kuninori Morimoto
Kuninori Morimoto
maintainerPATCH v3 1/2 ASoC: simple-card-utils: Don't use __free(device_node) at graph_util_parse_dai()
commit 419d1918105e ("ASoC: simple-card-utils: use __free(device_node) for device node") uses __free(device_node) for dlc->of_node, but we need to keep it while driver is in use.
Don't use __free(device_node) in graph_util_parse_dai().
--- sound/soc/generic/simple-card-utils.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
sound/soc/generic/simple-card-utils.c +5 -2
@@ -1077,6 +1077,7 @@ static int graph_get_dai_id(struct device_node *ep)int graph_util_parse_dai (struct device *dev,struct device_node *ep,struct snd_soc_dai_link_component *dlc,int *is_single_link) { +struct device_node *node;struct of_phandle_args args = {};struct snd_soc_dai *dai;int ret;
@@ -1084,7 +1085,7 @@ int graph_util_parse_dai(struct device *dev, struct device_node *ep,if (!ep)return 0 ; - struct device_node *node __free(device_node) = of_graph_get_port_parent(ep); + node =of_graph_get_port_parent (ep);/* * Try to find from DAI node
@@ -1126,8 +1127,10 @@ int graph_util_parse_dai(struct device *dev, struct device_node *ep,* if he unbinded CPU or Codec. */ ret =snd_soc_get_dlc (&args, dlc); -if (ret <0 ) +if (ret <0 ) { +of_node_put (node);return ret; + } parse_dai_end:if (is_single_link)
Signature · 1 line
2.43.0
Kuninori Morimoto
maintainerPATCH v3 2/2 merge fixup for simple-card-utils asoc-v6.14 vs asoc-v6.15
In reply to Kuninori Morimoto--- sound/soc/generic/simple-card-utils.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-)
sound/soc/generic/simple-card-utils.c +1 -9
@@ -1102,11 +1102,8 @@ static int graph_get_dai_id(struct device_node *ep)int graph_util_parse_dai (struct simple_util_priv *priv,struct device_node *ep,struct snd_soc_dai_link_component *dlc,int *is_single_link) { -<<<<<<< HEADstruct device *dev =simple_priv_to_dev (priv); -=======struct device_node *node; ->>>>>>> asoc/for-6.14struct of_phandle_args args = {};struct snd_soc_dai *dai;int ret;
@@ -1157,15 +1154,10 @@ int graph_util_parse_dai(struct simple_util_priv *priv, struct device_node *ep,* if he unbinded CPU or Codec. */ ret =snd_soc_get_dlc (&args, dlc); -<<<<<<< HEAD - if (ret < 0) - goto end; -=======if (ret <0 ) {of_node_put (node); -return ret; + goto end; } ->>>>>>> asoc/for-6.14 parse_dai_end:if (is_single_link)
Signature · 1 line
2.43.0
Mark Brown
maintainerRe: (subset) [PATCH v3 0/2] ASoC: simple-card-utils fixups
In reply to Kuninori MorimotoQuoted 10 lines · Kuninori Morimoto
linus/master includes my patch (
419d1918105e) which uses__free()in simple-card-utils. But because of it, it hasof_node_put()count underrun issue. This patch will solve it.[1/2] is for asoc/for-6.14.
My previous v2 patch had extra cleanup patch, but I will post it again to avoid confusion.
[...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
Thanks!
[1/2] ASoC: simple-card-utils: Don't use __free(device_node) at graph_util_parse_dai()
commit: de74ec718e0788e1998eb7289ad07970e27cae27
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