On Sun, Jan 29, 2006 at 06:54:54PM +0100, Daniele Venzano wrote:

> >>+   if (wol->wolopts == 0) {
> >>+           pci_read_config_dword(sis_priv->pci_dev, CFGPMCSR, 
> >>&cfgpmcsr);
> >>+           cfgpmcsr |= ~PME_EN;
> >
> >"cfgpmcsr &= ~PME_EN;"  ?
> 
> Since cfgpmcsr is initialized as 0 I don't think this is a problem.

Instead of turning the PME_EN bit off, you are turning every bit other
than PME_EN on, which means that once you turn on WOL, you won't be able
to turn it off again.. so let's fix it anyway?

Signed-off-by: Lennert Buytenhek <[EMAIL PROTECTED]>

--- linux-2.6.16-rc1/drivers/net/sis900.c.orig  2006-01-29 20:35:19.000000000 
+0100
+++ linux-2.6.16-rc1/drivers/net/sis900.c       2006-01-29 20:34:52.000000000 
+0100
@@ -2040,7 +2040,7 @@
 
        if (wol->wolopts == 0) {
                pci_read_config_dword(sis_priv->pci_dev, CFGPMCSR, &cfgpmcsr);
-               cfgpmcsr |= ~PME_EN;
+               cfgpmcsr &= ~PME_EN;
                pci_write_config_dword(sis_priv->pci_dev, CFGPMCSR, cfgpmcsr);
                outl(pmctrl_bits, pmctrl_addr);
                if (netif_msg_wol(sis_priv))
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to