Linux-rt-users archive on lore.kernel.org
 help / color / Atom feed
From: Joe Korty <joe.korty@concurrent-rt.com>
To: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Cc: Tom Zanussi <zanussi@kernel.org>,
	linux-rt-users <linux-rt-users@vger.kernel.org>
Subject: Re: [PATCH 4.14-rt] Fix wrong-variable use in irq_set_affinity_notifier
Date: Tue, 11 Feb 2020 13:40:06 -0500
Message-ID: <20200211184006.GA53490@zipoli.concurrent-rt.com> (raw)
In-Reply-To: <20200211174915.mh5bntkysztjmjdd@linutronix.de>

On Tue, Feb 11, 2020 at 06:49:15PM +0100, Sebastian Andrzej Siewior wrote:
> On 2020-02-11 09:00:07 [-0500], Joe Korty wrote:
> > 4.14-rt: Fix wrong-variable use in irq_set_affinity_notifier.
> > 
> > The bug was introduced in the 4.14-rt patch
> >  
> >    0461-genirq-Handle-missing-work_struct-in-irq_set_affinit.patch
> > 
> > The symptom is a NULL pointer panic in the i40e driver on
> > system shutdown.
> ???
> > 4.19-rt and above do not have this problem due to a refactoring.
> 
> That would be Tom's to pick. Is v4.14-RT the only one affected? I was
> under the impression that we fixed it already in each stable rt tree.

A quick grep of all the -rt patch files in kernel.org/../projects/rt, newer
than May, 2019, shows that 4.14 is the only one needing a fix.

    patch-4.14.170-rt74.patch.xz:
    +		kthread_cancel_work_sync(&notify->work);
    patch-4.4.208-rt191.patch.xz:
    patch-3.18.18-rt15.patch.xz:
    patch-5.0.21-rt16.patch.xz:
    patch-5.2.21-rt14.patch.xz:
    patch-5.4.17-rt9.patch.xz:
    patch-4.9.201-rt134.patch.xz:

> 
> > Signed-off-by: Joe Korty <Joe.Korty@concurrent-rt.com>
> > 
> > Index: b/kernel/irq/manage.c
> > ===================================================================
> > --- a/kernel/irq/manage.c
> > +++ b/kernel/irq/manage.c
> > @@ -353,7 +353,7 @@ irq_set_affinity_notifier(unsigned int i
> >  
> >  	if (old_notify) {
> >  #ifdef CONFIG_PREEMPT_RT_BASE
> > -		kthread_cancel_work_sync(&notify->work);
> > +		kthread_cancel_work_sync(&old_notify->work);
> >  #else
> >  		cancel_work_sync(&old_notify->work);
> >  #endif
> 
> Sebastian

-- 

Regards,
Joe

_________________________________________________
Joe Korty
Concurrent Real-Time, Inc.
2881 Gateway Drive
Pompano Beach, Florida USA 33069
Phone: +1 954.973.5262
Email: joe.korty@concurrent-rt.com
_________________________________________________

  reply index

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-11 14:00 Joe Korty
2020-02-11 17:49 ` Sebastian Andrzej Siewior
2020-02-11 18:40   ` Joe Korty [this message]
2020-02-11 20:06     ` Tom Zanussi

Reply instructions:

You may reply publically 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=20200211184006.GA53490@zipoli.concurrent-rt.com \
    --to=joe.korty@concurrent-rt.com \
    --cc=bigeasy@linutronix.de \
    --cc=linux-rt-users@vger.kernel.org \
    --cc=zanussi@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

Linux-rt-users archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-rt-users/0 linux-rt-users/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-rt-users linux-rt-users/ https://lore.kernel.org/linux-rt-users \
		linux-rt-users@vger.kernel.org
	public-inbox-index linux-rt-users

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-rt-users


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git