From patchwork Sun Jul 12 14:25:32 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bob Copeland X-Patchwork-Id: 6772341 Return-Path: X-Original-To: patchwork-ath10k@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id C5D6FC05AC for ; Sun, 12 Jul 2015 14:26:22 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D83782065E for ; Sun, 12 Jul 2015 14:26:21 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 9EC9C20453 for ; Sun, 12 Jul 2015 14:26:20 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZEICj-0006AB-4S; Sun, 12 Jul 2015 14:26:05 +0000 Received: from mail-ie0-f174.google.com ([209.85.223.174]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZEICh-00069V-E4 for ath10k@lists.infradead.org; Sun, 12 Jul 2015 14:26:04 +0000 Received: by iebmu5 with SMTP id mu5so220394280ieb.1 for ; Sun, 12 Jul 2015 07:25:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-type:content-disposition:in-reply-to :user-agent; bh=8zkAbz8LCi8+oHK7GjBnU/S4VEnDwBfnUxjyGwF5/v0=; b=WEaMk8oqpBBC8l+y56njfwY/5Cgvqt84sSmpe0D8BMLS1kjL8C/pjseskz5IboAYYA yhOTphcgbdq4UpuMSuJieHZbsz4cmMi8+Rvk0xRe+DALkwwcnTgNRKLapuy9zLdt0an2 CCa26fzyyR0MbuZrIvyYXFASmV8+ZkxgcRdMxKiRq1DrVsyw3HisViIFHkcM6ZzIJKwF kdPkHSD2nJNHwuFCoHqDjbd26YKsEyY4ih6Q8amoK6xvfd/QZOj10rBDbqk5fQ3er3rF QxiUutC2J6Ha9LsZLQ4464jaEnNcnEoYjbkPdD42xDklUD9piqWyqp6+FzOqzAKwuZoh FeDg== X-Gm-Message-State: ALoCoQlFxwHbtcKZXNKx309b+fyOHivn3H1zYEx9pigOLbKowKDnYx6aZyfvNZPyAVX3TYFbdL8z X-Received: by 10.50.132.70 with SMTP id os6mr7746454igb.27.1436711140636; Sun, 12 Jul 2015 07:25:40 -0700 (PDT) Received: from hash ([2001:470:1d:6db:230:48ff:fe9d:9c89]) by smtp.gmail.com with ESMTPSA id d4sm3706484igl.1.2015.07.12.07.25.38 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 12 Jul 2015 07:25:39 -0700 (PDT) Received: from bob by hash with local (Exim 4.84) (envelope-from ) id 1ZEICC-0006Ti-WF; Sun, 12 Jul 2015 10:25:32 -0400 Date: Sun, 12 Jul 2015 10:25:32 -0400 From: Bob Copeland To: Freddy Lee Subject: Re: attempting mesh on ath10k Message-ID: <20150712142532.GA24495@localhost> References: <20150706214921.GF23012@localhost> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20150706214921.GF23012@localhost> User-Agent: Mutt/1.5.23 (2014-03-12) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150712_072603_516983_BBC92690 X-CRM114-Status: GOOD ( 17.45 ) X-Spam-Score: -2.6 (--) X-BeenThere: ath10k@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: ath10k@lists.infradead.org Sender: "ath10k" Errors-To: ath10k-bounces+patchwork-ath10k=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-5.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable 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 On Mon, Jul 06, 2015 at 05:49:21PM -0400, Bob Copeland wrote: > Here's the latest patch-in-progress but I haven't tested it; it also > requires the AID series I sent to l-w last week (and still requires the > filters be disabled). Once I get an hour to run it through the paces > and also fix the filter issue then I plan to send upstream. Ok, so I've tested it now and I'm having some problems with raw mode on latest driver. On top of previously posted patch, I have the following (not sure if the various checksum changes are really needed, but tried to have it match last working patch). It looks like unicast self-protected action frames (peering) works fine, but broadcast multihop action frames (PREQs) never go over the air. Does this sound familiar to anyone? diff --git a/drivers/net/wireless/ath/ath10k/htt_tx.c b/drivers/net/wireless/ath/ath10k/htt_tx.c index a60ef7d..6da3952 100644 --- a/drivers/net/wireless/ath/ath10k/htt_tx.c +++ b/drivers/net/wireless/ath/ath10k/htt_tx.c @@ -513,7 +513,8 @@ int ath10k_htt_tx(struct ath10k_htt *htt, struct sk_buff *msdu) flags1 |= SM((u16)vdev_id, HTT_DATA_TX_DESC_FLAGS1_VDEV_ID); flags1 |= SM((u16)tid, HTT_DATA_TX_DESC_FLAGS1_EXT_TID); - if (msdu->ip_summed == CHECKSUM_PARTIAL) { + if (msdu->ip_summed == CHECKSUM_PARTIAL && + skb_cb->txmode != ATH10K_HW_TXRX_RAW) { flags1 |= HTT_DATA_TX_DESC_FLAGS1_CKSUM_L3_OFFLOAD; flags1 |= HTT_DATA_TX_DESC_FLAGS1_CKSUM_L4_OFFLOAD; } diff --git a/drivers/net/wireless/ath/ath10k/mac.c b/drivers/net/wireless/ath/ath10k/mac.c index aa81880..e136e9c 100644 --- a/drivers/net/wireless/ath/ath10k/mac.c +++ b/drivers/net/wireless/ath/ath10k/mac.c @@ -3636,12 +3636,9 @@ static void ath10k_tx(struct ieee80211_hw *hw, ath10k_tx_h_8023(skb); break; case ATH10K_HW_TXRX_RAW: - /* FIXME: Packet injection isn't implemented. It should be - * doable with firmware 10.2 on qca988x. - */ - WARN_ON_ONCE(1); - ieee80211_free_txskb(hw, skb); - return; + ath10k_tx_h_add_p2p_noa_ie(ar, vif, skb); + ath10k_tx_h_seq_no(vif, skb); + break; } if (info->flags & IEEE80211_TX_CTL_TX_OFFCHAN) { @@ -4053,6 +4050,7 @@ static int ath10k_add_interface(struct ieee80211_hw *hw, struct ath10k *ar = hw->priv; struct ath10k_vif *arvif = ath10k_vif_to_arvif(vif); enum wmi_sta_powersave_param param; + enum ath10k_hw_txrx_mode tx_mode = ATH10K_HW_TXRX_NATIVE_WIFI; int ret = 0; u32 value; int bit; @@ -4109,6 +4107,7 @@ static int ath10k_add_interface(struct ieee80211_hw *hw, arvif->vdev_type = WMI_VDEV_TYPE_IBSS; break; case NL80211_IFTYPE_MESH_POINT: + tx_mode = ATH10K_HW_TXRX_RAW; arvif->vdev_type = WMI_VDEV_TYPE_AP; break; case NL80211_IFTYPE_AP: @@ -4193,7 +4192,7 @@ static int ath10k_add_interface(struct ieee80211_hw *hw, vdev_param = ar->wmi.vdev_param->tx_encap_type; ret = ath10k_wmi_vdev_set_param(ar, arvif->vdev_id, vdev_param, - ATH10K_HW_TXRX_NATIVE_WIFI); + tx_mode); /* 10.X firmware does not support this VDEV parameter. Do not warn */ if (ret && ret != -EOPNOTSUPP) { ath10k_warn(ar, "failed to set vdev %i TX encapsulation: %d\n", @@ -6969,7 +6968,7 @@ int ath10k_mac_register(struct ath10k *ar) goto err_free; } - ar->hw->netdev_features = NETIF_F_HW_CSUM; + /* ar->hw->netdev_features = NETIF_F_HW_CSUM; */ if (config_enabled(CPTCFG_ATH10K_DFS_CERTIFIED)) { /* Init ath dfs pattern detector */