From: Joe Perches <joe@perches.com>
To: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
Cc: "Thomas Petazzoni" <thomas.petazzoni@free-electrons.com>,
"Noralf Trønnes" <noralf@tronnes.org>,
"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] staging: fbtft: fix out of bound access
Date: Thu, 04 Jun 2015 22:46:51 -0700 [thread overview]
Message-ID: <1433483211.2658.22.camel@perches.com> (raw)
In-Reply-To: <20150605045257.GA4012@sudip-PC>
On Fri, 2015-06-05 at 10:22 +0530, Sudip Mukherjee wrote:
> On Thu, Jun 04, 2015 at 01:48:31PM -0700, Joe Perches wrote:
[]
> ccing you just slipped out of my mind.
No worries.
> > > diff --git a/drivers/staging/fbtft/fbtft-core.c b/drivers/staging/fbtft/fbtft-core.c
> > []
> > > @@ -1067,8 +1067,6 @@ static int fbtft_init_display_dt(struct fbtft_par *par)
> > > const __be32 *p;
> > > u32 val;
> > > int buf[64], i, j;
> > []
> > > par->fbtftops.write_register(par, i,
> > > buf[0], buf[1], buf[2], buf[3],
> >
> > It seems there are only 2 callers of (*write_register)()
> > and the arguments are always an in-order array int[64]
> >
> > Maybe it'd be nicer to change the prototypes of the
> > write_register functions to take a const int *
> > instead of pushing 64 ints on the stack.
> yes, I will send it as a separate patch as that is another change.
I looked at it a bit more and there's a macro that calls
write_register so there are actually many more call sites.
It's a bit non trivial to change the macro as all the
called (*write_register) functions would need changing
and these functions use va_list.
Maybe if you _really_ feel like it, but it's a bit of work.
next prev parent reply other threads:[~2015-06-05 5:46 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-06-04 13:34 [PATCH v2] staging: fbtft: fix out of bound access Sudip Mukherjee
2015-06-04 20:48 ` Joe Perches
2015-06-05 4:52 ` Sudip Mukherjee
2015-06-05 5:46 ` Joe Perches [this message]
2015-06-08 14:52 ` Sudip Mukherjee
2015-06-08 15:57 ` Joe Perches
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=1433483211.2658.22.camel@perches.com \
--to=joe@perches.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=noralf@tronnes.org \
--cc=sudipm.mukherjee@gmail.com \
--cc=thomas.petazzoni@free-electrons.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.