From: Dan Carpenter <dan.carpenter@linaro.org>
To: Bartosz Golaszewski <brgl@bgdev.pl>
Cc: Kent Gibson <warthog618@gmail.com>,
Linus Walleij <linus.walleij@linaro.org>,
linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org,
Alexey Dobriyan <adobriyan@gmail.com>,
Bartosz Golaszewski <bartosz.golaszewski@linaro.org>,
stable@vger.kernel.org, Stefan Wahren <wahrenst@gmx.net>
Subject: Re: [PATCH] gpio: cdev: sanitize the label before requesting the interrupt
Date: Fri, 22 Mar 2024 12:31:36 +0300 [thread overview]
Message-ID: <f529d746-f8c5-466b-860b-e2bfaeb2cc27@moroto.mountain> (raw)
In-Reply-To: <CAMRc=MfQnZQU_t9-uDPp18vFikz_9eP6LtnWJYG0+KFgWjBcEg@mail.gmail.com>
On Fri, Mar 22, 2024 at 08:46:50AM +0100, Bartosz Golaszewski wrote:
> On Fri, Mar 22, 2024 at 2:30 AM Kent Gibson <warthog618@gmail.com> wrote:
> >
> > On Wed, Mar 20, 2024 at 01:59:44PM +0100, Bartosz Golaszewski wrote:
> > > From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> > >
> > > Let's replace all "/" with "-".
> > >
> >
> > I actually prefer the ":" you originally suggested, as it more clearly
> > indicates a tier separation, whereas a hyphen is commonly used for
> > multi-word names. And as the hyphen is more commonly used the sanitized
> > name is more likely to conflict.
> >
>
> Sounds good, will do.
> > >
> > > + label = make_irq_label(le->label);
> > > + if (!label)
> > > + goto out_free_le;
> > > +
> >
> > Need to set ret = -ENOMEM before the goto, else you will return 0.
> >
>
> Eek, right, thanks.
Smatch has a warning about this, btw.
drivers/gpio/gpiolib-cdev.c:2221 lineevent_create() warn: missing error code 'ret'
The other warning here is:
drivers/gpio/gpiolib-cdev.c:2269 lineevent_create() warn: 'irq' from request_threaded_irq() not released on lines: 2258.
regards,
dan carpenter
next prev parent reply other threads:[~2024-03-22 9:31 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-20 12:59 Bartosz Golaszewski
2024-03-22 1:30 ` Kent Gibson
2024-03-22 7:46 ` Bartosz Golaszewski
2024-03-22 9:31 ` Dan Carpenter [this message]
2024-03-22 11:54 ` Kent Gibson
2024-03-22 12:58 ` Dan Carpenter
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=f529d746-f8c5-466b-860b-e2bfaeb2cc27@moroto.mountain \
--to=dan.carpenter@linaro.org \
--cc=adobriyan@gmail.com \
--cc=bartosz.golaszewski@linaro.org \
--cc=brgl@bgdev.pl \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=stable@vger.kernel.org \
--cc=wahrenst@gmx.net \
--cc=warthog618@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®