public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: KY Srinivasan <kys@microsoft.com>
Cc: "gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"devel@linuxdriverproject.org" <devel@linuxdriverproject.org>,
	"olaf@aepfle.de" <olaf@aepfle.de>,
	"apw@canonical.com" <apw@canonical.com>,
	"jasowang@redhat.com" <jasowang@redhat.com>
Subject: Re: 3.7 RC1
Date: Wed, 24 Oct 2012 09:41:36 +0300	[thread overview]
Message-ID: <20121024064135.GF20754@mwanda> (raw)
In-Reply-To: <426367E2313C2449837CD2DE46E7EAF930A45A90@SN2PRD0310MB382.namprd03.prod.outlook.com>

On Tue, Oct 23, 2012 at 02:24:58PM +0000, KY Srinivasan wrote:
> 
> 
> > -----Original Message-----
> > From: Dan Carpenter [mailto:dan.carpenter@oracle.com]
> > Sent: Tuesday, October 23, 2012 1:47 AM
> > To: KY Srinivasan
> > Cc: gregkh@linuxfoundation.org; linux-kernel@vger.kernel.org;
> > devel@linuxdriverproject.org; olaf@aepfle.de; apw@canonical.com;
> > jasowang@redhat.com
> > Subject: Re: 3.7 RC1
> > 
> > On Mon, Oct 22, 2012 at 04:37:45PM -0700, K. Y. Srinivasan wrote:
> > >
> > > While testing 3.7 RC1 I discovered that invoking the function
> > orderly_poweroff()
> > > from an interrupt context will trigger an ASSERT(). This was not the case till
> > > recently. The comment preceding the orderly_poweroff() function claims that
> > this
> > > function can be invoked from any context and in the current Hyper-V util driver,
> > > we support host-driven orderly shut down of the guest by invoking this
> > > orderly_poweroff() function in the context of the message callback. This code
> > has
> > > been working for a very long time and it is broken now. Is my assumption that
> > > orderly_poweroff() could be invoked from the interrupt context a wrong
> > assumption?
> > 
> > You can't call orderly_poweroff() from interrupt context.
> 
> Thanks Dan; I am curious  to understand the basis for your assertion.
> As I noted earlier  the documentation for this function clearly says it can
> be called from any context. Furthermore, __orderly_poweroff(), the helper
> function allocates memory with the GFP_ATOMIC flag set. Lastly, the behavior
> of orderly_poweroff() has been such that this function could be called from interrupt context
> for a very long time and something has changed now. For what it is worth, there are other users in
> the kernel (in 3.7 RC1) that are invoking the orderly_poweroff() function from interrupt
> context other than the Hyper-V shutdown handler:  fsl_hv_shutdown_isr() in drivers/virt/fsl_hypervisor.c.
> I suspect there are other users as well that have made this similar assumption.
> 

Aw crap.  I was wrong.  Sorry about that.

regards,
dan carpenter


      reply	other threads:[~2012-10-24  6:41 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-22 23:37 3.7 RC1 K. Y. Srinivasan
2012-10-22 23:33 ` Greg KH
2012-10-22 23:55   ` KY Srinivasan
2012-10-23 18:45   ` KY Srinivasan
2012-10-25 13:50   ` KY Srinivasan
2012-10-23  5:47 ` Dan Carpenter
2012-10-23 14:24   ` KY Srinivasan
2012-10-24  6:41     ` Dan Carpenter [this message]

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=20121024064135.GF20754@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=apw@canonical.com \
    --cc=devel@linuxdriverproject.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=jasowang@redhat.com \
    --cc=kys@microsoft.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=olaf@aepfle.de \
    /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