linux-omap.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jyri Sarha <jsarha@ti.com>
To: kbuild test robot <lkp@intel.com>
Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org,
	peter.ujfalusi@ti.com, tomi.valkeinen@ti.com,
	arnaud.pouliquen@st.com, dri-devel@lists.freedesktop.org,
	liam.r.girdwood@linux.intel.com, tony@atomide.com,
	broonie@kernel.org, kbuild-all@01.org, bcousson@baylibre.com,
	rmk+kernel@arm.linux.org.uk, linux-omap@vger.kernel.org
Subject: Re: [PATCH v6 5/6] drm/i2c: tda998x: Register ASoC hdmi-codec and add audio DT binding
Date: Thu, 10 Mar 2016 14:44:20 +0200	[thread overview]
Message-ID: <56E16C24.3070207@ti.com> (raw)
In-Reply-To: <201603092102.WhNJg52h%fengguang.wu@intel.com>

On 03/09/16 15:52, kbuild test robot wrote:
> Hi Jyri,
>
> [auto build test WARNING on drm/drm-next]
> [also build test WARNING on v4.5-rc7 next-20160309]
> [if your patch is applied to the wrong git tree, please drop us a note to help improving the system]
>
> url:    https://github.com/0day-ci/linux/commits/Jyri-Sarha/Implement-generic-ASoC-HDMI-codec-and-use-it-in-tda998x/20160309-041821
> base:   git://people.freedesktop.org/~airlied/linux.git drm-next
> config: x86_64-rhel (attached as .config)
> reproduce:
>          # save the attached .config to linux build tree
>          make ARCH=x86_64
>
> All warnings (new ones prefixed by >>):
>
>     drivers/gpu/drm/i2c/tda998x_drv.c: In function 'tda998x_get_audio_ports':
>>> drivers/gpu/drm/i2c/tda998x_drv.c:1345:7: warning: 'size' is used uninitialized in this function [-Wuninitialized]
>       size /= sizeof(u32);
>            ^
>
> vim +/size +1345 drivers/gpu/drm/i2c/tda998x_drv.c
>
>    1329		if (IS_ERR(priv->audio_pdev))
>    1330			return PTR_ERR(priv->audio_pdev);
>    1331	
>    1332		return 0;
>    1333	}
>    1334	
>    1335	/* I2C driver functions */
>    1336	
>    1337	static int tda998x_get_audio_ports(struct tda998x_priv *priv,
>    1338					   struct device_node *np)
>    1339	{
>    1340		const u32 *port_data;
>    1341		u32 size;
>    1342		int i;
>    1343	
>    1344		port_data = of_get_property(np, "audio-ports", &size);
 >> 1345		size /= sizeof(u32);

Oops, that is a real bug. I should test if port_data is not null before 
assuming that the size has been set (/me thinks that he had that line 
there at some point but then it vanished). Actually initializing size to 
0 would be enough, but I think I'll do the both just to be more explicit.

And I'll start using PTR_ERR_OR_ZERO() while I am at it.

>    1346	
>    1347		if (size > 2 * ARRAY_SIZE(priv->audio_port) || size % 2 != 0) {
>    1348			dev_err(&priv->hdmi->dev,
>    1349				"Bad number of elements in audio-ports dt-property\n");
>    1350			return -EINVAL;
>    1351		}
>    1352	
>    1353		size /= 2;
>
> ---
> 0-DAY kernel test infrastructure                Open Source Technology Center
> https://lists.01.org/pipermail/kbuild-all                   Intel Corporation
>

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

  reply	other threads:[~2016-03-10 12:44 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-08 20:14 [PATCH v6 0/6] Implement generic ASoC HDMI codec and use it in tda998x Jyri Sarha
2016-03-08 20:14 ` [PATCH v6 1/6] ALSA: pcm: add IEC958 channel status helper for hw_params Jyri Sarha
2016-03-09 10:08   ` Arnaud Pouliquen
2016-03-09 14:38     ` Jyri Sarha
2016-03-10  5:24   ` Mark Brown
2016-03-08 20:14 ` [PATCH v6 2/6] ASoC: hdmi-codec: Add hdmi-codec for external HDMI-encoders Jyri Sarha
2016-03-09 10:17   ` Arnaud Pouliquen
2016-03-09 15:12   ` Philipp Zabel
     [not found]   ` <6269edecc567c7b1431b023bc812f0309db99273.1457465383.git.jsarha-l0cyMroinI0@public.gmane.org>
2016-03-09 15:28     ` Philipp Zabel
2016-03-08 20:14 ` [PATCH v6 3/6] ASoC: hdmi-codec: Add audio abort() callback for video side to use Jyri Sarha
2016-03-08 20:14 ` [PATCH v6 4/6] drm/i2c: tda998x: Improve tda998x_configure_audio() audio related pdata Jyri Sarha
2016-03-08 20:14 ` [PATCH v6 5/6] drm/i2c: tda998x: Register ASoC hdmi-codec and add audio DT binding Jyri Sarha
     [not found]   ` <7e2cd007e1ea3217c817fb4e7782b0bfe11ea56c.1457465383.git.jsarha-l0cyMroinI0@public.gmane.org>
2016-03-09  0:15     ` [PATCH] drm/i2c: tda998x: fix ptr_ret.cocci warnings kbuild test robot
2016-03-09  0:15     ` [PATCH v6 5/6] drm/i2c: tda998x: Register ASoC hdmi-codec and add audio DT binding kbuild test robot
2016-03-09 13:52     ` kbuild test robot
2016-03-10 12:44       ` Jyri Sarha [this message]
2016-03-08 20:14 ` [PATCH v6 6/6] ARM: dts: am335x-boneblack: Add HDMI audio support Jyri Sarha
2016-03-09  3:27 ` [PATCH v6 0/6] Implement generic ASoC HDMI codec and use it in tda998x Mark Brown
     [not found] ` <cover.1457465383.git.jsarha-l0cyMroinI0@public.gmane.org>
2016-03-09  3:29   ` Mark Brown

Reply instructions:

You may reply publicly 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:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

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

  git send-email \
    --in-reply-to=56E16C24.3070207@ti.com \
    --to=jsarha@ti.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=arnaud.pouliquen@st.com \
    --cc=bcousson@baylibre.com \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=kbuild-all@01.org \
    --cc=liam.r.girdwood@linux.intel.com \
    --cc=linux-omap@vger.kernel.org \
    --cc=lkp@intel.com \
    --cc=peter.ujfalusi@ti.com \
    --cc=rmk+kernel@arm.linux.org.uk \
    --cc=tomi.valkeinen@ti.com \
    --cc=tony@atomide.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).