From patchwork Mon May 20 08:55:07 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Crispin X-Patchwork-Id: 10950555 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 38AE86C5 for ; Mon, 20 May 2019 08:55:26 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2BC8228785 for ; Mon, 20 May 2019 08:55:26 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1FFF42878E; Mon, 20 May 2019 08:55:26 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C125928785 for ; Mon, 20 May 2019 08:55:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731680AbfETIzZ (ORCPT ); Mon, 20 May 2019 04:55:25 -0400 Received: from nbd.name ([46.4.11.11]:41470 "EHLO nbd.name" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731671AbfETIzX (ORCPT ); Mon, 20 May 2019 04:55:23 -0400 Received: from p548c87ba.dip0.t-ipconnect.de ([84.140.135.186] helo=bertha.datto.lan) by ds12 with esmtpa (Exim 4.89) (envelope-from ) id 1hSe4l-0002Y7-GY; Mon, 20 May 2019 10:55:19 +0200 From: John Crispin To: Kalle Valo Cc: ath11k@lists.infradead.org, linux-wireless@vger.kernel.org, John Crispin , Shashidhar Lakkavalli Subject: [PATCH V5 7/8] ath11k: handle rx status for HE frames Date: Mon, 20 May 2019 10:55:07 +0200 Message-Id: <20190520085508.5888-8-john@phrozen.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190520085508.5888-1-john@phrozen.org> References: <20190520085508.5888-1-john@phrozen.org> MIME-Version: 1.0 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The case clause handling HE frames was not handled yet in the code reading the RX status. The new case is identical to VHT with the difference of the higher maximum MCS rate. Signed-off-by: Shashidhar Lakkavalli Signed-off-by: John Crispin --- drivers/net/wireless/ath/ath11k/dp_rx.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/ath/ath11k/dp_rx.c b/drivers/net/wireless/ath/ath11k/dp_rx.c index e52a54cd2b79..71d385cf55d7 100644 --- a/drivers/net/wireless/ath/ath11k/dp_rx.c +++ b/drivers/net/wireless/ath/ath11k/dp_rx.c @@ -1727,7 +1727,16 @@ static void ath11k_dp_rx_h_rate(struct ath11k *ar, void *rx_desc, rx_status->bw = ath11k_bw_to_mac80211_bw(bw); break; case RX_MSDU_START_PKT_TYPE_11AX: - ath11k_warn(ar->ab, "pkt_type %d not yet supported\n", pkt_type); + rx_status->rate_idx = rate_mcs; + if (rate_mcs > ATH11K_HE_MCS_MAX) { + ath11k_warn(ar->ab, + "Received with invalid mcs in HE mode %d\n", + rate_mcs); + break; + } + rx_status->encoding = RX_ENC_HE; + rx_status->nss = nss; + rx_status->bw = ath11k_bw_to_mac80211_bw(bw); break; } }