From patchwork Sun Nov 9 21:05:30 2008 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "J. K. Cliburn" X-Patchwork-Id: 7952 X-Patchwork-Delegate: jgarzik@pobox.com Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by ozlabs.org (Postfix) with ESMTP id 3B68A474C3 for ; Mon, 10 Nov 2008 08:05:42 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756121AbYKIVFh (ORCPT ); Sun, 9 Nov 2008 16:05:37 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1756100AbYKIVFh (ORCPT ); Sun, 9 Nov 2008 16:05:37 -0500 Received: from wf-out-1314.google.com ([209.85.200.174]:58769 "EHLO wf-out-1314.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755859AbYKIVFg (ORCPT ); Sun, 9 Nov 2008 16:05:36 -0500 Received: by wf-out-1314.google.com with SMTP id 27so2235630wfd.4 for ; Sun, 09 Nov 2008 13:05:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:date:from:to:cc:subject :message-id:x-mailer:mime-version:content-type :content-transfer-encoding; bh=RyJ3+2B6u4r5CuIbnP3eyqlLga6+ysSHBrpFv6TDo+A=; b=VLduPVOJh4Ka3hqI2tZWK99MthSmP9QIE+2FgDTXDaCCQsthkPWMuM5g6HIphHvnH5 RoL27QRe9tna3dSCjKxcOE6xDThX9G8fbFKHflMcaiMkexKKB6zH1wrGgSbKlHzlG7E6 /mrPurYdYa/GWzBvRwm/ItoW+oMvQTLSP8CB0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=date:from:to:cc:subject:message-id:x-mailer:mime-version :content-type:content-transfer-encoding; b=SLiOpMfqPMnOzX2hC5yDfZc5hEQenkGBDXl8aNtmHLzh0wVh2rLWXgU8rrfPtrXUFn gLsjbi9+jCiGkn+G0bYVzaG36I5yNjEMnL6opiPvnUdxLV5nvjpuQrLIYZNIJobSeH1k H0AQnN9b4iWrTEEuMglKr4y576VVJN3hv1+pc= Received: by 10.143.39.16 with SMTP id r16mr1981933wfj.172.1226264735665; Sun, 09 Nov 2008 13:05:35 -0800 (PST) Received: from osprey.hogchain.net ([70.152.123.69]) by mx.google.com with ESMTPS id 32sm8791380wfc.12.2008.11.09.13.05.33 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 09 Nov 2008 13:05:34 -0800 (PST) Date: Sun, 9 Nov 2008 15:05:30 -0600 From: "J. K. Cliburn" To: jeff@garzik.org Cc: Chris Snook , Jie.yang@atheros.com, netdev@vger.kernel.org Subject: atl1: use magic packet wake-on-lan only Message-ID: <20081109150530.3eb555f9@osprey.hogchain.net> X-Mailer: Claws Mail 3.5.0 (GTK+ 2.12.12; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org atl1: use magic packet wake-on-lan only Of the various WOL options provided in include/linux/ethtool.h, the L1 NIC supports only magic packet. Remove all options except magic packet from the atl1 driver. Signed-off-by: Jay Cliburn --- drivers/net/atlx/atl1.c | 17 +++-------------- 1 files changed, 3 insertions(+), 14 deletions(-) diff --git a/drivers/net/atlx/atl1.c b/drivers/net/atlx/atl1.c index 09ed2fd..611a86e 100644 --- a/drivers/net/atlx/atl1.c +++ b/drivers/net/atlx/atl1.c @@ -3384,14 +3384,8 @@ static void atl1_get_wol(struct net_device *netdev, { struct atl1_adapter *adapter = netdev_priv(netdev); - wol->supported = WAKE_UCAST | WAKE_MCAST | WAKE_BCAST | WAKE_MAGIC; + wol->supported = WAKE_MAGIC; wol->wolopts = 0; - if (adapter->wol & ATLX_WUFC_EX) - wol->wolopts |= WAKE_UCAST; - if (adapter->wol & ATLX_WUFC_MC) - wol->wolopts |= WAKE_MCAST; - if (adapter->wol & ATLX_WUFC_BC) - wol->wolopts |= WAKE_BCAST; if (adapter->wol & ATLX_WUFC_MAG) wol->wolopts |= WAKE_MAGIC; return; @@ -3402,15 +3396,10 @@ static int atl1_set_wol(struct net_device *netdev, { struct atl1_adapter *adapter = netdev_priv(netdev); - if (wol->wolopts & (WAKE_PHY | WAKE_ARP | WAKE_MAGICSECURE)) + if (wol->wolopts & (WAKE_PHY | WAKE_UCAST | WAKE_MCAST | WAKE_BCAST | + WAKE_ARP | WAKE_MAGICSECURE)) return -EOPNOTSUPP; adapter->wol = 0; - if (wol->wolopts & WAKE_UCAST) - adapter->wol |= ATLX_WUFC_EX; - if (wol->wolopts & WAKE_MCAST) - adapter->wol |= ATLX_WUFC_MC; - if (wol->wolopts & WAKE_BCAST) - adapter->wol |= ATLX_WUFC_BC; if (wol->wolopts & WAKE_MAGIC) adapter->wol |= ATLX_WUFC_MAG; return 0;