From: Mark Greer <mgreer@animalcreek.com>
To: Vaibhav Agarwal <vaibhav.sr@gmail.com>
Cc: Kangjie Lu <kjlu@umn.edu>,
pakki001@umn.edu, Mark Greer <mgreer@animalcreek.com>,
Johan Hovold <johan@kernel.org>, Alex Elder <elder@kernel.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
greybus-dev@lists.linaro.org, devel@driverdev.osuosl.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] greybus: audio_manager: fix a missing check of ida_simple_get
Date: Tue, 30 Apr 2019 08:19:28 -0700 [thread overview]
Message-ID: <20190430151928.GA1854@animalcreek.com> (raw)
In-Reply-To: <CAAs364_6MpywkbsFdZrT5TEdrD8+u1eTmg-8_KY0dypy_PgMxQ@mail.gmail.com>
On Fri, Mar 15, 2019 at 10:49:46AM +0530, Vaibhav Agarwal wrote:
> On Thu, Mar 14, 2019 at 12:15 PM Kangjie Lu <kjlu@umn.edu> wrote:
> >
> > ida_simple_get could fail. The fix inserts a check for its
> > return value.
> >
> > Signed-off-by: Kangjie Lu <kjlu@umn.edu>
> > ---
> > drivers/staging/greybus/audio_manager.c | 3 +++
> > 1 file changed, 3 insertions(+)
> >
> > diff --git a/drivers/staging/greybus/audio_manager.c b/drivers/staging/greybus/audio_manager.c
> > index d44b070d8862..c2a4af4c1d06 100644
> > --- a/drivers/staging/greybus/audio_manager.c
> > +++ b/drivers/staging/greybus/audio_manager.c
> > @@ -45,6 +45,9 @@ int gb_audio_manager_add(struct gb_audio_manager_module_descriptor *desc)
> > int err;
> >
> > id = ida_simple_get(&module_id, 0, 0, GFP_KERNEL);
> > + if (id < 0)
> > + return id;
> > +
> > err = gb_audio_manager_module_create(&module, manager_kset,
> > id, desc);
> > if (err) {
>
> Reviewed-by: Vaibhav Agarwal <vaibhav.sr@gmail.com>
I am sorry for not responding until now. For some strange reason, email
from this list are being delayed. I just got this today (April 30).
Thanks for the patch, Kangjie, and thanks for the review, Vaibhav.
And FWIW,
Reviewed-by: Mark Greer <mgreer@animalcreek.com>
Mark
--
prev parent reply other threads:[~2019-04-30 15:28 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-14 6:45 Kangjie Lu
2019-03-14 9:08 ` [greybus-dev] " Viresh Kumar
2019-03-15 5:19 ` Vaibhav Agarwal
2019-04-30 15:19 ` Mark Greer [this message]
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=20190430151928.GA1854@animalcreek.com \
--to=mgreer@animalcreek.com \
--cc=devel@driverdev.osuosl.org \
--cc=elder@kernel.org \
--cc=gregkh@linuxfoundation.org \
--cc=greybus-dev@lists.linaro.org \
--cc=johan@kernel.org \
--cc=kjlu@umn.edu \
--cc=linux-kernel@vger.kernel.org \
--cc=pakki001@umn.edu \
--cc=vaibhav.sr@gmail.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
all inboxes | Powered by JetHome®