kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rik van Riel <riel@redhat.com>
To: Frederic Weisbecker <fweisbec@gmail.com>
Cc: paulmck@linux.vnet.ibm.com, luto@amacapital.net,
	will.deacon@arm.com, linux-kernel@vger.kernel.org,
	kvm@vger.kernel.org, mtosatti@redhat.com, borntraeger@de.ibm.com,
	lcapitulino@redhat.com, pbonzini@redhat.com
Subject: Re: [PATCH -v5 6/5] context_tracking: fix exception_enter when already in IN_KERNEL
Date: Thu, 12 Feb 2015 10:47:10 -0500	[thread overview]
Message-ID: <54DCCAFE.7080206@redhat.com> (raw)
In-Reply-To: <20150212154232.GE18363@lerouge>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 02/12/2015 10:42 AM, Frederic Weisbecker wrote:
> On Wed, Feb 11, 2015 at 02:43:19PM -0500, Rik van Riel wrote:
>> If exception_enter happens when already in IN_KERNEL state, the 
>> code still calls context_tracking_exit, which ends up in 
>> rcu_eqs_exit_common, which explodes with a WARN_ON when it is 
>> called in a situation where dynticks are not enabled.
> 
> Fortunately context_tracking_exit() already has a current_state ==
> IN_KERNEL check so this shouldn't be a problem.

No, it had a hard-coded "current_state == IN_USER" check,
which is very close, but ...

... I replaced that with a state argument, and forgot to
ensure that it never gets called with state == IN_KERNEL.
This patch fixes that.

> Meanwhile I'll still take the patch, it's better to handle that 
> from the caller.

Thanks.

- -- 
All rights reversed
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQEcBAEBAgAGBQJU3Mr+AAoJEM553pKExN6DYNUH/2m9CtXhLdTHOEHRvxg41PCZ
/xafetUOS9cka0CNuiYpUuvfMSucoePW7YqUXqjYSIP25DsAleOh0qdep1Ob5bH+
2BqZNMwK3QDHf1+/V7nulnjVkeHtpXJm0HIZOjc06xeL+9T6ydB1vhQGIMLrGL9S
LvOstI3fseeIgglwYc2Gx7H7e99oOkxysvwMMvcMrW0cPSRAOdYxINQnfYW8A5kq
DTTXwWuJRZa4FLtP3wLpvocm5dMGDwTsDmuOk1PmXYlsTsO6H2BmCeio0euzStoJ
l+jR4x7Aq2KXES7gnMgpPw1iON3xKJ/RbXF8IC/doII8FYEV8Raxnf7hl47etBw=
=yIjW
-----END PGP SIGNATURE-----

  reply	other threads:[~2015-02-12 15:47 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-10 20:27 [PATCH -v5 0/5] rcu,nohz,kvm: use RCU extended quiescent state when running KVM guest riel
2015-02-10 20:27 ` [PATCH 1/5] context_tracking: generalize context tracking APIs to support user and guest riel
2015-02-10 21:28   ` Paul E. McKenney
2015-02-10 20:27 ` [PATCH 2/5] nohz: add stub context_tracking_is_enabled riel
2015-02-10 21:29   ` Paul E. McKenney
2015-02-10 20:27 ` [PATCH 3/5] rcu,nohz: run vtime_user_enter/exit only when state == IN_USER riel
2015-02-10 21:35   ` Paul E. McKenney
2015-02-10 20:27 ` [PATCH 4/5] nohz,kvm: export context_tracking_user_enter/exit riel
2015-02-10 21:36   ` Paul E. McKenney
2015-02-10 20:27 ` [PATCH 5/5] kvm,rcu,nohz: use RCU extended quiescent state when running KVM guest riel
2015-02-10 21:42   ` Paul E. McKenney
2015-02-11 19:43 ` [PATCH -v5 6/5] context_tracking: fix exception_enter when already in IN_KERNEL Rik van Riel
2015-02-11 21:27   ` Paul E. McKenney
2015-02-12 15:42   ` Frederic Weisbecker
2015-02-12 15:47     ` Rik van Riel [this message]
2015-02-12 17:00       ` Frederic Weisbecker
2015-02-12 17:48         ` Rik van Riel
2015-02-12 17:09 ` [PATCH -v5 0/5] rcu,nohz,kvm: use RCU extended quiescent state when running KVM guest Frederic Weisbecker

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=54DCCAFE.7080206@redhat.com \
    --to=riel@redhat.com \
    --cc=borntraeger@de.ibm.com \
    --cc=fweisbec@gmail.com \
    --cc=kvm@vger.kernel.org \
    --cc=lcapitulino@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luto@amacapital.net \
    --cc=mtosatti@redhat.com \
    --cc=paulmck@linux.vnet.ibm.com \
    --cc=pbonzini@redhat.com \
    --cc=will.deacon@arm.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;
as well as URLs for NNTP newsgroup(s).