diff mbox

[v3,1/6] ASoC: Intel: mrfld - remove unnecessary check for pointer

Message ID 1415098520-14113-2-git-send-email-vinod.koul@intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Vinod Koul Nov. 4, 2014, 10:55 a.m. UTC
the 'platform' pointer in sst_map_modules_to_pipe() is deref in caller
function so we need to check for it in this function

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
---
 sound/soc/intel/sst-atom-controls.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Comments

Mark Brown Nov. 6, 2014, 12:36 p.m. UTC | #1
On Tue, Nov 04, 2014 at 04:25:15PM +0530, Vinod Koul wrote:
> the 'platform' pointer in sst_map_modules_to_pipe() is deref in caller
> function so we need to check for it in this function

Applied, thanks.
diff mbox

Patch

diff --git a/sound/soc/intel/sst-atom-controls.c b/sound/soc/intel/sst-atom-controls.c
index 309a8f3..90aa5c0 100644
--- a/sound/soc/intel/sst-atom-controls.c
+++ b/sound/soc/intel/sst-atom-controls.c
@@ -1351,7 +1351,7 @@  static int sst_map_modules_to_pipe(struct snd_soc_platform *platform)
 	int ret = 0;
 
 	list_for_each_entry(w, &platform->component.card->widgets, list) {
-		if (platform && is_sst_dapm_widget(w) && (w->priv)) {
+		if (is_sst_dapm_widget(w) && (w->priv)) {
 			struct sst_ids *ids = w->priv;
 
 			dev_dbg(platform->dev, "widget type=%d name=%s\n",