public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [char-misc-next] mei: me: release irq in mei_me_pci_resume error path
@ 2024-06-03 13:29 Tomas Winkler
  2024-06-04  4:45 ` Greg Kroah-Hartman
  0 siblings, 1 reply; 4+ messages in thread
From: Tomas Winkler @ 2024-06-03 13:29 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Alexander Usyskin, Vitaly Lubart, linux-kernel, Tomas Winkler

The mei_me_pci_resume doesn't release irq on the error path,
in case mei_start() fails.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
---
 drivers/misc/mei/pci-me.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/misc/mei/pci-me.c b/drivers/misc/mei/pci-me.c
index 7f59dd38c32f52dccf632fb4..6589635f8ba32b35fd28876d 100644
--- a/drivers/misc/mei/pci-me.c
+++ b/drivers/misc/mei/pci-me.c
@@ -385,8 +385,10 @@ static int mei_me_pci_resume(struct device *device)
 	}
 
 	err = mei_restart(dev);
-	if (err)
+	if (err) {
+		free_irq(pdev->irq, dev);
 		return err;
+	}
 
 	/* Start timer if stopped in suspend */
 	schedule_delayed_work(&dev->timer_work, HZ);
-- 
2.45.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [char-misc-next] mei: me: release irq in mei_me_pci_resume error path
  2024-06-03 13:29 [char-misc-next] mei: me: release irq in mei_me_pci_resume error path Tomas Winkler
@ 2024-06-04  4:45 ` Greg Kroah-Hartman
  2024-06-04  5:45   ` Winkler, Tomas
  0 siblings, 1 reply; 4+ messages in thread
From: Greg Kroah-Hartman @ 2024-06-04  4:45 UTC (permalink / raw)
  To: Tomas Winkler; +Cc: Alexander Usyskin, Vitaly Lubart, linux-kernel

On Mon, Jun 03, 2024 at 04:29:28PM +0300, Tomas Winkler wrote:
> The mei_me_pci_resume doesn't release irq on the error path,
> in case mei_start() fails.
> 
> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
> ---
>  drivers/misc/mei/pci-me.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)

What commit does this fix?

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 4+ messages in thread

* RE: [char-misc-next] mei: me: release irq in mei_me_pci_resume error path
  2024-06-04  4:45 ` Greg Kroah-Hartman
@ 2024-06-04  5:45   ` Winkler, Tomas
  2024-06-04  6:00     ` Greg Kroah-Hartman
  0 siblings, 1 reply; 4+ messages in thread
From: Winkler, Tomas @ 2024-06-04  5:45 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Usyskin, Alexander, Lubart, Vitaly, linux-kernel@vger.kernel.org

> 
> On Mon, Jun 03, 2024 at 04:29:28PM +0300, Tomas Winkler wrote:
> > The mei_me_pci_resume doesn't release irq on the error path, in case
> > mei_start() fails.
> >
> > Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
> > ---
> >  drivers/misc/mei/pci-me.c | 4 +++-
> >  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> What commit does this fix?

I would say 33ec0826314734fc4f3c9bf37 , kernel version 3.13, it's very old. I can respin with the comment, if you wish.

Thanks
Tomas


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [char-misc-next] mei: me: release irq in mei_me_pci_resume error path
  2024-06-04  5:45   ` Winkler, Tomas
@ 2024-06-04  6:00     ` Greg Kroah-Hartman
  0 siblings, 0 replies; 4+ messages in thread
From: Greg Kroah-Hartman @ 2024-06-04  6:00 UTC (permalink / raw)
  To: Winkler, Tomas
  Cc: Usyskin, Alexander, Lubart, Vitaly, linux-kernel@vger.kernel.org

On Tue, Jun 04, 2024 at 05:45:56AM +0000, Winkler, Tomas wrote:
> > 
> > On Mon, Jun 03, 2024 at 04:29:28PM +0300, Tomas Winkler wrote:
> > > The mei_me_pci_resume doesn't release irq on the error path, in case
> > > mei_start() fails.
> > >
> > > Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
> > > ---
> > >  drivers/misc/mei/pci-me.c | 4 +++-
> > >  1 file changed, 3 insertions(+), 1 deletion(-)
> > 
> > What commit does this fix?
> 
> I would say 33ec0826314734fc4f3c9bf37 , kernel version 3.13, it's very old. I can respin with the comment, if you wish.

As it's a memory-leak fix, that would be good, thanks.

greg k-h

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-06-04  5:59 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-03 13:29 [char-misc-next] mei: me: release irq in mei_me_pci_resume error path Tomas Winkler
2024-06-04  4:45 ` Greg Kroah-Hartman
2024-06-04  5:45   ` Winkler, Tomas
2024-06-04  6:00     ` Greg Kroah-Hartman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox