From: "Rafael J. Wysocki" <rjw@sisk.pl>
To: Matthew Garrett <mjg@redhat.com>
Cc: linux-acpi@vger.kernel.org, robert.moore@intel.com
Subject: Re: [PATCH 1/3] acpi: Provide default GPE handler if the firmware doesn't
Date: Wed, 11 Nov 2009 22:31:57 +0100 [thread overview]
Message-ID: <200911112231.58027.rjw@sisk.pl> (raw)
In-Reply-To: <1257806687-6608-1-git-send-email-mjg@redhat.com>
On Monday 09 November 2009, Matthew Garrett wrote:
> Firmware may support using GPEs for system wakeup without providing any
> runtime GPE handlers. This prevents the use runtime power management on
> these devices even if the hardware supports it. This patch adds support
> for providing default GPE handlers if the firmware doesn't, allowing us
> to implement runtime power management on machines where it would be
> otherwise impossible.
>
> This implementation adds basic support for Intel chipsets.
Do I think correctly it's based on top of the run-time PM patches?
> Signed-off-by: Matthew Garrett <mjg@redhat.com>
> ---
> drivers/pci/pci-acpi.c | 119 ++++++++++++++++++++++++++++++++++++++++++++++++
> 1 files changed, 119 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/pci/pci-acpi.c b/drivers/pci/pci-acpi.c
> index dae90cc..7fff59c 100644
> --- a/drivers/pci/pci-acpi.c
> +++ b/drivers/pci/pci-acpi.c
> @@ -879,6 +879,124 @@ static struct acpi_bus_type acpi_pci_bus = {
> .find_bridge = acpi_pci_find_root_bridge,
> };
>
...
> +
> +static acpi_status acpi_pci_pme_notify(void *context)
> +{
> + struct work_struct *work = kzalloc(sizeof(struct work_struct),
> + GFP_ATOMIC);
kzalloc(sizeof(*work), ...) would save you a few characters. :-)
> +
> + if (work) {
> + INIT_WORK(work, context);
> + schedule_work(work);
Hmm. Not sure if putting that into pm_wq wouldn't be better.
Thanks,
Rafael
next prev parent reply other threads:[~2009-11-11 21:30 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-09 22:44 [PATCH 1/3] acpi: Provide default GPE handler if the firmware doesn't Matthew Garrett
2009-11-09 22:44 ` [PATCH 2/3] acpica: Add support for unregistering ACPI GPE methods Matthew Garrett
2009-11-09 22:44 ` [PATCH 3/3] pci: Override gpe 0xd on Dell machines Matthew Garrett
2009-11-11 21:33 ` [PATCH 2/3] acpica: Add support for unregistering ACPI GPE methods Rafael J. Wysocki
2009-11-11 21:31 ` Rafael J. Wysocki [this message]
2009-11-11 21:54 ` [PATCH 1/3] acpi: Provide default GPE handler if the firmware doesn't Matthew Garrett
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=200911112231.58027.rjw@sisk.pl \
--to=rjw@sisk.pl \
--cc=linux-acpi@vger.kernel.org \
--cc=mjg@redhat.com \
--cc=robert.moore@intel.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.