platform-driver-x86.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sebastian Reichel <sebastian.reichel@collabora.com>
To: Hans de Goede <hdegoede@redhat.com>
Cc: Andy Shevchenko <andy.shevchenko@gmail.com>,
	ACPI Devel Maling List <linux-acpi@vger.kernel.org>,
	Platform Driver <platform-driver-x86@vger.kernel.org>,
	Linux PM <linux-pm@vger.kernel.org>,
	"Andrew F . Davis" <afd@ti.com>
Subject: Re: [PATCH v2] power: supply: bq27xxx: Fix kernel crash on IRQ handler register error
Date: Tue, 2 Nov 2021 17:41:17 +0100	[thread overview]
Message-ID: <20211102164117.pnbpvephlh4wgrwb@earth.universe> (raw)
In-Reply-To: <e74947c4-74c8-a17e-f4cb-752a79851954@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 1740 bytes --]

Hi Hans,

On Tue, Nov 02, 2021 at 03:12:51PM +0100, Hans de Goede wrote:
> Hi Sebastian,
> 
> On 11/2/21 14:23, Sebastian Reichel wrote:
> > Hi,
> > 
> > On Sun, Oct 31, 2021 at 09:34:46PM +0200, Andy Shevchenko wrote:
> >> On Sun, Oct 31, 2021 at 5:25 PM Hans de Goede <hdegoede@redhat.com> wrote:
> >>>
> >>> When registering the IRQ handler fails, do not just return the error code,
> >>> this will free the devm_kzalloc()-ed data struct while leaving the queued
> >>> work queued and the registered power_supply registered with both of them
> >>> now pointing to free-ed memory, resulting in various kernel crashes
> >>> soon afterwards.
> >>>
> >>> Instead properly tear-down things on IRQ handler register errors.
> >>
> >> FWIW,
> >> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
> > 
> > Thanks, queued.
> 
> Thank you, note these 2 patches (for the bq25980 driver) are also
> pure bug-fixes, I posted them as part of a larger series, but
> in hindsight I should have probably posted them separately:
> 
> https://lore.kernel.org/platform-driver-x86/20211030182813.116672-4-hdegoede@redhat.com/
> https://lore.kernel.org/platform-driver-x86/20211030182813.116672-5-hdegoede@redhat.com/
> 
> It would be good if you can pick these 2 up too
> (I'll respin the rest of the series to address various
> review comments without them then).
> Let me know if you want me to resend these 2 as a stand alone
> series.

Thanks for the pointer, I queued both of them. I had to slightly
rebase, since your base did not include 172d0ccea55c. I have not
yet reviewed the remaining patchset, but considering there are more
patches to bq25890 a rebase would be ncie.

Greetings,

-- Sebastian

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2021-11-02 16:41 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-31 15:25 [PATCH v2] power: supply: bq27xxx: Fix kernel crash on IRQ handler register error Hans de Goede
2021-10-31 19:34 ` Andy Shevchenko
2021-11-02 13:23   ` Sebastian Reichel
2021-11-02 14:12     ` Hans de Goede
2021-11-02 16:41       ` Sebastian Reichel [this message]
2021-11-02 17:58         ` Hans de Goede

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=20211102164117.pnbpvephlh4wgrwb@earth.universe \
    --to=sebastian.reichel@collabora.com \
    --cc=afd@ti.com \
    --cc=andy.shevchenko@gmail.com \
    --cc=hdegoede@redhat.com \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=platform-driver-x86@vger.kernel.org \
    /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).