17 Jan
2020
17 Jan
'20
9:32 a.m.
Hello Morimoto-san,
I have a question about this snippet from sound/soc/soc-core.c
» /* » * CPU device may be specified by either name or OF node, but » * can be left unspecified, and will be matched based on DAI » * name alone.. » */ » if (link->cpus->name && link->cpus->of_node) { » » dev_err(card->dev, » » » "ASoC: Neither/both cpu name/of_node are set for %s\n", » » » link->name); » » return -EINVAL; » }
Here either the warning message is wrong OR the if () condition is wrong.
If the link->cpus->name = NULL && link->cpus->of_node == NULL the warning message will be not be printed.