From: Sven Ladegast <sven@linux4geeks.de>
To: linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2.6] via-rhine: WOL band-aid (patch against 2.6.9)
Date: Wed, 1 Dec 2004 01:46:13 +0100 [thread overview]
Message-ID: <200412010146.13552.sven@linux4geeks.de> (raw)
In-Reply-To: <20041130224014.GD29947@k3.hellgate.ch>
[-- Attachment #1: Type: text/plain, Size: 494 bytes --]
On Tuesday 30 November 2004 23:40, Roger Luethi wrote:
> This version applies against -mm. I suggest to put it there for testing
> and into 2.6.11 if feedback is good.
And here is the "backport" to 2.6.9 for current users waiting for this patch.
It is working for me on an ECS Elitegroup KT-600A mainboard with VT8237 and a
Rhine-II network controller.
Sven
--
Sven Ladegast, Friedrich-Fröbel-Straße 11, 93310 Arnstadt / Germany
Phone: +49-175-5334308, PGP-key: 0x5856A5ED
[-- Attachment #2: via-rhine-corrected-2.6.9.diff --]
[-- Type: text/x-diff, Size: 1444 bytes --]
--- via-rhine.c 2004-10-18 23:55:28.000000000 +0200
+++ via-rhine-patched.c 2004-12-01 01:02:18.000000000 +0100
@@ -664,7 +664,7 @@ static void __devinit rhine_reload_eepro
/* Turn off EEPROM-controlled wake-up (magic packet) */
if (rp->quirks & rqWOL)
- writeb(readb(ioaddr + ConfigA) & 0xFE, ioaddr + ConfigA);
+ writeb(readb(ioaddr + ConfigA) & 0xFC, ioaddr + ConfigA);
}
@@ -1917,8 +1917,14 @@ static void rhine_shutdown (struct devic
if (rp->quirks & rq6patterns)
writeb(0x04, ioaddr + 0xA7);
- if (rp->wolopts & WAKE_MAGIC)
+ if (rp->wolopts & WAKE_MAGIC) {
writeb(WOLmagic, ioaddr + WOLcrSet);
+ /*
+ * Turn EEPROM-controlled wake-up back on -- some hardware may
+ * not cooperate otherwise.
+ */
+ writeb(readb(ioaddr + ConfigA) | 0x03, ioaddr + ConfigA);
+ }
if (rp->wolopts & (WAKE_BCAST|WAKE_MCAST))
writeb(WOLbmcast, ioaddr + WOLcgSet);
@@ -1929,9 +1935,11 @@ static void rhine_shutdown (struct devic
if (rp->wolopts & WAKE_UCAST)
writeb(WOLucast, ioaddr + WOLcrSet);
- /* Enable legacy WOL (for old motherboards) */
- writeb(0x01, ioaddr + PwcfgSet);
- writeb(readb(ioaddr + StickyHW) | 0x04, ioaddr + StickyHW);
+ if (rp->wolopts) {
+ /* Enable legacy WOL (for old motherboards) */
+ writeb(0x01, ioaddr + PwcfgSet);
+ writeb(readb(ioaddr + StickyHW) | 0x04, ioaddr + StickyHW);
+ }
/* Hit power state D3 (sleep) */
writeb(readb(ioaddr + StickyHW) | 0x03, ioaddr + StickyHW);
prev parent reply other threads:[~2004-12-01 0:56 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-11-30 22:40 [PATCH 2.6] via-rhine: WOL band-aid Roger Luethi
2004-11-30 23:17 ` Jeff Garzik
2004-11-30 23:45 ` Roger Luethi
2004-12-02 22:40 ` Jeff Garzik
2004-12-01 0:46 ` Sven Ladegast [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=200412010146.13552.sven@linux4geeks.de \
--to=sven@linux4geeks.de \
--cc=linux-kernel@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