From: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: Linux Media Mailing List <linux-media@vger.kernel.org>,
Mauro Carvalho Chehab <mchehab@infradead.org>
Subject: Re: [PATCH 5/6] media: isp: fix a warning about a wrong struct initializer
Date: Thu, 20 Sep 2018 11:44:53 -0300 [thread overview]
Message-ID: <20180920114453.54424b60@coco.lan> (raw)
In-Reply-To: <1547255.gQsGpOKB2G@avalon>
Em Fri, 07 Sep 2018 14:46:34 +0300
Laurent Pinchart <laurent.pinchart@ideasonboard.com> escreveu:
> Hi Mauro,
>
> As maintainers should be held to the same level of obligations as developers,
> and to avoid demotivating reviewers, could you handle comments you receive
> before pushing your own patches to your tree ? There should be no maintainer
> privilege here.
Sorry, yeah, this was improperly handled. Not sure what happened.
From whatever reason, I ended by mishandling this and lost the
related emails. I had to do several e-mail changes at the beginning
of August, as I'm not using s-opensource.com anymore, and had to
reconfigure my inbox handling logic.
Do you want me to revert the patch?
>
> On Wednesday, 8 August 2018 18:45:49 EEST Laurent Pinchart wrote:
> > Hi Mauro,
> >
> > Thank you for the patch.
> >
> > The subject line should be "media: omap3isp: ...".
> >
> > On Wednesday, 8 August 2018 17:52:55 EEST Mauro Carvalho Chehab wrote:
> > > As sparse complains:
> > > drivers/media/platform/omap3isp/isp.c:303:39: warning: Using plain
> > > integer
> > >
> > > as NULL pointer
> > >
> > > when a struct is initialized with { 0 }, actually the first
> > > element of the struct is initialized with zeros, initializing the
> > > other elements recursively. That can even generate gcc warnings
> > > on nested structs.
> > >
> > > So, instead, use the gcc-specific syntax for that (with is used
> > > broadly inside the Kernel), initializing it with {};
> > >
> > > Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
> > > ---
> > >
> > > drivers/media/platform/omap3isp/isp.c | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/media/platform/omap3isp/isp.c
> > > b/drivers/media/platform/omap3isp/isp.c index 03354d513311..842e2235047d
> > > 100644
> > > --- a/drivers/media/platform/omap3isp/isp.c
> > > +++ b/drivers/media/platform/omap3isp/isp.c
> > > @@ -300,7 +300,7 @@ static struct clk *isp_xclk_src_get(struct
> > > of_phandle_args *clkspec, void *data) static int isp_xclk_init(struct
> > > isp_device *isp)
> > >
> > > {
> > >
> > > struct device_node *np = isp->dev->of_node;
> > >
> > > - struct clk_init_data init = { 0 };
> > > + struct clk_init_data init = {};
> >
> > How about = { NULL }; to avoid a gcc-specific syntax ?
> >
> > > unsigned int i;
> > >
> > > for (i = 0; i < ARRAY_SIZE(isp->xclks); ++i)
>
>
Thanks,
Mauro
next prev parent reply other threads:[~2018-09-20 20:28 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-08 14:52 [PATCH 1/6] media: exynos-gsc: fix return code if mutex was interrupted Mauro Carvalho Chehab
2018-08-08 14:52 ` [PATCH 2/6] media: saa7164: fix return codes for the polling routine Mauro Carvalho Chehab
2018-08-08 14:52 ` [PATCH 3/6] media: s3c-camif: fix return code " Mauro Carvalho Chehab
2018-08-08 14:52 ` [PATCH 4/6] media: radio-wl1273: " Mauro Carvalho Chehab
2018-08-08 14:52 ` [PATCH 5/6] media: isp: fix a warning about a wrong struct initializer Mauro Carvalho Chehab
2018-08-08 15:45 ` Laurent Pinchart
2018-09-07 11:46 ` Laurent Pinchart
2018-09-11 15:30 ` Laurent Pinchart
2018-09-20 14:44 ` Mauro Carvalho Chehab [this message]
2018-09-20 17:20 ` Laurent Pinchart
2018-08-08 14:52 ` [PATCH 6/6] siano: get rid of an unused return code for debugfs register Mauro Carvalho Chehab
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=20180920114453.54424b60@coco.lan \
--to=mchehab+samsung@kernel.org \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@infradead.org \
/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).