public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com>
To: Joseph Dunn <jdunn14@hotpop.com>
Cc: linux-acpi@vger.kernel.org
Subject: Re: wake-on-lan
Date: Fri, 20 Jan 2006 17:24:10 +0900	[thread overview]
Message-ID: <87zmlrb93p.wl%takeuchi_satoru@jp.fujitsu.com> (raw)
In-Reply-To: <20060108104513.1468689f@taco>

Hi, Joseph

At Sun, 8 Jan 2006 10:45:13 -0700,
Joseph Dunn wrote:
> 
> I'm trying to get wake-on-lan working for my media box.  However, I'm
> running into a problem.  When I halt the machine (shutdown -h) I cannot
> wake it.  However, if the machine is unplugged, then plugged back in,
> *then* I can wake it.  The lights on the ethernet card will only glow
> when the machine is off (i.e. card can wake the machine) when I unplug
> the power and plug it back in.  I did find that however software
> suspend 2 shuts down the machine does leave it in a wakable state.

How about this patch?

Thanks,

Satoru Takeuchi

To enable wakeup GPEs, acpi_enable_wakeup_device() has to be called.
But current ACPI subssytem doesn't call this function at the shutdown
time.
This patch fixes it.

Signed-off-by: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com>

 drivers/acpi/sleep/poweroff.c |    1 +
 drivers/acpi/sleep/wakeup.c   |    2 ++
 2 files changed, 3 insertions(+)

Index: linux-2.6.16-rc1/drivers/acpi/sleep/poweroff.c
===================================================================
--- linux-2.6.16-rc1.orig/drivers/acpi/sleep/poweroff.c	2006-01-03 12:21:10.000000000 +0900
+++ linux-2.6.16-rc1/drivers/acpi/sleep/poweroff.c	2006-01-20 09:47:42.000000000 +0900
@@ -47,6 +47,7 @@
 	/* acpi_sleep_prepare(ACPI_STATE_S5) should have already been called */
 	printk("%s called\n", __FUNCTION__);
 	local_irq_disable();
+	acpi_enable_wakeup_device(ACPI_STATE_S5);
 	/* Some SMP machines only can poweroff in boot CPU */
 	acpi_enter_sleep_state(ACPI_STATE_S5);
 }
Index: linux-2.6.16-rc1/drivers/acpi/sleep/wakeup.c
===================================================================
--- linux-2.6.16-rc1.orig/drivers/acpi/sleep/wakeup.c	2006-01-20 12:04:41.000000000 +0900
+++ linux-2.6.16-rc1/drivers/acpi/sleep/wakeup.c	2006-01-20 12:05:40.000000000 +0900
@@ -48,6 +48,7 @@
 	}
 	spin_unlock(&acpi_device_lock);
 }
+#endif
 
 /**
  * acpi_enable_wakeup_device - enable wakeup devices
@@ -100,6 +101,7 @@
 	spin_unlock(&acpi_device_lock);
 }
 
+#ifdef CONFIG_ACPI_SLEEP
 /**
  * acpi_disable_wakeup_device - disable devices' wakeup capability
  *	@sleep_state:	ACPI state

  reply	other threads:[~2006-01-20  8:18 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-01-08 17:45 wake-on-lan Joseph Dunn
2006-01-20  8:24 ` Satoru Takeuchi [this message]
  -- strict thread matches above, loose matches on Subject: below --
2006-01-20  4:55 wake-on-lan Brown, Len
2006-01-20  5:16 ` wake-on-lan Karol Kozimor
2006-01-20  6:36   ` wake-on-lan Adam Belay
2006-01-20  6:50     ` wake-on-lan Karol Kozimor
2006-01-20 21:56       ` wake-on-lan Adam Belay

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=87zmlrb93p.wl%takeuchi_satoru@jp.fujitsu.com \
    --to=takeuchi_satoru@jp.fujitsu.com \
    --cc=jdunn14@hotpop.com \
    --cc=linux-acpi@vger.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox