Re: [PATCH] [STABLE-4.13] [media] imx-media-of: avoid uninitialized variable warning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Oct 04, 2017 at 03:34:55PM +0200, Arnd Bergmann wrote:
> Replaces upstream commit 0b2e9e7947e7 ("media: staging/imx: remove
> confusing IS_ERR_OR_NULL usage")
> 
> We get a harmless warning about a potential uninitialized variable
> use in the driver:
> 
> drivers/staging/media/imx/imx-media-of.c: In function 'of_parse_subdev':
> drivers/staging/media/imx/imx-media-of.c:216:4: warning: 'remote_np' may be used uninitialized in this function [-Wmaybe-uninitialized]
> 
> I reworked that code to be easier to understand by gcc in mainline,
> but that commit is too large to backport. This is a much simpler
> workaround, avoiding the warning by adding a fake initialization
> to the variable. The driver was only introduced in linux-4.13,
> so the workaround is not needed for earlier stable kernels.
> 
> Fixes: e130291212df ("[media] media: Add i.MX media core driver")

I normally leave off the Fixes tag when it's not a bugfix.  The warning
is, as you mentioned, harmless.

regards,
dan carpenter

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux