diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2018-02-07 21:11:09 +0100 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2018-02-07 21:11:09 +0100 |
commit | 7590e37bdaeec25ae325f4ba450be13e2aac6c8d (patch) | |
tree | 8249846959a09148a467269c65756d4c278d4f07 /sound/soc/soc-core.c | |
parent | Merge tag 'linux-watchdog-4.16-rc1' of git://www.linux-watchdog.org/linux-wat... (diff) | |
parent | Merge remote-tracking branches 'asoc/topic/sam9x5_wm8731', 'asoc/topic/sgtl50... (diff) | |
download | linux-7590e37bdaeec25ae325f4ba450be13e2aac6c8d.tar.xz linux-7590e37bdaeec25ae325f4ba450be13e2aac6c8d.zip |
Merge tag 'asoc-v4.16-5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound
Pull more ASoC updates from Mark Brown:
"With the merge window having been delayed for another week here's
another batch of updates that came in during that week.
There's a few important fixes in here, mainly a fix for I/O on a
number of devices caused by some of the component rework and a fix for
a potential issue if more than one component in a link provides
compressed operations. The I/O fixes are particularly important as the
problem causes a power regression on a number of OMAP platforms"
* tag 'asoc-v4.16-5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound: (22 commits)
ASoC: stm32: add of dependency for stm32 drivers
ASoC: mt8173-rt5650: fix child-node lookup
ASoC: dapm: fix debugfs read using path->connected
ASoC: compress: Fixup error messages
ASoC: compress: Remove some extraneous blank lines
ASoC: compress: Correct handling of copy callback
ASoC: Intel: kbl: Enable mclk and ssp sclk early
ASoC: Intel: Skylake: Add extended I2S config blob support in Clock driver
ASoC: Intel: Skylake: Add ssp clock driver
ASoC: Fix twl4030 and 6040 regression by adding back read and write
ASoC: sun8i-codec: Add ADC support for a33
ASoC: rockchip: Use dummy_dai for rt5514 dsp dailink
ASoC: soc-pcm: rename .pmdown_time to .use_pmdown_time for Component
ASoC: ak4613: call dummy write for PW_MGMT1/3 when Playback
ASoC: soc-pcm: don't call flush_delayed_work() many times in soc_pcm_private_free()
ASoC: soc-core: snd_soc_rtdcom_lookup() cares component driver name
ASoC: sam9x5_wm8731: Drop 'ASoC' prefix from error messages
ASoC: sam9g20_wm8731: use dev_*() logging functions
ASoC: max98373 Changed SPDX header in C++ comments style
ASoC: dmic: Fix check of return value from read of 'num-channels'
...
Diffstat (limited to 'sound/soc/soc-core.c')
-rw-r--r-- | sound/soc/soc-core.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index 88efc84f3e7b..96c44f6576c9 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -553,9 +553,17 @@ struct snd_soc_component *snd_soc_rtdcom_lookup(struct snd_soc_pcm_runtime *rtd, { struct snd_soc_rtdcom_list *rtdcom; + if (!driver_name) + return NULL; + for_each_rtdcom(rtd, rtdcom) { - if ((rtdcom->component->driver->name == driver_name) || - strcmp(rtdcom->component->driver->name, driver_name) == 0) + const char *component_name = rtdcom->component->driver->name; + + if (!component_name) + continue; + + if ((component_name == driver_name) || + strcmp(component_name, driver_name) == 0) return rtdcom->component; } |