From: Andy Shevchenko <andriy.shevchenko@linux.intel.com> To: Jonathan Cameron <jic23@kernel.org> Cc: Dan Carpenter <dan.carpenter@oracle.com>, Vincent Pelletier <plr.vincent@gmail.com>, Hartmut Knaack <knaack.h@gmx.de>, Lars-Peter Clausen <lars@metafoo.de>, Peter Meerwald-Stadler <pmeerw@pmeerw.net>, linux-iio@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: Re: [PATCH] iio: adc: intel_mrfld_adc: Allocating too much data in probe() Date: Mon, 25 Nov 2019 09:33:23 +0000 [thread overview] Message-ID: <20191125093323.GZ32742@smile.fi.intel.com> (raw) In-Reply-To: <20191123144206.7d3e5bd4@archlinux> On Sat, Nov 23, 2019 at 02:42:06PM +0000, Jonathan Cameron wrote: > On Tue, 19 Nov 2019 12:23:32 +0200 > Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote: > > > On Tue, Nov 19, 2019 at 09:21:24AM +0300, Dan Carpenter wrote: > > > This probe function is passing the wrong size to devm_iio_device_alloc(). > > > It is supposed to be the size of the private data. Fortunately, > > > sizeof(*indio_dev) is larger than sizeof(struct mrfld_adc) so it doesn't > > > cause a runtime problem. > > > > > > > Ah, indeed, thanks for fixing this! > > Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> > Applied to the fixes-togreg branch of iio.git. Thanks! > I'll wait until after the merge window now to send a pull request for this > one so will be rc2ish before it's in. Sure, as pointed out by Dan it seems to work due to size of wrong structure is bigger than needed, thus it's not a critical fix. -- With Best Regards, Andy Shevchenko
WARNING: multiple messages have this Message-ID (diff)
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com> To: Jonathan Cameron <jic23@kernel.org> Cc: Dan Carpenter <dan.carpenter@oracle.com>, Vincent Pelletier <plr.vincent@gmail.com>, Hartmut Knaack <knaack.h@gmx.de>, Lars-Peter Clausen <lars@metafoo.de>, Peter Meerwald-Stadler <pmeerw@pmeerw.net>, linux-iio@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: Re: [PATCH] iio: adc: intel_mrfld_adc: Allocating too much data in probe() Date: Mon, 25 Nov 2019 11:33:23 +0200 [thread overview] Message-ID: <20191125093323.GZ32742@smile.fi.intel.com> (raw) In-Reply-To: <20191123144206.7d3e5bd4@archlinux> On Sat, Nov 23, 2019 at 02:42:06PM +0000, Jonathan Cameron wrote: > On Tue, 19 Nov 2019 12:23:32 +0200 > Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote: > > > On Tue, Nov 19, 2019 at 09:21:24AM +0300, Dan Carpenter wrote: > > > This probe function is passing the wrong size to devm_iio_device_alloc(). > > > It is supposed to be the size of the private data. Fortunately, > > > sizeof(*indio_dev) is larger than sizeof(struct mrfld_adc) so it doesn't > > > cause a runtime problem. > > > > > > > Ah, indeed, thanks for fixing this! > > Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> > Applied to the fixes-togreg branch of iio.git. Thanks! > I'll wait until after the merge window now to send a pull request for this > one so will be rc2ish before it's in. Sure, as pointed out by Dan it seems to work due to size of wrong structure is bigger than needed, thus it's not a critical fix. -- With Best Regards, Andy Shevchenko
next prev parent reply other threads:[~2019-11-25 9:33 UTC|newest] Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-11-19 6:21 [PATCH] iio: adc: intel_mrfld_adc: Allocating too much data in probe() Dan Carpenter 2019-11-19 6:21 ` Dan Carpenter 2019-11-19 10:23 ` Andy Shevchenko 2019-11-19 10:23 ` Andy Shevchenko 2019-11-23 14:42 ` Jonathan Cameron 2019-11-25 9:33 ` Andy Shevchenko [this message] 2019-11-25 9:33 ` Andy Shevchenko
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=20191125093323.GZ32742@smile.fi.intel.com \ --to=andriy.shevchenko@linux.intel.com \ --cc=dan.carpenter@oracle.com \ --cc=jic23@kernel.org \ --cc=kernel-janitors@vger.kernel.org \ --cc=knaack.h@gmx.de \ --cc=lars@metafoo.de \ --cc=linux-iio@vger.kernel.org \ --cc=plr.vincent@gmail.com \ --cc=pmeerw@pmeerw.net \ /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: linkBe 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.