From: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
To: Toshi Kani <toshi.kani@hp.com>
Cc: lenb@kernel.org, linux-acpi@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ACPI: Add ACPI CPU hot-remove support
Date: Fri, 6 Jul 2012 12:02:13 +0900 [thread overview]
Message-ID: <4FF65535.4060802@jp.fujitsu.com> (raw)
In-Reply-To: <1340981479-6521-1-git-send-email-toshi.kani@hp.com>
Hi Toshi,
2012/06/29 23:51, Toshi Kani wrote:
> Added CPU hot-remove support through an ACPI eject notification.
> It calls acpi_bus_hot_remove_device(), which shares the same code
> path with the sysfs eject operation. acpi_os_hotplug_execute()
> serializes hot-remove operations between ACPI hot-remove and sysfs
> eject requests.
>
> Signed-off-by: Toshi Kani <toshi.kani@hp.com>
Looks good to me.
Reviewed-by: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
>
> ---
> This patch applies on top of the patchset below.
>
> [PATCH v6 0/6] ACPI: Add _OST support for ACPI hotplug
> http://marc.info/?l=linux-acpi&m=134074381322973&w=2
>
> ---
> drivers/acpi/processor_driver.c | 27 +++++++++++++++++----------
> 1 files changed, 17 insertions(+), 10 deletions(-)
>
> diff --git a/drivers/acpi/processor_driver.c b/drivers/acpi/processor_driver.c
> index f9fa1b2..a6f6bde 100644
> --- a/drivers/acpi/processor_driver.c
> +++ b/drivers/acpi/processor_driver.c
> @@ -699,8 +699,8 @@ int acpi_processor_device_add(acpi_handle handle, struct acpi_device **device)
> static void acpi_processor_hotplug_notify(acpi_handle handle,
> u32 event, void *data)
> {
> - struct acpi_processor *pr;
> struct acpi_device *device = NULL;
> + struct acpi_eject_event *ej_event = NULL;
> u32 ost_code = ACPI_OST_SC_NON_SPECIFIC_FAILURE; /* default */
> int result;
>
> @@ -732,20 +732,27 @@ static void acpi_processor_hotplug_notify(acpi_handle handle,
> "received ACPI_NOTIFY_EJECT_REQUEST\n"));
>
> if (acpi_bus_get_device(handle, &device)) {
> - printk(KERN_ERR PREFIX
> - "Device don't exist, dropping EJECT\n");
> + pr_err(PREFIX "Device don't exist, dropping EJECT\n");
> break;
> }
> - pr = acpi_driver_data(device);
> - if (!pr) {
> - printk(KERN_ERR PREFIX
> - "Driver data is NULL, dropping EJECT\n");
> + if (!acpi_driver_data(device)) {
> + pr_err(PREFIX "Driver data is NULL, dropping EJECT\n");
> break;
> }
>
> - /* REVISIT: update when eject is supported */
> - ost_code = ACPI_OST_SC_EJECT_NOT_SUPPORTED;
> - break;
> + ej_event = kmalloc(sizeof(*ej_event), GFP_KERNEL);
> + if (!ej_event) {
> + pr_err(PREFIX "No memory, dropping EJECT\n");
> + break;
> + }
> +
> + ej_event->handle = handle;
> + ej_event->event = ACPI_NOTIFY_EJECT_REQUEST;
> + acpi_os_hotplug_execute(acpi_bus_hot_remove_device,
> + (void *)ej_event);
> +
> + /* eject is performed asynchronously */
> + return;
>
> default:
> ACPI_DEBUG_PRINT((ACPI_DB_INFO,
>
WARNING: multiple messages have this Message-ID (diff)
From: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
To: Toshi Kani <toshi.kani@hp.com>
Cc: <lenb@kernel.org>, <linux-acpi@vger.kernel.org>,
<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] ACPI: Add ACPI CPU hot-remove support
Date: Fri, 6 Jul 2012 12:02:13 +0900 [thread overview]
Message-ID: <4FF65535.4060802@jp.fujitsu.com> (raw)
In-Reply-To: <1340981479-6521-1-git-send-email-toshi.kani@hp.com>
Hi Toshi,
2012/06/29 23:51, Toshi Kani wrote:
> Added CPU hot-remove support through an ACPI eject notification.
> It calls acpi_bus_hot_remove_device(), which shares the same code
> path with the sysfs eject operation. acpi_os_hotplug_execute()
> serializes hot-remove operations between ACPI hot-remove and sysfs
> eject requests.
>
> Signed-off-by: Toshi Kani <toshi.kani@hp.com>
Looks good to me.
Reviewed-by: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
>
> ---
> This patch applies on top of the patchset below.
>
> [PATCH v6 0/6] ACPI: Add _OST support for ACPI hotplug
> http://marc.info/?l=linux-acpi&m=134074381322973&w=2
>
> ---
> drivers/acpi/processor_driver.c | 27 +++++++++++++++++----------
> 1 files changed, 17 insertions(+), 10 deletions(-)
>
> diff --git a/drivers/acpi/processor_driver.c b/drivers/acpi/processor_driver.c
> index f9fa1b2..a6f6bde 100644
> --- a/drivers/acpi/processor_driver.c
> +++ b/drivers/acpi/processor_driver.c
> @@ -699,8 +699,8 @@ int acpi_processor_device_add(acpi_handle handle, struct acpi_device **device)
> static void acpi_processor_hotplug_notify(acpi_handle handle,
> u32 event, void *data)
> {
> - struct acpi_processor *pr;
> struct acpi_device *device = NULL;
> + struct acpi_eject_event *ej_event = NULL;
> u32 ost_code = ACPI_OST_SC_NON_SPECIFIC_FAILURE; /* default */
> int result;
>
> @@ -732,20 +732,27 @@ static void acpi_processor_hotplug_notify(acpi_handle handle,
> "received ACPI_NOTIFY_EJECT_REQUEST\n"));
>
> if (acpi_bus_get_device(handle, &device)) {
> - printk(KERN_ERR PREFIX
> - "Device don't exist, dropping EJECT\n");
> + pr_err(PREFIX "Device don't exist, dropping EJECT\n");
> break;
> }
> - pr = acpi_driver_data(device);
> - if (!pr) {
> - printk(KERN_ERR PREFIX
> - "Driver data is NULL, dropping EJECT\n");
> + if (!acpi_driver_data(device)) {
> + pr_err(PREFIX "Driver data is NULL, dropping EJECT\n");
> break;
> }
>
> - /* REVISIT: update when eject is supported */
> - ost_code = ACPI_OST_SC_EJECT_NOT_SUPPORTED;
> - break;
> + ej_event = kmalloc(sizeof(*ej_event), GFP_KERNEL);
> + if (!ej_event) {
> + pr_err(PREFIX "No memory, dropping EJECT\n");
> + break;
> + }
> +
> + ej_event->handle = handle;
> + ej_event->event = ACPI_NOTIFY_EJECT_REQUEST;
> + acpi_os_hotplug_execute(acpi_bus_hot_remove_device,
> + (void *)ej_event);
> +
> + /* eject is performed asynchronously */
> + return;
>
> default:
> ACPI_DEBUG_PRINT((ACPI_DB_INFO,
>
next prev parent reply other threads:[~2012-07-06 3:02 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-29 14:51 [PATCH] ACPI: Add ACPI CPU hot-remove support Toshi Kani
2012-07-06 3:02 ` Yasuaki Ishimatsu [this message]
2012-07-06 3:02 ` Yasuaki Ishimatsu
2012-07-06 14:17 ` Toshi Kani
2012-07-06 16:27 ` Jiang Liu
2012-07-06 19:13 ` Toshi Kani
2012-07-06 20:09 ` Khalid Aziz
2012-07-06 21:00 ` Toshi Kani
2012-07-10 22:56 ` Khalid Aziz
2012-07-10 23:30 ` Toshi Kani
[not found] ` <CAOEr4mpL952Z2iPuhfad+jhxUpOdHPRenEVmTUkU9LC8kKR29w@mail.gmail.com>
2012-08-13 15:21 ` Toshi Kani
2012-07-16 4:53 ` Pandarathil, Vijaymohan R
2012-07-16 4:53 ` Pandarathil, Vijaymohan R
2012-07-16 14:48 ` Toshi Kani
-- strict thread matches above, loose matches on Subject: below --
2012-06-29 14:47 y
2012-07-10 11:29 ` IgorMammedov
2012-07-10 17:36 ` Toshi Kani
2012-06-29 14:47 y
2012-06-29 14:47 y
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=4FF65535.4060802@jp.fujitsu.com \
--to=isimatu.yasuaki@jp.fujitsu.com \
--cc=lenb@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=toshi.kani@hp.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 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.