From patchwork Fri Jan 17 14:26:20 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Fenkart X-Patchwork-Id: 3504871 Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 378869F169 for ; Fri, 17 Jan 2014 14:30:22 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2BCE52015E for ; Fri, 17 Jan 2014 14:30:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 90B292015D for ; Fri, 17 Jan 2014 14:30:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752184AbaAQOaO (ORCPT ); Fri, 17 Jan 2014 09:30:14 -0500 Received: from mail-ea0-f169.google.com ([209.85.215.169]:57671 "EHLO mail-ea0-f169.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751989AbaAQOaN (ORCPT ); Fri, 17 Jan 2014 09:30:13 -0500 Received: by mail-ea0-f169.google.com with SMTP id l9so1558950eaj.28 for ; Fri, 17 Jan 2014 06:30:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=UceBDWDCgypGvm7XI771x6Rb8rCYeUfg6ZK9MFoA0tc=; b=EfL0UxxNfJQ7MoI7qTBStPaUgVCszmTnAgpJjuu6eLnt80ys+h+Ik3CAYIaPZv5QD4 TZIhJSrTmMa6MqEUvNSU4TmJP/FnKM6a6uTGcoIPAZysKhKHigFH1/xfYqtodayE0CIb CcW5VQCL7E2gCmMjUYi7Gqe7fA4mAo1v0g6My7h50bFGhCGEZURZTALYUEkp2Tf7No9T OjPBTOnEeqIJl22QqIfcyEbtM9wRQrW8vgs5euFuKuBdzPlbYK0wb6VHzAAlX+Fk6Klt KI4M6tVIJy3jGUHWujO3+8DIIMEk2Z+VtxsFPW1tZT8chVuLb1Z/CeCyZq3h2CM3vCsc qw8w== X-Received: by 10.14.178.65 with SMTP id e41mr2690383eem.79.1389969009840; Fri, 17 Jan 2014 06:30:09 -0800 (PST) Received: from localhost (ip-94-112-2-150.net.upcbroadband.cz. [94.112.2.150]) by mx.google.com with ESMTPSA id u7sm27305272eep.11.2014.01.17.06.30.08 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 17 Jan 2014 06:30:09 -0800 (PST) From: Andreas Fenkart To: bzhao@marvell.com Cc: akarwar@marvell.com, linux-wireless@vger.kernel.org, Andreas Fenkart Subject: [PATCH] mwifiex: fix wakeup on magic packet Date: Fri, 17 Jan 2014 15:26:20 +0100 Message-Id: <1389968780-27268-1-git-send-email-afenkart@gmail.com> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: References: Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP 8 bytes preamble 14 bytes src/dst/eth_type 6 bytes 0xff:0xff.. http://en.wikipedia.org/wiki/Wake-on-LAN#Magic_packet http://en.wikipedia.org/wiki/EtherType This will fail if we VLAN or the magic packet is encapsulated as a UDP packet... Signed-off-by: Andreas Fenkart Acked-by: Bing Zhao --- drivers/net/wireless/mwifiex/cfg80211.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/mwifiex/cfg80211.c b/drivers/net/wireless/mwifiex/cfg80211.c index aeaea0e..7e91587 100644 --- a/drivers/net/wireless/mwifiex/cfg80211.c +++ b/drivers/net/wireless/mwifiex/cfg80211.c @@ -2438,7 +2438,7 @@ static int mwifiex_cfg80211_suspend(struct wiphy *wiphy, ETH_ALEN); mef_entry->filter[filt_num].byte_seq[MWIFIEX_MEF_MAX_BYTESEQ] = ETH_ALEN; - mef_entry->filter[filt_num].offset = 14; + mef_entry->filter[filt_num].offset = 28; mef_entry->filter[filt_num].filt_type = TYPE_EQ; if (filt_num) mef_entry->filter[filt_num].filt_action = TYPE_OR;