Alsa-Devel Archive on
 help / color / Atom feed
From: Dan Carpenter <>
To: Liam Girdwood <>
Cc:,,, Takashi Iwai <>,
	Mark Brown <>
Subject: [alsa-devel] [PATCH] ASoC: topology: Fix a signedness bug in soc_tplg_dapm_widget_create()
Date: Wed, 25 Sep 2019 14:06:24 +0300
Message-ID: <20190925110624.GR3264@mwanda> (raw)

The "" variable is an enum and in this context GCC will
treat it as an unsigned int so it can never be less than zero.

Fixes: 8a9782346dcc ("ASoC: topology: Add topology core")
Signed-off-by: Dan Carpenter <>
 sound/soc/soc-topology.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/soc-topology.c b/sound/soc/soc-topology.c
index aa9a1fca46fa..0fd032914a31 100644
--- a/sound/soc/soc-topology.c
+++ b/sound/soc/soc-topology.c
@@ -1582,7 +1582,7 @@ static int soc_tplg_dapm_widget_create(struct soc_tplg *tplg,
 	/* map user to kernel widget ID */ = get_widget_id(le32_to_cpu(w->id));
-	if ( < 0)
+	if ((int) < 0)
 	/* strings are allocated here, but used and freed by the widget */

Alsa-devel mailing list

             reply index

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-25 11:06 Dan Carpenter [this message]
2019-09-26 15:24 ` [alsa-devel] Applied "ASoC: topology: Fix a signedness bug in soc_tplg_dapm_widget_create()" to the asoc tree Mark Brown

Reply instructions:

You may reply publically to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190925110624.GR3264@mwanda \ \ \ \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Alsa-Devel Archive on

Archives are clonable:
	git clone --mirror alsa-devel/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 alsa-devel alsa-devel/ \
	public-inbox-index alsa-devel

Example config snippet for mirrors

Newsgroup available over NNTP:

AGPL code for this site: git clone