From patchwork Thu Dec 21 09:00:51 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Govind Singh X-Patchwork-Id: 10127199 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id A4149603B5 for ; Thu, 21 Dec 2017 09:03:11 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 96EBB29B3E for ; Thu, 21 Dec 2017 09:03:11 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8BC2229B41; Thu, 21 Dec 2017 09:03:11 +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=-4.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_MED autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 3566C29B3E for ; Thu, 21 Dec 2017 09:03:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=i8aqJsfmTRkuYuxoGppu6pNo4JHm4NVASSamC2b9LGY=; b=ld++TwwPij5MGgNEYimFQH8Gxn ZDNx4RvBVDSinK9BvGBrEbCcf+WQBa/5LPxlTFIITPBVy8nU3HnqBHZp94w+c4sC/hsTph8H+G53B EnJDbbwGqnI6aKqkUunGqQyOmSiCiosKTdwoYZb3WFrjCDZqxxbx9hAVcCH6E7SzPoV99fi6K+swA T1isiiMD6aChTQLKxd5xy+EaukNkPvQdeZBXP17n62NZ2dLdQQGR2aeMO7xpi2uV19VnpvArtog2B 5hGA67zJLhEb5tYWx493aIneggQZiZrUTs+Lev/R9O0MBIrDddNaoKLuBBPtRNwyu/U3LeEhy78YC Egd6tBCQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.89 #1 (Red Hat Linux)) id 1eRwkn-0008Tz-LV; Thu, 21 Dec 2017 09:03:01 +0000 Received: from alexa-out.qualcomm.com ([129.46.98.28]) by bombadil.infradead.org with esmtps (Exim 4.89 #1 (Red Hat Linux)) id 1eRwjn-0007Vk-LX for ath10k@lists.infradead.org; Thu, 21 Dec 2017 09:02:25 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=qti.qualcomm.com; i=@qti.qualcomm.com; q=dns/txt; s=qcdkim; t=1513846919; x=1545382919; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=t6tLwbDaXRgHVTBXq8x54d1zE/Jjt8jlqvSxs0yMVlk=; b=chwRlqouMEd/afX9B/m0JxGe+EaPxanRDubgDwzyAWGYUPLnesJejKCh mY9temzVxu40LSSPvUE3QRzFhb16zQY1j6ild3gA6rA846dOXJGtYquzq /Dzhukm3dUxZ/aiDvYKdiJeN7f4nlIIg6OWoghean4za+iowPfDIzK8fw 4=; Received: from ironmsg01-sd.qualcomm.com ([10.53.140.141]) by alexa-out.qualcomm.com with ESMTP/TLS/AES256-SHA; 21 Dec 2017 01:01:49 -0800 X-MGA-submission: =?us-ascii?q?MDFZytJsrv72yGvfV3MPrA4zw6Paj5yzXp6h0S?= =?us-ascii?q?XACCTPlfa2Leo1T4+GbxWAXjw0ZPW3QO7mrsLS+dvzzE2+5L7tPAL2vn?= =?us-ascii?q?MxG5zbKaXN6+CyjR7VMRbC0qvgB7kL3k/HR7LHjTAHL1UrgjrF99+coD?= =?us-ascii?q?Ai?= Received: from govinds-linux.qualcomm.com ([10.204.116.70]) by ironmsg01-sd.qualcomm.com with ESMTP; 21 Dec 2017 01:01:46 -0800 Received: by govinds-linux.qualcomm.com (Postfix, from userid 399420) id 54F2B3647; Thu, 21 Dec 2017 14:31:45 +0530 (IST) From: Govind Singh To: ath10k@lists.infradead.org Subject: [PATCH 02/10] ath10k: Update rx descriptor for WCN3990 target Date: Thu, 21 Dec 2017 14:30:51 +0530 Message-Id: <1513846859-23639-3-git-send-email-govinds@qti.qualcomm.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1513846859-23639-1-git-send-email-govinds@qti.qualcomm.com> References: <1513846859-23639-1-git-send-email-govinds@qti.qualcomm.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20171221_010200_548428_65344E3E X-CRM114-Status: UNSURE ( 7.46 ) X-CRM114-Notice: Please train this message. X-BeenThere: ath10k@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Govind Singh , linux-wireless@vger.kernel.org MIME-Version: 1.0 Sender: "ath10k" Errors-To: ath10k-bounces+patchwork-ath10k=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP WCN3990 rx descriptor uses different offset of msdu start, msdu end, ppdu end, rx pkt end and rx frag info. To accommodate different offsets, define respective fields in rx descriptor of WCN3990 target. Signed-off-by: Govind Singh --- drivers/net/wireless/ath/ath10k/rx_desc.h | 50 +++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/drivers/net/wireless/ath/ath10k/rx_desc.h b/drivers/net/wireless/ath/ath10k/rx_desc.h index 28da143..210e4b16 100644 --- a/drivers/net/wireless/ath/ath10k/rx_desc.h +++ b/drivers/net/wireless/ath/ath10k/rx_desc.h @@ -210,6 +210,10 @@ struct rx_frag_info { u8 ring1_more_count; u8 ring2_more_count; u8 ring3_more_count; + u8 ring4_more_count; + u8 ring5_more_count; + u8 ring6_more_count; + u8 ring7_more_count; } __packed; /* @@ -471,10 +475,16 @@ struct rx_msdu_start_qca99x0 { __le32 info2; /* %RX_MSDU_START_INFO2_ */ } __packed; +struct rx_msdu_start_wcn3990 { + __le32 info2; /* %RX_MSDU_START_INFO2_ */ + __le32 info3; /* %RX_MSDU_START_INFO3_ */ +} __packed; + struct rx_msdu_start { struct rx_msdu_start_common common; union { struct rx_msdu_start_qca99x0 qca99x0; + struct rx_msdu_start_wcn3990 wcn3990; } __packed; } __packed; @@ -595,10 +605,23 @@ struct rx_msdu_end_qca99x0 { __le32 info2; } __packed; +struct rx_msdu_end_wcn3990 { + __le32 ipv6_crc; + __le32 tcp_seq_no; + __le32 tcp_ack_no; + __le32 info1; + __le32 info2; + __le32 rule_indication_0; + __le32 rule_indication_1; + __le32 rule_indication_2; + __le32 rule_indication_3; +} __packed; + struct rx_msdu_end { struct rx_msdu_end_common common; union { struct rx_msdu_end_qca99x0 qca99x0; + struct rx_msdu_end_wcn3990 wcn3990; } __packed; } __packed; @@ -963,6 +986,12 @@ struct rx_pkt_end { __le32 phy_timestamp_2; } __packed; +struct rx_pkt_end_wcn3990 { + __le32 info0; /* %RX_PKT_END_INFO0_ */ + __le64 phy_timestamp_1; + __le64 phy_timestamp_2; +} __packed; + #define RX_LOCATION_INFO0_RTT_FAC_LEGACY_MASK 0x00003fff #define RX_LOCATION_INFO0_RTT_FAC_LEGACY_LSB 0 #define RX_LOCATION_INFO0_RTT_FAC_VHT_MASK 0x1fff8000 @@ -998,6 +1027,12 @@ struct rx_location_info { __le32 rx_location_info1; /* %RX_LOCATION_INFO1_ */ } __packed; +struct rx_location_info_wcn3990 { + __le32 rx_location_info0; /* %RX_LOCATION_INFO0_ */ + __le32 rx_location_info1; /* %RX_LOCATION_INFO1_ */ + __le32 rx_location_info2; /* %RX_LOCATION_INFO2_ */ +} __packed; + enum rx_phy_ppdu_end_info0 { RX_PHY_PPDU_END_INFO0_ERR_RADAR = BIT(2), RX_PHY_PPDU_END_INFO0_ERR_RX_ABORT = BIT(3), @@ -1086,6 +1121,20 @@ struct rx_ppdu_end_qca9984 { __le16 info1; /* %RX_PPDU_END_INFO1_ */ } __packed; +struct rx_ppdu_end_wcn3990 { + struct rx_pkt_end_wcn3990 rx_pkt_end; + struct rx_location_info_wcn3990 rx_location_info; + struct rx_phy_ppdu_end rx_phy_ppdu_end; + __le32 rx_timing_offset; + __le32 reserved_info_0; + __le32 reserved_info_1; + __le32 rx_antenna_info; + __le32 rx_coex_info; + __le32 rx_mpdu_cnt_info; + __le64 phy_timestamp_tx; + __le32 rx_bb_length; +} __packed; + struct rx_ppdu_end { struct rx_ppdu_end_common common; union { @@ -1093,6 +1142,7 @@ struct rx_ppdu_end { struct rx_ppdu_end_qca6174 qca6174; struct rx_ppdu_end_qca99x0 qca99x0; struct rx_ppdu_end_qca9984 qca9984; + struct rx_ppdu_end_wcn3990 wcn3990; } __packed; } __packed;