All of lore.kernel.org
 help / color / mirror / Atom feed
From: Toshi Kani <toshi.kani@hp.com>
To: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: Jiang Liu <jiang.liu@linux.intel.com>,
	"Rafael J . Wysocki" <rafael.j.wysocki@intel.com>,
	Bjorn Helgaas <bhelgaas@google.com>,
	Yinghai Lu <yinghai@kernel.org>,
	Yijing Wang <wangyijing@huawei.com>, Len Brown <lenb@kernel.org>,
	Robert Moore <robert.moore@intel.com>,
	Lv Zheng <lv.zheng@intel.com>,
	linux-acpi@vger.kernel.org, linux-pci@vger.kernel.org,
	linux-kernel@vger.kernel.org, devel@acpica.org
Subject: Re: [Patch v1 1/3] ACPI: add callback prepare() into acpi_hotplug_handler
Date: Tue, 21 Jan 2014 16:06:36 -0700	[thread overview]
Message-ID: <1390345596.1792.468.camel@misato.fc.hp.com> (raw)
In-Reply-To: <2201697.uqWgsYrLat@vostro.rjw.lan>

On Wed, 2014-01-22 at 00:17 +0100, Rafael J. Wysocki wrote:
> On Tuesday, January 21, 2014 02:14:57 PM Toshi Kani wrote:
> > On Sat, 2014-01-18 at 10:48 +0800, Jiang Liu wrote:
> > > Add callback prepare() into acpi_hotplug_handler, which will get called
> > > at the very beginning of ACPI hotplug event handler. The ACPI core will
> > > ignore the event if prepare() returns NOTIFY_STOP.
> > > 
> > > Signed-off-by: Jiang Liu <jiang.liu@linux.intel.com>
> > > ---
> > >  drivers/acpi/scan.c     |    4 ++++
> > >  include/acpi/acpi_bus.h |    1 +
> > >  2 files changed, 5 insertions(+)
> > > 
> > > diff --git a/drivers/acpi/scan.c b/drivers/acpi/scan.c
> > > index fd39459..6b0f419 100644
> > > --- a/drivers/acpi/scan.c
> > > +++ b/drivers/acpi/scan.c
> > > @@ -392,6 +392,10 @@ static void acpi_hotplug_notify_cb(acpi_handle handle, u32 type, void *data)
> > >  	struct acpi_device *adev;
> > >  	acpi_status status;
> > >  
> > > +	if (handler->prepare &&
> > > +	    handler->prepare(handle, type, data) == NOTIFY_STOP)
> > > +		return;
> > 
> > The OS is responsible for calling _OST when it is implemented.  So you
> > cannot just return here.  See acpi_hotplug_unsupported(handle, type)
> > next line.  Also, please describe why prepare() needs to be added.
> 
> I don't think it's needed any more, please see:
> 
> http://marc.info/?l=linux-acpi&m=139001691317575&w=2

Oh, I see.  Thanks!
-Toshi

      reply	other threads:[~2014-01-21 23:06 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-18  2:48 [Patch v1 1/3] ACPI: add callback prepare() into acpi_hotplug_handler Jiang Liu
2014-01-18  2:48 ` [Patch v1 2/3] ACPI, PCI: reuse ACPI hotplug framework to support PCI host bridge hotplug Jiang Liu
2014-01-18  3:23   ` Yinghai Lu
2014-01-18  3:48     ` Jiang Liu
2014-01-18  2:48 ` [Patch v1 3/3] ACPI: kill field 'ignore' in acpi_hotplug_profile Jiang Liu
2014-01-21 21:14 ` [Patch v1 1/3] ACPI: add callback prepare() into acpi_hotplug_handler Toshi Kani
2014-01-21 23:17   ` Rafael J. Wysocki
2014-01-21 23:06     ` Toshi Kani [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=1390345596.1792.468.camel@misato.fc.hp.com \
    --to=toshi.kani@hp.com \
    --cc=bhelgaas@google.com \
    --cc=devel@acpica.org \
    --cc=jiang.liu@linux.intel.com \
    --cc=lenb@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lv.zheng@intel.com \
    --cc=rafael.j.wysocki@intel.com \
    --cc=rjw@rjwysocki.net \
    --cc=robert.moore@intel.com \
    --cc=wangyijing@huawei.com \
    --cc=yinghai@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.