kernel-janitors.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Markus Elfring <Markus.Elfring@web.de>
To: Navid Emamdoost <navid.emamdoost@gmail.com>, linux-input@vger.kernel.org
Cc: "Navid Emamdoost" <emamd001@umn.edu>, "Kangjie Lu" <kjlu@umn.edu>,
	"Stephen McCamant" <mccamant@cs.umn.edu>,
	"Qiushi Wu" <wu000273@umn.edu>,
	linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org,
	"Andy Shevchenko" <andy.shevchenko@gmail.com>,
	"Dmitry Torokhov" <dmitry.torokhov@gmail.com>,
	"Jonathan Bakker" <xc-racer2@live.ca>,
	"Paweł Chmiel" <pawel.mikolaj.chmiel@gmail.com>
Subject: Re: [PATCH v2] Input: bma150: fix ref count leak in bma150_open
Date: Mon, 15 Jun 2020 16:18:36 +0000	[thread overview]
Message-ID: <3639cbd1-1ddc-2207-b119-b6a45723be04@web.de> (raw)

> in bma150_open, …

* Can the term “reference count” become relevant also for this commit message
  besides other possible adjustments?

* Would you like to add the tag “Fixes”?


…
> +++ b/drivers/input/misc/bma150.c
> @@ -357,10 +357,13 @@  static int bma150_open(struct input_dev *input)
>  	if (bma150->mode != BMA150_MODE_NORMAL) {
>  		error = bma150_set_mode(bma150, BMA150_MODE_NORMAL);
>  		if (error)
> -			return error;
> +			goto out;
>  	}
>
>  	return 0;
> +out:
> +	pm_runtime_put_noidle(&bma150->client->dev);
> +	return error;
>  }
…

Perhaps use the label “put_runtime” instead?

Regards,
Markus

                 reply	other threads:[~2020-06-15 16:18 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=3639cbd1-1ddc-2207-b119-b6a45723be04@web.de \
    --to=markus.elfring@web.de \
    --cc=andy.shevchenko@gmail.com \
    --cc=dmitry.torokhov@gmail.com \
    --cc=emamd001@umn.edu \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=kjlu@umn.edu \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mccamant@cs.umn.edu \
    --cc=navid.emamdoost@gmail.com \
    --cc=pawel.mikolaj.chmiel@gmail.com \
    --cc=wu000273@umn.edu \
    --cc=xc-racer2@live.ca \
    /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).