Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge tag 'wireless-drivers-next-2021-04-13' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next

Kalle Valo says:

====================
wireless-drivers-next patches for v5.13

First set of patches for v5.13. I have been offline for a couple of
and I have a smaller pull request this time. The next one will be
bigger. Nothing really special standing out.

ath11k

* add initial support for QCN9074, but not enabled yet due to firmware problems

* enable radar detection for 160MHz secondary segment

* handle beacon misses in station mode

rtw88

* 8822c: support firmware crash dump

mt7601u

* enable TDLS support
====================

Signed-off-by: David S. Miller <davem@davemloft.net>

+2708 -870
+20 -9
drivers/net/wireless/ath/ath10k/snoc.c
··· 1759 1759 return ret; 1760 1760 } 1761 1761 1762 - static int ath10k_snoc_remove(struct platform_device *pdev) 1762 + static int ath10k_snoc_free_resources(struct ath10k *ar) 1763 1763 { 1764 - struct ath10k *ar = platform_get_drvdata(pdev); 1765 1764 struct ath10k_snoc *ar_snoc = ath10k_snoc_priv(ar); 1766 1765 1767 - ath10k_dbg(ar, ATH10K_DBG_SNOC, "snoc remove\n"); 1768 - 1769 - reinit_completion(&ar->driver_recovery); 1770 - 1771 - if (test_bit(ATH10K_SNOC_FLAG_RECOVERY, &ar_snoc->flags)) 1772 - wait_for_completion_timeout(&ar->driver_recovery, 3 * HZ); 1766 + ath10k_dbg(ar, ATH10K_DBG_SNOC, "snoc free resources\n"); 1773 1767 1774 1768 set_bit(ATH10K_SNOC_FLAG_UNREGISTERING, &ar_snoc->flags); 1775 1769 ··· 1777 1783 return 0; 1778 1784 } 1779 1785 1786 + static int ath10k_snoc_remove(struct platform_device *pdev) 1787 + { 1788 + struct ath10k *ar = platform_get_drvdata(pdev); 1789 + struct ath10k_snoc *ar_snoc = ath10k_snoc_priv(ar); 1790 + 1791 + ath10k_dbg(ar, ATH10K_DBG_SNOC, "snoc remove\n"); 1792 + 1793 + reinit_completion(&ar->driver_recovery); 1794 + 1795 + if (test_bit(ATH10K_SNOC_FLAG_RECOVERY, &ar_snoc->flags)) 1796 + wait_for_completion_timeout(&ar->driver_recovery, 3 * HZ); 1797 + 1798 + ath10k_snoc_free_resources(ar); 1799 + 1800 + return 0; 1801 + } 1802 + 1780 1803 static void ath10k_snoc_shutdown(struct platform_device *pdev) 1781 1804 { 1782 1805 struct ath10k *ar = platform_get_drvdata(pdev); 1783 1806 1784 1807 ath10k_dbg(ar, ATH10K_DBG_SNOC, "snoc shutdown\n"); 1785 - ath10k_snoc_remove(pdev); 1808 + ath10k_snoc_free_resources(ar); 1786 1809 } 1787 1810 1788 1811 static struct platform_driver ath10k_snoc_driver = {
+1 -1
drivers/net/wireless/ath/ath11k/ahb.c
··· 373 373 cfg->tgt_ce = ab->hw_params.target_ce_config; 374 374 cfg->svc_to_ce_map_len = ab->hw_params.svc_to_ce_map_len; 375 375 cfg->svc_to_ce_map = ab->hw_params.svc_to_ce_map; 376 - ab->qmi.service_ins_id = ATH11K_QMI_WLFW_SERVICE_INS_ID_V01_IPQ8074; 376 + ab->qmi.service_ins_id = ab->hw_params.qmi_service_ins_id; 377 377 } 378 378 379 379 static void ath11k_ahb_free_ext_irq(struct ath11k_base *ab)
+56 -2
drivers/net/wireless/ath/ath11k/ce.c
··· 187 187 188 188 }; 189 189 190 + const struct ce_attr ath11k_host_ce_config_qcn9074[] = { 191 + /* CE0: host->target HTC control and raw streams */ 192 + { 193 + .flags = CE_ATTR_FLAGS, 194 + .src_nentries = 16, 195 + .src_sz_max = 2048, 196 + .dest_nentries = 0, 197 + }, 198 + 199 + /* CE1: target->host HTT + HTC control */ 200 + { 201 + .flags = CE_ATTR_FLAGS, 202 + .src_nentries = 0, 203 + .src_sz_max = 2048, 204 + .dest_nentries = 512, 205 + .recv_cb = ath11k_htc_rx_completion_handler, 206 + }, 207 + 208 + /* CE2: target->host WMI */ 209 + { 210 + .flags = CE_ATTR_FLAGS, 211 + .src_nentries = 0, 212 + .src_sz_max = 2048, 213 + .dest_nentries = 32, 214 + .recv_cb = ath11k_htc_rx_completion_handler, 215 + }, 216 + 217 + /* CE3: host->target WMI (mac0) */ 218 + { 219 + .flags = CE_ATTR_FLAGS, 220 + .src_nentries = 32, 221 + .src_sz_max = 2048, 222 + .dest_nentries = 0, 223 + }, 224 + 225 + /* CE4: host->target HTT */ 226 + { 227 + .flags = CE_ATTR_FLAGS | CE_ATTR_DIS_INTR, 228 + .src_nentries = 2048, 229 + .src_sz_max = 256, 230 + .dest_nentries = 0, 231 + }, 232 + 233 + /* CE5: target->host pktlog */ 234 + { 235 + .flags = CE_ATTR_FLAGS, 236 + .src_nentries = 0, 237 + .src_sz_max = 2048, 238 + .dest_nentries = 512, 239 + .recv_cb = ath11k_dp_htt_htc_t2h_msg_handler, 240 + }, 241 + }; 242 + 190 243 static bool ath11k_ce_need_shadow_fix(int ce_id) 191 244 { 192 245 /* only ce4 needs shadow workaroud*/ ··· 508 455 struct hal_srng_params *ring_params) 509 456 { 510 457 u32 msi_data_start; 511 - u32 msi_data_count; 458 + u32 msi_data_count, msi_data_idx; 512 459 u32 msi_irq_start; 513 460 u32 addr_lo; 514 461 u32 addr_hi; ··· 522 469 return; 523 470 524 471 ath11k_get_msi_address(ab, &addr_lo, &addr_hi); 472 + ath11k_get_ce_msi_idx(ab, ce_id, &msi_data_idx); 525 473 526 474 ring_params->msi_addr = addr_lo; 527 475 ring_params->msi_addr |= (dma_addr_t)(((uint64_t)addr_hi) << 32); 528 - ring_params->msi_data = (ce_id % msi_data_count) + msi_data_start; 476 + ring_params->msi_data = (msi_data_idx % msi_data_count) + msi_data_start; 529 477 ring_params->flags |= HAL_SRNG_FLAGS_MSI_INTR; 530 478 } 531 479
+1
drivers/net/wireless/ath/ath11k/ce.h
··· 173 173 174 174 extern const struct ce_attr ath11k_host_ce_config_ipq8074[]; 175 175 extern const struct ce_attr ath11k_host_ce_config_qca6390[]; 176 + extern const struct ce_attr ath11k_host_ce_config_qcn9074[]; 176 177 177 178 void ath11k_ce_cleanup_pipes(struct ath11k_base *ab); 178 179 void ath11k_ce_rx_replenish_retry(struct timer_list *t);
+44 -1
drivers/net/wireless/ath/ath11k/core.c
··· 45 45 .ring_mask = &ath11k_hw_ring_mask_ipq8074, 46 46 .internal_sleep_clock = false, 47 47 .regs = &ipq8074_regs, 48 + .qmi_service_ins_id = ATH11K_QMI_WLFW_SERVICE_INS_ID_V01_IPQ8074, 48 49 .host_ce_config = ath11k_host_ce_config_ipq8074, 49 50 .ce_count = 12, 50 51 .target_ce_config = ath11k_target_ce_config_wlan_ipq8074, ··· 69 68 .idle_ps = false, 70 69 .cold_boot_calib = true, 71 70 .supports_suspend = false, 71 + .hal_desc_sz = sizeof(struct hal_rx_desc_ipq8074), 72 72 }, 73 73 { 74 74 .hw_rev = ATH11K_HW_IPQ6018_HW10, ··· 85 83 .ring_mask = &ath11k_hw_ring_mask_ipq8074, 86 84 .internal_sleep_clock = false, 87 85 .regs = &ipq8074_regs, 86 + .qmi_service_ins_id = ATH11K_QMI_WLFW_SERVICE_INS_ID_V01_IPQ8074, 88 87 .host_ce_config = ath11k_host_ce_config_ipq8074, 89 88 .ce_count = 12, 90 89 .target_ce_config = ath11k_target_ce_config_wlan_ipq8074, ··· 109 106 .idle_ps = false, 110 107 .cold_boot_calib = true, 111 108 .supports_suspend = false, 109 + .hal_desc_sz = sizeof(struct hal_rx_desc_ipq8074), 112 110 }, 113 111 { 114 112 .name = "qca6390 hw2.0", ··· 125 121 .ring_mask = &ath11k_hw_ring_mask_qca6390, 126 122 .internal_sleep_clock = true, 127 123 .regs = &qca6390_regs, 124 + .qmi_service_ins_id = ATH11K_QMI_WLFW_SERVICE_INS_ID_V01_QCA6390, 128 125 .host_ce_config = ath11k_host_ce_config_qca6390, 129 126 .ce_count = 9, 130 127 .target_ce_config = ath11k_target_ce_config_wlan_qca6390, ··· 148 143 .idle_ps = true, 149 144 .cold_boot_calib = false, 150 145 .supports_suspend = true, 146 + .hal_desc_sz = sizeof(struct hal_rx_desc_ipq8074), 147 + }, 148 + { 149 + .name = "qcn9074 hw1.0", 150 + .hw_rev = ATH11K_HW_QCN9074_HW10, 151 + .fw = { 152 + .dir = "QCN9074/hw1.0", 153 + .board_size = 256 * 1024, 154 + .cal_size = 256 * 1024, 155 + }, 156 + .max_radios = 1, 157 + .single_pdev_only = false, 158 + .qmi_service_ins_id = ATH11K_QMI_WLFW_SERVICE_INS_ID_V01_QCN9074, 159 + .hw_ops = &qcn9074_ops, 160 + .ring_mask = &ath11k_hw_ring_mask_qcn9074, 161 + .internal_sleep_clock = false, 162 + .regs = &qcn9074_regs, 163 + .host_ce_config = ath11k_host_ce_config_qcn9074, 164 + .ce_count = 6, 165 + .target_ce_config = ath11k_target_ce_config_wlan_qcn9074, 166 + .target_ce_count = 9, 167 + .svc_to_ce_map = ath11k_target_service_to_ce_map_wlan_qcn9074, 168 + .svc_to_ce_map_len = 18, 169 + .rxdma1_enable = true, 170 + .num_rxmda_per_pdev = 1, 171 + .rx_mac_buf_ring = false, 172 + .vdev_start_delay = false, 173 + .htt_peer_map_v2 = true, 174 + .tcl_0_only = false, 175 + .interface_modes = BIT(NL80211_IFTYPE_STATION) | 176 + BIT(NL80211_IFTYPE_AP) | 177 + BIT(NL80211_IFTYPE_MESH_POINT), 178 + .supports_monitor = true, 179 + .supports_shadow_regs = false, 180 + .idle_ps = false, 181 + .cold_boot_calib = false, 182 + .supports_suspend = false, 183 + .hal_desc_sz = sizeof(struct hal_rx_desc_qcn9074), 151 184 }, 152 185 }; 153 186 ··· 1017 974 1018 975 ab->hw_params = *hw_params; 1019 976 1020 - ath11k_dbg(ab, ATH11K_DBG_BOOT, "Hardware name %s\n", ab->hw_params.name); 977 + ath11k_info(ab, "%s\n", ab->hw_params.name); 1021 978 1022 979 return 0; 1023 980 }
+6
drivers/net/wireless/ath/ath11k/core.h
··· 34 34 #define ATH11K_PRB_RSP_DROP_THRESHOLD ((ATH11K_TX_MGMT_TARGET_MAX_SUPPORT_WMI * 3) / 4) 35 35 36 36 #define ATH11K_INVALID_HW_MAC_ID 0xFF 37 + #define ATH11K_CONNECTION_LOSS_HZ (3 * HZ) 37 38 38 39 extern unsigned int ath11k_frame_mode; 39 40 ··· 106 105 ATH11K_HW_IPQ8074, 107 106 ATH11K_HW_QCA6390_HW20, 108 107 ATH11K_HW_IPQ6018_HW10, 108 + ATH11K_HW_QCN9074_HW10, 109 109 }; 110 110 111 111 enum ath11k_firmware_mode { ··· 236 234 u32 aid; 237 235 u8 bssid[ETH_ALEN]; 238 236 struct cfg80211_bitrate_mask bitrate_mask; 237 + struct delayed_work connection_loss_work; 239 238 int num_legacy_stations; 240 239 int rtscts_prot_mode; 241 240 int txpower; ··· 610 607 bool m3_fw_support; 611 608 bool fixed_bdf_addr; 612 609 bool fixed_mem_region; 610 + bool static_window_map; 613 611 }; 614 612 615 613 /* IPQ8074 HW channel counters frequency value in hertz */ ··· 880 876 extern const struct ce_pipe_config ath11k_target_ce_config_wlan_qca6390[]; 881 877 extern const struct service_to_pipe ath11k_target_service_to_ce_map_wlan_qca6390[]; 882 878 879 + extern const struct ce_pipe_config ath11k_target_ce_config_wlan_qcn9074[]; 880 + extern const struct service_to_pipe ath11k_target_service_to_ce_map_wlan_qcn9074[]; 883 881 int ath11k_core_qmi_firmware_ready(struct ath11k_base *ab); 884 882 int ath11k_core_pre_init(struct ath11k_base *ab); 885 883 int ath11k_core_init(struct ath11k_base *ath11k);
+1 -1
drivers/net/wireless/ath/ath11k/debugfs_htt_stats.c
··· 3851 3851 htt_stats_buf->num_non_srg_ppdu_tried); 3852 3852 len += HTT_DBG_OUT(buf + len, buf_len - len, "Non-SRG success PPDU = %u\n", 3853 3853 htt_stats_buf->num_non_srg_ppdu_success); 3854 - len += HTT_DBG_OUT(buf + len, buf_len - len, "SRG Opportunies = %u\n", 3854 + len += HTT_DBG_OUT(buf + len, buf_len - len, "SRG Opportunities = %u\n", 3855 3855 htt_stats_buf->num_srg_opportunities); 3856 3856 len += HTT_DBG_OUT(buf + len, buf_len - len, "SRG tried PPDU = %u\n", 3857 3857 htt_stats_buf->num_srg_ppdu_tried);
+248 -226
drivers/net/wireless/ath/ath11k/dp_rx.c
··· 20 20 21 21 #define ATH11K_DP_RX_FRAGMENT_TIMEOUT_MS (2 * HZ) 22 22 23 - static u8 *ath11k_dp_rx_h_80211_hdr(struct hal_rx_desc *desc) 23 + static u8 *ath11k_dp_rx_h_80211_hdr(struct ath11k_base *ab, struct hal_rx_desc *desc) 24 24 { 25 - return desc->hdr_status; 25 + return ab->hw_params.hw_ops->rx_desc_get_hdr_status(desc); 26 26 } 27 27 28 - static enum hal_encrypt_type ath11k_dp_rx_h_mpdu_start_enctype(struct hal_rx_desc *desc) 28 + static enum hal_encrypt_type ath11k_dp_rx_h_mpdu_start_enctype(struct ath11k_base *ab, 29 + struct hal_rx_desc *desc) 29 30 { 30 - if (!(__le32_to_cpu(desc->mpdu_start.info1) & 31 - RX_MPDU_START_INFO1_ENCRYPT_INFO_VALID)) 31 + if (!ab->hw_params.hw_ops->rx_desc_encrypt_valid(desc)) 32 32 return HAL_ENCRYPT_TYPE_OPEN; 33 33 34 - return FIELD_GET(RX_MPDU_START_INFO2_ENC_TYPE, 35 - __le32_to_cpu(desc->mpdu_start.info2)); 34 + return ab->hw_params.hw_ops->rx_desc_get_encrypt_type(desc); 36 35 } 37 36 38 - static u8 ath11k_dp_rx_h_msdu_start_decap_type(struct hal_rx_desc *desc) 37 + static u8 ath11k_dp_rx_h_msdu_start_decap_type(struct ath11k_base *ab, 38 + struct hal_rx_desc *desc) 39 39 { 40 - return FIELD_GET(RX_MSDU_START_INFO2_DECAP_FORMAT, 41 - __le32_to_cpu(desc->msdu_start.info2)); 40 + return ab->hw_params.hw_ops->rx_desc_get_decap_type(desc); 42 41 } 43 42 44 - static u8 ath11k_dp_rx_h_msdu_start_mesh_ctl_present(struct hal_rx_desc *desc) 43 + static u8 ath11k_dp_rx_h_msdu_start_mesh_ctl_present(struct ath11k_base *ab, 44 + struct hal_rx_desc *desc) 45 45 { 46 - return FIELD_GET(RX_MSDU_START_INFO2_MESH_CTRL_PRESENT, 47 - __le32_to_cpu(desc->msdu_start.info2)); 46 + return ab->hw_params.hw_ops->rx_desc_get_mesh_ctl(desc); 48 47 } 49 48 50 - static bool ath11k_dp_rx_h_mpdu_start_seq_ctrl_valid(struct hal_rx_desc *desc) 49 + static bool ath11k_dp_rx_h_mpdu_start_seq_ctrl_valid(struct ath11k_base *ab, 50 + struct hal_rx_desc *desc) 51 51 { 52 - return !!FIELD_GET(RX_MPDU_START_INFO1_MPDU_SEQ_CTRL_VALID, 53 - __le32_to_cpu(desc->mpdu_start.info1)); 52 + return ab->hw_params.hw_ops->rx_desc_get_mpdu_seq_ctl_vld(desc); 54 53 } 55 54 56 - static bool ath11k_dp_rx_h_mpdu_start_fc_valid(struct hal_rx_desc *desc) 55 + static bool ath11k_dp_rx_h_mpdu_start_fc_valid(struct ath11k_base *ab, 56 + struct hal_rx_desc *desc) 57 57 { 58 - return !!FIELD_GET(RX_MPDU_START_INFO1_MPDU_FCTRL_VALID, 59 - __le32_to_cpu(desc->mpdu_start.info1)); 58 + return ab->hw_params.hw_ops->rx_desc_get_mpdu_fc_valid(desc); 60 59 } 61 60 62 - static bool ath11k_dp_rx_h_mpdu_start_more_frags(struct sk_buff *skb) 61 + static bool ath11k_dp_rx_h_mpdu_start_more_frags(struct ath11k_base *ab, 62 + struct sk_buff *skb) 63 63 { 64 64 struct ieee80211_hdr *hdr; 65 65 66 - hdr = (struct ieee80211_hdr *)(skb->data + HAL_RX_DESC_SIZE); 66 + hdr = (struct ieee80211_hdr *)(skb->data + ab->hw_params.hal_desc_sz); 67 67 return ieee80211_has_morefrags(hdr->frame_control); 68 68 } 69 69 70 - static u16 ath11k_dp_rx_h_mpdu_start_frag_no(struct sk_buff *skb) 70 + static u16 ath11k_dp_rx_h_mpdu_start_frag_no(struct ath11k_base *ab, 71 + struct sk_buff *skb) 71 72 { 72 73 struct ieee80211_hdr *hdr; 73 74 74 - hdr = (struct ieee80211_hdr *)(skb->data + HAL_RX_DESC_SIZE); 75 + hdr = (struct ieee80211_hdr *)(skb->data + ab->hw_params.hal_desc_sz); 75 76 return le16_to_cpu(hdr->seq_ctrl) & IEEE80211_SCTL_FRAG; 76 77 } 77 78 78 - static u16 ath11k_dp_rx_h_mpdu_start_seq_no(struct hal_rx_desc *desc) 79 + static u16 ath11k_dp_rx_h_mpdu_start_seq_no(struct ath11k_base *ab, 80 + struct hal_rx_desc *desc) 79 81 { 80 - return FIELD_GET(RX_MPDU_START_INFO1_MPDU_SEQ_NUM, 81 - __le32_to_cpu(desc->mpdu_start.info1)); 82 + return ab->hw_params.hw_ops->rx_desc_get_mpdu_start_seq_no(desc); 82 83 } 83 84 84 - static bool ath11k_dp_rx_h_attn_msdu_done(struct hal_rx_desc *desc) 85 + static void *ath11k_dp_rx_get_attention(struct ath11k_base *ab, 86 + struct hal_rx_desc *desc) 87 + { 88 + return ab->hw_params.hw_ops->rx_desc_get_attention(desc); 89 + } 90 + 91 + static bool ath11k_dp_rx_h_attn_msdu_done(struct rx_attention *attn) 85 92 { 86 93 return !!FIELD_GET(RX_ATTENTION_INFO2_MSDU_DONE, 87 - __le32_to_cpu(desc->attention.info2)); 94 + __le32_to_cpu(attn->info2)); 88 95 } 89 96 90 - static bool ath11k_dp_rx_h_attn_l4_cksum_fail(struct hal_rx_desc *desc) 97 + static bool ath11k_dp_rx_h_attn_l4_cksum_fail(struct rx_attention *attn) 91 98 { 92 99 return !!FIELD_GET(RX_ATTENTION_INFO1_TCP_UDP_CKSUM_FAIL, 93 - __le32_to_cpu(desc->attention.info1)); 100 + __le32_to_cpu(attn->info1)); 94 101 } 95 102 96 - static bool ath11k_dp_rx_h_attn_ip_cksum_fail(struct hal_rx_desc *desc) 103 + static bool ath11k_dp_rx_h_attn_ip_cksum_fail(struct rx_attention *attn) 97 104 { 98 105 return !!FIELD_GET(RX_ATTENTION_INFO1_IP_CKSUM_FAIL, 99 - __le32_to_cpu(desc->attention.info1)); 106 + __le32_to_cpu(attn->info1)); 100 107 } 101 108 102 - static bool ath11k_dp_rx_h_attn_is_decrypted(struct hal_rx_desc *desc) 109 + static bool ath11k_dp_rx_h_attn_is_decrypted(struct rx_attention *attn) 103 110 { 104 111 return (FIELD_GET(RX_ATTENTION_INFO2_DCRYPT_STATUS_CODE, 105 - __le32_to_cpu(desc->attention.info2)) == 112 + __le32_to_cpu(attn->info2)) == 106 113 RX_DESC_DECRYPT_STATUS_CODE_OK); 107 114 } 108 115 109 - static u32 ath11k_dp_rx_h_attn_mpdu_err(struct hal_rx_desc *desc) 116 + static u32 ath11k_dp_rx_h_attn_mpdu_err(struct rx_attention *attn) 110 117 { 111 - u32 info = __le32_to_cpu(desc->attention.info1); 118 + u32 info = __le32_to_cpu(attn->info1); 112 119 u32 errmap = 0; 113 120 114 121 if (info & RX_ATTENTION_INFO1_FCS_ERR) ··· 142 135 return errmap; 143 136 } 144 137 145 - static u16 ath11k_dp_rx_h_msdu_start_msdu_len(struct hal_rx_desc *desc) 138 + static u16 ath11k_dp_rx_h_msdu_start_msdu_len(struct ath11k_base *ab, 139 + struct hal_rx_desc *desc) 146 140 { 147 - return FIELD_GET(RX_MSDU_START_INFO1_MSDU_LENGTH, 148 - __le32_to_cpu(desc->msdu_start.info1)); 141 + return ab->hw_params.hw_ops->rx_desc_get_msdu_len(desc); 149 142 } 150 143 151 - static u8 ath11k_dp_rx_h_msdu_start_sgi(struct hal_rx_desc *desc) 144 + static u8 ath11k_dp_rx_h_msdu_start_sgi(struct ath11k_base *ab, 145 + struct hal_rx_desc *desc) 152 146 { 153 - return FIELD_GET(RX_MSDU_START_INFO3_SGI, 154 - __le32_to_cpu(desc->msdu_start.info3)); 147 + return ab->hw_params.hw_ops->rx_desc_get_msdu_sgi(desc); 155 148 } 156 149 157 - static u8 ath11k_dp_rx_h_msdu_start_rate_mcs(struct hal_rx_desc *desc) 150 + static u8 ath11k_dp_rx_h_msdu_start_rate_mcs(struct ath11k_base *ab, 151 + struct hal_rx_desc *desc) 158 152 { 159 - return FIELD_GET(RX_MSDU_START_INFO3_RATE_MCS, 160 - __le32_to_cpu(desc->msdu_start.info3)); 153 + return ab->hw_params.hw_ops->rx_desc_get_msdu_rate_mcs(desc); 161 154 } 162 155 163 - static u8 ath11k_dp_rx_h_msdu_start_rx_bw(struct hal_rx_desc *desc) 156 + static u8 ath11k_dp_rx_h_msdu_start_rx_bw(struct ath11k_base *ab, 157 + struct hal_rx_desc *desc) 164 158 { 165 - return FIELD_GET(RX_MSDU_START_INFO3_RECV_BW, 166 - __le32_to_cpu(desc->msdu_start.info3)); 159 + return ab->hw_params.hw_ops->rx_desc_get_msdu_rx_bw(desc); 167 160 } 168 161 169 - static u32 ath11k_dp_rx_h_msdu_start_freq(struct hal_rx_desc *desc) 162 + static u32 ath11k_dp_rx_h_msdu_start_freq(struct ath11k_base *ab, 163 + struct hal_rx_desc *desc) 170 164 { 171 - return __le32_to_cpu(desc->msdu_start.phy_meta_data); 165 + return ab->hw_params.hw_ops->rx_desc_get_msdu_freq(desc); 172 166 } 173 167 174 - static u8 ath11k_dp_rx_h_msdu_start_pkt_type(struct hal_rx_desc *desc) 168 + static u8 ath11k_dp_rx_h_msdu_start_pkt_type(struct ath11k_base *ab, 169 + struct hal_rx_desc *desc) 175 170 { 176 - return FIELD_GET(RX_MSDU_START_INFO3_PKT_TYPE, 177 - __le32_to_cpu(desc->msdu_start.info3)); 171 + return ab->hw_params.hw_ops->rx_desc_get_msdu_pkt_type(desc); 178 172 } 179 173 180 - static u8 ath11k_dp_rx_h_msdu_start_nss(struct hal_rx_desc *desc) 174 + static u8 ath11k_dp_rx_h_msdu_start_nss(struct ath11k_base *ab, 175 + struct hal_rx_desc *desc) 181 176 { 182 - u8 mimo_ss_bitmap = FIELD_GET(RX_MSDU_START_INFO3_MIMO_SS_BITMAP, 183 - __le32_to_cpu(desc->msdu_start.info3)); 184 - 185 - return hweight8(mimo_ss_bitmap); 177 + return hweight8(ab->hw_params.hw_ops->rx_desc_get_msdu_nss(desc)); 186 178 } 187 179 188 - static u8 ath11k_dp_rx_h_mpdu_start_tid(struct hal_rx_desc *desc) 180 + static u8 ath11k_dp_rx_h_mpdu_start_tid(struct ath11k_base *ab, 181 + struct hal_rx_desc *desc) 189 182 { 190 - return FIELD_GET(RX_MPDU_START_INFO2_TID, 191 - __le32_to_cpu(desc->mpdu_start.info2)); 183 + return ab->hw_params.hw_ops->rx_desc_get_mpdu_tid(desc); 192 184 } 193 185 194 - static u16 ath11k_dp_rx_h_mpdu_start_peer_id(struct hal_rx_desc *desc) 186 + static u16 ath11k_dp_rx_h_mpdu_start_peer_id(struct ath11k_base *ab, 187 + struct hal_rx_desc *desc) 195 188 { 196 - return __le16_to_cpu(desc->mpdu_start.sw_peer_id); 189 + return ab->hw_params.hw_ops->rx_desc_get_mpdu_peer_id(desc); 197 190 } 198 191 199 - static u8 ath11k_dp_rx_h_msdu_end_l3pad(struct hal_rx_desc *desc) 192 + static u8 ath11k_dp_rx_h_msdu_end_l3pad(struct ath11k_base *ab, 193 + struct hal_rx_desc *desc) 200 194 { 201 - return FIELD_GET(RX_MSDU_END_INFO2_L3_HDR_PADDING, 202 - __le32_to_cpu(desc->msdu_end.info2)); 195 + return ab->hw_params.hw_ops->rx_desc_get_l3_pad_bytes(desc); 203 196 } 204 197 205 - static bool ath11k_dp_rx_h_msdu_end_first_msdu(struct hal_rx_desc *desc) 198 + static bool ath11k_dp_rx_h_msdu_end_first_msdu(struct ath11k_base *ab, 199 + struct hal_rx_desc *desc) 206 200 { 207 - return !!FIELD_GET(RX_MSDU_END_INFO2_FIRST_MSDU, 208 - __le32_to_cpu(desc->msdu_end.info2)); 201 + return ab->hw_params.hw_ops->rx_desc_get_first_msdu(desc); 209 202 } 210 203 211 - static bool ath11k_dp_rx_h_msdu_end_last_msdu(struct hal_rx_desc *desc) 204 + static bool ath11k_dp_rx_h_msdu_end_last_msdu(struct ath11k_base *ab, 205 + struct hal_rx_desc *desc) 212 206 { 213 - return !!FIELD_GET(RX_MSDU_END_INFO2_LAST_MSDU, 214 - __le32_to_cpu(desc->msdu_end.info2)); 207 + return ab->hw_params.hw_ops->rx_desc_get_last_msdu(desc); 215 208 } 216 209 217 - static void ath11k_dp_rx_desc_end_tlv_copy(struct hal_rx_desc *fdesc, 210 + static void ath11k_dp_rx_desc_end_tlv_copy(struct ath11k_base *ab, 211 + struct hal_rx_desc *fdesc, 218 212 struct hal_rx_desc *ldesc) 219 213 { 220 - memcpy((u8 *)&fdesc->msdu_end, (u8 *)&ldesc->msdu_end, 221 - sizeof(struct rx_msdu_end)); 222 - memcpy((u8 *)&fdesc->attention, (u8 *)&ldesc->attention, 223 - sizeof(struct rx_attention)); 224 - memcpy((u8 *)&fdesc->mpdu_end, (u8 *)&ldesc->mpdu_end, 225 - sizeof(struct rx_mpdu_end)); 214 + ab->hw_params.hw_ops->rx_desc_copy_attn_end_tlv(fdesc, ldesc); 226 215 } 227 216 228 - static u32 ath11k_dp_rxdesc_get_mpdulen_err(struct hal_rx_desc *rx_desc) 217 + static u32 ath11k_dp_rxdesc_get_mpdulen_err(struct rx_attention *attn) 229 218 { 230 - struct rx_attention *rx_attn; 231 - 232 - rx_attn = &rx_desc->attention; 233 - 234 219 return FIELD_GET(RX_ATTENTION_INFO1_MPDU_LEN_ERR, 235 - __le32_to_cpu(rx_attn->info1)); 220 + __le32_to_cpu(attn->info1)); 236 221 } 237 222 238 - static u32 ath11k_dp_rxdesc_get_decap_format(struct hal_rx_desc *rx_desc) 239 - { 240 - struct rx_msdu_start *rx_msdu_start; 241 - 242 - rx_msdu_start = &rx_desc->msdu_start; 243 - 244 - return FIELD_GET(RX_MSDU_START_INFO2_DECAP_FORMAT, 245 - __le32_to_cpu(rx_msdu_start->info2)); 246 - } 247 - 248 - static u8 *ath11k_dp_rxdesc_get_80211hdr(struct hal_rx_desc *rx_desc) 223 + static u8 *ath11k_dp_rxdesc_get_80211hdr(struct ath11k_base *ab, 224 + struct hal_rx_desc *rx_desc) 249 225 { 250 226 u8 *rx_pkt_hdr; 251 227 252 - rx_pkt_hdr = &rx_desc->msdu_payload[0]; 228 + rx_pkt_hdr = ab->hw_params.hw_ops->rx_desc_get_msdu_payload(rx_desc); 253 229 254 230 return rx_pkt_hdr; 255 231 } 256 232 257 - static bool ath11k_dp_rxdesc_mpdu_valid(struct hal_rx_desc *rx_desc) 233 + static bool ath11k_dp_rxdesc_mpdu_valid(struct ath11k_base *ab, 234 + struct hal_rx_desc *rx_desc) 258 235 { 259 236 u32 tlv_tag; 260 237 261 - tlv_tag = FIELD_GET(HAL_TLV_HDR_TAG, 262 - __le32_to_cpu(rx_desc->mpdu_start_tag)); 238 + tlv_tag = ab->hw_params.hw_ops->rx_desc_get_mpdu_start_tag(rx_desc); 263 239 264 240 return tlv_tag == HAL_RX_MPDU_START; 265 241 } 266 242 267 - static u32 ath11k_dp_rxdesc_get_ppduid(struct hal_rx_desc *rx_desc) 243 + static u32 ath11k_dp_rxdesc_get_ppduid(struct ath11k_base *ab, 244 + struct hal_rx_desc *rx_desc) 268 245 { 269 - return __le16_to_cpu(rx_desc->mpdu_start.phy_ppdu_id); 246 + return ab->hw_params.hw_ops->rx_desc_get_mpdu_ppdu_id(rx_desc); 247 + } 248 + 249 + static void ath11k_dp_rxdesc_set_msdu_len(struct ath11k_base *ab, 250 + struct hal_rx_desc *desc, 251 + u16 len) 252 + { 253 + ab->hw_params.hw_ops->rx_desc_set_msdu_len(desc, len); 270 254 } 271 255 272 256 static void ath11k_dp_service_mon_ring(struct timer_list *t) ··· 1720 1722 struct sk_buff *first, struct sk_buff *last, 1721 1723 u8 l3pad_bytes, int msdu_len) 1722 1724 { 1725 + struct ath11k_base *ab = ar->ab; 1723 1726 struct sk_buff *skb; 1724 1727 struct ath11k_skb_rxcb *rxcb = ATH11K_SKB_RXCB(first); 1725 1728 int buf_first_hdr_len, buf_first_len; 1726 1729 struct hal_rx_desc *ldesc; 1727 - int space_extra; 1728 - int rem_len; 1729 - int buf_len; 1730 + int space_extra, rem_len, buf_len; 1731 + u32 hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz; 1730 1732 1731 1733 /* As the msdu is spread across multiple rx buffers, 1732 1734 * find the offset to the start of msdu for computing 1733 1735 * the length of the msdu in the first buffer. 1734 1736 */ 1735 - buf_first_hdr_len = HAL_RX_DESC_SIZE + l3pad_bytes; 1737 + buf_first_hdr_len = hal_rx_desc_sz + l3pad_bytes; 1736 1738 buf_first_len = DP_RX_BUFFER_SIZE - buf_first_hdr_len; 1737 1739 1738 1740 if (WARN_ON_ONCE(msdu_len <= buf_first_len)) { ··· 1742 1744 } 1743 1745 1744 1746 ldesc = (struct hal_rx_desc *)last->data; 1745 - rxcb->is_first_msdu = ath11k_dp_rx_h_msdu_end_first_msdu(ldesc); 1746 - rxcb->is_last_msdu = ath11k_dp_rx_h_msdu_end_last_msdu(ldesc); 1747 + rxcb->is_first_msdu = ath11k_dp_rx_h_msdu_end_first_msdu(ab, ldesc); 1748 + rxcb->is_last_msdu = ath11k_dp_rx_h_msdu_end_last_msdu(ab, ldesc); 1747 1749 1748 1750 /* MSDU spans over multiple buffers because the length of the MSDU 1749 1751 * exceeds DP_RX_BUFFER_SIZE - HAL_RX_DESC_SIZE. So assume the data ··· 1755 1757 /* When an MSDU spread over multiple buffers attention, MSDU_END and 1756 1758 * MPDU_END tlvs are valid only in the last buffer. Copy those tlvs. 1757 1759 */ 1758 - ath11k_dp_rx_desc_end_tlv_copy(rxcb->rx_desc, ldesc); 1760 + ath11k_dp_rx_desc_end_tlv_copy(ab, rxcb->rx_desc, ldesc); 1759 1761 1760 1762 space_extra = msdu_len - (buf_first_len + skb_tailroom(first)); 1761 1763 if (space_extra > 0 && ··· 1776 1778 while ((skb = __skb_dequeue(msdu_list)) != NULL && rem_len > 0) { 1777 1779 rxcb = ATH11K_SKB_RXCB(skb); 1778 1780 if (rxcb->is_continuation) 1779 - buf_len = DP_RX_BUFFER_SIZE - HAL_RX_DESC_SIZE; 1781 + buf_len = DP_RX_BUFFER_SIZE - hal_rx_desc_sz; 1780 1782 else 1781 1783 buf_len = rem_len; 1782 1784 1783 - if (buf_len > (DP_RX_BUFFER_SIZE - HAL_RX_DESC_SIZE)) { 1785 + if (buf_len > (DP_RX_BUFFER_SIZE - hal_rx_desc_sz)) { 1784 1786 WARN_ON_ONCE(1); 1785 1787 dev_kfree_skb_any(skb); 1786 1788 return -EINVAL; 1787 1789 } 1788 1790 1789 - skb_put(skb, buf_len + HAL_RX_DESC_SIZE); 1790 - skb_pull(skb, HAL_RX_DESC_SIZE); 1791 + skb_put(skb, buf_len + hal_rx_desc_sz); 1792 + skb_pull(skb, hal_rx_desc_sz); 1791 1793 skb_copy_from_linear_data(skb, skb_put(first, buf_len), 1792 1794 buf_len); 1793 1795 dev_kfree_skb_any(skb); ··· 1818 1820 return NULL; 1819 1821 } 1820 1822 1821 - static void ath11k_dp_rx_h_csum_offload(struct sk_buff *msdu) 1823 + static void ath11k_dp_rx_h_csum_offload(struct ath11k *ar, struct sk_buff *msdu) 1822 1824 { 1823 1825 struct ath11k_skb_rxcb *rxcb = ATH11K_SKB_RXCB(msdu); 1826 + struct rx_attention *rx_attention; 1824 1827 bool ip_csum_fail, l4_csum_fail; 1825 1828 1826 - ip_csum_fail = ath11k_dp_rx_h_attn_ip_cksum_fail(rxcb->rx_desc); 1827 - l4_csum_fail = ath11k_dp_rx_h_attn_l4_cksum_fail(rxcb->rx_desc); 1829 + rx_attention = ath11k_dp_rx_get_attention(ar->ab, rxcb->rx_desc); 1830 + ip_csum_fail = ath11k_dp_rx_h_attn_ip_cksum_fail(rx_attention); 1831 + l4_csum_fail = ath11k_dp_rx_h_attn_l4_cksum_fail(rx_attention); 1828 1832 1829 1833 msdu->ip_summed = (ip_csum_fail || l4_csum_fail) ? 1830 1834 CHECKSUM_NONE : CHECKSUM_UNNECESSARY; ··· 1957 1957 1958 1958 qos_ctl = rxcb->tid; 1959 1959 1960 - if (ath11k_dp_rx_h_msdu_start_mesh_ctl_present(rxcb->rx_desc)) 1960 + if (ath11k_dp_rx_h_msdu_start_mesh_ctl_present(ar->ab, rxcb->rx_desc)) 1961 1961 qos_ctl |= IEEE80211_QOS_CTL_MESH_CONTROL_PRESENT; 1962 1962 1963 1963 /* TODO Add other QoS ctl fields when required */ ··· 2061 2061 bool is_amsdu; 2062 2062 2063 2063 is_amsdu = !(rxcb->is_first_msdu && rxcb->is_last_msdu); 2064 - hdr = (struct ieee80211_hdr *)ath11k_dp_rx_h_80211_hdr(rxcb->rx_desc); 2064 + hdr = (struct ieee80211_hdr *)ath11k_dp_rx_h_80211_hdr(ar->ab, rxcb->rx_desc); 2065 2065 rfc1042 = hdr; 2066 2066 2067 2067 if (rxcb->is_first_msdu) { ··· 2134 2134 u8 *first_hdr; 2135 2135 u8 decap; 2136 2136 2137 - first_hdr = ath11k_dp_rx_h_80211_hdr(rx_desc); 2138 - decap = ath11k_dp_rx_h_msdu_start_decap_type(rx_desc); 2137 + first_hdr = ath11k_dp_rx_h_80211_hdr(ar->ab, rx_desc); 2138 + decap = ath11k_dp_rx_h_msdu_start_decap_type(ar->ab, rx_desc); 2139 2139 2140 2140 switch (decap) { 2141 2141 case DP_RX_DECAP_TYPE_NATIVE_WIFI: ··· 2167 2167 bool is_decrypted = false; 2168 2168 struct ieee80211_hdr *hdr; 2169 2169 struct ath11k_peer *peer; 2170 + struct rx_attention *rx_attention; 2170 2171 u32 err_bitmap; 2171 2172 2172 2173 hdr = (struct ieee80211_hdr *)msdu->data; ··· 2189 2188 } 2190 2189 spin_unlock_bh(&ar->ab->base_lock); 2191 2190 2192 - err_bitmap = ath11k_dp_rx_h_attn_mpdu_err(rx_desc); 2191 + rx_attention = ath11k_dp_rx_get_attention(ar->ab, rx_desc); 2192 + err_bitmap = ath11k_dp_rx_h_attn_mpdu_err(rx_attention); 2193 2193 if (enctype != HAL_ENCRYPT_TYPE_OPEN && !err_bitmap) 2194 - is_decrypted = ath11k_dp_rx_h_attn_is_decrypted(rx_desc); 2194 + is_decrypted = ath11k_dp_rx_h_attn_is_decrypted(rx_attention); 2195 2195 2196 2196 /* Clear per-MPDU flags while leaving per-PPDU flags intact */ 2197 2197 rx_status->flag &= ~(RX_FLAG_FAILED_FCS_CRC | ··· 2217 2215 RX_FLAG_PN_VALIDATED; 2218 2216 } 2219 2217 2220 - ath11k_dp_rx_h_csum_offload(msdu); 2218 + ath11k_dp_rx_h_csum_offload(ar, msdu); 2221 2219 ath11k_dp_rx_h_undecap(ar, msdu, rx_desc, 2222 2220 enctype, rx_status, is_decrypted); 2223 2221 ··· 2238 2236 u8 sgi; 2239 2237 bool is_cck; 2240 2238 2241 - pkt_type = ath11k_dp_rx_h_msdu_start_pkt_type(rx_desc); 2242 - bw = ath11k_dp_rx_h_msdu_start_rx_bw(rx_desc); 2243 - rate_mcs = ath11k_dp_rx_h_msdu_start_rate_mcs(rx_desc); 2244 - nss = ath11k_dp_rx_h_msdu_start_nss(rx_desc); 2245 - sgi = ath11k_dp_rx_h_msdu_start_sgi(rx_desc); 2239 + pkt_type = ath11k_dp_rx_h_msdu_start_pkt_type(ar->ab, rx_desc); 2240 + bw = ath11k_dp_rx_h_msdu_start_rx_bw(ar->ab, rx_desc); 2241 + rate_mcs = ath11k_dp_rx_h_msdu_start_rate_mcs(ar->ab, rx_desc); 2242 + nss = ath11k_dp_rx_h_msdu_start_nss(ar->ab, rx_desc); 2243 + sgi = ath11k_dp_rx_h_msdu_start_sgi(ar->ab, rx_desc); 2246 2244 2247 2245 switch (pkt_type) { 2248 2246 case RX_MSDU_START_PKT_TYPE_11A: ··· 2299 2297 struct ieee80211_rx_status *rx_status) 2300 2298 { 2301 2299 u8 channel_num; 2302 - u32 center_freq; 2300 + u32 center_freq, meta_data; 2303 2301 struct ieee80211_channel *channel; 2304 2302 2305 2303 rx_status->freq = 0; ··· 2310 2308 2311 2309 rx_status->flag |= RX_FLAG_NO_SIGNAL_VAL; 2312 2310 2313 - channel_num = ath11k_dp_rx_h_msdu_start_freq(rx_desc); 2314 - center_freq = ath11k_dp_rx_h_msdu_start_freq(rx_desc) >> 16; 2311 + meta_data = ath11k_dp_rx_h_msdu_start_freq(ar->ab, rx_desc); 2312 + channel_num = meta_data; 2313 + center_freq = meta_data >> 16; 2315 2314 2316 2315 if (center_freq >= 5935 && center_freq <= 7105) { 2317 2316 rx_status->band = NL80211_BAND_6GHZ; ··· 2412 2409 struct sk_buff *msdu, 2413 2410 struct sk_buff_head *msdu_list) 2414 2411 { 2412 + struct ath11k_base *ab = ar->ab; 2415 2413 struct hal_rx_desc *rx_desc, *lrx_desc; 2414 + struct rx_attention *rx_attention; 2416 2415 struct ieee80211_rx_status rx_status = {0}; 2417 2416 struct ieee80211_rx_status *status; 2418 2417 struct ath11k_skb_rxcb *rxcb; ··· 2424 2419 u8 *hdr_status; 2425 2420 u16 msdu_len; 2426 2421 int ret; 2422 + u32 hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz; 2427 2423 2428 2424 last_buf = ath11k_dp_rx_get_msdu_last_buf(msdu_list, msdu); 2429 2425 if (!last_buf) { 2430 - ath11k_warn(ar->ab, 2426 + ath11k_warn(ab, 2431 2427 "No valid Rx buffer to access Atten/MSDU_END/MPDU_END tlvs\n"); 2432 2428 ret = -EIO; 2433 2429 goto free_out; ··· 2436 2430 2437 2431 rx_desc = (struct hal_rx_desc *)msdu->data; 2438 2432 lrx_desc = (struct hal_rx_desc *)last_buf->data; 2439 - if (!ath11k_dp_rx_h_attn_msdu_done(lrx_desc)) { 2440 - ath11k_warn(ar->ab, "msdu_done bit in attention is not set\n"); 2433 + rx_attention = ath11k_dp_rx_get_attention(ab, lrx_desc); 2434 + if (!ath11k_dp_rx_h_attn_msdu_done(rx_attention)) { 2435 + ath11k_warn(ab, "msdu_done bit in attention is not set\n"); 2441 2436 ret = -EIO; 2442 2437 goto free_out; 2443 2438 } 2444 2439 2445 2440 rxcb = ATH11K_SKB_RXCB(msdu); 2446 2441 rxcb->rx_desc = rx_desc; 2447 - msdu_len = ath11k_dp_rx_h_msdu_start_msdu_len(rx_desc); 2448 - l3_pad_bytes = ath11k_dp_rx_h_msdu_end_l3pad(lrx_desc); 2442 + msdu_len = ath11k_dp_rx_h_msdu_start_msdu_len(ab, rx_desc); 2443 + l3_pad_bytes = ath11k_dp_rx_h_msdu_end_l3pad(ab, lrx_desc); 2449 2444 2450 2445 if (rxcb->is_frag) { 2451 - skb_pull(msdu, HAL_RX_DESC_SIZE); 2446 + skb_pull(msdu, hal_rx_desc_sz); 2452 2447 } else if (!rxcb->is_continuation) { 2453 - if ((msdu_len + HAL_RX_DESC_SIZE) > DP_RX_BUFFER_SIZE) { 2454 - hdr_status = ath11k_dp_rx_h_80211_hdr(rx_desc); 2448 + if ((msdu_len + hal_rx_desc_sz) > DP_RX_BUFFER_SIZE) { 2449 + hdr_status = ath11k_dp_rx_h_80211_hdr(ab, rx_desc); 2455 2450 ret = -EINVAL; 2456 - ath11k_warn(ar->ab, "invalid msdu len %u\n", msdu_len); 2457 - ath11k_dbg_dump(ar->ab, ATH11K_DBG_DATA, NULL, "", hdr_status, 2451 + ath11k_warn(ab, "invalid msdu len %u\n", msdu_len); 2452 + ath11k_dbg_dump(ab, ATH11K_DBG_DATA, NULL, "", hdr_status, 2458 2453 sizeof(struct ieee80211_hdr)); 2459 - ath11k_dbg_dump(ar->ab, ATH11K_DBG_DATA, NULL, "", rx_desc, 2454 + ath11k_dbg_dump(ab, ATH11K_DBG_DATA, NULL, "", rx_desc, 2460 2455 sizeof(struct hal_rx_desc)); 2461 2456 goto free_out; 2462 2457 } 2463 - skb_put(msdu, HAL_RX_DESC_SIZE + l3_pad_bytes + msdu_len); 2464 - skb_pull(msdu, HAL_RX_DESC_SIZE + l3_pad_bytes); 2458 + skb_put(msdu, hal_rx_desc_sz + l3_pad_bytes + msdu_len); 2459 + skb_pull(msdu, hal_rx_desc_sz + l3_pad_bytes); 2465 2460 } else { 2466 2461 ret = ath11k_dp_rx_msdu_coalesce(ar, msdu_list, 2467 2462 msdu, last_buf, 2468 2463 l3_pad_bytes, msdu_len); 2469 2464 if (ret) { 2470 - ath11k_warn(ar->ab, 2465 + ath11k_warn(ab, 2471 2466 "failed to coalesce msdu rx buffer%d\n", ret); 2472 2467 goto free_out; 2473 2468 } ··· 3097 3090 u8 mic[IEEE80211_CCMP_MIC_LEN]; 3098 3091 int head_len, tail_len, ret; 3099 3092 size_t data_len; 3100 - u32 hdr_len; 3093 + u32 hdr_len, hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz; 3101 3094 u8 *key, *data; 3102 3095 u8 key_idx; 3103 3096 3104 - if (ath11k_dp_rx_h_mpdu_start_enctype(rx_desc) != HAL_ENCRYPT_TYPE_TKIP_MIC) 3097 + if (ath11k_dp_rx_h_mpdu_start_enctype(ar->ab, rx_desc) != 3098 + HAL_ENCRYPT_TYPE_TKIP_MIC) 3105 3099 return 0; 3106 3100 3107 - hdr = (struct ieee80211_hdr *)(msdu->data + HAL_RX_DESC_SIZE); 3101 + hdr = (struct ieee80211_hdr *)(msdu->data + hal_rx_desc_sz); 3108 3102 hdr_len = ieee80211_hdrlen(hdr->frame_control); 3109 - head_len = hdr_len + HAL_RX_DESC_SIZE + IEEE80211_TKIP_IV_LEN; 3103 + head_len = hdr_len + hal_rx_desc_sz + IEEE80211_TKIP_IV_LEN; 3110 3104 tail_len = IEEE80211_CCMP_MIC_LEN + IEEE80211_TKIP_ICV_LEN + FCS_LEN; 3111 3105 3112 3106 if (!is_multicast_ether_addr(hdr->addr1)) ··· 3133 3125 3134 3126 rxs->flag |= RX_FLAG_MMIC_ERROR | RX_FLAG_MMIC_STRIPPED | 3135 3127 RX_FLAG_IV_STRIPPED | RX_FLAG_DECRYPTED; 3136 - skb_pull(msdu, HAL_RX_DESC_SIZE); 3128 + skb_pull(msdu, hal_rx_desc_sz); 3137 3129 3138 3130 ath11k_dp_rx_h_ppdu(ar, rx_desc, rxs); 3139 3131 ath11k_dp_rx_h_undecap(ar, msdu, rx_desc, ··· 3148 3140 struct ieee80211_hdr *hdr; 3149 3141 size_t hdr_len; 3150 3142 size_t crypto_len; 3143 + u32 hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz; 3151 3144 3152 3145 if (!flags) 3153 3146 return; 3154 3147 3155 - hdr = (struct ieee80211_hdr *)(msdu->data + HAL_RX_DESC_SIZE); 3148 + hdr = (struct ieee80211_hdr *)(msdu->data + hal_rx_desc_sz); 3156 3149 3157 3150 if (flags & RX_FLAG_MIC_STRIPPED) 3158 3151 skb_trim(msdu, msdu->len - ··· 3167 3158 hdr_len = ieee80211_hdrlen(hdr->frame_control); 3168 3159 crypto_len = ath11k_dp_rx_crypto_param_len(ar, enctype); 3169 3160 3170 - memmove((void *)msdu->data + HAL_RX_DESC_SIZE + crypto_len, 3171 - (void *)msdu->data + HAL_RX_DESC_SIZE, hdr_len); 3161 + memmove((void *)msdu->data + hal_rx_desc_sz + crypto_len, 3162 + (void *)msdu->data + hal_rx_desc_sz, hdr_len); 3172 3163 skb_pull(msdu, crypto_len); 3173 3164 } 3174 3165 } ··· 3181 3172 struct hal_rx_desc *rx_desc; 3182 3173 struct sk_buff *skb, *first_frag, *last_frag; 3183 3174 struct ieee80211_hdr *hdr; 3175 + struct rx_attention *rx_attention; 3184 3176 enum hal_encrypt_type enctype; 3185 3177 bool is_decrypted = false; 3186 3178 int msdu_len = 0; 3187 3179 int extra_space; 3188 - u32 flags; 3180 + u32 flags, hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz; 3189 3181 3190 3182 first_frag = skb_peek(&rx_tid->rx_frags); 3191 3183 last_frag = skb_peek_tail(&rx_tid->rx_frags); ··· 3194 3184 skb_queue_walk(&rx_tid->rx_frags, skb) { 3195 3185 flags = 0; 3196 3186 rx_desc = (struct hal_rx_desc *)skb->data; 3197 - hdr = (struct ieee80211_hdr *)(skb->data + HAL_RX_DESC_SIZE); 3187 + hdr = (struct ieee80211_hdr *)(skb->data + hal_rx_desc_sz); 3198 3188 3199 - enctype = ath11k_dp_rx_h_mpdu_start_enctype(rx_desc); 3200 - if (enctype != HAL_ENCRYPT_TYPE_OPEN) 3201 - is_decrypted = ath11k_dp_rx_h_attn_is_decrypted(rx_desc); 3189 + enctype = ath11k_dp_rx_h_mpdu_start_enctype(ar->ab, rx_desc); 3190 + if (enctype != HAL_ENCRYPT_TYPE_OPEN) { 3191 + rx_attention = ath11k_dp_rx_get_attention(ar->ab, rx_desc); 3192 + is_decrypted = ath11k_dp_rx_h_attn_is_decrypted(rx_attention); 3193 + } 3202 3194 3203 3195 if (is_decrypted) { 3204 3196 if (skb != first_frag) ··· 3216 3204 ath11k_dp_rx_h_undecap_frag(ar, skb, enctype, flags); 3217 3205 3218 3206 if (skb != first_frag) 3219 - skb_pull(skb, HAL_RX_DESC_SIZE + 3207 + skb_pull(skb, hal_rx_desc_sz + 3220 3208 ieee80211_hdrlen(hdr->frame_control)); 3221 3209 msdu_len += skb->len; 3222 3210 } ··· 3232 3220 dev_kfree_skb_any(skb); 3233 3221 } 3234 3222 3235 - hdr = (struct ieee80211_hdr *)(first_frag->data + HAL_RX_DESC_SIZE); 3223 + hdr = (struct ieee80211_hdr *)(first_frag->data + hal_rx_desc_sz); 3236 3224 hdr->frame_control &= ~__cpu_to_le16(IEEE80211_FCTL_MOREFRAGS); 3237 3225 ATH11K_SKB_RXCB(first_frag)->is_frag = 1; 3238 3226 ··· 3258 3246 struct hal_srng *srng; 3259 3247 dma_addr_t paddr; 3260 3248 u32 desc_bank, msdu_info, mpdu_info; 3261 - u32 dst_idx, cookie; 3262 - u32 *msdu_len_offset; 3249 + u32 dst_idx, cookie, hal_rx_desc_sz; 3263 3250 int ret, buf_id; 3264 3251 3252 + hal_rx_desc_sz = ab->hw_params.hal_desc_sz; 3265 3253 link_desc_banks = ab->dp.link_desc_banks; 3266 3254 reo_dest_ring = rx_tid->dst_ring_desc; 3267 3255 ··· 3276 3264 FIELD_PREP(RX_MSDU_DESC_INFO0_LAST_MSDU_IN_MPDU, 1) | 3277 3265 FIELD_PREP(RX_MSDU_DESC_INFO0_MSDU_CONTINUATION, 0) | 3278 3266 FIELD_PREP(RX_MSDU_DESC_INFO0_MSDU_LENGTH, 3279 - defrag_skb->len - HAL_RX_DESC_SIZE) | 3267 + defrag_skb->len - hal_rx_desc_sz) | 3280 3268 FIELD_PREP(RX_MSDU_DESC_INFO0_REO_DEST_IND, dst_idx) | 3281 3269 FIELD_PREP(RX_MSDU_DESC_INFO0_VALID_SA, 1) | 3282 3270 FIELD_PREP(RX_MSDU_DESC_INFO0_VALID_DA, 1); 3283 3271 msdu0->rx_msdu_info.info0 = msdu_info; 3284 3272 3285 3273 /* change msdu len in hal rx desc */ 3286 - msdu_len_offset = (u32 *)&rx_desc->msdu_start; 3287 - *msdu_len_offset &= ~(RX_MSDU_START_INFO1_MSDU_LENGTH); 3288 - *msdu_len_offset |= defrag_skb->len - HAL_RX_DESC_SIZE; 3274 + ath11k_dp_rxdesc_set_msdu_len(ab, rx_desc, defrag_skb->len - hal_rx_desc_sz); 3289 3275 3290 3276 paddr = dma_map_single(ab->dev, defrag_skb->data, 3291 3277 defrag_skb->len + skb_tailroom(defrag_skb), ··· 3356 3346 return ret; 3357 3347 } 3358 3348 3359 - static int ath11k_dp_rx_h_cmp_frags(struct sk_buff *a, struct sk_buff *b) 3349 + static int ath11k_dp_rx_h_cmp_frags(struct ath11k *ar, 3350 + struct sk_buff *a, struct sk_buff *b) 3360 3351 { 3361 3352 int frag1, frag2; 3362 3353 3363 - frag1 = ath11k_dp_rx_h_mpdu_start_frag_no(a); 3364 - frag2 = ath11k_dp_rx_h_mpdu_start_frag_no(b); 3354 + frag1 = ath11k_dp_rx_h_mpdu_start_frag_no(ar->ab, a); 3355 + frag2 = ath11k_dp_rx_h_mpdu_start_frag_no(ar->ab, b); 3365 3356 3366 3357 return frag1 - frag2; 3367 3358 } 3368 3359 3369 - static void ath11k_dp_rx_h_sort_frags(struct sk_buff_head *frag_list, 3360 + static void ath11k_dp_rx_h_sort_frags(struct ath11k *ar, 3361 + struct sk_buff_head *frag_list, 3370 3362 struct sk_buff *cur_frag) 3371 3363 { 3372 3364 struct sk_buff *skb; 3373 3365 int cmp; 3374 3366 3375 3367 skb_queue_walk(frag_list, skb) { 3376 - cmp = ath11k_dp_rx_h_cmp_frags(skb, cur_frag); 3368 + cmp = ath11k_dp_rx_h_cmp_frags(ar, skb, cur_frag); 3377 3369 if (cmp < 0) 3378 3370 continue; 3379 3371 __skb_queue_before(frag_list, skb, cur_frag); ··· 3384 3372 __skb_queue_tail(frag_list, cur_frag); 3385 3373 } 3386 3374 3387 - static u64 ath11k_dp_rx_h_get_pn(struct sk_buff *skb) 3375 + static u64 ath11k_dp_rx_h_get_pn(struct ath11k *ar, struct sk_buff *skb) 3388 3376 { 3389 3377 struct ieee80211_hdr *hdr; 3390 3378 u64 pn = 0; 3391 3379 u8 *ehdr; 3380 + u32 hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz; 3392 3381 3393 - hdr = (struct ieee80211_hdr *)(skb->data + HAL_RX_DESC_SIZE); 3394 - ehdr = skb->data + HAL_RX_DESC_SIZE + ieee80211_hdrlen(hdr->frame_control); 3382 + hdr = (struct ieee80211_hdr *)(skb->data + hal_rx_desc_sz); 3383 + ehdr = skb->data + hal_rx_desc_sz + ieee80211_hdrlen(hdr->frame_control); 3395 3384 3396 3385 pn = ehdr[0]; 3397 3386 pn |= (u64)ehdr[1] << 8; ··· 3416 3403 first_frag = skb_peek(&rx_tid->rx_frags); 3417 3404 desc = (struct hal_rx_desc *)first_frag->data; 3418 3405 3419 - encrypt_type = ath11k_dp_rx_h_mpdu_start_enctype(desc); 3406 + encrypt_type = ath11k_dp_rx_h_mpdu_start_enctype(ar->ab, desc); 3420 3407 if (encrypt_type != HAL_ENCRYPT_TYPE_CCMP_128 && 3421 3408 encrypt_type != HAL_ENCRYPT_TYPE_CCMP_256 && 3422 3409 encrypt_type != HAL_ENCRYPT_TYPE_GCMP_128 && 3423 3410 encrypt_type != HAL_ENCRYPT_TYPE_AES_GCMP_256) 3424 3411 return true; 3425 3412 3426 - last_pn = ath11k_dp_rx_h_get_pn(first_frag); 3413 + last_pn = ath11k_dp_rx_h_get_pn(ar, first_frag); 3427 3414 skb_queue_walk(&rx_tid->rx_frags, skb) { 3428 3415 if (skb == first_frag) 3429 3416 continue; 3430 3417 3431 - cur_pn = ath11k_dp_rx_h_get_pn(skb); 3418 + cur_pn = ath11k_dp_rx_h_get_pn(ar, skb); 3432 3419 if (cur_pn != last_pn + 1) 3433 3420 return false; 3434 3421 last_pn = cur_pn; ··· 3452 3439 bool more_frags; 3453 3440 3454 3441 rx_desc = (struct hal_rx_desc *)msdu->data; 3455 - peer_id = ath11k_dp_rx_h_mpdu_start_peer_id(rx_desc); 3456 - tid = ath11k_dp_rx_h_mpdu_start_tid(rx_desc); 3457 - seqno = ath11k_dp_rx_h_mpdu_start_seq_no(rx_desc); 3458 - frag_no = ath11k_dp_rx_h_mpdu_start_frag_no(msdu); 3459 - more_frags = ath11k_dp_rx_h_mpdu_start_more_frags(msdu); 3442 + peer_id = ath11k_dp_rx_h_mpdu_start_peer_id(ar->ab, rx_desc); 3443 + tid = ath11k_dp_rx_h_mpdu_start_tid(ar->ab, rx_desc); 3444 + seqno = ath11k_dp_rx_h_mpdu_start_seq_no(ar->ab, rx_desc); 3445 + frag_no = ath11k_dp_rx_h_mpdu_start_frag_no(ar->ab, msdu); 3446 + more_frags = ath11k_dp_rx_h_mpdu_start_more_frags(ar->ab, msdu); 3460 3447 3461 - if (!ath11k_dp_rx_h_mpdu_start_seq_ctrl_valid(rx_desc) || 3462 - !ath11k_dp_rx_h_mpdu_start_fc_valid(rx_desc) || 3448 + if (!ath11k_dp_rx_h_mpdu_start_seq_ctrl_valid(ar->ab, rx_desc) || 3449 + !ath11k_dp_rx_h_mpdu_start_fc_valid(ar->ab, rx_desc) || 3463 3450 tid > IEEE80211_NUM_TIDS) 3464 3451 return -EINVAL; 3465 3452 ··· 3497 3484 if (frag_no > __fls(rx_tid->rx_frag_bitmap)) 3498 3485 __skb_queue_tail(&rx_tid->rx_frags, msdu); 3499 3486 else 3500 - ath11k_dp_rx_h_sort_frags(&rx_tid->rx_frags, msdu); 3487 + ath11k_dp_rx_h_sort_frags(ar, &rx_tid->rx_frags, msdu); 3501 3488 3502 3489 rx_tid->rx_frag_bitmap |= BIT(frag_no); 3503 3490 if (!more_frags) ··· 3564 3551 struct hal_rx_desc *rx_desc; 3565 3552 u8 *hdr_status; 3566 3553 u16 msdu_len; 3554 + u32 hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz; 3567 3555 3568 3556 spin_lock_bh(&rx_ring->idr_lock); 3569 3557 msdu = idr_find(&rx_ring->bufs_idr, buf_id); ··· 3600 3586 } 3601 3587 3602 3588 rx_desc = (struct hal_rx_desc *)msdu->data; 3603 - msdu_len = ath11k_dp_rx_h_msdu_start_msdu_len(rx_desc); 3604 - if ((msdu_len + HAL_RX_DESC_SIZE) > DP_RX_BUFFER_SIZE) { 3605 - hdr_status = ath11k_dp_rx_h_80211_hdr(rx_desc); 3589 + msdu_len = ath11k_dp_rx_h_msdu_start_msdu_len(ar->ab, rx_desc); 3590 + if ((msdu_len + hal_rx_desc_sz) > DP_RX_BUFFER_SIZE) { 3591 + hdr_status = ath11k_dp_rx_h_80211_hdr(ar->ab, rx_desc); 3606 3592 ath11k_warn(ar->ab, "invalid msdu leng %u", msdu_len); 3607 3593 ath11k_dbg_dump(ar->ab, ATH11K_DBG_DATA, NULL, "", hdr_status, 3608 3594 sizeof(struct ieee80211_hdr)); ··· 3612 3598 goto exit; 3613 3599 } 3614 3600 3615 - skb_put(msdu, HAL_RX_DESC_SIZE + msdu_len); 3601 + skb_put(msdu, hal_rx_desc_sz + msdu_len); 3616 3602 3617 3603 if (ath11k_dp_rx_frag_h_mpdu(ar, msdu, ring_desc)) { 3618 3604 dev_kfree_skb_any(msdu); ··· 3746 3732 int n_buffs; 3747 3733 3748 3734 n_buffs = DIV_ROUND_UP(msdu_len, 3749 - (DP_RX_BUFFER_SIZE - HAL_RX_DESC_SIZE)); 3735 + (DP_RX_BUFFER_SIZE - ar->ab->hw_params.hal_desc_sz)); 3750 3736 3751 3737 skb_queue_walk_safe(msdu_list, skb, tmp) { 3752 3738 rxcb = ATH11K_SKB_RXCB(skb); ··· 3767 3753 { 3768 3754 u16 msdu_len; 3769 3755 struct hal_rx_desc *desc = (struct hal_rx_desc *)msdu->data; 3756 + struct rx_attention *rx_attention; 3770 3757 u8 l3pad_bytes; 3771 3758 struct ath11k_skb_rxcb *rxcb = ATH11K_SKB_RXCB(msdu); 3759 + u32 hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz; 3772 3760 3773 - msdu_len = ath11k_dp_rx_h_msdu_start_msdu_len(desc); 3761 + msdu_len = ath11k_dp_rx_h_msdu_start_msdu_len(ar->ab, desc); 3774 3762 3775 - if (!rxcb->is_frag && ((msdu_len + HAL_RX_DESC_SIZE) > DP_RX_BUFFER_SIZE)) { 3763 + if (!rxcb->is_frag && ((msdu_len + hal_rx_desc_sz) > DP_RX_BUFFER_SIZE)) { 3776 3764 /* First buffer will be freed by the caller, so deduct it's length */ 3777 - msdu_len = msdu_len - (DP_RX_BUFFER_SIZE - HAL_RX_DESC_SIZE); 3765 + msdu_len = msdu_len - (DP_RX_BUFFER_SIZE - hal_rx_desc_sz); 3778 3766 ath11k_dp_rx_null_q_desc_sg_drop(ar, msdu_len, msdu_list); 3779 3767 return -EINVAL; 3780 3768 } 3781 3769 3782 - if (!ath11k_dp_rx_h_attn_msdu_done(desc)) { 3770 + rx_attention = ath11k_dp_rx_get_attention(ar->ab, desc); 3771 + if (!ath11k_dp_rx_h_attn_msdu_done(rx_attention)) { 3783 3772 ath11k_warn(ar->ab, 3784 3773 "msdu_done bit not set in null_q_des processing\n"); 3785 3774 __skb_queue_purge(msdu_list); ··· 3798 3781 * This error can show up both in a REO destination or WBM release ring. 3799 3782 */ 3800 3783 3801 - rxcb->is_first_msdu = ath11k_dp_rx_h_msdu_end_first_msdu(desc); 3802 - rxcb->is_last_msdu = ath11k_dp_rx_h_msdu_end_last_msdu(desc); 3784 + rxcb->is_first_msdu = ath11k_dp_rx_h_msdu_end_first_msdu(ar->ab, desc); 3785 + rxcb->is_last_msdu = ath11k_dp_rx_h_msdu_end_last_msdu(ar->ab, desc); 3803 3786 3804 3787 if (rxcb->is_frag) { 3805 - skb_pull(msdu, HAL_RX_DESC_SIZE); 3788 + skb_pull(msdu, hal_rx_desc_sz); 3806 3789 } else { 3807 - l3pad_bytes = ath11k_dp_rx_h_msdu_end_l3pad(desc); 3790 + l3pad_bytes = ath11k_dp_rx_h_msdu_end_l3pad(ar->ab, desc); 3808 3791 3809 - if ((HAL_RX_DESC_SIZE + l3pad_bytes + msdu_len) > DP_RX_BUFFER_SIZE) 3792 + if ((hal_rx_desc_sz + l3pad_bytes + msdu_len) > DP_RX_BUFFER_SIZE) 3810 3793 return -EINVAL; 3811 3794 3812 - skb_put(msdu, HAL_RX_DESC_SIZE + l3pad_bytes + msdu_len); 3813 - skb_pull(msdu, HAL_RX_DESC_SIZE + l3pad_bytes); 3795 + skb_put(msdu, hal_rx_desc_sz + l3pad_bytes + msdu_len); 3796 + skb_pull(msdu, hal_rx_desc_sz + l3pad_bytes); 3814 3797 } 3815 3798 ath11k_dp_rx_h_ppdu(ar, desc, status); 3816 3799 3817 3800 ath11k_dp_rx_h_mpdu(ar, msdu, desc, status); 3818 3801 3819 - rxcb->tid = ath11k_dp_rx_h_mpdu_start_tid(desc); 3802 + rxcb->tid = ath11k_dp_rx_h_mpdu_start_tid(ar->ab, desc); 3820 3803 3821 3804 /* Please note that caller will having the access to msdu and completing 3822 3805 * rx with mac80211. Need not worry about cleaning up amsdu_list. ··· 3863 3846 struct hal_rx_desc *desc = (struct hal_rx_desc *)msdu->data; 3864 3847 u8 l3pad_bytes; 3865 3848 struct ath11k_skb_rxcb *rxcb = ATH11K_SKB_RXCB(msdu); 3849 + u32 hal_rx_desc_sz = ar->ab->hw_params.hal_desc_sz; 3866 3850 3867 - rxcb->is_first_msdu = ath11k_dp_rx_h_msdu_end_first_msdu(desc); 3868 - rxcb->is_last_msdu = ath11k_dp_rx_h_msdu_end_last_msdu(desc); 3851 + rxcb->is_first_msdu = ath11k_dp_rx_h_msdu_end_first_msdu(ar->ab, desc); 3852 + rxcb->is_last_msdu = ath11k_dp_rx_h_msdu_end_last_msdu(ar->ab, desc); 3869 3853 3870 - l3pad_bytes = ath11k_dp_rx_h_msdu_end_l3pad(desc); 3871 - msdu_len = ath11k_dp_rx_h_msdu_start_msdu_len(desc); 3872 - skb_put(msdu, HAL_RX_DESC_SIZE + l3pad_bytes + msdu_len); 3873 - skb_pull(msdu, HAL_RX_DESC_SIZE + l3pad_bytes); 3854 + l3pad_bytes = ath11k_dp_rx_h_msdu_end_l3pad(ar->ab, desc); 3855 + msdu_len = ath11k_dp_rx_h_msdu_start_msdu_len(ar->ab, desc); 3856 + skb_put(msdu, hal_rx_desc_sz + l3pad_bytes + msdu_len); 3857 + skb_pull(msdu, hal_rx_desc_sz + l3pad_bytes); 3874 3858 3875 3859 ath11k_dp_rx_h_ppdu(ar, desc, status); 3876 3860 ··· 4613 4595 rx_desc = (struct hal_rx_desc *)msdu->data; 4614 4596 4615 4597 rx_pkt_offset = sizeof(struct hal_rx_desc); 4616 - l2_hdr_offset = ath11k_dp_rx_h_msdu_end_l3pad(rx_desc); 4598 + l2_hdr_offset = ath11k_dp_rx_h_msdu_end_l3pad(ar->ab, rx_desc); 4617 4599 4618 4600 if (is_first_msdu) { 4619 - if (!ath11k_dp_rxdesc_mpdu_valid(rx_desc)) { 4601 + if (!ath11k_dp_rxdesc_mpdu_valid(ar->ab, rx_desc)) { 4620 4602 drop_mpdu = true; 4621 4603 dev_kfree_skb_any(msdu); 4622 4604 msdu = NULL; ··· 4625 4607 } 4626 4608 4627 4609 msdu_ppdu_id = 4628 - ath11k_dp_rxdesc_get_ppduid(rx_desc); 4610 + ath11k_dp_rxdesc_get_ppduid(ar->ab, rx_desc); 4629 4611 4630 4612 if (ath11k_dp_rx_mon_comp_ppduid(msdu_ppdu_id, 4631 4613 ppdu_id, ··· 4694 4676 return rx_bufs_used; 4695 4677 } 4696 4678 4697 - static void ath11k_dp_rx_msdus_set_payload(struct sk_buff *msdu) 4679 + static void ath11k_dp_rx_msdus_set_payload(struct ath11k *ar, struct sk_buff *msdu) 4698 4680 { 4699 4681 u32 rx_pkt_offset, l2_hdr_offset; 4700 4682 4701 - rx_pkt_offset = sizeof(struct hal_rx_desc); 4702 - l2_hdr_offset = ath11k_dp_rx_h_msdu_end_l3pad((struct hal_rx_desc *)msdu->data); 4683 + rx_pkt_offset = ar->ab->hw_params.hal_desc_sz; 4684 + l2_hdr_offset = ath11k_dp_rx_h_msdu_end_l3pad(ar->ab, 4685 + (struct hal_rx_desc *)msdu->data); 4703 4686 skb_pull(msdu, rx_pkt_offset + l2_hdr_offset); 4704 4687 } 4705 4688 ··· 4710 4691 struct sk_buff *last_msdu, 4711 4692 struct ieee80211_rx_status *rxs) 4712 4693 { 4694 + struct ath11k_base *ab = ar->ab; 4713 4695 struct sk_buff *msdu, *mpdu_buf, *prev_buf; 4714 - u32 decap_format, wifi_hdr_len; 4696 + u32 wifi_hdr_len; 4715 4697 struct hal_rx_desc *rx_desc; 4716 4698 char *hdr_desc; 4717 - u8 *dest; 4699 + u8 *dest, decap_format; 4718 4700 struct ieee80211_hdr_3addr *wh; 4701 + struct rx_attention *rx_attention; 4719 4702 4720 4703 mpdu_buf = NULL; 4721 4704 ··· 4725 4704 goto err_merge_fail; 4726 4705 4727 4706 rx_desc = (struct hal_rx_desc *)head_msdu->data; 4707 + rx_attention = ath11k_dp_rx_get_attention(ab, rx_desc); 4728 4708 4729 - if (ath11k_dp_rxdesc_get_mpdulen_err(rx_desc)) 4709 + if (ath11k_dp_rxdesc_get_mpdulen_err(rx_attention)) 4730 4710 return NULL; 4731 4711 4732 - decap_format = ath11k_dp_rxdesc_get_decap_format(rx_desc); 4712 + decap_format = ath11k_dp_rx_h_msdu_start_decap_type(ab, rx_desc); 4733 4713 4734 4714 ath11k_dp_rx_h_ppdu(ar, rx_desc, rxs); 4735 4715 4736 4716 if (decap_format == DP_RX_DECAP_TYPE_RAW) { 4737 - ath11k_dp_rx_msdus_set_payload(head_msdu); 4717 + ath11k_dp_rx_msdus_set_payload(ar, head_msdu); 4738 4718 4739 4719 prev_buf = head_msdu; 4740 4720 msdu = head_msdu->next; 4741 4721 4742 4722 while (msdu) { 4743 - ath11k_dp_rx_msdus_set_payload(msdu); 4723 + ath11k_dp_rx_msdus_set_payload(ar, msdu); 4744 4724 4745 4725 prev_buf = msdu; 4746 4726 msdu = msdu->next; ··· 4755 4733 u8 qos_pkt = 0; 4756 4734 4757 4735 rx_desc = (struct hal_rx_desc *)head_msdu->data; 4758 - hdr_desc = ath11k_dp_rxdesc_get_80211hdr(rx_desc); 4736 + hdr_desc = ath11k_dp_rxdesc_get_80211hdr(ab, rx_desc); 4759 4737 4760 4738 /* Base size */ 4761 4739 wifi_hdr_len = sizeof(struct ieee80211_hdr_3addr); ··· 4772 4750 4773 4751 while (msdu) { 4774 4752 rx_desc = (struct hal_rx_desc *)msdu->data; 4775 - hdr_desc = ath11k_dp_rxdesc_get_80211hdr(rx_desc); 4753 + hdr_desc = ath11k_dp_rxdesc_get_80211hdr(ab, rx_desc); 4776 4754 4777 4755 if (qos_pkt) { 4778 4756 dest = skb_push(msdu, sizeof(__le16)); ··· 4782 4760 memcpy(dest + wifi_hdr_len, 4783 4761 (u8 *)&qos_field, sizeof(__le16)); 4784 4762 } 4785 - ath11k_dp_rx_msdus_set_payload(msdu); 4763 + ath11k_dp_rx_msdus_set_payload(ar, msdu); 4786 4764 prev_buf = msdu; 4787 4765 msdu = msdu->next; 4788 4766 } ··· 4790 4768 if (!dest) 4791 4769 goto err_merge_fail; 4792 4770 4793 - ath11k_dbg(ar->ab, ATH11K_DBG_DATA, 4771 + ath11k_dbg(ab, ATH11K_DBG_DATA, 4794 4772 "mpdu_buf %pK mpdu_buf->len %u", 4795 4773 prev_buf, prev_buf->len); 4796 4774 } else { 4797 - ath11k_dbg(ar->ab, ATH11K_DBG_DATA, 4775 + ath11k_dbg(ab, ATH11K_DBG_DATA, 4798 4776 "decap format %d is not supported!\n", 4799 4777 decap_format); 4800 4778 goto err_merge_fail; ··· 4804 4782 4805 4783 err_merge_fail: 4806 4784 if (mpdu_buf && decap_format != DP_RX_DECAP_TYPE_RAW) { 4807 - ath11k_dbg(ar->ab, ATH11K_DBG_DATA, 4785 + ath11k_dbg(ab, ATH11K_DBG_DATA, 4808 4786 "err_merge_fail mpdu_buf %pK", mpdu_buf); 4809 4787 /* Free the head buffer */ 4810 4788 dev_kfree_skb_any(mpdu_buf);
+3 -3
drivers/net/wireless/ath/ath11k/dp_tx.c
··· 178 178 } 179 179 180 180 if (ieee80211_vif_is_mesh(arvif->vif)) 181 - ti.flags1 |= FIELD_PREP(HAL_TCL_DATA_CMD_INFO2_MESH_ENABLE, 1); 181 + ti.enable_mesh = true; 182 182 183 183 ti.flags1 |= FIELD_PREP(HAL_TCL_DATA_CMD_INFO2_TID_OVERWRITE, 1); 184 184 ··· 792 792 cmd->ring_tail_off32_remote_addr_hi = (u64)tp_addr >> 793 793 HAL_ADDR_MSB_REG_SHIFT; 794 794 795 - cmd->ring_msi_addr_lo = params.msi_addr & 0xffffffff; 796 - cmd->ring_msi_addr_hi = ((uint64_t)(params.msi_addr) >> 32) & 0xffffffff; 795 + cmd->ring_msi_addr_lo = lower_32_bits(params.msi_addr); 796 + cmd->ring_msi_addr_hi = upper_32_bits(params.msi_addr); 797 797 cmd->msi_data = params.msi_data; 798 798 799 799 cmd->intr_info = FIELD_PREP(
+41 -55
drivers/net/wireless/ath/ath11k/hal.c
··· 89 89 .entry_size = sizeof(struct hal_ce_srng_src_desc) >> 2, 90 90 .lmac_ring = false, 91 91 .ring_dir = HAL_SRNG_DIR_SRC, 92 - .reg_start = { 93 - (HAL_SEQ_WCSS_UMAC_CE0_SRC_REG + 94 - HAL_CE_DST_RING_BASE_LSB), 95 - HAL_SEQ_WCSS_UMAC_CE0_SRC_REG + HAL_CE_DST_RING_HP, 96 - }, 97 - .reg_size = { 98 - (HAL_SEQ_WCSS_UMAC_CE1_SRC_REG - 99 - HAL_SEQ_WCSS_UMAC_CE0_SRC_REG), 100 - (HAL_SEQ_WCSS_UMAC_CE1_SRC_REG - 101 - HAL_SEQ_WCSS_UMAC_CE0_SRC_REG), 102 - }, 103 92 .max_size = HAL_CE_SRC_RING_BASE_MSB_RING_SIZE, 104 93 }, 105 94 { /* CE_DST */ ··· 97 108 .entry_size = sizeof(struct hal_ce_srng_dest_desc) >> 2, 98 109 .lmac_ring = false, 99 110 .ring_dir = HAL_SRNG_DIR_SRC, 100 - .reg_start = { 101 - (HAL_SEQ_WCSS_UMAC_CE0_DST_REG + 102 - HAL_CE_DST_RING_BASE_LSB), 103 - HAL_SEQ_WCSS_UMAC_CE0_DST_REG + HAL_CE_DST_RING_HP, 104 - }, 105 - .reg_size = { 106 - (HAL_SEQ_WCSS_UMAC_CE1_DST_REG - 107 - HAL_SEQ_WCSS_UMAC_CE0_DST_REG), 108 - (HAL_SEQ_WCSS_UMAC_CE1_DST_REG - 109 - HAL_SEQ_WCSS_UMAC_CE0_DST_REG), 110 - }, 111 111 .max_size = HAL_CE_DST_RING_BASE_MSB_RING_SIZE, 112 112 }, 113 113 { /* CE_DST_STATUS */ ··· 105 127 .entry_size = sizeof(struct hal_ce_srng_dst_status_desc) >> 2, 106 128 .lmac_ring = false, 107 129 .ring_dir = HAL_SRNG_DIR_DST, 108 - .reg_start = { 109 - (HAL_SEQ_WCSS_UMAC_CE0_DST_REG + 110 - HAL_CE_DST_STATUS_RING_BASE_LSB), 111 - (HAL_SEQ_WCSS_UMAC_CE0_DST_REG + 112 - HAL_CE_DST_STATUS_RING_HP), 113 - }, 114 - .reg_size = { 115 - (HAL_SEQ_WCSS_UMAC_CE1_DST_REG - 116 - HAL_SEQ_WCSS_UMAC_CE0_DST_REG), 117 - (HAL_SEQ_WCSS_UMAC_CE1_DST_REG - 118 - HAL_SEQ_WCSS_UMAC_CE0_DST_REG), 119 - }, 120 130 .max_size = HAL_CE_DST_STATUS_RING_BASE_MSB_RING_SIZE, 121 131 }, 122 132 { /* WBM_IDLE_LINK */ ··· 113 147 .entry_size = sizeof(struct hal_wbm_link_desc) >> 2, 114 148 .lmac_ring = false, 115 149 .ring_dir = HAL_SRNG_DIR_SRC, 116 - .reg_start = { 117 - (HAL_SEQ_WCSS_UMAC_WBM_REG + 118 - HAL_WBM_IDLE_LINK_RING_BASE_LSB), 119 - (HAL_SEQ_WCSS_UMAC_WBM_REG + HAL_WBM_IDLE_LINK_RING_HP), 120 - }, 121 150 .max_size = HAL_WBM_IDLE_LINK_RING_BASE_MSB_RING_SIZE, 122 151 }, 123 152 { /* SW2WBM_RELEASE */ ··· 121 160 .entry_size = sizeof(struct hal_wbm_release_ring) >> 2, 122 161 .lmac_ring = false, 123 162 .ring_dir = HAL_SRNG_DIR_SRC, 124 - .reg_start = { 125 - (HAL_SEQ_WCSS_UMAC_WBM_REG + 126 - HAL_WBM_RELEASE_RING_BASE_LSB), 127 - (HAL_SEQ_WCSS_UMAC_WBM_REG + HAL_WBM_RELEASE_RING_HP), 128 - }, 129 163 .max_size = HAL_SW2WBM_RELEASE_RING_BASE_MSB_RING_SIZE, 130 164 }, 131 165 { /* WBM2SW_RELEASE */ ··· 129 173 .entry_size = sizeof(struct hal_wbm_release_ring) >> 2, 130 174 .lmac_ring = false, 131 175 .ring_dir = HAL_SRNG_DIR_DST, 132 - .reg_start = { 133 - (HAL_SEQ_WCSS_UMAC_WBM_REG + 134 - HAL_WBM0_RELEASE_RING_BASE_LSB), 135 - (HAL_SEQ_WCSS_UMAC_WBM_REG + HAL_WBM0_RELEASE_RING_HP), 136 - }, 137 - .reg_size = { 138 - (HAL_WBM1_RELEASE_RING_BASE_LSB - 139 - HAL_WBM0_RELEASE_RING_BASE_LSB), 140 - (HAL_WBM1_RELEASE_RING_HP - HAL_WBM0_RELEASE_RING_HP), 141 - }, 142 176 .max_size = HAL_WBM2SW_RELEASE_RING_BASE_MSB_RING_SIZE, 143 177 }, 144 178 { /* RXDMA_BUF */ ··· 901 955 /* Enable the SRNG */ 902 956 ath11k_hif_write32(ab, 903 957 HAL_SEQ_WCSS_UMAC_WBM_REG + 904 - HAL_WBM_IDLE_LINK_RING_MISC_ADDR, 0x40); 958 + HAL_WBM_IDLE_LINK_RING_MISC_ADDR(ab), 0x40); 905 959 } 906 960 907 961 int ath11k_hal_srng_setup(struct ath11k_base *ab, enum hal_ring_type type, ··· 1179 1233 s = &hal->srng_config[HAL_TCL_STATUS]; 1180 1234 s->reg_start[0] = HAL_SEQ_WCSS_UMAC_TCL_REG + HAL_TCL_STATUS_RING_BASE_LSB(ab); 1181 1235 s->reg_start[1] = HAL_SEQ_WCSS_UMAC_TCL_REG + HAL_TCL_STATUS_RING_HP; 1236 + 1237 + s = &hal->srng_config[HAL_CE_SRC]; 1238 + s->reg_start[0] = HAL_SEQ_WCSS_UMAC_CE0_SRC_REG(ab) + HAL_CE_DST_RING_BASE_LSB; 1239 + s->reg_start[1] = HAL_SEQ_WCSS_UMAC_CE0_SRC_REG(ab) + HAL_CE_DST_RING_HP; 1240 + s->reg_size[0] = HAL_SEQ_WCSS_UMAC_CE1_SRC_REG(ab) - 1241 + HAL_SEQ_WCSS_UMAC_CE0_SRC_REG(ab); 1242 + s->reg_size[1] = HAL_SEQ_WCSS_UMAC_CE1_SRC_REG(ab) - 1243 + HAL_SEQ_WCSS_UMAC_CE0_SRC_REG(ab); 1244 + 1245 + s = &hal->srng_config[HAL_CE_DST]; 1246 + s->reg_start[0] = HAL_SEQ_WCSS_UMAC_CE0_DST_REG(ab) + HAL_CE_DST_RING_BASE_LSB; 1247 + s->reg_start[1] = HAL_SEQ_WCSS_UMAC_CE0_DST_REG(ab) + HAL_CE_DST_RING_HP; 1248 + s->reg_size[0] = HAL_SEQ_WCSS_UMAC_CE1_DST_REG(ab) - 1249 + HAL_SEQ_WCSS_UMAC_CE0_DST_REG(ab); 1250 + s->reg_size[1] = HAL_SEQ_WCSS_UMAC_CE1_DST_REG(ab) - 1251 + HAL_SEQ_WCSS_UMAC_CE0_DST_REG(ab); 1252 + 1253 + s = &hal->srng_config[HAL_CE_DST_STATUS]; 1254 + s->reg_start[0] = HAL_SEQ_WCSS_UMAC_CE0_DST_REG(ab) + 1255 + HAL_CE_DST_STATUS_RING_BASE_LSB; 1256 + s->reg_start[1] = HAL_SEQ_WCSS_UMAC_CE0_DST_REG(ab) + HAL_CE_DST_STATUS_RING_HP; 1257 + s->reg_size[0] = HAL_SEQ_WCSS_UMAC_CE1_DST_REG(ab) - 1258 + HAL_SEQ_WCSS_UMAC_CE0_DST_REG(ab); 1259 + s->reg_size[1] = HAL_SEQ_WCSS_UMAC_CE1_DST_REG(ab) - 1260 + HAL_SEQ_WCSS_UMAC_CE0_DST_REG(ab); 1261 + 1262 + s = &hal->srng_config[HAL_WBM_IDLE_LINK]; 1263 + s->reg_start[0] = HAL_SEQ_WCSS_UMAC_WBM_REG + HAL_WBM_IDLE_LINK_RING_BASE_LSB(ab); 1264 + s->reg_start[1] = HAL_SEQ_WCSS_UMAC_WBM_REG + HAL_WBM_IDLE_LINK_RING_HP; 1265 + 1266 + s = &hal->srng_config[HAL_SW2WBM_RELEASE]; 1267 + s->reg_start[0] = HAL_SEQ_WCSS_UMAC_WBM_REG + HAL_WBM_RELEASE_RING_BASE_LSB(ab); 1268 + s->reg_start[1] = HAL_SEQ_WCSS_UMAC_WBM_REG + HAL_WBM_RELEASE_RING_HP; 1269 + 1270 + s = &hal->srng_config[HAL_WBM2SW_RELEASE]; 1271 + s->reg_start[0] = HAL_SEQ_WCSS_UMAC_WBM_REG + HAL_WBM0_RELEASE_RING_BASE_LSB(ab); 1272 + s->reg_start[1] = HAL_SEQ_WCSS_UMAC_WBM_REG + HAL_WBM0_RELEASE_RING_HP; 1273 + s->reg_size[0] = HAL_WBM1_RELEASE_RING_BASE_LSB(ab) - 1274 + HAL_WBM0_RELEASE_RING_BASE_LSB(ab); 1275 + s->reg_size[1] = HAL_WBM1_RELEASE_RING_HP - HAL_WBM0_RELEASE_RING_HP; 1182 1276 1183 1277 return 0; 1184 1278 }
+22 -11
drivers/net/wireless/ath/ath11k/hal.h
··· 39 39 #define HAL_SHADOW_REG(x) (HAL_SHADOW_BASE_ADDR + (4 * (x))) 40 40 41 41 /* WCSS Relative address */ 42 + #define HAL_SEQ_WCSS_UMAC_OFFSET 0x00a00000 42 43 #define HAL_SEQ_WCSS_UMAC_REO_REG 0x00a38000 43 44 #define HAL_SEQ_WCSS_UMAC_TCL_REG 0x00a44000 44 - #define HAL_SEQ_WCSS_UMAC_CE0_SRC_REG 0x00a00000 45 - #define HAL_SEQ_WCSS_UMAC_CE0_DST_REG 0x00a01000 46 - #define HAL_SEQ_WCSS_UMAC_CE1_SRC_REG 0x00a02000 47 - #define HAL_SEQ_WCSS_UMAC_CE1_DST_REG 0x00a03000 45 + #define HAL_SEQ_WCSS_UMAC_CE0_SRC_REG(x) \ 46 + (ab->hw_params.regs->hal_seq_wcss_umac_ce0_src_reg) 47 + #define HAL_SEQ_WCSS_UMAC_CE0_DST_REG(x) \ 48 + (ab->hw_params.regs->hal_seq_wcss_umac_ce0_dst_reg) 49 + #define HAL_SEQ_WCSS_UMAC_CE1_SRC_REG(x) \ 50 + (ab->hw_params.regs->hal_seq_wcss_umac_ce1_src_reg) 51 + #define HAL_SEQ_WCSS_UMAC_CE1_DST_REG(x) \ 52 + (ab->hw_params.regs->hal_seq_wcss_umac_ce1_dst_reg) 48 53 #define HAL_SEQ_WCSS_UMAC_WBM_REG 0x00a34000 54 + 55 + #define HAL_CE_WFSS_CE_REG_BASE 0x01b80000 56 + #define HAL_WLAON_REG_BASE 0x01f80000 49 57 50 58 /* SW2TCL(x) R0 ring configuration address */ 51 59 #define HAL_TCL1_RING_CMN_CTRL_REG 0x00000014 ··· 205 197 #define HAL_REO_STATUS_HP(ab) ab->hw_params.regs->hal_reo_status_hp 206 198 207 199 /* WBM Idle R0 address */ 208 - #define HAL_WBM_IDLE_LINK_RING_BASE_LSB 0x00000860 209 - #define HAL_WBM_IDLE_LINK_RING_MISC_ADDR 0x00000870 200 + #define HAL_WBM_IDLE_LINK_RING_BASE_LSB(x) \ 201 + (ab->hw_params.regs->hal_wbm_idle_link_ring_base_lsb) 202 + #define HAL_WBM_IDLE_LINK_RING_MISC_ADDR(x) \ 203 + (ab->hw_params.regs->hal_wbm_idle_link_ring_misc) 210 204 #define HAL_WBM_R0_IDLE_LIST_CONTROL_ADDR 0x00000048 211 205 #define HAL_WBM_R0_IDLE_LIST_SIZE_ADDR 0x0000004c 212 206 #define HAL_WBM_SCATTERED_RING_BASE_LSB 0x00000058 ··· 223 213 #define HAL_WBM_IDLE_LINK_RING_HP 0x000030b0 224 214 225 215 /* SW2WBM R0 release address */ 226 - #define HAL_WBM_RELEASE_RING_BASE_LSB 0x000001d8 216 + #define HAL_WBM_RELEASE_RING_BASE_LSB(x) \ 217 + (ab->hw_params.regs->hal_wbm_release_ring_base_lsb) 227 218 228 219 /* SW2WBM R2 release address */ 229 220 #define HAL_WBM_RELEASE_RING_HP 0x00003018 230 221 231 222 /* WBM2SW R0 release address */ 232 - #define HAL_WBM0_RELEASE_RING_BASE_LSB 0x00000910 233 - #define HAL_WBM1_RELEASE_RING_BASE_LSB 0x00000968 223 + #define HAL_WBM0_RELEASE_RING_BASE_LSB(x) \ 224 + (ab->hw_params.regs->hal_wbm0_release_ring_base_lsb) 225 + #define HAL_WBM1_RELEASE_RING_BASE_LSB(x) \ 226 + (ab->hw_params.regs->hal_wbm1_release_ring_base_lsb) 234 227 235 228 /* WBM2SW R2 release address */ 236 229 #define HAL_WBM0_RELEASE_RING_HP 0x000030c0 ··· 315 302 #define HAL_SW2WBM_RELEASE_RING_BASE_MSB_RING_SIZE 0x0000ffff 316 303 #define HAL_WBM2SW_RELEASE_RING_BASE_MSB_RING_SIZE 0x000fffff 317 304 #define HAL_RXDMA_RING_MAX_SIZE 0x0000ffff 318 - 319 - #define HAL_RX_DESC_SIZE (sizeof(struct hal_rx_desc)) 320 305 321 306 /* Add any other errors here and return them in 322 307 * ath11k_hal_rx_desc_get_err().
+7 -6
drivers/net/wireless/ath/ath11k/hal_desc.h
··· 949 949 #define HAL_TCL_DATA_CMD_INFO1_TO_FW BIT(21) 950 950 #define HAL_TCL_DATA_CMD_INFO1_PKT_OFFSET GENMASK(31, 23) 951 951 952 - #define HAL_TCL_DATA_CMD_INFO2_BUF_TIMESTAMP GENMASK(18, 0) 953 - #define HAL_TCL_DATA_CMD_INFO2_BUF_T_VALID BIT(19) 954 - #define HAL_TCL_DATA_CMD_INFO2_MESH_ENABLE BIT(20) 955 - #define HAL_TCL_DATA_CMD_INFO2_TID_OVERWRITE BIT(21) 956 - #define HAL_TCL_DATA_CMD_INFO2_TID GENMASK(25, 22) 957 - #define HAL_TCL_DATA_CMD_INFO2_LMAC_ID GENMASK(27, 26) 952 + #define HAL_TCL_DATA_CMD_INFO2_BUF_TIMESTAMP GENMASK(18, 0) 953 + #define HAL_TCL_DATA_CMD_INFO2_BUF_T_VALID BIT(19) 954 + #define HAL_IPQ8074_TCL_DATA_CMD_INFO2_MESH_ENABLE BIT(20) 955 + #define HAL_TCL_DATA_CMD_INFO2_TID_OVERWRITE BIT(21) 956 + #define HAL_TCL_DATA_CMD_INFO2_TID GENMASK(25, 22) 957 + #define HAL_TCL_DATA_CMD_INFO2_LMAC_ID GENMASK(27, 26) 958 958 959 959 #define HAL_TCL_DATA_CMD_INFO3_DSCP_TID_TABLE_IDX GENMASK(5, 0) 960 960 #define HAL_TCL_DATA_CMD_INFO3_SEARCH_INDEX GENMASK(25, 6) 961 961 #define HAL_TCL_DATA_CMD_INFO3_CACHE_SET_NUM GENMASK(29, 26) 962 + #define HAL_QCN9074_TCL_DATA_CMD_INFO3_MESH_ENABLE GENMASK(31, 30) 962 963 963 964 #define HAL_TCL_DATA_CMD_INFO4_RING_ID GENMASK(27, 20) 964 965 #define HAL_TCL_DATA_CMD_INFO4_LOOPING_COUNT GENMASK(31, 28)
+3
drivers/net/wireless/ath/ath11k/hal_tx.c
··· 75 75 FIELD_PREP(HAL_TCL_DATA_CMD_INFO3_CACHE_SET_NUM, 76 76 ti->bss_ast_hash); 77 77 tcl_cmd->info4 = 0; 78 + 79 + if (ti->enable_mesh) 80 + ab->hw_params.hw_ops->tx_mesh_enable(ab, tcl_cmd); 78 81 } 79 82 80 83 void ath11k_hal_tx_set_dscp_tid_map(struct ath11k_base *ab, int id)
+1
drivers/net/wireless/ath/ath11k/hal_tx.h
··· 34 34 u8 search_type; /* %HAL_TX_ADDR_SEARCH_ */ 35 35 u8 lmac_id; 36 36 u8 dscp_tid_tbl_idx; 37 + bool enable_mesh; 37 38 }; 38 39 39 40 /* TODO: Check if the actual desc macros can be used instead */
+10
drivers/net/wireless/ath/ath11k/hif.h
··· 28 28 u32 *msi_addr_hi); 29 29 void (*ce_irq_enable)(struct ath11k_base *ab); 30 30 void (*ce_irq_disable)(struct ath11k_base *ab); 31 + void (*get_ce_msi_idx)(struct ath11k_base *ab, u32 ce_id, u32 *msi_idx); 31 32 }; 32 33 33 34 static inline void ath11k_hif_ce_irq_enable(struct ath11k_base *ab) ··· 124 123 return; 125 124 126 125 ab->hif.ops->get_msi_address(ab, msi_addr_lo, msi_addr_hi); 126 + } 127 + 128 + static inline void ath11k_get_ce_msi_idx(struct ath11k_base *ab, u32 ce_id, 129 + u32 *msi_data_idx) 130 + { 131 + if (ab->hif.ops->get_ce_msi_idx) 132 + ab->hif.ops->get_ce_msi_idx(ab, ce_id, msi_data_idx); 133 + else 134 + *msi_data_idx = ce_id; 127 135 } 128 136 #endif /* _HIF_H_ */
+796
drivers/net/wireless/ath/ath11k/hw.c
··· 31 31 return pdev_idx; 32 32 } 33 33 34 + static void ath11k_hw_ipq8074_tx_mesh_enable(struct ath11k_base *ab, 35 + struct hal_tcl_data_cmd *tcl_cmd) 36 + { 37 + tcl_cmd->info2 |= FIELD_PREP(HAL_IPQ8074_TCL_DATA_CMD_INFO2_MESH_ENABLE, 38 + true); 39 + } 40 + 41 + static void ath11k_hw_qcn9074_tx_mesh_enable(struct ath11k_base *ab, 42 + struct hal_tcl_data_cmd *tcl_cmd) 43 + { 44 + tcl_cmd->info3 |= FIELD_PREP(HAL_QCN9074_TCL_DATA_CMD_INFO3_MESH_ENABLE, 45 + true); 46 + } 47 + 34 48 static void ath11k_init_wmi_config_qca6390(struct ath11k_base *ab, 35 49 struct target_resource_config *config) 36 50 { ··· 169 155 return mac_id; 170 156 } 171 157 158 + static bool ath11k_hw_ipq8074_rx_desc_get_first_msdu(struct hal_rx_desc *desc) 159 + { 160 + return !!FIELD_GET(RX_MSDU_END_INFO2_FIRST_MSDU, 161 + __le32_to_cpu(desc->u.ipq8074.msdu_end.info2)); 162 + } 163 + 164 + static bool ath11k_hw_ipq8074_rx_desc_get_last_msdu(struct hal_rx_desc *desc) 165 + { 166 + return !!FIELD_GET(RX_MSDU_END_INFO2_LAST_MSDU, 167 + __le32_to_cpu(desc->u.ipq8074.msdu_end.info2)); 168 + } 169 + 170 + static u8 ath11k_hw_ipq8074_rx_desc_get_l3_pad_bytes(struct hal_rx_desc *desc) 171 + { 172 + return FIELD_GET(RX_MSDU_END_INFO2_L3_HDR_PADDING, 173 + __le32_to_cpu(desc->u.ipq8074.msdu_end.info2)); 174 + } 175 + 176 + static u8 *ath11k_hw_ipq8074_rx_desc_get_hdr_status(struct hal_rx_desc *desc) 177 + { 178 + return desc->u.ipq8074.hdr_status; 179 + } 180 + 181 + static bool ath11k_hw_ipq8074_rx_desc_encrypt_valid(struct hal_rx_desc *desc) 182 + { 183 + return __le32_to_cpu(desc->u.ipq8074.mpdu_start.info1) & 184 + RX_MPDU_START_INFO1_ENCRYPT_INFO_VALID; 185 + } 186 + 187 + static u32 ath11k_hw_ipq8074_rx_desc_get_encrypt_type(struct hal_rx_desc *desc) 188 + { 189 + return FIELD_GET(RX_MPDU_START_INFO2_ENC_TYPE, 190 + __le32_to_cpu(desc->u.ipq8074.mpdu_start.info2)); 191 + } 192 + 193 + static u8 ath11k_hw_ipq8074_rx_desc_get_decap_type(struct hal_rx_desc *desc) 194 + { 195 + return FIELD_GET(RX_MSDU_START_INFO2_DECAP_FORMAT, 196 + __le32_to_cpu(desc->u.ipq8074.msdu_start.info2)); 197 + } 198 + 199 + static u8 ath11k_hw_ipq8074_rx_desc_get_mesh_ctl(struct hal_rx_desc *desc) 200 + { 201 + return FIELD_GET(RX_MSDU_START_INFO2_MESH_CTRL_PRESENT, 202 + __le32_to_cpu(desc->u.ipq8074.msdu_start.info2)); 203 + } 204 + 205 + static bool ath11k_hw_ipq8074_rx_desc_get_mpdu_seq_ctl_vld(struct hal_rx_desc *desc) 206 + { 207 + return !!FIELD_GET(RX_MPDU_START_INFO1_MPDU_SEQ_CTRL_VALID, 208 + __le32_to_cpu(desc->u.ipq8074.mpdu_start.info1)); 209 + } 210 + 211 + static bool ath11k_hw_ipq8074_rx_desc_get_mpdu_fc_valid(struct hal_rx_desc *desc) 212 + { 213 + return !!FIELD_GET(RX_MPDU_START_INFO1_MPDU_FCTRL_VALID, 214 + __le32_to_cpu(desc->u.ipq8074.mpdu_start.info1)); 215 + } 216 + 217 + static u16 ath11k_hw_ipq8074_rx_desc_get_mpdu_start_seq_no(struct hal_rx_desc *desc) 218 + { 219 + return FIELD_GET(RX_MPDU_START_INFO1_MPDU_SEQ_NUM, 220 + __le32_to_cpu(desc->u.ipq8074.mpdu_start.info1)); 221 + } 222 + 223 + static u16 ath11k_hw_ipq8074_rx_desc_get_msdu_len(struct hal_rx_desc *desc) 224 + { 225 + return FIELD_GET(RX_MSDU_START_INFO1_MSDU_LENGTH, 226 + __le32_to_cpu(desc->u.ipq8074.msdu_start.info1)); 227 + } 228 + 229 + static u8 ath11k_hw_ipq8074_rx_desc_get_msdu_sgi(struct hal_rx_desc *desc) 230 + { 231 + return FIELD_GET(RX_MSDU_START_INFO3_SGI, 232 + __le32_to_cpu(desc->u.ipq8074.msdu_start.info3)); 233 + } 234 + 235 + static u8 ath11k_hw_ipq8074_rx_desc_get_msdu_rate_mcs(struct hal_rx_desc *desc) 236 + { 237 + return FIELD_GET(RX_MSDU_START_INFO3_RATE_MCS, 238 + __le32_to_cpu(desc->u.ipq8074.msdu_start.info3)); 239 + } 240 + 241 + static u8 ath11k_hw_ipq8074_rx_desc_get_msdu_rx_bw(struct hal_rx_desc *desc) 242 + { 243 + return FIELD_GET(RX_MSDU_START_INFO3_RECV_BW, 244 + __le32_to_cpu(desc->u.ipq8074.msdu_start.info3)); 245 + } 246 + 247 + static u32 ath11k_hw_ipq8074_rx_desc_get_msdu_freq(struct hal_rx_desc *desc) 248 + { 249 + return __le32_to_cpu(desc->u.ipq8074.msdu_start.phy_meta_data); 250 + } 251 + 252 + static u8 ath11k_hw_ipq8074_rx_desc_get_msdu_pkt_type(struct hal_rx_desc *desc) 253 + { 254 + return FIELD_GET(RX_MSDU_START_INFO3_PKT_TYPE, 255 + __le32_to_cpu(desc->u.ipq8074.msdu_start.info3)); 256 + } 257 + 258 + static u8 ath11k_hw_ipq8074_rx_desc_get_msdu_nss(struct hal_rx_desc *desc) 259 + { 260 + return FIELD_GET(RX_MSDU_START_INFO3_MIMO_SS_BITMAP, 261 + __le32_to_cpu(desc->u.ipq8074.msdu_start.info3)); 262 + } 263 + 264 + static u8 ath11k_hw_ipq8074_rx_desc_get_mpdu_tid(struct hal_rx_desc *desc) 265 + { 266 + return FIELD_GET(RX_MPDU_START_INFO2_TID, 267 + __le32_to_cpu(desc->u.ipq8074.mpdu_start.info2)); 268 + } 269 + 270 + static u16 ath11k_hw_ipq8074_rx_desc_get_mpdu_peer_id(struct hal_rx_desc *desc) 271 + { 272 + return __le16_to_cpu(desc->u.ipq8074.mpdu_start.sw_peer_id); 273 + } 274 + 275 + static void ath11k_hw_ipq8074_rx_desc_copy_attn_end(struct hal_rx_desc *fdesc, 276 + struct hal_rx_desc *ldesc) 277 + { 278 + memcpy((u8 *)&fdesc->u.ipq8074.msdu_end, (u8 *)&ldesc->u.ipq8074.msdu_end, 279 + sizeof(struct rx_msdu_end_ipq8074)); 280 + memcpy((u8 *)&fdesc->u.ipq8074.attention, (u8 *)&ldesc->u.ipq8074.attention, 281 + sizeof(struct rx_attention)); 282 + memcpy((u8 *)&fdesc->u.ipq8074.mpdu_end, (u8 *)&ldesc->u.ipq8074.mpdu_end, 283 + sizeof(struct rx_mpdu_end)); 284 + } 285 + 286 + static u32 ath11k_hw_ipq8074_rx_desc_get_mpdu_start_tag(struct hal_rx_desc *desc) 287 + { 288 + return FIELD_GET(HAL_TLV_HDR_TAG, 289 + __le32_to_cpu(desc->u.ipq8074.mpdu_start_tag)); 290 + } 291 + 292 + static u32 ath11k_hw_ipq8074_rx_desc_get_mpdu_ppdu_id(struct hal_rx_desc *desc) 293 + { 294 + return __le16_to_cpu(desc->u.ipq8074.mpdu_start.phy_ppdu_id); 295 + } 296 + 297 + static void ath11k_hw_ipq8074_rx_desc_set_msdu_len(struct hal_rx_desc *desc, u16 len) 298 + { 299 + u32 info = __le32_to_cpu(desc->u.ipq8074.msdu_start.info1); 300 + 301 + info &= ~RX_MSDU_START_INFO1_MSDU_LENGTH; 302 + info |= FIELD_PREP(RX_MSDU_START_INFO1_MSDU_LENGTH, len); 303 + 304 + desc->u.ipq8074.msdu_start.info1 = __cpu_to_le32(info); 305 + } 306 + 307 + static 308 + struct rx_attention *ath11k_hw_ipq8074_rx_desc_get_attention(struct hal_rx_desc *desc) 309 + { 310 + return &desc->u.ipq8074.attention; 311 + } 312 + 313 + static u8 *ath11k_hw_ipq8074_rx_desc_get_msdu_payload(struct hal_rx_desc *desc) 314 + { 315 + return &desc->u.ipq8074.msdu_payload[0]; 316 + } 317 + 318 + static bool ath11k_hw_qcn9074_rx_desc_get_first_msdu(struct hal_rx_desc *desc) 319 + { 320 + return !!FIELD_GET(RX_MSDU_END_INFO4_FIRST_MSDU, 321 + __le16_to_cpu(desc->u.qcn9074.msdu_end.info4)); 322 + } 323 + 324 + static bool ath11k_hw_qcn9074_rx_desc_get_last_msdu(struct hal_rx_desc *desc) 325 + { 326 + return !!FIELD_GET(RX_MSDU_END_INFO4_LAST_MSDU, 327 + __le16_to_cpu(desc->u.qcn9074.msdu_end.info4)); 328 + } 329 + 330 + static u8 ath11k_hw_qcn9074_rx_desc_get_l3_pad_bytes(struct hal_rx_desc *desc) 331 + { 332 + return FIELD_GET(RX_MSDU_END_INFO4_L3_HDR_PADDING, 333 + __le16_to_cpu(desc->u.qcn9074.msdu_end.info4)); 334 + } 335 + 336 + static u8 *ath11k_hw_qcn9074_rx_desc_get_hdr_status(struct hal_rx_desc *desc) 337 + { 338 + return desc->u.qcn9074.hdr_status; 339 + } 340 + 341 + static bool ath11k_hw_qcn9074_rx_desc_encrypt_valid(struct hal_rx_desc *desc) 342 + { 343 + return __le32_to_cpu(desc->u.qcn9074.mpdu_start.info11) & 344 + RX_MPDU_START_INFO11_ENCRYPT_INFO_VALID; 345 + } 346 + 347 + static u32 ath11k_hw_qcn9074_rx_desc_get_encrypt_type(struct hal_rx_desc *desc) 348 + { 349 + return FIELD_GET(RX_MPDU_START_INFO9_ENC_TYPE, 350 + __le32_to_cpu(desc->u.qcn9074.mpdu_start.info9)); 351 + } 352 + 353 + static u8 ath11k_hw_qcn9074_rx_desc_get_decap_type(struct hal_rx_desc *desc) 354 + { 355 + return FIELD_GET(RX_MSDU_START_INFO2_DECAP_FORMAT, 356 + __le32_to_cpu(desc->u.qcn9074.msdu_start.info2)); 357 + } 358 + 359 + static u8 ath11k_hw_qcn9074_rx_desc_get_mesh_ctl(struct hal_rx_desc *desc) 360 + { 361 + return FIELD_GET(RX_MSDU_START_INFO2_MESH_CTRL_PRESENT, 362 + __le32_to_cpu(desc->u.qcn9074.msdu_start.info2)); 363 + } 364 + 365 + static bool ath11k_hw_qcn9074_rx_desc_get_mpdu_seq_ctl_vld(struct hal_rx_desc *desc) 366 + { 367 + return !!FIELD_GET(RX_MPDU_START_INFO11_MPDU_SEQ_CTRL_VALID, 368 + __le32_to_cpu(desc->u.qcn9074.mpdu_start.info11)); 369 + } 370 + 371 + static bool ath11k_hw_qcn9074_rx_desc_get_mpdu_fc_valid(struct hal_rx_desc *desc) 372 + { 373 + return !!FIELD_GET(RX_MPDU_START_INFO11_MPDU_FCTRL_VALID, 374 + __le32_to_cpu(desc->u.qcn9074.mpdu_start.info11)); 375 + } 376 + 377 + static u16 ath11k_hw_qcn9074_rx_desc_get_mpdu_start_seq_no(struct hal_rx_desc *desc) 378 + { 379 + return FIELD_GET(RX_MPDU_START_INFO11_MPDU_SEQ_NUM, 380 + __le32_to_cpu(desc->u.qcn9074.mpdu_start.info11)); 381 + } 382 + 383 + static u16 ath11k_hw_qcn9074_rx_desc_get_msdu_len(struct hal_rx_desc *desc) 384 + { 385 + return FIELD_GET(RX_MSDU_START_INFO1_MSDU_LENGTH, 386 + __le32_to_cpu(desc->u.qcn9074.msdu_start.info1)); 387 + } 388 + 389 + static u8 ath11k_hw_qcn9074_rx_desc_get_msdu_sgi(struct hal_rx_desc *desc) 390 + { 391 + return FIELD_GET(RX_MSDU_START_INFO3_SGI, 392 + __le32_to_cpu(desc->u.qcn9074.msdu_start.info3)); 393 + } 394 + 395 + static u8 ath11k_hw_qcn9074_rx_desc_get_msdu_rate_mcs(struct hal_rx_desc *desc) 396 + { 397 + return FIELD_GET(RX_MSDU_START_INFO3_RATE_MCS, 398 + __le32_to_cpu(desc->u.qcn9074.msdu_start.info3)); 399 + } 400 + 401 + static u8 ath11k_hw_qcn9074_rx_desc_get_msdu_rx_bw(struct hal_rx_desc *desc) 402 + { 403 + return FIELD_GET(RX_MSDU_START_INFO3_RECV_BW, 404 + __le32_to_cpu(desc->u.qcn9074.msdu_start.info3)); 405 + } 406 + 407 + static u32 ath11k_hw_qcn9074_rx_desc_get_msdu_freq(struct hal_rx_desc *desc) 408 + { 409 + return __le32_to_cpu(desc->u.qcn9074.msdu_start.phy_meta_data); 410 + } 411 + 412 + static u8 ath11k_hw_qcn9074_rx_desc_get_msdu_pkt_type(struct hal_rx_desc *desc) 413 + { 414 + return FIELD_GET(RX_MSDU_START_INFO3_PKT_TYPE, 415 + __le32_to_cpu(desc->u.qcn9074.msdu_start.info3)); 416 + } 417 + 418 + static u8 ath11k_hw_qcn9074_rx_desc_get_msdu_nss(struct hal_rx_desc *desc) 419 + { 420 + return FIELD_GET(RX_MSDU_START_INFO3_MIMO_SS_BITMAP, 421 + __le32_to_cpu(desc->u.qcn9074.msdu_start.info3)); 422 + } 423 + 424 + static u8 ath11k_hw_qcn9074_rx_desc_get_mpdu_tid(struct hal_rx_desc *desc) 425 + { 426 + return FIELD_GET(RX_MPDU_START_INFO9_TID, 427 + __le32_to_cpu(desc->u.qcn9074.mpdu_start.info9)); 428 + } 429 + 430 + static u16 ath11k_hw_qcn9074_rx_desc_get_mpdu_peer_id(struct hal_rx_desc *desc) 431 + { 432 + return __le16_to_cpu(desc->u.qcn9074.mpdu_start.sw_peer_id); 433 + } 434 + 435 + static void ath11k_hw_qcn9074_rx_desc_copy_attn_end(struct hal_rx_desc *fdesc, 436 + struct hal_rx_desc *ldesc) 437 + { 438 + memcpy((u8 *)&fdesc->u.qcn9074.msdu_end, (u8 *)&ldesc->u.qcn9074.msdu_end, 439 + sizeof(struct rx_msdu_end_qcn9074)); 440 + memcpy((u8 *)&fdesc->u.qcn9074.attention, (u8 *)&ldesc->u.qcn9074.attention, 441 + sizeof(struct rx_attention)); 442 + memcpy((u8 *)&fdesc->u.qcn9074.mpdu_end, (u8 *)&ldesc->u.qcn9074.mpdu_end, 443 + sizeof(struct rx_mpdu_end)); 444 + } 445 + 446 + static u32 ath11k_hw_qcn9074_rx_desc_get_mpdu_start_tag(struct hal_rx_desc *desc) 447 + { 448 + return FIELD_GET(HAL_TLV_HDR_TAG, 449 + __le32_to_cpu(desc->u.qcn9074.mpdu_start_tag)); 450 + } 451 + 452 + static u32 ath11k_hw_qcn9074_rx_desc_get_mpdu_ppdu_id(struct hal_rx_desc *desc) 453 + { 454 + return __le16_to_cpu(desc->u.qcn9074.mpdu_start.phy_ppdu_id); 455 + } 456 + 457 + static void ath11k_hw_qcn9074_rx_desc_set_msdu_len(struct hal_rx_desc *desc, u16 len) 458 + { 459 + u32 info = __le32_to_cpu(desc->u.qcn9074.msdu_start.info1); 460 + 461 + info &= ~RX_MSDU_START_INFO1_MSDU_LENGTH; 462 + info |= FIELD_PREP(RX_MSDU_START_INFO1_MSDU_LENGTH, len); 463 + 464 + desc->u.qcn9074.msdu_start.info1 = __cpu_to_le32(info); 465 + } 466 + 467 + static 468 + struct rx_attention *ath11k_hw_qcn9074_rx_desc_get_attention(struct hal_rx_desc *desc) 469 + { 470 + return &desc->u.qcn9074.attention; 471 + } 472 + 473 + static u8 *ath11k_hw_qcn9074_rx_desc_get_msdu_payload(struct hal_rx_desc *desc) 474 + { 475 + return &desc->u.qcn9074.msdu_payload[0]; 476 + } 477 + 172 478 const struct ath11k_hw_ops ipq8074_ops = { 173 479 .get_hw_mac_from_pdev_id = ath11k_hw_ipq8074_mac_from_pdev_id, 174 480 .wmi_init_config = ath11k_init_wmi_config_ipq8074, 175 481 .mac_id_to_pdev_id = ath11k_hw_mac_id_to_pdev_id_ipq8074, 176 482 .mac_id_to_srng_id = ath11k_hw_mac_id_to_srng_id_ipq8074, 483 + .tx_mesh_enable = ath11k_hw_ipq8074_tx_mesh_enable, 484 + .rx_desc_get_first_msdu = ath11k_hw_ipq8074_rx_desc_get_first_msdu, 485 + .rx_desc_get_last_msdu = ath11k_hw_ipq8074_rx_desc_get_last_msdu, 486 + .rx_desc_get_l3_pad_bytes = ath11k_hw_ipq8074_rx_desc_get_l3_pad_bytes, 487 + .rx_desc_get_hdr_status = ath11k_hw_ipq8074_rx_desc_get_hdr_status, 488 + .rx_desc_encrypt_valid = ath11k_hw_ipq8074_rx_desc_encrypt_valid, 489 + .rx_desc_get_encrypt_type = ath11k_hw_ipq8074_rx_desc_get_encrypt_type, 490 + .rx_desc_get_decap_type = ath11k_hw_ipq8074_rx_desc_get_decap_type, 491 + .rx_desc_get_mesh_ctl = ath11k_hw_ipq8074_rx_desc_get_mesh_ctl, 492 + .rx_desc_get_mpdu_seq_ctl_vld = ath11k_hw_ipq8074_rx_desc_get_mpdu_seq_ctl_vld, 493 + .rx_desc_get_mpdu_fc_valid = ath11k_hw_ipq8074_rx_desc_get_mpdu_fc_valid, 494 + .rx_desc_get_mpdu_start_seq_no = ath11k_hw_ipq8074_rx_desc_get_mpdu_start_seq_no, 495 + .rx_desc_get_msdu_len = ath11k_hw_ipq8074_rx_desc_get_msdu_len, 496 + .rx_desc_get_msdu_sgi = ath11k_hw_ipq8074_rx_desc_get_msdu_sgi, 497 + .rx_desc_get_msdu_rate_mcs = ath11k_hw_ipq8074_rx_desc_get_msdu_rate_mcs, 498 + .rx_desc_get_msdu_rx_bw = ath11k_hw_ipq8074_rx_desc_get_msdu_rx_bw, 499 + .rx_desc_get_msdu_freq = ath11k_hw_ipq8074_rx_desc_get_msdu_freq, 500 + .rx_desc_get_msdu_pkt_type = ath11k_hw_ipq8074_rx_desc_get_msdu_pkt_type, 501 + .rx_desc_get_msdu_nss = ath11k_hw_ipq8074_rx_desc_get_msdu_nss, 502 + .rx_desc_get_mpdu_tid = ath11k_hw_ipq8074_rx_desc_get_mpdu_tid, 503 + .rx_desc_get_mpdu_peer_id = ath11k_hw_ipq8074_rx_desc_get_mpdu_peer_id, 504 + .rx_desc_copy_attn_end_tlv = ath11k_hw_ipq8074_rx_desc_copy_attn_end, 505 + .rx_desc_get_mpdu_start_tag = ath11k_hw_ipq8074_rx_desc_get_mpdu_start_tag, 506 + .rx_desc_get_mpdu_ppdu_id = ath11k_hw_ipq8074_rx_desc_get_mpdu_ppdu_id, 507 + .rx_desc_set_msdu_len = ath11k_hw_ipq8074_rx_desc_set_msdu_len, 508 + .rx_desc_get_attention = ath11k_hw_ipq8074_rx_desc_get_attention, 509 + .rx_desc_get_msdu_payload = ath11k_hw_ipq8074_rx_desc_get_msdu_payload, 177 510 }; 178 511 179 512 const struct ath11k_hw_ops ipq6018_ops = { ··· 528 167 .wmi_init_config = ath11k_init_wmi_config_ipq8074, 529 168 .mac_id_to_pdev_id = ath11k_hw_mac_id_to_pdev_id_ipq8074, 530 169 .mac_id_to_srng_id = ath11k_hw_mac_id_to_srng_id_ipq8074, 170 + .tx_mesh_enable = ath11k_hw_ipq8074_tx_mesh_enable, 171 + .rx_desc_get_first_msdu = ath11k_hw_ipq8074_rx_desc_get_first_msdu, 172 + .rx_desc_get_last_msdu = ath11k_hw_ipq8074_rx_desc_get_last_msdu, 173 + .rx_desc_get_l3_pad_bytes = ath11k_hw_ipq8074_rx_desc_get_l3_pad_bytes, 174 + .rx_desc_get_hdr_status = ath11k_hw_ipq8074_rx_desc_get_hdr_status, 175 + .rx_desc_encrypt_valid = ath11k_hw_ipq8074_rx_desc_encrypt_valid, 176 + .rx_desc_get_encrypt_type = ath11k_hw_ipq8074_rx_desc_get_encrypt_type, 177 + .rx_desc_get_decap_type = ath11k_hw_ipq8074_rx_desc_get_decap_type, 178 + .rx_desc_get_mesh_ctl = ath11k_hw_ipq8074_rx_desc_get_mesh_ctl, 179 + .rx_desc_get_mpdu_seq_ctl_vld = ath11k_hw_ipq8074_rx_desc_get_mpdu_seq_ctl_vld, 180 + .rx_desc_get_mpdu_fc_valid = ath11k_hw_ipq8074_rx_desc_get_mpdu_fc_valid, 181 + .rx_desc_get_mpdu_start_seq_no = ath11k_hw_ipq8074_rx_desc_get_mpdu_start_seq_no, 182 + .rx_desc_get_msdu_len = ath11k_hw_ipq8074_rx_desc_get_msdu_len, 183 + .rx_desc_get_msdu_sgi = ath11k_hw_ipq8074_rx_desc_get_msdu_sgi, 184 + .rx_desc_get_msdu_rate_mcs = ath11k_hw_ipq8074_rx_desc_get_msdu_rate_mcs, 185 + .rx_desc_get_msdu_rx_bw = ath11k_hw_ipq8074_rx_desc_get_msdu_rx_bw, 186 + .rx_desc_get_msdu_freq = ath11k_hw_ipq8074_rx_desc_get_msdu_freq, 187 + .rx_desc_get_msdu_pkt_type = ath11k_hw_ipq8074_rx_desc_get_msdu_pkt_type, 188 + .rx_desc_get_msdu_nss = ath11k_hw_ipq8074_rx_desc_get_msdu_nss, 189 + .rx_desc_get_mpdu_tid = ath11k_hw_ipq8074_rx_desc_get_mpdu_tid, 190 + .rx_desc_get_mpdu_peer_id = ath11k_hw_ipq8074_rx_desc_get_mpdu_peer_id, 191 + .rx_desc_copy_attn_end_tlv = ath11k_hw_ipq8074_rx_desc_copy_attn_end, 192 + .rx_desc_get_mpdu_start_tag = ath11k_hw_ipq8074_rx_desc_get_mpdu_start_tag, 193 + .rx_desc_get_mpdu_ppdu_id = ath11k_hw_ipq8074_rx_desc_get_mpdu_ppdu_id, 194 + .rx_desc_set_msdu_len = ath11k_hw_ipq8074_rx_desc_set_msdu_len, 195 + .rx_desc_get_attention = ath11k_hw_ipq8074_rx_desc_get_attention, 196 + .rx_desc_get_msdu_payload = ath11k_hw_ipq8074_rx_desc_get_msdu_payload, 531 197 }; 532 198 533 199 const struct ath11k_hw_ops qca6390_ops = { ··· 562 174 .wmi_init_config = ath11k_init_wmi_config_qca6390, 563 175 .mac_id_to_pdev_id = ath11k_hw_mac_id_to_pdev_id_qca6390, 564 176 .mac_id_to_srng_id = ath11k_hw_mac_id_to_srng_id_qca6390, 177 + .tx_mesh_enable = ath11k_hw_ipq8074_tx_mesh_enable, 178 + .rx_desc_get_first_msdu = ath11k_hw_ipq8074_rx_desc_get_first_msdu, 179 + .rx_desc_get_last_msdu = ath11k_hw_ipq8074_rx_desc_get_last_msdu, 180 + .rx_desc_get_l3_pad_bytes = ath11k_hw_ipq8074_rx_desc_get_l3_pad_bytes, 181 + .rx_desc_get_hdr_status = ath11k_hw_ipq8074_rx_desc_get_hdr_status, 182 + .rx_desc_encrypt_valid = ath11k_hw_ipq8074_rx_desc_encrypt_valid, 183 + .rx_desc_get_encrypt_type = ath11k_hw_ipq8074_rx_desc_get_encrypt_type, 184 + .rx_desc_get_decap_type = ath11k_hw_ipq8074_rx_desc_get_decap_type, 185 + .rx_desc_get_mesh_ctl = ath11k_hw_ipq8074_rx_desc_get_mesh_ctl, 186 + .rx_desc_get_mpdu_seq_ctl_vld = ath11k_hw_ipq8074_rx_desc_get_mpdu_seq_ctl_vld, 187 + .rx_desc_get_mpdu_fc_valid = ath11k_hw_ipq8074_rx_desc_get_mpdu_fc_valid, 188 + .rx_desc_get_mpdu_start_seq_no = ath11k_hw_ipq8074_rx_desc_get_mpdu_start_seq_no, 189 + .rx_desc_get_msdu_len = ath11k_hw_ipq8074_rx_desc_get_msdu_len, 190 + .rx_desc_get_msdu_sgi = ath11k_hw_ipq8074_rx_desc_get_msdu_sgi, 191 + .rx_desc_get_msdu_rate_mcs = ath11k_hw_ipq8074_rx_desc_get_msdu_rate_mcs, 192 + .rx_desc_get_msdu_rx_bw = ath11k_hw_ipq8074_rx_desc_get_msdu_rx_bw, 193 + .rx_desc_get_msdu_freq = ath11k_hw_ipq8074_rx_desc_get_msdu_freq, 194 + .rx_desc_get_msdu_pkt_type = ath11k_hw_ipq8074_rx_desc_get_msdu_pkt_type, 195 + .rx_desc_get_msdu_nss = ath11k_hw_ipq8074_rx_desc_get_msdu_nss, 196 + .rx_desc_get_mpdu_tid = ath11k_hw_ipq8074_rx_desc_get_mpdu_tid, 197 + .rx_desc_get_mpdu_peer_id = ath11k_hw_ipq8074_rx_desc_get_mpdu_peer_id, 198 + .rx_desc_copy_attn_end_tlv = ath11k_hw_ipq8074_rx_desc_copy_attn_end, 199 + .rx_desc_get_mpdu_start_tag = ath11k_hw_ipq8074_rx_desc_get_mpdu_start_tag, 200 + .rx_desc_get_mpdu_ppdu_id = ath11k_hw_ipq8074_rx_desc_get_mpdu_ppdu_id, 201 + .rx_desc_set_msdu_len = ath11k_hw_ipq8074_rx_desc_set_msdu_len, 202 + .rx_desc_get_attention = ath11k_hw_ipq8074_rx_desc_get_attention, 203 + .rx_desc_get_msdu_payload = ath11k_hw_ipq8074_rx_desc_get_msdu_payload, 204 + }; 205 + 206 + const struct ath11k_hw_ops qcn9074_ops = { 207 + .get_hw_mac_from_pdev_id = ath11k_hw_ipq6018_mac_from_pdev_id, 208 + .wmi_init_config = ath11k_init_wmi_config_ipq8074, 209 + .mac_id_to_pdev_id = ath11k_hw_mac_id_to_pdev_id_ipq8074, 210 + .mac_id_to_srng_id = ath11k_hw_mac_id_to_srng_id_ipq8074, 211 + .tx_mesh_enable = ath11k_hw_qcn9074_tx_mesh_enable, 212 + .rx_desc_get_first_msdu = ath11k_hw_qcn9074_rx_desc_get_first_msdu, 213 + .rx_desc_get_last_msdu = ath11k_hw_qcn9074_rx_desc_get_last_msdu, 214 + .rx_desc_get_l3_pad_bytes = ath11k_hw_qcn9074_rx_desc_get_l3_pad_bytes, 215 + .rx_desc_get_hdr_status = ath11k_hw_qcn9074_rx_desc_get_hdr_status, 216 + .rx_desc_encrypt_valid = ath11k_hw_qcn9074_rx_desc_encrypt_valid, 217 + .rx_desc_get_encrypt_type = ath11k_hw_qcn9074_rx_desc_get_encrypt_type, 218 + .rx_desc_get_decap_type = ath11k_hw_qcn9074_rx_desc_get_decap_type, 219 + .rx_desc_get_mesh_ctl = ath11k_hw_qcn9074_rx_desc_get_mesh_ctl, 220 + .rx_desc_get_mpdu_seq_ctl_vld = ath11k_hw_qcn9074_rx_desc_get_mpdu_seq_ctl_vld, 221 + .rx_desc_get_mpdu_fc_valid = ath11k_hw_qcn9074_rx_desc_get_mpdu_fc_valid, 222 + .rx_desc_get_mpdu_start_seq_no = ath11k_hw_qcn9074_rx_desc_get_mpdu_start_seq_no, 223 + .rx_desc_get_msdu_len = ath11k_hw_qcn9074_rx_desc_get_msdu_len, 224 + .rx_desc_get_msdu_sgi = ath11k_hw_qcn9074_rx_desc_get_msdu_sgi, 225 + .rx_desc_get_msdu_rate_mcs = ath11k_hw_qcn9074_rx_desc_get_msdu_rate_mcs, 226 + .rx_desc_get_msdu_rx_bw = ath11k_hw_qcn9074_rx_desc_get_msdu_rx_bw, 227 + .rx_desc_get_msdu_freq = ath11k_hw_qcn9074_rx_desc_get_msdu_freq, 228 + .rx_desc_get_msdu_pkt_type = ath11k_hw_qcn9074_rx_desc_get_msdu_pkt_type, 229 + .rx_desc_get_msdu_nss = ath11k_hw_qcn9074_rx_desc_get_msdu_nss, 230 + .rx_desc_get_mpdu_tid = ath11k_hw_qcn9074_rx_desc_get_mpdu_tid, 231 + .rx_desc_get_mpdu_peer_id = ath11k_hw_qcn9074_rx_desc_get_mpdu_peer_id, 232 + .rx_desc_copy_attn_end_tlv = ath11k_hw_qcn9074_rx_desc_copy_attn_end, 233 + .rx_desc_get_mpdu_start_tag = ath11k_hw_qcn9074_rx_desc_get_mpdu_start_tag, 234 + .rx_desc_get_mpdu_ppdu_id = ath11k_hw_qcn9074_rx_desc_get_mpdu_ppdu_id, 235 + .rx_desc_set_msdu_len = ath11k_hw_qcn9074_rx_desc_set_msdu_len, 236 + .rx_desc_get_attention = ath11k_hw_qcn9074_rx_desc_get_attention, 237 + .rx_desc_get_msdu_payload = ath11k_hw_qcn9074_rx_desc_get_msdu_payload, 565 238 }; 566 239 567 240 #define ATH11K_TX_RING_MASK_0 0x1 ··· 1241 792 }, 1242 793 }; 1243 794 795 + /* Target firmware's Copy Engine configuration. */ 796 + const struct ce_pipe_config ath11k_target_ce_config_wlan_qcn9074[] = { 797 + /* CE0: host->target HTC control and raw streams */ 798 + { 799 + .pipenum = __cpu_to_le32(0), 800 + .pipedir = __cpu_to_le32(PIPEDIR_OUT), 801 + .nentries = __cpu_to_le32(32), 802 + .nbytes_max = __cpu_to_le32(2048), 803 + .flags = __cpu_to_le32(CE_ATTR_FLAGS), 804 + .reserved = __cpu_to_le32(0), 805 + }, 806 + 807 + /* CE1: target->host HTT + HTC control */ 808 + { 809 + .pipenum = __cpu_to_le32(1), 810 + .pipedir = __cpu_to_le32(PIPEDIR_IN), 811 + .nentries = __cpu_to_le32(32), 812 + .nbytes_max = __cpu_to_le32(2048), 813 + .flags = __cpu_to_le32(CE_ATTR_FLAGS), 814 + .reserved = __cpu_to_le32(0), 815 + }, 816 + 817 + /* CE2: target->host WMI */ 818 + { 819 + .pipenum = __cpu_to_le32(2), 820 + .pipedir = __cpu_to_le32(PIPEDIR_IN), 821 + .nentries = __cpu_to_le32(32), 822 + .nbytes_max = __cpu_to_le32(2048), 823 + .flags = __cpu_to_le32(CE_ATTR_FLAGS), 824 + .reserved = __cpu_to_le32(0), 825 + }, 826 + 827 + /* CE3: host->target WMI */ 828 + { 829 + .pipenum = __cpu_to_le32(3), 830 + .pipedir = __cpu_to_le32(PIPEDIR_OUT), 831 + .nentries = __cpu_to_le32(32), 832 + .nbytes_max = __cpu_to_le32(2048), 833 + .flags = __cpu_to_le32(CE_ATTR_FLAGS), 834 + .reserved = __cpu_to_le32(0), 835 + }, 836 + 837 + /* CE4: host->target HTT */ 838 + { 839 + .pipenum = __cpu_to_le32(4), 840 + .pipedir = __cpu_to_le32(PIPEDIR_OUT), 841 + .nentries = __cpu_to_le32(256), 842 + .nbytes_max = __cpu_to_le32(256), 843 + .flags = __cpu_to_le32(CE_ATTR_FLAGS | CE_ATTR_DIS_INTR), 844 + .reserved = __cpu_to_le32(0), 845 + }, 846 + 847 + /* CE5: target->host Pktlog */ 848 + { 849 + .pipenum = __cpu_to_le32(5), 850 + .pipedir = __cpu_to_le32(PIPEDIR_IN), 851 + .nentries = __cpu_to_le32(32), 852 + .nbytes_max = __cpu_to_le32(2048), 853 + .flags = __cpu_to_le32(CE_ATTR_FLAGS), 854 + .reserved = __cpu_to_le32(0), 855 + }, 856 + 857 + /* CE6: Reserved for target autonomous hif_memcpy */ 858 + { 859 + .pipenum = __cpu_to_le32(6), 860 + .pipedir = __cpu_to_le32(PIPEDIR_INOUT), 861 + .nentries = __cpu_to_le32(32), 862 + .nbytes_max = __cpu_to_le32(16384), 863 + .flags = __cpu_to_le32(CE_ATTR_FLAGS), 864 + .reserved = __cpu_to_le32(0), 865 + }, 866 + 867 + /* CE7 used only by Host */ 868 + { 869 + .pipenum = __cpu_to_le32(7), 870 + .pipedir = __cpu_to_le32(PIPEDIR_INOUT_H2H), 871 + .nentries = __cpu_to_le32(0), 872 + .nbytes_max = __cpu_to_le32(0), 873 + .flags = __cpu_to_le32(CE_ATTR_FLAGS | CE_ATTR_DIS_INTR), 874 + .reserved = __cpu_to_le32(0), 875 + }, 876 + 877 + /* CE8 target->host used only by IPA */ 878 + { 879 + .pipenum = __cpu_to_le32(8), 880 + .pipedir = __cpu_to_le32(PIPEDIR_INOUT), 881 + .nentries = __cpu_to_le32(32), 882 + .nbytes_max = __cpu_to_le32(16384), 883 + .flags = __cpu_to_le32(CE_ATTR_FLAGS), 884 + .reserved = __cpu_to_le32(0), 885 + }, 886 + /* CE 9, 10, 11 are used by MHI driver */ 887 + }; 888 + 889 + /* Map from service/endpoint to Copy Engine. 890 + * This table is derived from the CE_PCI TABLE, above. 891 + * It is passed to the Target at startup for use by firmware. 892 + */ 893 + const struct service_to_pipe ath11k_target_service_to_ce_map_wlan_qcn9074[] = { 894 + { 895 + __cpu_to_le32(ATH11K_HTC_SVC_ID_WMI_DATA_VO), 896 + __cpu_to_le32(PIPEDIR_OUT), /* out = UL = host -> target */ 897 + __cpu_to_le32(3), 898 + }, 899 + { 900 + __cpu_to_le32(ATH11K_HTC_SVC_ID_WMI_DATA_VO), 901 + __cpu_to_le32(PIPEDIR_IN), /* in = DL = target -> host */ 902 + __cpu_to_le32(2), 903 + }, 904 + { 905 + __cpu_to_le32(ATH11K_HTC_SVC_ID_WMI_DATA_BK), 906 + __cpu_to_le32(PIPEDIR_OUT), /* out = UL = host -> target */ 907 + __cpu_to_le32(3), 908 + }, 909 + { 910 + __cpu_to_le32(ATH11K_HTC_SVC_ID_WMI_DATA_BK), 911 + __cpu_to_le32(PIPEDIR_IN), /* in = DL = target -> host */ 912 + __cpu_to_le32(2), 913 + }, 914 + { 915 + __cpu_to_le32(ATH11K_HTC_SVC_ID_WMI_DATA_BE), 916 + __cpu_to_le32(PIPEDIR_OUT), /* out = UL = host -> target */ 917 + __cpu_to_le32(3), 918 + }, 919 + { 920 + __cpu_to_le32(ATH11K_HTC_SVC_ID_WMI_DATA_BE), 921 + __cpu_to_le32(PIPEDIR_IN), /* in = DL = target -> host */ 922 + __cpu_to_le32(2), 923 + }, 924 + { 925 + __cpu_to_le32(ATH11K_HTC_SVC_ID_WMI_DATA_VI), 926 + __cpu_to_le32(PIPEDIR_OUT), /* out = UL = host -> target */ 927 + __cpu_to_le32(3), 928 + }, 929 + { 930 + __cpu_to_le32(ATH11K_HTC_SVC_ID_WMI_DATA_VI), 931 + __cpu_to_le32(PIPEDIR_IN), /* in = DL = target -> host */ 932 + __cpu_to_le32(2), 933 + }, 934 + { 935 + __cpu_to_le32(ATH11K_HTC_SVC_ID_WMI_CONTROL), 936 + __cpu_to_le32(PIPEDIR_OUT), /* out = UL = host -> target */ 937 + __cpu_to_le32(3), 938 + }, 939 + { 940 + __cpu_to_le32(ATH11K_HTC_SVC_ID_WMI_CONTROL), 941 + __cpu_to_le32(PIPEDIR_IN), /* in = DL = target -> host */ 942 + __cpu_to_le32(2), 943 + }, 944 + { 945 + __cpu_to_le32(ATH11K_HTC_SVC_ID_RSVD_CTRL), 946 + __cpu_to_le32(PIPEDIR_OUT), /* out = UL = host -> target */ 947 + __cpu_to_le32(0), 948 + }, 949 + { 950 + __cpu_to_le32(ATH11K_HTC_SVC_ID_RSVD_CTRL), 951 + __cpu_to_le32(PIPEDIR_IN), /* in = DL = target -> host */ 952 + __cpu_to_le32(1), 953 + }, 954 + { 955 + __cpu_to_le32(ATH11K_HTC_SVC_ID_TEST_RAW_STREAMS), 956 + __cpu_to_le32(PIPEDIR_OUT), /* out = UL = host -> target */ 957 + __cpu_to_le32(0), 958 + }, 959 + { 960 + __cpu_to_le32(ATH11K_HTC_SVC_ID_TEST_RAW_STREAMS), 961 + __cpu_to_le32(PIPEDIR_IN), /* in = DL = target -> host */ 962 + __cpu_to_le32(1), 963 + }, 964 + { 965 + __cpu_to_le32(ATH11K_HTC_SVC_ID_HTT_DATA_MSG), 966 + __cpu_to_le32(PIPEDIR_OUT), /* out = UL = host -> target */ 967 + __cpu_to_le32(4), 968 + }, 969 + { 970 + __cpu_to_le32(ATH11K_HTC_SVC_ID_HTT_DATA_MSG), 971 + __cpu_to_le32(PIPEDIR_IN), /* in = DL = target -> host */ 972 + __cpu_to_le32(1), 973 + }, 974 + { 975 + __cpu_to_le32(ATH11K_HTC_SVC_ID_PKT_LOG), 976 + __cpu_to_le32(PIPEDIR_IN), /* in = DL = target -> host */ 977 + __cpu_to_le32(5), 978 + }, 979 + 980 + /* (Additions here) */ 981 + 982 + { /* must be last */ 983 + __cpu_to_le32(0), 984 + __cpu_to_le32(0), 985 + __cpu_to_le32(0), 986 + }, 987 + }; 988 + 989 + const struct ath11k_hw_ring_mask ath11k_hw_ring_mask_qcn9074 = { 990 + .tx = { 991 + ATH11K_TX_RING_MASK_0, 992 + ATH11K_TX_RING_MASK_1, 993 + ATH11K_TX_RING_MASK_2, 994 + }, 995 + .rx_mon_status = { 996 + 0, 0, 0, 997 + ATH11K_RX_MON_STATUS_RING_MASK_0, 998 + ATH11K_RX_MON_STATUS_RING_MASK_1, 999 + ATH11K_RX_MON_STATUS_RING_MASK_2, 1000 + }, 1001 + .rx = { 1002 + 0, 0, 0, 0, 1003 + ATH11K_RX_RING_MASK_0, 1004 + ATH11K_RX_RING_MASK_1, 1005 + ATH11K_RX_RING_MASK_2, 1006 + ATH11K_RX_RING_MASK_3, 1007 + }, 1008 + .rx_err = { 1009 + 0, 0, 0, 1010 + ATH11K_RX_ERR_RING_MASK_0, 1011 + }, 1012 + .rx_wbm_rel = { 1013 + 0, 0, 0, 1014 + ATH11K_RX_WBM_REL_RING_MASK_0, 1015 + }, 1016 + .reo_status = { 1017 + 0, 0, 0, 1018 + ATH11K_REO_STATUS_RING_MASK_0, 1019 + }, 1020 + .rxdma2host = { 1021 + 0, 0, 0, 1022 + ATH11K_RXDMA2HOST_RING_MASK_0, 1023 + }, 1024 + .host2rxdma = { 1025 + 0, 0, 0, 1026 + ATH11K_HOST2RXDMA_RING_MASK_0, 1027 + }, 1028 + }; 1029 + 1244 1030 const struct ath11k_hw_regs ipq8074_regs = { 1245 1031 /* SW2TCL(x) R0 ring configuration address */ 1246 1032 .hal_tcl1_ring_base_lsb = 0x00000510, ··· 1525 841 .hal_reo_status_ring_base_lsb = 0x00000504, 1526 842 .hal_reo_status_hp = 0x00003070, 1527 843 844 + /* WCSS relative address */ 845 + .hal_seq_wcss_umac_ce0_src_reg = 0x00a00000, 846 + .hal_seq_wcss_umac_ce0_dst_reg = 0x00a01000, 847 + .hal_seq_wcss_umac_ce1_src_reg = 0x00a02000, 848 + .hal_seq_wcss_umac_ce1_dst_reg = 0x00a03000, 849 + 850 + /* WBM Idle address */ 851 + .hal_wbm_idle_link_ring_base_lsb = 0x00000860, 852 + .hal_wbm_idle_link_ring_misc = 0x00000870, 853 + 854 + /* SW2WBM release address */ 855 + .hal_wbm_release_ring_base_lsb = 0x000001d8, 856 + 857 + /* WBM2SW release address */ 858 + .hal_wbm0_release_ring_base_lsb = 0x00000910, 859 + .hal_wbm1_release_ring_base_lsb = 0x00000968, 860 + 861 + /* PCIe base address */ 862 + .pcie_qserdes_sysclk_en_sel = 0x0, 863 + .pcie_pcs_osc_dtct_config_base = 0x0, 1528 864 }; 1529 865 1530 866 const struct ath11k_hw_regs qca6390_regs = { ··· 1595 891 /* REO status address */ 1596 892 .hal_reo_status_ring_base_lsb = 0x000004ac, 1597 893 .hal_reo_status_hp = 0x00003068, 894 + 895 + /* WCSS relative address */ 896 + .hal_seq_wcss_umac_ce0_src_reg = 0x00a00000, 897 + .hal_seq_wcss_umac_ce0_dst_reg = 0x00a01000, 898 + .hal_seq_wcss_umac_ce1_src_reg = 0x00a02000, 899 + .hal_seq_wcss_umac_ce1_dst_reg = 0x00a03000, 900 + 901 + /* WBM Idle address */ 902 + .hal_wbm_idle_link_ring_base_lsb = 0x00000860, 903 + .hal_wbm_idle_link_ring_misc = 0x00000870, 904 + 905 + /* SW2WBM release address */ 906 + .hal_wbm_release_ring_base_lsb = 0x000001d8, 907 + 908 + /* WBM2SW release address */ 909 + .hal_wbm0_release_ring_base_lsb = 0x00000910, 910 + .hal_wbm1_release_ring_base_lsb = 0x00000968, 911 + 912 + /* PCIe base address */ 913 + .pcie_qserdes_sysclk_en_sel = 0x01e0c0ac, 914 + .pcie_pcs_osc_dtct_config_base = 0x01e0c628, 915 + }; 916 + 917 + const struct ath11k_hw_regs qcn9074_regs = { 918 + /* SW2TCL(x) R0 ring configuration address */ 919 + .hal_tcl1_ring_base_lsb = 0x000004f0, 920 + .hal_tcl1_ring_base_msb = 0x000004f4, 921 + .hal_tcl1_ring_id = 0x000004f8, 922 + .hal_tcl1_ring_misc = 0x00000500, 923 + .hal_tcl1_ring_tp_addr_lsb = 0x0000050c, 924 + .hal_tcl1_ring_tp_addr_msb = 0x00000510, 925 + .hal_tcl1_ring_consumer_int_setup_ix0 = 0x00000520, 926 + .hal_tcl1_ring_consumer_int_setup_ix1 = 0x00000524, 927 + .hal_tcl1_ring_msi1_base_lsb = 0x00000538, 928 + .hal_tcl1_ring_msi1_base_msb = 0x0000053c, 929 + .hal_tcl1_ring_msi1_data = 0x00000540, 930 + .hal_tcl2_ring_base_lsb = 0x00000548, 931 + .hal_tcl_ring_base_lsb = 0x000005f8, 932 + 933 + /* TCL STATUS ring address */ 934 + .hal_tcl_status_ring_base_lsb = 0x00000700, 935 + 936 + /* REO2SW(x) R0 ring configuration address */ 937 + .hal_reo1_ring_base_lsb = 0x0000029c, 938 + .hal_reo1_ring_base_msb = 0x000002a0, 939 + .hal_reo1_ring_id = 0x000002a4, 940 + .hal_reo1_ring_misc = 0x000002ac, 941 + .hal_reo1_ring_hp_addr_lsb = 0x000002b0, 942 + .hal_reo1_ring_hp_addr_msb = 0x000002b4, 943 + .hal_reo1_ring_producer_int_setup = 0x000002c0, 944 + .hal_reo1_ring_msi1_base_lsb = 0x000002e4, 945 + .hal_reo1_ring_msi1_base_msb = 0x000002e8, 946 + .hal_reo1_ring_msi1_data = 0x000002ec, 947 + .hal_reo2_ring_base_lsb = 0x000002f4, 948 + .hal_reo1_aging_thresh_ix_0 = 0x00000564, 949 + .hal_reo1_aging_thresh_ix_1 = 0x00000568, 950 + .hal_reo1_aging_thresh_ix_2 = 0x0000056c, 951 + .hal_reo1_aging_thresh_ix_3 = 0x00000570, 952 + 953 + /* REO2SW(x) R2 ring pointers (head/tail) address */ 954 + .hal_reo1_ring_hp = 0x00003038, 955 + .hal_reo1_ring_tp = 0x0000303c, 956 + .hal_reo2_ring_hp = 0x00003040, 957 + 958 + /* REO2TCL R0 ring configuration address */ 959 + .hal_reo_tcl_ring_base_lsb = 0x000003fc, 960 + .hal_reo_tcl_ring_hp = 0x00003058, 961 + 962 + /* REO status address */ 963 + .hal_reo_status_ring_base_lsb = 0x00000504, 964 + .hal_reo_status_hp = 0x00003070, 965 + 966 + /* WCSS relative address */ 967 + .hal_seq_wcss_umac_ce0_src_reg = 0x01b80000, 968 + .hal_seq_wcss_umac_ce0_dst_reg = 0x01b81000, 969 + .hal_seq_wcss_umac_ce1_src_reg = 0x01b82000, 970 + .hal_seq_wcss_umac_ce1_dst_reg = 0x01b83000, 971 + 972 + /* WBM Idle address */ 973 + .hal_wbm_idle_link_ring_base_lsb = 0x00000874, 974 + .hal_wbm_idle_link_ring_misc = 0x00000884, 975 + 976 + /* SW2WBM release address */ 977 + .hal_wbm_release_ring_base_lsb = 0x000001ec, 978 + 979 + /* WBM2SW release address */ 980 + .hal_wbm0_release_ring_base_lsb = 0x00000924, 981 + .hal_wbm1_release_ring_base_lsb = 0x0000097c, 982 + 983 + /* PCIe base address */ 984 + .pcie_qserdes_sysclk_en_sel = 0x01e0e0a8, 985 + .pcie_pcs_osc_dtct_config_base = 0x01e0f45c, 1598 986 };
+53
drivers/net/wireless/ath/ath11k/hw.h
··· 105 105 106 106 #define ATH11K_EXT_IRQ_GRP_NUM_MAX 11 107 107 108 + struct hal_rx_desc; 109 + struct hal_tcl_data_cmd; 110 + 108 111 struct ath11k_hw_ring_mask { 109 112 u8 tx[ATH11K_EXT_IRQ_GRP_NUM_MAX]; 110 113 u8 rx_mon_status[ATH11K_EXT_IRQ_GRP_NUM_MAX]; ··· 137 134 bool internal_sleep_clock; 138 135 139 136 const struct ath11k_hw_regs *regs; 137 + u32 qmi_service_ins_id; 140 138 const struct ce_attr *host_ce_config; 141 139 u32 ce_count; 142 140 const struct ce_pipe_config *target_ce_config; ··· 161 157 bool idle_ps; 162 158 bool cold_boot_calib; 163 159 bool supports_suspend; 160 + u32 hal_desc_sz; 164 161 }; 165 162 166 163 struct ath11k_hw_ops { ··· 170 165 struct target_resource_config *config); 171 166 int (*mac_id_to_pdev_id)(struct ath11k_hw_params *hw, int mac_id); 172 167 int (*mac_id_to_srng_id)(struct ath11k_hw_params *hw, int mac_id); 168 + void (*tx_mesh_enable)(struct ath11k_base *ab, 169 + struct hal_tcl_data_cmd *tcl_cmd); 170 + bool (*rx_desc_get_first_msdu)(struct hal_rx_desc *desc); 171 + bool (*rx_desc_get_last_msdu)(struct hal_rx_desc *desc); 172 + u8 (*rx_desc_get_l3_pad_bytes)(struct hal_rx_desc *desc); 173 + u8 *(*rx_desc_get_hdr_status)(struct hal_rx_desc *desc); 174 + bool (*rx_desc_encrypt_valid)(struct hal_rx_desc *desc); 175 + u32 (*rx_desc_get_encrypt_type)(struct hal_rx_desc *desc); 176 + u8 (*rx_desc_get_decap_type)(struct hal_rx_desc *desc); 177 + u8 (*rx_desc_get_mesh_ctl)(struct hal_rx_desc *desc); 178 + bool (*rx_desc_get_mpdu_seq_ctl_vld)(struct hal_rx_desc *desc); 179 + bool (*rx_desc_get_mpdu_fc_valid)(struct hal_rx_desc *desc); 180 + u16 (*rx_desc_get_mpdu_start_seq_no)(struct hal_rx_desc *desc); 181 + u16 (*rx_desc_get_msdu_len)(struct hal_rx_desc *desc); 182 + u8 (*rx_desc_get_msdu_sgi)(struct hal_rx_desc *desc); 183 + u8 (*rx_desc_get_msdu_rate_mcs)(struct hal_rx_desc *desc); 184 + u8 (*rx_desc_get_msdu_rx_bw)(struct hal_rx_desc *desc); 185 + u32 (*rx_desc_get_msdu_freq)(struct hal_rx_desc *desc); 186 + u8 (*rx_desc_get_msdu_pkt_type)(struct hal_rx_desc *desc); 187 + u8 (*rx_desc_get_msdu_nss)(struct hal_rx_desc *desc); 188 + u8 (*rx_desc_get_mpdu_tid)(struct hal_rx_desc *desc); 189 + u16 (*rx_desc_get_mpdu_peer_id)(struct hal_rx_desc *desc); 190 + void (*rx_desc_copy_attn_end_tlv)(struct hal_rx_desc *fdesc, 191 + struct hal_rx_desc *ldesc); 192 + u32 (*rx_desc_get_mpdu_start_tag)(struct hal_rx_desc *desc); 193 + u32 (*rx_desc_get_mpdu_ppdu_id)(struct hal_rx_desc *desc); 194 + void (*rx_desc_set_msdu_len)(struct hal_rx_desc *desc, u16 len); 195 + struct rx_attention *(*rx_desc_get_attention)(struct hal_rx_desc *desc); 196 + u8 *(*rx_desc_get_msdu_payload)(struct hal_rx_desc *desc); 173 197 }; 174 198 175 199 extern const struct ath11k_hw_ops ipq8074_ops; 176 200 extern const struct ath11k_hw_ops ipq6018_ops; 177 201 extern const struct ath11k_hw_ops qca6390_ops; 202 + extern const struct ath11k_hw_ops qcn9074_ops; 178 203 179 204 extern const struct ath11k_hw_ring_mask ath11k_hw_ring_mask_ipq8074; 180 205 extern const struct ath11k_hw_ring_mask ath11k_hw_ring_mask_qca6390; 206 + extern const struct ath11k_hw_ring_mask ath11k_hw_ring_mask_qcn9074; 181 207 182 208 static inline 183 209 int ath11k_hw_get_mac_from_pdev_id(struct ath11k_hw_params *hw, ··· 297 261 298 262 u32 hal_reo_status_ring_base_lsb; 299 263 u32 hal_reo_status_hp; 264 + 265 + u32 hal_seq_wcss_umac_ce0_src_reg; 266 + u32 hal_seq_wcss_umac_ce0_dst_reg; 267 + u32 hal_seq_wcss_umac_ce1_src_reg; 268 + u32 hal_seq_wcss_umac_ce1_dst_reg; 269 + 270 + u32 hal_wbm_idle_link_ring_base_lsb; 271 + u32 hal_wbm_idle_link_ring_misc; 272 + 273 + u32 hal_wbm_release_ring_base_lsb; 274 + 275 + u32 hal_wbm0_release_ring_base_lsb; 276 + u32 hal_wbm1_release_ring_base_lsb; 277 + 278 + u32 pcie_qserdes_sysclk_en_sel; 279 + u32 pcie_pcs_osc_dtct_config_base; 300 280 }; 301 281 302 282 extern const struct ath11k_hw_regs ipq8074_regs; 303 283 extern const struct ath11k_hw_regs qca6390_regs; 284 + extern const struct ath11k_hw_regs qcn9074_regs; 304 285 305 286 #endif
+79 -9
drivers/net/wireless/ath/ath11k/mac.c
··· 829 829 ath11k_dbg(ar->ab, ATH11K_DBG_MAC, "mac vdev %d up\n", arvif->vdev_id); 830 830 } 831 831 832 + static void ath11k_mac_handle_beacon_iter(void *data, u8 *mac, 833 + struct ieee80211_vif *vif) 834 + { 835 + struct sk_buff *skb = data; 836 + struct ieee80211_mgmt *mgmt = (void *)skb->data; 837 + struct ath11k_vif *arvif = (void *)vif->drv_priv; 838 + 839 + if (vif->type != NL80211_IFTYPE_STATION) 840 + return; 841 + 842 + if (!ether_addr_equal(mgmt->bssid, vif->bss_conf.bssid)) 843 + return; 844 + 845 + cancel_delayed_work(&arvif->connection_loss_work); 846 + } 847 + 848 + void ath11k_mac_handle_beacon(struct ath11k *ar, struct sk_buff *skb) 849 + { 850 + ieee80211_iterate_active_interfaces_atomic(ar->hw, 851 + IEEE80211_IFACE_ITER_NORMAL, 852 + ath11k_mac_handle_beacon_iter, 853 + skb); 854 + } 855 + 856 + static void ath11k_mac_handle_beacon_miss_iter(void *data, u8 *mac, 857 + struct ieee80211_vif *vif) 858 + { 859 + u32 *vdev_id = data; 860 + struct ath11k_vif *arvif = (void *)vif->drv_priv; 861 + struct ath11k *ar = arvif->ar; 862 + struct ieee80211_hw *hw = ar->hw; 863 + 864 + if (arvif->vdev_id != *vdev_id) 865 + return; 866 + 867 + if (!arvif->is_up) 868 + return; 869 + 870 + ieee80211_beacon_loss(vif); 871 + 872 + /* Firmware doesn't report beacon loss events repeatedly. If AP probe 873 + * (done by mac80211) succeeds but beacons do not resume then it 874 + * doesn't make sense to continue operation. Queue connection loss work 875 + * which can be cancelled when beacon is received. 876 + */ 877 + ieee80211_queue_delayed_work(hw, &arvif->connection_loss_work, 878 + ATH11K_CONNECTION_LOSS_HZ); 879 + } 880 + 881 + void ath11k_mac_handle_beacon_miss(struct ath11k *ar, u32 vdev_id) 882 + { 883 + ieee80211_iterate_active_interfaces_atomic(ar->hw, 884 + IEEE80211_IFACE_ITER_NORMAL, 885 + ath11k_mac_handle_beacon_miss_iter, 886 + &vdev_id); 887 + } 888 + 889 + static void ath11k_mac_vif_sta_connection_loss_work(struct work_struct *work) 890 + { 891 + struct ath11k_vif *arvif = container_of(work, struct ath11k_vif, 892 + connection_loss_work.work); 893 + struct ieee80211_vif *vif = arvif->vif; 894 + 895 + if (!arvif->is_up) 896 + return; 897 + 898 + ieee80211_connection_loss(vif); 899 + } 900 + 832 901 static void ath11k_peer_assoc_h_basic(struct ath11k *ar, 833 902 struct ieee80211_vif *vif, 834 903 struct ieee80211_sta *sta, ··· 1829 1760 1830 1761 arvif->is_up = false; 1831 1762 1832 - /* TODO: cancel connection_loss_work */ 1763 + cancel_delayed_work_sync(&arvif->connection_loss_work); 1833 1764 } 1834 1765 1835 1766 static u32 ath11k_mac_get_rate_hw_value(int bitrate) ··· 3988 3919 3989 3920 he_cap_elem->phy_cap_info[5] &= 3990 3921 ~IEEE80211_HE_PHY_CAP5_BEAMFORMEE_NUM_SND_DIM_UNDER_80MHZ_MASK; 3991 - he_cap_elem->phy_cap_info[5] &= 3992 - ~IEEE80211_HE_PHY_CAP5_BEAMFORMEE_NUM_SND_DIM_ABOVE_80MHZ_MASK; 3993 3922 he_cap_elem->phy_cap_info[5] |= ar->num_tx_chains - 1; 3994 3923 3995 3924 switch (i) { ··· 4280 4213 return -ENOSPC; 4281 4214 } 4282 4215 4283 - if (skb_queue_len(q) == ATH11K_TX_MGMT_NUM_PENDING_MAX) { 4216 + if (skb_queue_len_lockless(q) >= ATH11K_TX_MGMT_NUM_PENDING_MAX) { 4284 4217 ath11k_warn(ar->ab, "mgmt tx queue is full\n"); 4285 4218 return -ENOSPC; 4286 4219 } ··· 4684 4617 arvif->vif = vif; 4685 4618 4686 4619 INIT_LIST_HEAD(&arvif->list); 4687 - 4688 - /* Should we initialize any worker to handle connection loss indication 4689 - * from firmware in sta mode? 4690 - */ 4620 + INIT_DELAYED_WORK(&arvif->connection_loss_work, 4621 + ath11k_mac_vif_sta_connection_loss_work); 4691 4622 4692 4623 for (i = 0; i < ARRAY_SIZE(arvif->bitrate_mask.control); i++) { 4693 4624 arvif->bitrate_mask.control[i].legacy = 0xffffffff; ··· 4893 4828 unsigned long time_left; 4894 4829 int ret; 4895 4830 int i; 4831 + 4832 + cancel_delayed_work_sync(&arvif->connection_loss_work); 4896 4833 4897 4834 mutex_lock(&ar->conf_mutex); 4898 4835 ··· 5163 5096 arg.channel.chan_radar = 5164 5097 !!(chandef->chan->flags & IEEE80211_CHAN_RADAR); 5165 5098 5099 + arg.channel.freq2_radar = 5100 + !!(chandef->chan->flags & IEEE80211_CHAN_RADAR); 5101 + 5166 5102 arg.channel.passive = arg.channel.chan_radar; 5167 5103 5168 5104 spin_lock_bh(&ab->base_lock); 5169 5105 arg.regdomain = ar->ab->dfs_region; 5170 5106 spin_unlock_bh(&ab->base_lock); 5171 5107 5172 - /* TODO: Notify if secondary 80Mhz also needs radar detection */ 5173 5108 if (he_support) { 5174 5109 ret = ath11k_set_he_mu_sounding_mode(ar, arvif); 5175 5110 if (ret) { ··· 6151 6082 6152 6083 /* TODO: Use real NF instead of default one. */ 6153 6084 sinfo->signal = arsta->rssi_comb + ATH11K_DEFAULT_NOISE_FLOOR; 6085 + sinfo->filled |= BIT_ULL(NL80211_STA_INFO_SIGNAL); 6154 6086 } 6155 6087 6156 6088 static const struct ieee80211_ops ath11k_ops = {
+2
drivers/net/wireless/ath/ath11k/mac.h
··· 150 150 u8 ath11k_mac_bw_to_mac80211_bw(u8 bw); 151 151 enum ath11k_supported_bw ath11k_mac_mac80211_bw_to_ath11k_bw(enum rate_info_bw bw); 152 152 enum hal_encrypt_type ath11k_dp_tx_get_encrypt_type(u32 cipher); 153 + void ath11k_mac_handle_beacon(struct ath11k *ar, struct sk_buff *skb); 154 + void ath11k_mac_handle_beacon_miss(struct ath11k *ar, u32 vdev_id); 153 155 #endif
+108 -8
drivers/net/wireless/ath/ath11k/mhi.c
··· 7 7 #include "core.h" 8 8 #include "debug.h" 9 9 #include "mhi.h" 10 + #include "pci.h" 10 11 11 12 #define MHI_TIMEOUT_DEFAULT_MS 90000 12 13 13 - static struct mhi_channel_config ath11k_mhi_channels[] = { 14 + static struct mhi_channel_config ath11k_mhi_channels_qca6390[] = { 14 15 { 15 16 .num = 0, 16 17 .name = "LOOPBACK", ··· 70 69 }, 71 70 }; 72 71 73 - static struct mhi_event_config ath11k_mhi_events[] = { 72 + static struct mhi_event_config ath11k_mhi_events_qca6390[] = { 74 73 { 75 74 .num_elements = 32, 76 75 .irq_moderation_ms = 0, ··· 93 92 }, 94 93 }; 95 94 96 - static struct mhi_controller_config ath11k_mhi_config = { 95 + static struct mhi_controller_config ath11k_mhi_config_qca6390 = { 97 96 .max_channels = 128, 98 97 .timeout_ms = 2000, 99 98 .use_bounce_buf = false, 100 99 .buf_len = 0, 101 - .num_channels = ARRAY_SIZE(ath11k_mhi_channels), 102 - .ch_cfg = ath11k_mhi_channels, 103 - .num_events = ARRAY_SIZE(ath11k_mhi_events), 104 - .event_cfg = ath11k_mhi_events, 100 + .num_channels = ARRAY_SIZE(ath11k_mhi_channels_qca6390), 101 + .ch_cfg = ath11k_mhi_channels_qca6390, 102 + .num_events = ARRAY_SIZE(ath11k_mhi_events_qca6390), 103 + .event_cfg = ath11k_mhi_events_qca6390, 104 + }; 105 + 106 + static struct mhi_channel_config ath11k_mhi_channels_qcn9074[] = { 107 + { 108 + .num = 0, 109 + .name = "LOOPBACK", 110 + .num_elements = 32, 111 + .event_ring = 1, 112 + .dir = DMA_TO_DEVICE, 113 + .ee_mask = 0x14, 114 + .pollcfg = 0, 115 + .doorbell = MHI_DB_BRST_DISABLE, 116 + .lpm_notify = false, 117 + .offload_channel = false, 118 + .doorbell_mode_switch = false, 119 + .auto_queue = false, 120 + }, 121 + { 122 + .num = 1, 123 + .name = "LOOPBACK", 124 + .num_elements = 32, 125 + .event_ring = 1, 126 + .dir = DMA_FROM_DEVICE, 127 + .ee_mask = 0x14, 128 + .pollcfg = 0, 129 + .doorbell = MHI_DB_BRST_DISABLE, 130 + .lpm_notify = false, 131 + .offload_channel = false, 132 + .doorbell_mode_switch = false, 133 + .auto_queue = false, 134 + }, 135 + { 136 + .num = 20, 137 + .name = "IPCR", 138 + .num_elements = 32, 139 + .event_ring = 1, 140 + .dir = DMA_TO_DEVICE, 141 + .ee_mask = 0x14, 142 + .pollcfg = 0, 143 + .doorbell = MHI_DB_BRST_DISABLE, 144 + .lpm_notify = false, 145 + .offload_channel = false, 146 + .doorbell_mode_switch = false, 147 + .auto_queue = false, 148 + }, 149 + { 150 + .num = 21, 151 + .name = "IPCR", 152 + .num_elements = 32, 153 + .event_ring = 1, 154 + .dir = DMA_FROM_DEVICE, 155 + .ee_mask = 0x14, 156 + .pollcfg = 0, 157 + .doorbell = MHI_DB_BRST_DISABLE, 158 + .lpm_notify = false, 159 + .offload_channel = false, 160 + .doorbell_mode_switch = false, 161 + .auto_queue = true, 162 + }, 163 + }; 164 + 165 + static struct mhi_event_config ath11k_mhi_events_qcn9074[] = { 166 + { 167 + .num_elements = 32, 168 + .irq_moderation_ms = 0, 169 + .irq = 1, 170 + .data_type = MHI_ER_CTRL, 171 + .mode = MHI_DB_BRST_DISABLE, 172 + .hardware_event = false, 173 + .client_managed = false, 174 + .offload_channel = false, 175 + }, 176 + { 177 + .num_elements = 256, 178 + .irq_moderation_ms = 1, 179 + .irq = 2, 180 + .mode = MHI_DB_BRST_DISABLE, 181 + .priority = 1, 182 + .hardware_event = false, 183 + .client_managed = false, 184 + .offload_channel = false, 185 + }, 186 + }; 187 + 188 + static struct mhi_controller_config ath11k_mhi_config_qcn9074 = { 189 + .max_channels = 30, 190 + .timeout_ms = 10000, 191 + .use_bounce_buf = false, 192 + .buf_len = 0, 193 + .num_channels = ARRAY_SIZE(ath11k_mhi_channels_qcn9074), 194 + .ch_cfg = ath11k_mhi_channels_qcn9074, 195 + .num_events = ARRAY_SIZE(ath11k_mhi_events_qcn9074), 196 + .event_cfg = ath11k_mhi_events_qcn9074, 105 197 }; 106 198 107 199 void ath11k_mhi_set_mhictrl_reset(struct ath11k_base *ab) ··· 315 221 { 316 222 struct ath11k_base *ab = ab_pci->ab; 317 223 struct mhi_controller *mhi_ctrl; 224 + struct mhi_controller_config *ath11k_mhi_config; 318 225 int ret; 319 226 320 227 mhi_ctrl = mhi_alloc_controller(); ··· 349 254 mhi_ctrl->read_reg = ath11k_mhi_op_read_reg; 350 255 mhi_ctrl->write_reg = ath11k_mhi_op_write_reg; 351 256 352 - ret = mhi_register_controller(mhi_ctrl, &ath11k_mhi_config); 257 + if (ab->hw_rev == ATH11K_HW_QCA6390_HW20) 258 + ath11k_mhi_config = &ath11k_mhi_config_qca6390; 259 + else if (ab->hw_rev == ATH11K_HW_QCN9074_HW10) 260 + ath11k_mhi_config = &ath11k_mhi_config_qcn9074; 261 + 262 + ret = mhi_register_controller(mhi_ctrl, ath11k_mhi_config); 353 263 if (ret) { 354 264 ath11k_err(ab, "failed to register to mhi bus, err = %d\n", ret); 355 265 mhi_free_controller(mhi_ctrl);
+149 -45
drivers/net/wireless/ath/ath11k/pci.c
··· 35 35 #define ACCESS_ALWAYS_OFF 0xFE0 36 36 37 37 #define QCA6390_DEVICE_ID 0x1101 38 + #define QCN9074_DEVICE_ID 0x1104 38 39 39 40 static const struct pci_device_id ath11k_pci_id_table[] = { 40 41 { PCI_VDEVICE(QCOM, QCA6390_DEVICE_ID) }, 42 + /* TODO: add QCN9074_DEVICE_ID) once firmware issues are resolved */ 41 43 {0} 42 44 }; 43 45 ··· 52 50 .fixed_mem_region = false, 53 51 }; 54 52 55 - static const struct ath11k_msi_config msi_config = { 56 - .total_vectors = 32, 57 - .total_users = 4, 58 - .users = (struct ath11k_msi_user[]) { 59 - { .name = "MHI", .num_vectors = 3, .base_vector = 0 }, 60 - { .name = "CE", .num_vectors = 10, .base_vector = 3 }, 61 - { .name = "WAKE", .num_vectors = 1, .base_vector = 13 }, 62 - { .name = "DP", .num_vectors = 18, .base_vector = 14 }, 53 + static const struct ath11k_msi_config ath11k_msi_config[] = { 54 + { 55 + .total_vectors = 32, 56 + .total_users = 4, 57 + .users = (struct ath11k_msi_user[]) { 58 + { .name = "MHI", .num_vectors = 3, .base_vector = 0 }, 59 + { .name = "CE", .num_vectors = 10, .base_vector = 3 }, 60 + { .name = "WAKE", .num_vectors = 1, .base_vector = 13 }, 61 + { .name = "DP", .num_vectors = 18, .base_vector = 14 }, 62 + }, 63 + }, 64 + { 65 + .total_vectors = 16, 66 + .total_users = 3, 67 + .users = (struct ath11k_msi_user[]) { 68 + { .name = "MHI", .num_vectors = 3, .base_vector = 0 }, 69 + { .name = "CE", .num_vectors = 5, .base_vector = 3 }, 70 + { .name = "DP", .num_vectors = 8, .base_vector = 8 }, 71 + }, 63 72 }, 64 73 }; 65 74 ··· 144 131 } 145 132 } 146 133 134 + static inline void ath11k_pci_select_static_window(struct ath11k_pci *ab_pci) 135 + { 136 + u32 umac_window = FIELD_GET(WINDOW_VALUE_MASK, HAL_SEQ_WCSS_UMAC_OFFSET); 137 + u32 ce_window = FIELD_GET(WINDOW_VALUE_MASK, HAL_CE_WFSS_CE_REG_BASE); 138 + u32 window; 139 + 140 + window = (umac_window << 12) | (ce_window << 6); 141 + 142 + iowrite32(WINDOW_ENABLE_BIT | window, ab_pci->ab->mem + WINDOW_REG_ADDRESS); 143 + } 144 + 145 + static inline u32 ath11k_pci_get_window_start(struct ath11k_base *ab, 146 + u32 offset) 147 + { 148 + u32 window_start; 149 + 150 + /* If offset lies within DP register range, use 3rd window */ 151 + if ((offset ^ HAL_SEQ_WCSS_UMAC_OFFSET) < WINDOW_RANGE_MASK) 152 + window_start = 3 * WINDOW_START; 153 + /* If offset lies within CE register range, use 2nd window */ 154 + else if ((offset ^ HAL_CE_WFSS_CE_REG_BASE) < WINDOW_RANGE_MASK) 155 + window_start = 2 * WINDOW_START; 156 + else 157 + window_start = WINDOW_START; 158 + 159 + return window_start; 160 + } 161 + 147 162 void ath11k_pci_write32(struct ath11k_base *ab, u32 offset, u32 value) 148 163 { 149 164 struct ath11k_pci *ab_pci = ath11k_pci_priv(ab); 165 + u32 window_start; 150 166 151 167 /* for offset beyond BAR + 4K - 32, may 152 168 * need to wakeup MHI to access. ··· 187 145 if (offset < WINDOW_START) { 188 146 iowrite32(value, ab->mem + offset); 189 147 } else { 190 - spin_lock_bh(&ab_pci->window_lock); 191 - ath11k_pci_select_window(ab_pci, offset); 192 - iowrite32(value, ab->mem + WINDOW_START + (offset & WINDOW_RANGE_MASK)); 193 - spin_unlock_bh(&ab_pci->window_lock); 148 + if (ab->bus_params.static_window_map) 149 + window_start = ath11k_pci_get_window_start(ab, offset); 150 + else 151 + window_start = WINDOW_START; 152 + 153 + if (window_start == WINDOW_START) { 154 + spin_lock_bh(&ab_pci->window_lock); 155 + ath11k_pci_select_window(ab_pci, offset); 156 + iowrite32(value, ab->mem + window_start + 157 + (offset & WINDOW_RANGE_MASK)); 158 + spin_unlock_bh(&ab_pci->window_lock); 159 + } else { 160 + iowrite32(value, ab->mem + window_start + 161 + (offset & WINDOW_RANGE_MASK)); 162 + } 194 163 } 195 164 196 165 if (test_bit(ATH11K_PCI_FLAG_INIT_DONE, &ab_pci->flags) && ··· 212 159 u32 ath11k_pci_read32(struct ath11k_base *ab, u32 offset) 213 160 { 214 161 struct ath11k_pci *ab_pci = ath11k_pci_priv(ab); 215 - u32 val; 162 + u32 val, window_start; 216 163 217 164 /* for offset beyond BAR + 4K - 32, may 218 165 * need to wakeup MHI to access. ··· 224 171 if (offset < WINDOW_START) { 225 172 val = ioread32(ab->mem + offset); 226 173 } else { 227 - spin_lock_bh(&ab_pci->window_lock); 228 - ath11k_pci_select_window(ab_pci, offset); 229 - val = ioread32(ab->mem + WINDOW_START + (offset & WINDOW_RANGE_MASK)); 230 - spin_unlock_bh(&ab_pci->window_lock); 174 + if (ab->bus_params.static_window_map) 175 + window_start = ath11k_pci_get_window_start(ab, offset); 176 + else 177 + window_start = WINDOW_START; 178 + 179 + if (window_start == WINDOW_START) { 180 + spin_lock_bh(&ab_pci->window_lock); 181 + ath11k_pci_select_window(ab_pci, offset); 182 + val = ioread32(ab->mem + window_start + 183 + (offset & WINDOW_RANGE_MASK)); 184 + spin_unlock_bh(&ab_pci->window_lock); 185 + } else { 186 + val = ioread32(ab->mem + window_start + 187 + (offset & WINDOW_RANGE_MASK)); 188 + } 231 189 } 232 190 233 191 if (test_bit(ATH11K_PCI_FLAG_INIT_DONE, &ab_pci->flags) && ··· 335 271 int ret; 336 272 337 273 ret = ath11k_pci_set_link_reg(ab, 338 - PCIE_QSERDES_COM_SYSCLK_EN_SEL_REG, 274 + PCIE_QSERDES_COM_SYSCLK_EN_SEL_REG(ab), 339 275 PCIE_QSERDES_COM_SYSCLK_EN_SEL_VAL, 340 276 PCIE_QSERDES_COM_SYSCLK_EN_SEL_MSK); 341 277 if (ret) { ··· 344 280 } 345 281 346 282 ret = ath11k_pci_set_link_reg(ab, 347 - PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG1_REG, 348 - PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG1_VAL, 349 - PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG_MSK); 283 + PCIE_PCS_OSC_DTCT_CONFIG1_REG(ab), 284 + PCIE_PCS_OSC_DTCT_CONFIG1_VAL, 285 + PCIE_PCS_OSC_DTCT_CONFIG_MSK); 350 286 if (ret) { 351 287 ath11k_warn(ab, "failed to set dtct config1 error: %d\n", ret); 352 288 return ret; 353 289 } 354 290 355 291 ret = ath11k_pci_set_link_reg(ab, 356 - PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG2_REG, 357 - PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG2_VAL, 358 - PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG_MSK); 292 + PCIE_PCS_OSC_DTCT_CONFIG2_REG(ab), 293 + PCIE_PCS_OSC_DTCT_CONFIG2_VAL, 294 + PCIE_PCS_OSC_DTCT_CONFIG_MSK); 359 295 if (ret) { 360 296 ath11k_warn(ab, "failed to set dtct config2: %d\n", ret); 361 297 return ret; 362 298 } 363 299 364 300 ret = ath11k_pci_set_link_reg(ab, 365 - PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG4_REG, 366 - PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG4_VAL, 367 - PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG_MSK); 301 + PCIE_PCS_OSC_DTCT_CONFIG4_REG(ab), 302 + PCIE_PCS_OSC_DTCT_CONFIG4_VAL, 303 + PCIE_PCS_OSC_DTCT_CONFIG_MSK); 368 304 if (ret) { 369 305 ath11k_warn(ab, "failed to set dtct config4: %d\n", ret); 370 306 return ret; ··· 470 406 u32 *base_vector) 471 407 { 472 408 struct ath11k_base *ab = ab_pci->ab; 409 + const struct ath11k_msi_config *msi_config = ab_pci->msi_config; 473 410 int idx; 474 411 475 - for (idx = 0; idx < msi_config.total_users; idx++) { 476 - if (strcmp(user_name, msi_config.users[idx].name) == 0) { 477 - *num_vectors = msi_config.users[idx].num_vectors; 478 - *user_base_data = msi_config.users[idx].base_vector 412 + for (idx = 0; idx < msi_config->total_users; idx++) { 413 + if (strcmp(user_name, msi_config->users[idx].name) == 0) { 414 + *num_vectors = msi_config->users[idx].num_vectors; 415 + *user_base_data = msi_config->users[idx].base_vector 479 416 + ab_pci->msi_ep_base_data; 480 - *base_vector = msi_config.users[idx].base_vector; 417 + *base_vector = msi_config->users[idx].base_vector; 481 418 482 419 ath11k_dbg(ab, ATH11K_DBG_PCI, "Assign MSI to user: %s, num_vectors: %d, user_base_data: %u, base_vector: %u\n", 483 420 user_name, *num_vectors, *user_base_data, ··· 491 426 ath11k_err(ab, "Failed to find MSI assignment for %s!\n", user_name); 492 427 493 428 return -EINVAL; 429 + } 430 + 431 + static void ath11k_pci_get_ce_msi_idx(struct ath11k_base *ab, u32 ce_id, 432 + u32 *msi_idx) 433 + { 434 + u32 i, msi_data_idx; 435 + 436 + for (i = 0, msi_data_idx = 0; i < ab->hw_params.ce_count; i++) { 437 + if (ath11k_ce_get_attr_flags(ab, i) & CE_ATTR_DIS_INTR) 438 + continue; 439 + 440 + if (ce_id == i) 441 + break; 442 + 443 + msi_data_idx++; 444 + } 445 + *msi_idx = msi_data_idx; 494 446 } 495 447 496 448 static int ath11k_get_user_msi_assignment(struct ath11k_base *ab, char *user_name, ··· 603 521 { 604 522 struct ath11k_ce_pipe *ce_pipe = arg; 605 523 524 + /* last interrupt received for this CE */ 525 + ce_pipe->timestamp = jiffies; 526 + 606 527 ath11k_pci_ce_irq_disable(ce_pipe->ab, ce_pipe->pipe_num); 607 528 tasklet_schedule(&ce_pipe->intr_tq); 608 529 ··· 700 615 701 616 ath11k_dbg(irq_grp->ab, ATH11K_DBG_PCI, "ext irq:%d\n", irq); 702 617 618 + /* last interrupt received for this group */ 619 + irq_grp->timestamp = jiffies; 620 + 703 621 ath11k_pci_ext_grp_disable(irq_grp); 704 622 705 623 napi_schedule(&irq_grp->napi); ··· 713 625 static int ath11k_pci_ext_irq_config(struct ath11k_base *ab) 714 626 { 715 627 int i, j, ret, num_vectors = 0; 716 - u32 user_base_data = 0, base_vector = 0; 628 + u32 user_base_data = 0, base_vector = 0, base_idx; 717 629 630 + base_idx = ATH11K_PCI_IRQ_CE0_OFFSET + CE_COUNT_MAX; 718 631 ret = ath11k_pci_get_user_msi_assignment(ath11k_pci_priv(ab), "DP", 719 632 &num_vectors, 720 633 &user_base_data, ··· 745 656 } 746 657 747 658 irq_grp->num_irq = num_irq; 748 - irq_grp->irqs[0] = base_vector + i; 659 + irq_grp->irqs[0] = base_idx + i; 749 660 750 661 for (j = 0; j < irq_grp->num_irq; j++) { 751 662 int irq_idx = irq_grp->irqs[j]; ··· 756 667 757 668 ath11k_dbg(ab, ATH11K_DBG_PCI, 758 669 "irq:%d group:%d\n", irq, i); 670 + 671 + irq_set_status_flags(irq, IRQ_DISABLE_UNLAZY); 759 672 ret = request_irq(irq, ath11k_pci_ext_interrupt_handler, 760 673 IRQF_SHARED, 761 674 "DP_EXT_IRQ", irq_grp); ··· 778 687 { 779 688 struct ath11k_ce_pipe *ce_pipe; 780 689 u32 msi_data_start; 781 - u32 msi_data_count; 690 + u32 msi_data_count, msi_data_idx; 782 691 u32 msi_irq_start; 783 692 unsigned int msi_data; 784 693 int irq, i, ret, irq_idx; ··· 790 699 return ret; 791 700 792 701 /* Configure CE irqs */ 793 - for (i = 0; i < ab->hw_params.ce_count; i++) { 794 - msi_data = (i % msi_data_count) + msi_irq_start; 795 - irq = ath11k_pci_get_msi_irq(ab->dev, msi_data); 796 - ce_pipe = &ab->ce.ce_pipe[i]; 797 - 702 + for (i = 0, msi_data_idx = 0; i < ab->hw_params.ce_count; i++) { 798 703 if (ath11k_ce_get_attr_flags(ab, i) & CE_ATTR_DIS_INTR) 799 704 continue; 705 + 706 + msi_data = (msi_data_idx % msi_data_count) + msi_irq_start; 707 + irq = ath11k_pci_get_msi_irq(ab->dev, msi_data); 708 + ce_pipe = &ab->ce.ce_pipe[i]; 800 709 801 710 irq_idx = ATH11K_PCI_IRQ_CE0_OFFSET + i; 802 711 ··· 812 721 } 813 722 814 723 ab->irq_num[irq_idx] = irq; 724 + msi_data_idx++; 725 + 815 726 ath11k_pci_ce_irq_disable(ab, i); 816 727 } 817 728 ··· 833 740 834 741 cfg->svc_to_ce_map = ab->hw_params.svc_to_ce_map; 835 742 cfg->svc_to_ce_map_len = ab->hw_params.svc_to_ce_map_len; 836 - ab->qmi.service_ins_id = ATH11K_QMI_WLFW_SERVICE_INS_ID_V01_QCA6390; 743 + ab->qmi.service_ins_id = ab->hw_params.qmi_service_ins_id; 837 744 838 745 ath11k_ce_get_shadow_config(ab, &cfg->shadow_reg_v2, 839 746 &cfg->shadow_reg_v2_len); ··· 853 760 static int ath11k_pci_enable_msi(struct ath11k_pci *ab_pci) 854 761 { 855 762 struct ath11k_base *ab = ab_pci->ab; 763 + const struct ath11k_msi_config *msi_config = ab_pci->msi_config; 856 764 struct msi_desc *msi_desc; 857 765 int num_vectors; 858 766 int ret; 859 767 860 768 num_vectors = pci_alloc_irq_vectors(ab_pci->pdev, 861 - msi_config.total_vectors, 862 - msi_config.total_vectors, 769 + msi_config->total_vectors, 770 + msi_config->total_vectors, 863 771 PCI_IRQ_MSI); 864 - if (num_vectors != msi_config.total_vectors) { 772 + if (num_vectors != msi_config->total_vectors) { 865 773 ath11k_err(ab, "failed to get %d MSI vectors, only %d available", 866 - msi_config.total_vectors, num_vectors); 774 + msi_config->total_vectors, num_vectors); 867 775 868 776 if (num_vectors >= 0) 869 777 return -EINVAL; ··· 1026 932 return ret; 1027 933 } 1028 934 935 + if (ab->bus_params.static_window_map) 936 + ath11k_pci_select_static_window(ab_pci); 937 + 1029 938 return 0; 1030 939 } 1031 940 ··· 1173 1076 .map_service_to_pipe = ath11k_pci_map_service_to_pipe, 1174 1077 .ce_irq_enable = ath11k_pci_hif_ce_irq_enable, 1175 1078 .ce_irq_disable = ath11k_pci_hif_ce_irq_disable, 1079 + .get_ce_msi_idx = ath11k_pci_get_ce_msi_idx, 1176 1080 }; 1177 1081 1178 1082 static int ath11k_pci_probe(struct pci_dev *pdev, ··· 1228 1130 ret = -EOPNOTSUPP; 1229 1131 goto err_pci_free_region; 1230 1132 } 1133 + ab_pci->msi_config = &ath11k_msi_config[0]; 1134 + break; 1135 + case QCN9074_DEVICE_ID: 1136 + ab_pci->msi_config = &ath11k_msi_config[1]; 1137 + ab->bus_params.static_window_map = true; 1138 + ab->hw_rev = ATH11K_HW_QCN9074_HW10; 1231 1139 break; 1232 1140 default: 1233 1141 dev_err(&pdev->dev, "Unknown PCI device found: 0x%x\n",
+13 -8
drivers/net/wireless/ath/ath11k/pci.h
··· 34 34 #define PCIE_SMLH_REQ_RST_LINK_DOWN 0x2 35 35 #define PCIE_INT_CLEAR_ALL 0xffffffff 36 36 37 - #define PCIE_QSERDES_COM_SYSCLK_EN_SEL_REG 0x01e0c0ac 37 + #define PCIE_QSERDES_COM_SYSCLK_EN_SEL_REG(x) \ 38 + (ab->hw_params.regs->pcie_qserdes_sysclk_en_sel) 38 39 #define PCIE_QSERDES_COM_SYSCLK_EN_SEL_VAL 0x10 39 40 #define PCIE_QSERDES_COM_SYSCLK_EN_SEL_MSK 0xffffffff 40 - #define PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG1_REG 0x01e0c628 41 - #define PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG1_VAL 0x02 42 - #define PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG2_REG 0x01e0c62c 43 - #define PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG2_VAL 0x52 44 - #define PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG4_REG 0x01e0c634 45 - #define PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG4_VAL 0xff 46 - #define PCIE_USB3_PCS_MISC_OSC_DTCT_CONFIG_MSK 0x000000ff 41 + #define PCIE_PCS_OSC_DTCT_CONFIG1_REG(x) \ 42 + (ab->hw_params.regs->pcie_pcs_osc_dtct_config_base) 43 + #define PCIE_PCS_OSC_DTCT_CONFIG1_VAL 0x02 44 + #define PCIE_PCS_OSC_DTCT_CONFIG2_REG(x) \ 45 + (ab->hw_params.regs->pcie_pcs_osc_dtct_config_base + 0x4) 46 + #define PCIE_PCS_OSC_DTCT_CONFIG2_VAL 0x52 47 + #define PCIE_PCS_OSC_DTCT_CONFIG4_REG(x) \ 48 + (ab->hw_params.regs->pcie_pcs_osc_dtct_config_base + 0xc) 49 + #define PCIE_PCS_OSC_DTCT_CONFIG4_VAL 0xff 50 + #define PCIE_PCS_OSC_DTCT_CONFIG_MSK 0x000000ff 47 51 48 52 #define WLAON_QFPROM_PWR_CTRL_REG 0x01f8031c 49 53 #define QFPROM_PWR_CTRL_VDD4BLOW_MASK 0x4 ··· 77 73 char amss_path[100]; 78 74 u32 msi_ep_base_data; 79 75 struct mhi_controller *mhi_ctrl; 76 + const struct ath11k_msi_config *msi_config; 80 77 unsigned long mhi_state; 81 78 u32 register_window; 82 79
+73 -45
drivers/net/wireless/ath/ath11k/qmi.c
··· 1556 1556 req.nm_modem |= SLEEP_CLOCK_SELECT_INTERNAL_BIT; 1557 1557 } 1558 1558 1559 + ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi host cap request\n"); 1560 + 1559 1561 ret = qmi_txn_init(&ab->qmi.handle, &txn, 1560 1562 qmi_wlanfw_host_cap_resp_msg_v01_ei, &resp); 1561 1563 if (ret < 0) ··· 1568 1566 QMI_WLANFW_HOST_CAP_REQ_MSG_V01_MAX_LEN, 1569 1567 qmi_wlanfw_host_cap_req_msg_v01_ei, &req); 1570 1568 if (ret < 0) { 1571 - ath11k_warn(ab, "Failed to send host capability request,err = %d\n", ret); 1569 + ath11k_warn(ab, "failed to send host capability request: %d\n", ret); 1572 1570 goto out; 1573 1571 } 1574 1572 ··· 1577 1575 goto out; 1578 1576 1579 1577 if (resp.resp.result != QMI_RESULT_SUCCESS_V01) { 1580 - ath11k_warn(ab, "Host capability request failed, result: %d, err: %d\n", 1578 + ath11k_warn(ab, "host capability request failed: %d %d\n", 1581 1579 resp.resp.result, resp.resp.error); 1582 1580 ret = -EINVAL; 1583 1581 goto out; ··· 1626 1624 if (ret < 0) 1627 1625 goto out; 1628 1626 1627 + ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi indication register request\n"); 1628 + 1629 1629 ret = qmi_send_request(&ab->qmi.handle, NULL, &txn, 1630 1630 QMI_WLANFW_IND_REGISTER_REQ_V01, 1631 1631 QMI_WLANFW_IND_REGISTER_REQ_MSG_V01_MAX_LEN, 1632 1632 qmi_wlanfw_ind_register_req_msg_v01_ei, req); 1633 1633 if (ret < 0) { 1634 - ath11k_warn(ab, "Failed to send indication register request, err = %d\n", 1634 + ath11k_warn(ab, "failed to send indication register request: %d\n", 1635 1635 ret); 1636 1636 goto out; 1637 1637 } 1638 1638 1639 1639 ret = qmi_txn_wait(&txn, msecs_to_jiffies(ATH11K_QMI_WLANFW_TIMEOUT_MS)); 1640 1640 if (ret < 0) { 1641 - ath11k_warn(ab, "failed to register fw indication %d\n", ret); 1641 + ath11k_warn(ab, "failed to register fw indication: %d\n", ret); 1642 1642 goto out; 1643 1643 } 1644 1644 1645 1645 if (resp->resp.result != QMI_RESULT_SUCCESS_V01) { 1646 - ath11k_warn(ab, "FW Ind register request failed, result: %d, err: %d\n", 1646 + ath11k_warn(ab, "firmware indication register request failed: %d %d\n", 1647 1647 resp->resp.result, resp->resp.error); 1648 1648 ret = -EINVAL; 1649 1649 goto out; ··· 1703 1699 if (ret < 0) 1704 1700 goto out; 1705 1701 1702 + ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi respond memory request delayed %i\n", 1703 + delayed); 1704 + 1706 1705 ret = qmi_send_request(&ab->qmi.handle, NULL, &txn, 1707 1706 QMI_WLANFW_RESPOND_MEM_REQ_V01, 1708 1707 QMI_WLANFW_RESPOND_MEM_REQ_MSG_V01_MAX_LEN, 1709 1708 qmi_wlanfw_respond_mem_req_msg_v01_ei, req); 1710 1709 if (ret < 0) { 1711 - ath11k_warn(ab, "qmi failed to respond memory request, err = %d\n", 1710 + ath11k_warn(ab, "failed to respond qmi memory request: %d\n", 1712 1711 ret); 1713 1712 goto out; 1714 1713 } 1715 1714 1716 1715 ret = qmi_txn_wait(&txn, msecs_to_jiffies(ATH11K_QMI_WLANFW_TIMEOUT_MS)); 1717 1716 if (ret < 0) { 1718 - ath11k_warn(ab, "qmi failed memory request, err = %d\n", ret); 1717 + ath11k_warn(ab, "failed to wait qmi memory request: %d\n", ret); 1719 1718 goto out; 1720 1719 } 1721 1720 ··· 1729 1722 if (delayed && resp.resp.error == 0) 1730 1723 goto out; 1731 1724 1732 - ath11k_warn(ab, "Respond mem req failed, result: %d, err: %d\n", 1725 + ath11k_warn(ab, "qmi respond memory request failed: %d %d\n", 1733 1726 resp.resp.result, resp.resp.error); 1734 1727 ret = -EINVAL; 1735 1728 goto out; ··· 1772 1765 &chunk->paddr, 1773 1766 GFP_KERNEL); 1774 1767 if (!chunk->vaddr) { 1775 - if (ab->qmi.mem_seg_count <= 2) { 1768 + if (ab->qmi.mem_seg_count <= ATH11K_QMI_FW_MEM_REQ_SEGMENT_CNT) { 1776 1769 ath11k_dbg(ab, ATH11K_DBG_QMI, 1777 1770 "qmi dma allocation failed (%d B type %u), will try later with small size\n", 1778 1771 chunk->size, ··· 1781 1774 ab->qmi.target_mem_delayed = true; 1782 1775 return 0; 1783 1776 } 1784 - ath11k_err(ab, "failed to alloc memory, size: 0x%x, type: %u\n", 1777 + 1778 + ath11k_err(ab, "failed to allocate dma memory for qmi (%d B type %u)\n", 1785 1779 chunk->size, 1786 1780 chunk->type); 1787 1781 return -EINVAL; ··· 1851 1843 if (ret < 0) 1852 1844 goto out; 1853 1845 1846 + ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi target cap request\n"); 1847 + 1854 1848 ret = qmi_send_request(&ab->qmi.handle, NULL, &txn, 1855 1849 QMI_WLANFW_CAP_REQ_V01, 1856 1850 QMI_WLANFW_CAP_REQ_MSG_V01_MAX_LEN, 1857 1851 qmi_wlanfw_cap_req_msg_v01_ei, &req); 1858 1852 if (ret < 0) { 1859 - ath11k_warn(ab, "qmi failed to send target cap request, err = %d\n", 1853 + ath11k_warn(ab, "failed to send qmi cap request: %d\n", 1860 1854 ret); 1861 1855 goto out; 1862 1856 } 1863 1857 1864 1858 ret = qmi_txn_wait(&txn, msecs_to_jiffies(ATH11K_QMI_WLANFW_TIMEOUT_MS)); 1865 1859 if (ret < 0) { 1866 - ath11k_warn(ab, "qmi failed target cap request %d\n", ret); 1860 + ath11k_warn(ab, "failed to wait qmi cap request: %d\n", ret); 1867 1861 goto out; 1868 1862 } 1869 1863 1870 1864 if (resp.resp.result != QMI_RESULT_SUCCESS_V01) { 1871 - ath11k_warn(ab, "qmi targetcap req failed, result: %d, err: %d\n", 1865 + ath11k_warn(ab, "qmi cap request failed: %d %d\n", 1872 1866 resp.resp.result, resp.resp.error); 1873 1867 ret = -EINVAL; 1874 1868 goto out; ··· 1933 1923 1934 1924 ret = ath11k_core_fetch_bdf(ab, &bd); 1935 1925 if (ret) { 1936 - ath11k_warn(ab, "qmi failed to load BDF\n"); 1926 + ath11k_warn(ab, "failed to load board file: %d\n", ret); 1937 1927 return ret; 1938 1928 } 1939 1929 ··· 1981 1971 1982 1972 bdf_addr = ioremap(ab->hw_params.bdf_addr, ATH11K_QMI_BDF_MAX_SIZE); 1983 1973 if (!bdf_addr) { 1984 - ath11k_warn(ab, "qmi ioremap error for BDF\n"); 1974 + ath11k_warn(ab, "failed ioremap for board file\n"); 1985 1975 ret = -EIO; 1986 1976 goto out; 1987 1977 } ··· 2010 2000 if (ret < 0) 2011 2001 goto out_qmi_bdf; 2012 2002 2003 + ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi bdf download req fixed addr type %d\n", 2004 + type); 2005 + 2013 2006 ret = qmi_send_request(&ab->qmi.handle, NULL, &txn, 2014 2007 QMI_WLANFW_BDF_DOWNLOAD_REQ_V01, 2015 2008 QMI_WLANFW_BDF_DOWNLOAD_REQ_MSG_V01_MAX_LEN, ··· 2027 2014 goto out_qmi_bdf; 2028 2015 2029 2016 if (resp.resp.result != QMI_RESULT_SUCCESS_V01) { 2030 - ath11k_warn(ab, "qmi BDF download failed, result: %d, err: %d\n", 2017 + ath11k_warn(ab, "board file download request failed: %d %d\n", 2031 2018 resp.resp.result, resp.resp.error); 2032 2019 ret = -EINVAL; 2033 2020 goto out_qmi_bdf; ··· 2060 2047 memset(&bd, 0, sizeof(bd)); 2061 2048 ret = ath11k_core_fetch_bdf(ab, &bd); 2062 2049 if (ret) { 2063 - ath11k_warn(ab, "qmi failed to load bdf:\n"); 2050 + ath11k_warn(ab, "failed to fetch board file: %d\n", ret); 2064 2051 goto out; 2065 2052 } 2066 2053 ··· 2103 2090 if (ret < 0) 2104 2091 goto out_qmi_bdf; 2105 2092 2093 + ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi bdf download request remaining %i\n", 2094 + remaining); 2095 + 2106 2096 ret = qmi_send_request(&ab->qmi.handle, NULL, &txn, 2107 2097 QMI_WLANFW_BDF_DOWNLOAD_REQ_V01, 2108 2098 QMI_WLANFW_BDF_DOWNLOAD_REQ_MSG_V01_MAX_LEN, ··· 2120 2104 goto out_qmi_bdf; 2121 2105 2122 2106 if (resp.resp.result != QMI_RESULT_SUCCESS_V01) { 2123 - ath11k_warn(ab, "qmi BDF download failed, result: %d, err: %d\n", 2107 + ath11k_warn(ab, "bdf download request failed: %d %d\n", 2124 2108 resp.resp.result, resp.resp.error); 2125 2109 ret = resp.resp.result; 2126 2110 goto out_qmi_bdf; ··· 2216 2200 if (ret < 0) 2217 2201 goto out; 2218 2202 2203 + ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi m3 info req\n"); 2204 + 2219 2205 ret = qmi_send_request(&ab->qmi.handle, NULL, &txn, 2220 2206 QMI_WLANFW_M3_INFO_REQ_V01, 2221 2207 QMI_WLANFW_M3_INFO_REQ_MSG_V01_MAX_MSG_LEN, 2222 2208 qmi_wlanfw_m3_info_req_msg_v01_ei, &req); 2223 2209 if (ret < 0) { 2224 - ath11k_warn(ab, "qmi failed to send M3 information request, err = %d\n", 2210 + ath11k_warn(ab, "failed to send m3 information request: %d\n", 2225 2211 ret); 2226 2212 goto out; 2227 2213 } 2228 2214 2229 2215 ret = qmi_txn_wait(&txn, msecs_to_jiffies(ATH11K_QMI_WLANFW_TIMEOUT_MS)); 2230 2216 if (ret < 0) { 2231 - ath11k_warn(ab, "qmi failed M3 information request %d\n", ret); 2217 + ath11k_warn(ab, "failed to wait m3 information request: %d\n", ret); 2232 2218 goto out; 2233 2219 } 2234 2220 2235 2221 if (resp.resp.result != QMI_RESULT_SUCCESS_V01) { 2236 - ath11k_warn(ab, "qmi M3 info request failed, result: %d, err: %d\n", 2222 + ath11k_warn(ab, "m3 info request failed: %d %d\n", 2237 2223 resp.resp.result, resp.resp.error); 2238 2224 ret = -EINVAL; 2239 2225 goto out; ··· 2264 2246 if (ret < 0) 2265 2247 goto out; 2266 2248 2249 + ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi wlan mode req mode %d\n", mode); 2250 + 2267 2251 ret = qmi_send_request(&ab->qmi.handle, NULL, &txn, 2268 2252 QMI_WLANFW_WLAN_MODE_REQ_V01, 2269 2253 QMI_WLANFW_WLAN_MODE_REQ_MSG_V01_MAX_LEN, 2270 2254 qmi_wlanfw_wlan_mode_req_msg_v01_ei, &req); 2271 2255 if (ret < 0) { 2272 - ath11k_warn(ab, "qmi failed to send mode request, mode: %d, err = %d\n", 2256 + ath11k_warn(ab, "failed to send wlan mode request (mode %d): %d\n", 2273 2257 mode, ret); 2274 2258 goto out; 2275 2259 } ··· 2282 2262 ath11k_warn(ab, "WLFW service is dis-connected\n"); 2283 2263 return 0; 2284 2264 } 2285 - ath11k_warn(ab, "qmi failed set mode request, mode: %d, err = %d\n", 2265 + ath11k_warn(ab, "failed to wait wlan mode request (mode %d): %d\n", 2286 2266 mode, ret); 2287 2267 goto out; 2288 2268 } 2289 2269 2290 2270 if (resp.resp.result != QMI_RESULT_SUCCESS_V01) { 2291 - ath11k_warn(ab, "Mode request failed, mode: %d, result: %d err: %d\n", 2271 + ath11k_warn(ab, "wlan mode request failed (mode: %d): %d %d\n", 2292 2272 mode, resp.resp.result, resp.resp.error); 2293 2273 ret = -EINVAL; 2294 2274 goto out; ··· 2358 2338 if (ret < 0) 2359 2339 goto out; 2360 2340 2341 + ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi wlan cfg req\n"); 2342 + 2361 2343 ret = qmi_send_request(&ab->qmi.handle, NULL, &txn, 2362 2344 QMI_WLANFW_WLAN_CFG_REQ_V01, 2363 2345 QMI_WLANFW_WLAN_CFG_REQ_MSG_V01_MAX_LEN, 2364 2346 qmi_wlanfw_wlan_cfg_req_msg_v01_ei, req); 2365 2347 if (ret < 0) { 2366 - ath11k_warn(ab, "qmi failed to send wlan config request, err = %d\n", 2348 + ath11k_warn(ab, "failed to send wlan config request: %d\n", 2367 2349 ret); 2368 2350 goto out; 2369 2351 } 2370 2352 2371 2353 ret = qmi_txn_wait(&txn, msecs_to_jiffies(ATH11K_QMI_WLANFW_TIMEOUT_MS)); 2372 2354 if (ret < 0) { 2373 - ath11k_warn(ab, "qmi failed wlan config request, err = %d\n", ret); 2355 + ath11k_warn(ab, "failed to wait wlan config request: %d\n", ret); 2374 2356 goto out; 2375 2357 } 2376 2358 2377 2359 if (resp.resp.result != QMI_RESULT_SUCCESS_V01) { 2378 - ath11k_warn(ab, "qmi wlan config request failed, result: %d, err: %d\n", 2360 + ath11k_warn(ab, "wlan config request failed: %d %d\n", 2379 2361 resp.resp.result, resp.resp.error); 2380 2362 ret = -EINVAL; 2381 2363 goto out; ··· 2392 2370 { 2393 2371 int ret; 2394 2372 2373 + ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi firmware stop\n"); 2374 + 2395 2375 ret = ath11k_qmi_wlanfw_mode_send(ab, ATH11K_FIRMWARE_MODE_OFF); 2396 2376 if (ret < 0) { 2397 - ath11k_warn(ab, "qmi failed to send wlan mode off\n"); 2377 + ath11k_warn(ab, "qmi failed to send wlan mode off: %d\n", ret); 2398 2378 return; 2399 2379 } 2400 2380 } ··· 2406 2382 { 2407 2383 int ret; 2408 2384 2385 + ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi firmware start\n"); 2386 + 2409 2387 ret = ath11k_qmi_wlanfw_wlan_cfg_send(ab); 2410 2388 if (ret < 0) { 2411 - ath11k_warn(ab, "qmi failed to send wlan cfg:%d\n", ret); 2389 + ath11k_warn(ab, "qmi failed to send wlan cfg: %d\n", ret); 2412 2390 return ret; 2413 2391 } 2414 2392 2415 2393 ret = ath11k_qmi_wlanfw_mode_send(ab, mode); 2416 2394 if (ret < 0) { 2417 - ath11k_warn(ab, "qmi failed to send wlan fw mode:%d\n", ret); 2395 + ath11k_warn(ab, "qmi failed to send wlan fw mode: %d\n", ret); 2418 2396 return ret; 2419 2397 } 2420 2398 ··· 2430 2404 2431 2405 ret = ath11k_qmi_wlanfw_mode_send(ab, ATH11K_FIRMWARE_MODE_COLD_BOOT); 2432 2406 if (ret < 0) { 2433 - ath11k_warn(ab, "qmi failed to send wlan fw mode:%d\n", ret); 2407 + ath11k_warn(ab, "qmi failed to send wlan fw mode: %d\n", ret); 2434 2408 return ret; 2435 2409 } 2436 2410 ··· 2440 2414 (ab->qmi.cal_done == 1), 2441 2415 ATH11K_COLD_BOOT_FW_RESET_DELAY); 2442 2416 if (timeout <= 0) { 2443 - ath11k_warn(ab, "Coldboot Calibration failed - wait ended\n"); 2417 + ath11k_warn(ab, "coldboot calibration timed out\n"); 2444 2418 return 0; 2445 2419 } 2446 2420 ··· 2479 2453 2480 2454 ret = ath11k_qmi_fw_ind_register_send(ab); 2481 2455 if (ret < 0) { 2482 - ath11k_warn(ab, "qmi failed to send FW indication QMI:%d\n", ret); 2456 + ath11k_warn(ab, "failed to send qmi firmware indication: %d\n", 2457 + ret); 2483 2458 return ret; 2484 2459 } 2485 2460 2486 2461 ret = ath11k_qmi_host_cap_send(ab); 2487 2462 if (ret < 0) { 2488 - ath11k_warn(ab, "qmi failed to send host cap QMI:%d\n", ret); 2463 + ath11k_warn(ab, "failed to send qmi host cap: %d\n", ret); 2489 2464 return ret; 2490 2465 } 2491 2466 ··· 2500 2473 2501 2474 ret = ath11k_qmi_respond_fw_mem_request(ab); 2502 2475 if (ret < 0) { 2503 - ath11k_warn(ab, "qmi failed to respond fw mem req:%d\n", ret); 2476 + ath11k_warn(ab, "qmi failed to respond fw mem req: %d\n", ret); 2504 2477 return ret; 2505 2478 } 2506 2479 ··· 2514 2487 2515 2488 ret = ath11k_qmi_request_target_cap(ab); 2516 2489 if (ret < 0) { 2517 - ath11k_warn(ab, "qmi failed to req target capabilities:%d\n", ret); 2490 + ath11k_warn(ab, "failed to requeqst qmi target capabilities: %d\n", 2491 + ret); 2518 2492 return ret; 2519 2493 } 2520 2494 ··· 2524 2496 else 2525 2497 ret = ath11k_qmi_load_bdf_qmi(ab); 2526 2498 if (ret < 0) { 2527 - ath11k_warn(ab, "qmi failed to load board data file:%d\n", ret); 2499 + ath11k_warn(ab, "failed to load board data file: %d\n", ret); 2528 2500 return ret; 2529 2501 } 2530 2502 2531 2503 ret = ath11k_qmi_wlanfw_m3_info_send(ab); 2532 2504 if (ret < 0) { 2533 - ath11k_warn(ab, "qmi failed to send m3 info req:%d\n", ret); 2505 + ath11k_warn(ab, "failed to send qmi m3 info req: %d\n", ret); 2534 2506 return ret; 2535 2507 } 2536 2508 ··· 2551 2523 2552 2524 if (msg->mem_seg_len == 0 || 2553 2525 msg->mem_seg_len > ATH11K_QMI_WLANFW_MAX_NUM_MEM_SEG_V01) 2554 - ath11k_warn(ab, "Invalid memory segment length: %u\n", 2526 + ath11k_warn(ab, "invalid memory segment length: %u\n", 2555 2527 msg->mem_seg_len); 2556 2528 2557 2529 ab->qmi.mem_seg_count = msg->mem_seg_len; ··· 2566 2538 if (ab->bus_params.fixed_mem_region) { 2567 2539 ret = ath11k_qmi_assign_target_mem_chunk(ab); 2568 2540 if (ret) { 2569 - ath11k_warn(ab, "qmi failed to assign target memory: %d\n", 2541 + ath11k_warn(ab, "failed to assign qmi target memory: %d\n", 2570 2542 ret); 2571 2543 return; 2572 2544 } 2573 2545 } else { 2574 2546 ret = ath11k_qmi_alloc_target_mem_chunk(ab); 2575 2547 if (ret) { 2576 - ath11k_warn(ab, "qmi failed to alloc target memory: %d\n", 2548 + ath11k_warn(ab, "failed to allocate qmi target memory: %d\n", 2577 2549 ret); 2578 2550 return; 2579 2551 } ··· 2667 2639 ret = kernel_connect(qmi_hdl->sock, (struct sockaddr *)sq, 2668 2640 sizeof(*sq), 0); 2669 2641 if (ret) { 2670 - ath11k_warn(ab, "qmi failed to connect to remote service %d\n", ret); 2642 + ath11k_warn(ab, "failed to connect to qmi remote service: %d\n", ret); 2671 2643 return ret; 2672 2644 } 2673 2645 ··· 2753 2725 case ATH11K_QMI_EVENT_COLD_BOOT_CAL_DONE: 2754 2726 break; 2755 2727 default: 2756 - ath11k_warn(ab, "invalid event type: %d", event->type); 2728 + ath11k_warn(ab, "invalid qmi event type: %d", event->type); 2757 2729 break; 2758 2730 } 2759 2731 kfree(event); ··· 2774 2746 ret = qmi_handle_init(&ab->qmi.handle, ATH11K_QMI_RESP_LEN_MAX, 2775 2747 &ath11k_qmi_ops, ath11k_qmi_msg_handlers); 2776 2748 if (ret < 0) { 2777 - ath11k_warn(ab, "failed to initialize qmi handle\n"); 2749 + ath11k_warn(ab, "failed to initialize qmi handle: %d\n", ret); 2778 2750 return ret; 2779 2751 } 2780 2752 ··· 2793 2765 ATH11K_QMI_WLFW_SERVICE_VERS_V01, 2794 2766 ab->qmi.service_ins_id); 2795 2767 if (ret < 0) { 2796 - ath11k_warn(ab, "failed to add qmi lookup\n"); 2768 + ath11k_warn(ab, "failed to add qmi lookup: %d\n", ret); 2797 2769 destroy_workqueue(ab->qmi.event_wq); 2798 2770 return ret; 2799 2771 }
+6 -3
drivers/net/wireless/ath/ath11k/qmi.h
··· 21 21 #define ATH11K_QMI_WLFW_SERVICE_INS_ID_V01 0x02 22 22 #define ATH11K_QMI_WLFW_SERVICE_INS_ID_V01_QCA6390 0x01 23 23 #define ATH11K_QMI_WLFW_SERVICE_INS_ID_V01_IPQ8074 0x02 24 + #define ATH11K_QMI_WLFW_SERVICE_INS_ID_V01_QCN9074 0x07 24 25 #define ATH11K_QMI_WLANFW_MAX_TIMESTAMP_LEN_V01 32 25 26 #define ATH11K_QMI_RESP_LEN_MAX 8192 26 - #define ATH11K_QMI_WLANFW_MAX_NUM_MEM_SEG_V01 32 27 + #define ATH11K_QMI_WLANFW_MAX_NUM_MEM_SEG_V01 52 27 28 #define ATH11K_QMI_CALDB_SIZE 0x480000 28 29 #define ATH11K_QMI_BDF_EXT_STR_LENGTH 0x20 30 + #define ATH11K_QMI_FW_MEM_REQ_SEGMENT_CNT 3 29 31 30 32 #define QMI_WLFW_REQUEST_MEM_IND_V01 0x0035 31 33 #define QMI_WLFW_FW_MEM_READY_IND_V01 0x0037 ··· 143 141 #define QMI_IPQ8074_FW_MEM_MODE 0xFF 144 142 #define HOST_DDR_REGION_TYPE 0x1 145 143 #define BDF_MEM_REGION_TYPE 0x2 144 + #define M3_DUMP_REGION_TYPE 0x3 146 145 #define CALDB_MEM_REGION_TYPE 0x4 147 146 148 147 struct qmi_wlanfw_host_cap_req_msg_v01 { ··· 219 216 u64 fw_status; 220 217 }; 221 218 222 - #define QMI_WLANFW_REQUEST_MEM_IND_MSG_V01_MAX_LEN 1124 223 - #define QMI_WLANFW_RESPOND_MEM_REQ_MSG_V01_MAX_LEN 548 219 + #define QMI_WLANFW_REQUEST_MEM_IND_MSG_V01_MAX_LEN 1824 220 + #define QMI_WLANFW_RESPOND_MEM_REQ_MSG_V01_MAX_LEN 888 224 221 #define QMI_WLANFW_RESPOND_MEM_RESP_MSG_V01_MAX_LEN 7 225 222 #define QMI_WLANFW_REQUEST_MEM_IND_V01 0x0035 226 223 #define QMI_WLANFW_RESPOND_MEM_REQ_V01 0x0036
+205 -7
drivers/net/wireless/ath/ath11k/rx_desc.h
··· 414 414 415 415 #define RX_MPDU_START_RAW_MPDU BIT(0) 416 416 417 - struct rx_mpdu_start { 417 + struct rx_mpdu_start_ipq8074 { 418 418 __le16 info0; 419 419 __le16 phy_ppdu_id; 420 420 __le16 ast_index; ··· 438 438 __le16 qos_ctrl; 439 439 __le32 ht_ctrl; 440 440 __le32 raw; 441 + } __packed; 442 + 443 + #define RX_MPDU_START_INFO7_REO_DEST_IND GENMASK(4, 0) 444 + #define RX_MPDU_START_INFO7_LMAC_PEER_ID_MSB GENMASK(6, 5) 445 + #define RX_MPDU_START_INFO7_FLOW_ID_TOEPLITZ BIT(7) 446 + #define RX_MPDU_START_INFO7_PKT_SEL_FP_UCAST_DATA BIT(8) 447 + #define RX_MPDU_START_INFO7_PKT_SEL_FP_MCAST_DATA BIT(9) 448 + #define RX_MPDU_START_INFO7_PKT_SEL_FP_CTRL_BAR BIT(10) 449 + #define RX_MPDU_START_INFO7_RXDMA0_SRC_RING_SEL GENMASK(12, 11) 450 + #define RX_MPDU_START_INFO7_RXDMA0_DST_RING_SEL GENMASK(14, 13) 451 + 452 + #define RX_MPDU_START_INFO8_REO_QUEUE_DESC_HI GENMASK(7, 0) 453 + #define RX_MPDU_START_INFO8_RECV_QUEUE_NUM GENMASK(23, 8) 454 + #define RX_MPDU_START_INFO8_PRE_DELIM_ERR_WARN BIT(24) 455 + #define RX_MPDU_START_INFO8_FIRST_DELIM_ERR BIT(25) 456 + 457 + #define RX_MPDU_START_INFO9_EPD_EN BIT(0) 458 + #define RX_MPDU_START_INFO9_ALL_FRAME_ENCPD BIT(1) 459 + #define RX_MPDU_START_INFO9_ENC_TYPE GENMASK(5, 2) 460 + #define RX_MPDU_START_INFO9_VAR_WEP_KEY_WIDTH GENMASK(7, 6) 461 + #define RX_MPDU_START_INFO9_MESH_STA GENMASK(9, 8) 462 + #define RX_MPDU_START_INFO9_BSSID_HIT BIT(10) 463 + #define RX_MPDU_START_INFO9_BSSID_NUM GENMASK(14, 11) 464 + #define RX_MPDU_START_INFO9_TID GENMASK(18, 15) 465 + 466 + #define RX_MPDU_START_INFO10_RXPCU_MPDU_FLTR GENMASK(1, 0) 467 + #define RX_MPDU_START_INFO10_SW_FRAME_GRP_ID GENMASK(8, 2) 468 + #define RX_MPDU_START_INFO10_NDP_FRAME BIT(9) 469 + #define RX_MPDU_START_INFO10_PHY_ERR BIT(10) 470 + #define RX_MPDU_START_INFO10_PHY_ERR_MPDU_HDR BIT(11) 471 + #define RX_MPDU_START_INFO10_PROTO_VER_ERR BIT(12) 472 + #define RX_MPDU_START_INFO10_AST_LOOKUP_VALID BIT(13) 473 + 474 + #define RX_MPDU_START_INFO11_MPDU_FCTRL_VALID BIT(0) 475 + #define RX_MPDU_START_INFO11_MPDU_DUR_VALID BIT(1) 476 + #define RX_MPDU_START_INFO11_MAC_ADDR1_VALID BIT(2) 477 + #define RX_MPDU_START_INFO11_MAC_ADDR2_VALID BIT(3) 478 + #define RX_MPDU_START_INFO11_MAC_ADDR3_VALID BIT(4) 479 + #define RX_MPDU_START_INFO11_MAC_ADDR4_VALID BIT(5) 480 + #define RX_MPDU_START_INFO11_MPDU_SEQ_CTRL_VALID BIT(6) 481 + #define RX_MPDU_START_INFO11_MPDU_QOS_CTRL_VALID BIT(7) 482 + #define RX_MPDU_START_INFO11_MPDU_HT_CTRL_VALID BIT(8) 483 + #define RX_MPDU_START_INFO11_ENCRYPT_INFO_VALID BIT(9) 484 + #define RX_MPDU_START_INFO11_MPDU_FRAG_NUMBER GENMASK(13, 10) 485 + #define RX_MPDU_START_INFO11_MORE_FRAG_FLAG BIT(14) 486 + #define RX_MPDU_START_INFO11_FROM_DS BIT(16) 487 + #define RX_MPDU_START_INFO11_TO_DS BIT(17) 488 + #define RX_MPDU_START_INFO11_ENCRYPTED BIT(18) 489 + #define RX_MPDU_START_INFO11_MPDU_RETRY BIT(19) 490 + #define RX_MPDU_START_INFO11_MPDU_SEQ_NUM GENMASK(31, 20) 491 + 492 + #define RX_MPDU_START_INFO12_KEY_ID GENMASK(7, 0) 493 + #define RX_MPDU_START_INFO12_NEW_PEER_ENTRY BIT(8) 494 + #define RX_MPDU_START_INFO12_DECRYPT_NEEDED BIT(9) 495 + #define RX_MPDU_START_INFO12_DECAP_TYPE GENMASK(11, 10) 496 + #define RX_MPDU_START_INFO12_VLAN_TAG_C_PADDING BIT(12) 497 + #define RX_MPDU_START_INFO12_VLAN_TAG_S_PADDING BIT(13) 498 + #define RX_MPDU_START_INFO12_STRIP_VLAN_TAG_C BIT(14) 499 + #define RX_MPDU_START_INFO12_STRIP_VLAN_TAG_S BIT(15) 500 + #define RX_MPDU_START_INFO12_PRE_DELIM_COUNT GENMASK(27, 16) 501 + #define RX_MPDU_START_INFO12_AMPDU_FLAG BIT(28) 502 + #define RX_MPDU_START_INFO12_BAR_FRAME BIT(29) 503 + #define RX_MPDU_START_INFO12_RAW_MPDU BIT(30) 504 + 505 + #define RX_MPDU_START_INFO13_MPDU_LEN GENMASK(13, 0) 506 + #define RX_MPDU_START_INFO13_FIRST_MPDU BIT(14) 507 + #define RX_MPDU_START_INFO13_MCAST_BCAST BIT(15) 508 + #define RX_MPDU_START_INFO13_AST_IDX_NOT_FOUND BIT(16) 509 + #define RX_MPDU_START_INFO13_AST_IDX_TIMEOUT BIT(17) 510 + #define RX_MPDU_START_INFO13_POWER_MGMT BIT(18) 511 + #define RX_MPDU_START_INFO13_NON_QOS BIT(19) 512 + #define RX_MPDU_START_INFO13_NULL_DATA BIT(20) 513 + #define RX_MPDU_START_INFO13_MGMT_TYPE BIT(21) 514 + #define RX_MPDU_START_INFO13_CTRL_TYPE BIT(22) 515 + #define RX_MPDU_START_INFO13_MORE_DATA BIT(23) 516 + #define RX_MPDU_START_INFO13_EOSP BIT(24) 517 + #define RX_MPDU_START_INFO13_FRAGMENT BIT(25) 518 + #define RX_MPDU_START_INFO13_ORDER BIT(26) 519 + #define RX_MPDU_START_INFO13_UAPSD_TRIGGER BIT(27) 520 + #define RX_MPDU_START_INFO13_ENCRYPT_REQUIRED BIT(28) 521 + #define RX_MPDU_START_INFO13_DIRECTED BIT(29) 522 + #define RX_MPDU_START_INFO13_AMSDU_PRESENT BIT(30) 523 + 524 + struct rx_mpdu_start_qcn9074 { 525 + __le32 info7; 526 + __le32 reo_queue_desc_lo; 527 + __le32 info8; 528 + __le32 pn[4]; 529 + __le32 info9; 530 + __le32 peer_meta_data; 531 + __le16 info10; 532 + __le16 phy_ppdu_id; 533 + __le16 ast_index; 534 + __le16 sw_peer_id; 535 + __le32 info11; 536 + __le32 info12; 537 + __le32 info13; 538 + __le16 frame_ctrl; 539 + __le16 duration; 540 + u8 addr1[ETH_ALEN]; 541 + u8 addr2[ETH_ALEN]; 542 + u8 addr3[ETH_ALEN]; 543 + __le16 seq_ctrl; 544 + u8 addr4[ETH_ALEN]; 545 + __le16 qos_ctrl; 546 + __le32 ht_ctrl; 441 547 } __packed; 442 548 443 549 /* rx_mpdu_start ··· 778 672 #define RX_MSDU_START_INFO3_RECEPTION_TYPE GENMASK(23, 21) 779 673 #define RX_MSDU_START_INFO3_MIMO_SS_BITMAP GENMASK(31, 24) 780 674 781 - struct rx_msdu_start { 675 + struct rx_msdu_start_ipq8074 { 782 676 __le16 info0; 783 677 __le16 phy_ppdu_id; 784 678 __le32 info1; ··· 788 682 __le32 info3; 789 683 __le32 ppdu_start_timestamp; 790 684 __le32 phy_meta_data; 685 + } __packed; 686 + 687 + struct rx_msdu_start_qcn9074 { 688 + __le16 info0; 689 + __le16 phy_ppdu_id; 690 + __le32 info1; 691 + __le32 info2; 692 + __le32 toeplitz_hash; 693 + __le32 flow_id_toeplitz; 694 + __le32 info3; 695 + __le32 ppdu_start_timestamp; 696 + __le32 phy_meta_data; 697 + __le16 vlan_ctag_c1; 698 + __le16 vlan_stag_c1; 791 699 } __packed; 792 700 793 701 /* rx_msdu_start ··· 1014 894 #define RX_MSDU_END_INFO5_REO_DEST_IND GENMASK(5, 1) 1015 895 #define RX_MSDU_END_INFO5_FLOW_IDX GENMASK(25, 6) 1016 896 1017 - struct rx_msdu_end { 897 + struct rx_msdu_end_ipq8074 { 1018 898 __le16 info0; 1019 899 __le16 phy_ppdu_id; 1020 900 __le16 ip_hdr_cksum; ··· 1035 915 __le32 fse_metadata; 1036 916 __le16 cce_metadata; 1037 917 __le16 sa_sw_peer_id; 918 + } __packed; 919 + 920 + #define RX_MSDU_END_MPDU_LENGTH_INFO GENMASK(13, 0) 921 + 922 + #define RX_MSDU_END_INFO2_DA_OFFSET GENMASK(5, 0) 923 + #define RX_MSDU_END_INFO2_SA_OFFSET GENMASK(11, 6) 924 + #define RX_MSDU_END_INFO2_DA_OFFSET_VALID BIT(12) 925 + #define RX_MSDU_END_INFO2_SA_OFFSET_VALID BIT(13) 926 + #define RX_MSDU_END_INFO2_L3_TYPE GENMASK(31, 16) 927 + 928 + #define RX_MSDU_END_INFO4_SA_IDX_TIMEOUT BIT(0) 929 + #define RX_MSDU_END_INFO4_DA_IDX_TIMEOUT BIT(1) 930 + #define RX_MSDU_END_INFO4_MSDU_LIMIT_ERR BIT(2) 931 + #define RX_MSDU_END_INFO4_FLOW_IDX_TIMEOUT BIT(3) 932 + #define RX_MSDU_END_INFO4_FLOW_IDX_INVALID BIT(4) 933 + #define RX_MSDU_END_INFO4_WIFI_PARSER_ERR BIT(5) 934 + #define RX_MSDU_END_INFO4_AMSDU_PARSER_ERR BIT(6) 935 + #define RX_MSDU_END_INFO4_SA_IS_VALID BIT(7) 936 + #define RX_MSDU_END_INFO4_DA_IS_VALID BIT(8) 937 + #define RX_MSDU_END_INFO4_DA_IS_MCBC BIT(9) 938 + #define RX_MSDU_END_INFO4_L3_HDR_PADDING GENMASK(11, 10) 939 + #define RX_MSDU_END_INFO4_FIRST_MSDU BIT(12) 940 + #define RX_MSDU_END_INFO4_LAST_MSDU BIT(13) 941 + 942 + #define RX_MSDU_END_INFO6_AGGR_COUNT GENMASK(7, 0) 943 + #define RX_MSDU_END_INFO6_FLOW_AGGR_CONTN BIT(8) 944 + #define RX_MSDU_END_INFO6_FISA_TIMEOUT BIT(9) 945 + 946 + struct rx_msdu_end_qcn9074 { 947 + __le16 info0; 948 + __le16 phy_ppdu_id; 949 + __le16 ip_hdr_cksum; 950 + __le16 mpdu_length_info; 951 + __le32 info1; 952 + __le32 rule_indication[2]; 953 + __le32 info2; 954 + __le32 ipv6_options_crc; 955 + __le32 tcp_seq_num; 956 + __le32 tcp_ack_num; 957 + __le16 info3; 958 + __le16 window_size; 959 + __le16 tcp_udp_cksum; 960 + __le16 info4; 961 + __le16 sa_idx; 962 + __le16 da_idx; 963 + __le32 info5; 964 + __le32 fse_metadata; 965 + __le16 cce_metadata; 966 + __le16 sa_sw_peer_id; 967 + __le32 info6; 968 + __le16 cum_l4_cksum; 969 + __le16 cum_ip_length; 1038 970 } __packed; 1039 971 1040 972 /* rx_msdu_end ··· 1362 1190 1363 1191 #define HAL_RX_DESC_HDR_STATUS_LEN 120 1364 1192 1365 - struct hal_rx_desc { 1193 + struct hal_rx_desc_ipq8074 { 1366 1194 __le32 msdu_end_tag; 1367 - struct rx_msdu_end msdu_end; 1195 + struct rx_msdu_end_ipq8074 msdu_end; 1368 1196 __le32 rx_attn_tag; 1369 1197 struct rx_attention attention; 1370 1198 __le32 msdu_start_tag; 1371 - struct rx_msdu_start msdu_start; 1199 + struct rx_msdu_start_ipq8074 msdu_start; 1372 1200 u8 rx_padding0[HAL_RX_DESC_PADDING0_BYTES]; 1373 1201 __le32 mpdu_start_tag; 1374 - struct rx_mpdu_start mpdu_start; 1202 + struct rx_mpdu_start_ipq8074 mpdu_start; 1375 1203 __le32 mpdu_end_tag; 1376 1204 struct rx_mpdu_end mpdu_end; 1377 1205 u8 rx_padding1[HAL_RX_DESC_PADDING1_BYTES]; ··· 1379 1207 __le32 phy_ppdu_id; 1380 1208 u8 hdr_status[HAL_RX_DESC_HDR_STATUS_LEN]; 1381 1209 u8 msdu_payload[0]; 1210 + } __packed; 1211 + 1212 + struct hal_rx_desc_qcn9074 { 1213 + __le32 msdu_end_tag; 1214 + struct rx_msdu_end_qcn9074 msdu_end; 1215 + __le32 rx_attn_tag; 1216 + struct rx_attention attention; 1217 + __le32 msdu_start_tag; 1218 + struct rx_msdu_start_qcn9074 msdu_start; 1219 + u8 rx_padding0[HAL_RX_DESC_PADDING0_BYTES]; 1220 + __le32 mpdu_start_tag; 1221 + struct rx_mpdu_start_qcn9074 mpdu_start; 1222 + __le32 mpdu_end_tag; 1223 + struct rx_mpdu_end mpdu_end; 1224 + u8 rx_padding1[HAL_RX_DESC_PADDING1_BYTES]; 1225 + __le32 hdr_status_tag; 1226 + __le32 phy_ppdu_id; 1227 + u8 hdr_status[HAL_RX_DESC_HDR_STATUS_LEN]; 1228 + u8 msdu_payload[0]; 1229 + } __packed; 1230 + 1231 + struct hal_rx_desc { 1232 + union { 1233 + struct hal_rx_desc_ipq8074 ipq8074; 1234 + struct hal_rx_desc_qcn9074 qcn9074; 1235 + } u; 1382 1236 } __packed; 1383 1237 1384 1238 #define HAL_RX_RU_ALLOC_TYPE_MAX 6
+24 -40
drivers/net/wireless/ath/ath11k/wmi.c
··· 5417 5417 return 0; 5418 5418 } 5419 5419 5420 - static int 5421 - ath11k_pull_pdev_temp_ev(struct ath11k_base *ab, u8 *evt_buf, 5422 - u32 len, const struct wmi_pdev_temperature_event *ev) 5423 - { 5424 - const void **tb; 5425 - int ret; 5426 - 5427 - tb = ath11k_wmi_tlv_parse_alloc(ab, evt_buf, len, GFP_ATOMIC); 5428 - if (IS_ERR(tb)) { 5429 - ret = PTR_ERR(tb); 5430 - ath11k_warn(ab, "failed to parse tlv: %d\n", ret); 5431 - return ret; 5432 - } 5433 - 5434 - ev = tb[WMI_TAG_PDEV_TEMPERATURE_EVENT]; 5435 - if (!ev) { 5436 - ath11k_warn(ab, "failed to fetch pdev temp ev"); 5437 - kfree(tb); 5438 - return -EPROTO; 5439 - } 5440 - 5441 - kfree(tb); 5442 - return 0; 5443 - } 5444 - 5445 5420 size_t ath11k_wmi_fw_stats_num_vdevs(struct list_head *head) 5446 5421 { 5447 5422 struct ath11k_fw_stats_vdev *i; ··· 6171 6196 } 6172 6197 } 6173 6198 6174 - /* TODO: Pending handle beacon implementation 6175 - *if (ieee80211_is_beacon(hdr->frame_control)) 6176 - * ath11k_mac_handle_beacon(ar, skb); 6177 - */ 6199 + if (ieee80211_is_beacon(hdr->frame_control)) 6200 + ath11k_mac_handle_beacon(ar, skb); 6178 6201 6179 6202 ath11k_dbg(ab, ATH11K_DBG_MGMT, 6180 6203 "event mgmt rx skb %pK len %d ftype %02x stype %02x\n", ··· 6391 6418 6392 6419 switch (roam_ev.reason) { 6393 6420 case WMI_ROAM_REASON_BEACON_MISS: 6394 - /* TODO: Pending beacon miss and connection_loss_work 6395 - * implementation 6396 - * ath11k_mac_handle_beacon_miss(ar, vdev_id); 6397 - */ 6421 + ath11k_mac_handle_beacon_miss(ar, roam_ev.vdev_id); 6398 6422 break; 6399 6423 case WMI_ROAM_REASON_BETTER_AP: 6400 6424 case WMI_ROAM_REASON_LOW_RSSI: ··· 6819 6849 struct sk_buff *skb) 6820 6850 { 6821 6851 struct ath11k *ar; 6822 - struct wmi_pdev_temperature_event ev = {0}; 6852 + const void **tb; 6853 + const struct wmi_pdev_temperature_event *ev; 6854 + int ret; 6823 6855 6824 - if (ath11k_pull_pdev_temp_ev(ab, skb->data, skb->len, &ev) != 0) { 6825 - ath11k_warn(ab, "failed to extract pdev temperature event"); 6856 + tb = ath11k_wmi_tlv_parse_alloc(ab, skb->data, skb->len, GFP_ATOMIC); 6857 + if (IS_ERR(tb)) { 6858 + ret = PTR_ERR(tb); 6859 + ath11k_warn(ab, "failed to parse tlv: %d\n", ret); 6860 + return; 6861 + } 6862 + 6863 + ev = tb[WMI_TAG_PDEV_TEMPERATURE_EVENT]; 6864 + if (!ev) { 6865 + ath11k_warn(ab, "failed to fetch pdev temp ev"); 6866 + kfree(tb); 6826 6867 return; 6827 6868 } 6828 6869 6829 6870 ath11k_dbg(ab, ATH11K_DBG_WMI, 6830 - "pdev temperature ev temp %d pdev_id %d\n", ev.temp, ev.pdev_id); 6871 + "pdev temperature ev temp %d pdev_id %d\n", ev->temp, ev->pdev_id); 6831 6872 6832 - ar = ath11k_mac_get_ar_by_pdev_id(ab, ev.pdev_id); 6873 + ar = ath11k_mac_get_ar_by_pdev_id(ab, ev->pdev_id); 6833 6874 if (!ar) { 6834 - ath11k_warn(ab, "invalid pdev id in pdev temperature ev %d", ev.pdev_id); 6875 + ath11k_warn(ab, "invalid pdev id in pdev temperature ev %d", ev->pdev_id); 6876 + kfree(tb); 6835 6877 return; 6836 6878 } 6837 6879 6838 - ath11k_thermal_event_temperature(ar, ev.temp); 6880 + ath11k_thermal_event_temperature(ar, ev->temp); 6881 + 6882 + kfree(tb); 6839 6883 } 6840 6884 6841 6885 static void ath11k_fils_discovery_event(struct ath11k_base *ab,
-2
drivers/net/wireless/intel/iwlegacy/3945-mac.c
··· 751 751 static void 752 752 il3945_hdl_add_sta(struct il_priv *il, struct il_rx_buf *rxb) 753 753 { 754 - #ifdef CONFIG_IWLEGACY_DEBUG 755 754 struct il_rx_pkt *pkt = rxb_addr(rxb); 756 - #endif 757 755 758 756 D_RX("Received C_ADD_STA: 0x%02X\n", pkt->u.status); 759 757 }
-2
drivers/net/wireless/intel/iwlegacy/common.c
··· 1430 1430 il_hdl_scan_complete(struct il_priv *il, struct il_rx_buf *rxb) 1431 1431 { 1432 1432 1433 - #ifdef CONFIG_IWLEGACY_DEBUG 1434 1433 struct il_rx_pkt *pkt = rxb_addr(rxb); 1435 1434 struct il_scancomplete_notification *scan_notif = (void *)pkt->u.raw; 1436 - #endif 1437 1435 1438 1436 D_SCAN("Scan complete: %d channels (TSF 0x%08X:%08X) - %d\n", 1439 1437 scan_notif->scanned_channels, scan_notif->tsf_low,
+1 -1
drivers/net/wireless/intel/iwlegacy/common.h
··· 2937 2937 } while (0) 2938 2938 2939 2939 #else 2940 - #define IL_DBG(level, fmt, args...) 2940 + #define IL_DBG(level, fmt, args...) no_printk(fmt, ##args) 2941 2941 static inline void 2942 2942 il_print_hex_dump(struct il_priv *il, int level, const void *p, u32 len) 2943 2943 {
+1 -1
drivers/net/wireless/mediatek/mt7601u/eeprom.c
··· 99 99 { 100 100 u16 nic_conf1 = get_unaligned_le16(eeprom + MT_EE_NIC_CONF_1); 101 101 102 - return ~nic_conf1 && (nic_conf1 & MT_EE_NIC_CONF_1_TX_ALC_EN); 102 + return (u16)~nic_conf1 && (nic_conf1 & MT_EE_NIC_CONF_1_TX_ALC_EN); 103 103 } 104 104 105 105 static void
+1
drivers/net/wireless/mediatek/mt7601u/init.c
··· 610 610 611 611 wiphy->features |= NL80211_FEATURE_ACTIVE_MONITOR; 612 612 wiphy->interface_modes = BIT(NL80211_IFTYPE_STATION); 613 + wiphy->flags |= WIPHY_FLAG_SUPPORTS_TDLS; 613 614 614 615 wiphy_ext_feature_set(wiphy, NL80211_EXT_FEATURE_CQM_RSSI_LIST); 615 616
+5 -9
drivers/net/wireless/microchip/wilc1000/netdev.c
··· 24 24 25 25 static irqreturn_t isr_uh_routine(int irq, void *user_data) 26 26 { 27 - struct net_device *dev = user_data; 28 - struct wilc_vif *vif = netdev_priv(dev); 29 - struct wilc *wilc = vif->wilc; 27 + struct wilc *wilc = user_data; 30 28 31 29 if (wilc->close) { 32 - netdev_err(dev, "Can't handle UH interrupt\n"); 30 + pr_err("Can't handle UH interrupt"); 33 31 return IRQ_HANDLED; 34 32 } 35 33 return IRQ_WAKE_THREAD; ··· 35 37 36 38 static irqreturn_t isr_bh_routine(int irq, void *userdata) 37 39 { 38 - struct net_device *dev = userdata; 39 - struct wilc_vif *vif = netdev_priv(userdata); 40 - struct wilc *wilc = vif->wilc; 40 + struct wilc *wilc = userdata; 41 41 42 42 if (wilc->close) { 43 - netdev_err(dev, "Can't handle BH interrupt\n"); 43 + pr_err("Can't handle BH interrupt\n"); 44 44 return IRQ_HANDLED; 45 45 } 46 46 ··· 56 60 ret = request_threaded_irq(wl->dev_irq_num, isr_uh_routine, 57 61 isr_bh_routine, 58 62 IRQF_TRIGGER_FALLING | IRQF_ONESHOT, 59 - "WILC_IRQ", dev); 63 + "WILC_IRQ", wl); 60 64 if (ret) { 61 65 netdev_err(dev, "Failed to request IRQ [%d]\n", ret); 62 66 return ret;
+1 -1
drivers/net/wireless/microchip/wilc1000/sdio.c
··· 947 947 for (i = 0; (i < 3) && (nint > 0); i++, nint--) 948 948 reg |= BIT(i); 949 949 950 - ret = wilc_sdio_read_reg(wilc, WILC_INTR2_ENABLE, &reg); 950 + ret = wilc_sdio_write_reg(wilc, WILC_INTR2_ENABLE, reg); 951 951 if (ret) { 952 952 dev_err(&func->dev, 953 953 "Failed write reg (%08x)...\n",
+52 -4
drivers/net/wireless/microchip/wilc1000/wlan.c
··· 552 552 void chip_allow_sleep(struct wilc *wilc) 553 553 { 554 554 u32 reg = 0; 555 + const struct wilc_hif_func *hif_func = wilc->hif_func; 556 + u32 wakeup_reg, wakeup_bit; 557 + u32 to_host_from_fw_reg, to_host_from_fw_bit; 558 + u32 from_host_to_fw_reg, from_host_to_fw_bit; 559 + u32 trials = 100; 560 + int ret; 555 561 556 - wilc->hif_func->hif_read_reg(wilc, WILC_SDIO_WAKEUP_REG, &reg); 562 + if (wilc->io_type == WILC_HIF_SDIO) { 563 + wakeup_reg = WILC_SDIO_WAKEUP_REG; 564 + wakeup_bit = WILC_SDIO_WAKEUP_BIT; 565 + from_host_to_fw_reg = WILC_SDIO_HOST_TO_FW_REG; 566 + from_host_to_fw_bit = WILC_SDIO_HOST_TO_FW_BIT; 567 + to_host_from_fw_reg = WILC_SDIO_FW_TO_HOST_REG; 568 + to_host_from_fw_bit = WILC_SDIO_FW_TO_HOST_BIT; 569 + } else { 570 + wakeup_reg = WILC_SPI_WAKEUP_REG; 571 + wakeup_bit = WILC_SPI_WAKEUP_BIT; 572 + from_host_to_fw_reg = WILC_SPI_HOST_TO_FW_REG; 573 + from_host_to_fw_bit = WILC_SPI_HOST_TO_FW_BIT; 574 + to_host_from_fw_reg = WILC_SPI_FW_TO_HOST_REG; 575 + to_host_from_fw_bit = WILC_SPI_FW_TO_HOST_BIT; 576 + } 557 577 558 - wilc->hif_func->hif_write_reg(wilc, WILC_SDIO_WAKEUP_REG, 559 - reg & ~WILC_SDIO_WAKEUP_BIT); 560 - wilc->hif_func->hif_write_reg(wilc, WILC_SDIO_HOST_TO_FW_REG, 0); 578 + while (trials--) { 579 + ret = hif_func->hif_read_reg(wilc, to_host_from_fw_reg, &reg); 580 + if (ret) 581 + return; 582 + if ((reg & to_host_from_fw_bit) == 0) 583 + break; 584 + } 585 + if (!trials) 586 + pr_warn("FW not responding\n"); 587 + 588 + /* Clear bit 1 */ 589 + ret = hif_func->hif_read_reg(wilc, wakeup_reg, &reg); 590 + if (ret) 591 + return; 592 + if (reg & wakeup_bit) { 593 + reg &= ~wakeup_bit; 594 + ret = hif_func->hif_write_reg(wilc, wakeup_reg, reg); 595 + if (ret) 596 + return; 597 + } 598 + 599 + ret = hif_func->hif_read_reg(wilc, from_host_to_fw_reg, &reg); 600 + if (ret) 601 + return; 602 + if (reg & from_host_to_fw_bit) { 603 + reg &= ~from_host_to_fw_bit; 604 + ret = hif_func->hif_write_reg(wilc, from_host_to_fw_reg, reg); 605 + if (ret) 606 + return; 607 + 608 + } 561 609 } 562 610 EXPORT_SYMBOL_GPL(chip_allow_sleep); 563 611
+6
drivers/net/wireless/microchip/wilc1000/wlan.h
··· 97 97 #define WILC_SPI_WAKEUP_REG 0x1 98 98 #define WILC_SPI_WAKEUP_BIT BIT(1) 99 99 100 + #define WILC_SPI_HOST_TO_FW_REG 0x0b 101 + #define WILC_SPI_HOST_TO_FW_BIT BIT(0) 102 + 103 + #define WILC_SPI_FW_TO_HOST_REG 0x10 104 + #define WILC_SPI_FW_TO_HOST_BIT BIT(0) 105 + 100 106 #define WILC_SPI_PROTOCOL_OFFSET (WILC_SPI_PROTOCOL_CONFIG - \ 101 107 WILC_SPI_REG_BASE) 102 108
+10 -3
drivers/net/wireless/realtek/rtw88/coex.c
··· 787 787 { 788 788 struct rtw_chip_info *chip = rtwdev->chip; 789 789 struct rtw_coex_dm *coex_dm = &rtwdev->coex.dm; 790 - struct rtw_efuse *efuse = &rtwdev->efuse; 791 790 u8 link = 0; 792 791 u8 center_chan = 0; 793 792 u8 bw; ··· 797 798 if (type != COEX_MEDIA_DISCONNECT) 798 799 center_chan = rtwdev->hal.current_channel; 799 800 800 - if (center_chan == 0 || (efuse->share_ant && center_chan <= 14)) { 801 + if (center_chan == 0) { 801 802 link = 0; 802 803 center_chan = 0; 803 804 bw = 0; ··· 2324 2325 if (efuse->share_ant) { /* Shared-Ant */ 2325 2326 if (coex_stat->bt_a2dp_exist) { 2326 2327 slot_type = TDMA_4SLOT; 2327 - table_case = 9; 2328 2328 tdma_case = 11; 2329 + if (coex_stat->wl_gl_busy) 2330 + table_case = 26; 2331 + else 2332 + table_case = 9; 2329 2333 } else { 2330 2334 table_case = 9; 2331 2335 tdma_case = 7; ··· 2646 2644 /* red x issue */ 2647 2645 rtw_write8(rtwdev, 0xff1a, 0x0); 2648 2646 rtw_coex_set_gnt_debug(rtwdev); 2647 + } 2648 + 2649 + void rtw_coex_power_off_setting(struct rtw_dev *rtwdev) 2650 + { 2651 + rtw_write16(rtwdev, REG_WIFI_BT_INFO, BIT_BT_INT_EN); 2649 2652 } 2650 2653 2651 2654 void rtw_coex_init_hw_config(struct rtw_dev *rtwdev, bool wifi_only)
+1
drivers/net/wireless/realtek/rtw88/coex.h
··· 393 393 void rtw_coex_wl_ccklock_work(struct work_struct *work); 394 394 395 395 void rtw_coex_power_on_setting(struct rtw_dev *rtwdev); 396 + void rtw_coex_power_off_setting(struct rtw_dev *rtwdev); 396 397 void rtw_coex_init_hw_config(struct rtw_dev *rtwdev, bool wifi_only); 397 398 void rtw_coex_ips_notify(struct rtw_dev *rtwdev, u8 type); 398 399 void rtw_coex_lps_notify(struct rtw_dev *rtwdev, u8 type);
+42 -1
drivers/net/wireless/realtek/rtw88/debug.c
··· 10 10 #include "fw.h" 11 11 #include "debug.h" 12 12 #include "phy.h" 13 + #include "reg.h" 13 14 14 15 #ifdef CONFIG_RTW88_DEBUGFS 15 16 ··· 271 270 272 271 if (num != 2) { 273 272 rtw_warn(rtwdev, "invalid arguments\n"); 274 - return num; 273 + return -EINVAL; 275 274 } 276 275 277 276 debugfs_priv->rsvd_page.page_offset = offset; ··· 819 818 return 0; 820 819 } 821 820 821 + static ssize_t rtw_debugfs_set_fw_crash(struct file *filp, 822 + const char __user *buffer, 823 + size_t count, loff_t *loff) 824 + { 825 + struct seq_file *seqpriv = (struct seq_file *)filp->private_data; 826 + struct rtw_debugfs_priv *debugfs_priv = seqpriv->private; 827 + struct rtw_dev *rtwdev = debugfs_priv->rtwdev; 828 + char tmp[32 + 1]; 829 + bool input; 830 + int ret; 831 + 832 + rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 1); 833 + 834 + ret = kstrtobool(tmp, &input); 835 + if (ret) 836 + return -EINVAL; 837 + 838 + if (!input) 839 + return -EINVAL; 840 + 841 + rtw_write8(rtwdev, REG_HRCV_MSG, 1); 842 + 843 + return count; 844 + } 845 + 846 + static int rtw_debugfs_get_fw_crash(struct seq_file *m, void *v) 847 + { 848 + struct rtw_debugfs_priv *debugfs_priv = m->private; 849 + struct rtw_dev *rtwdev = debugfs_priv->rtwdev; 850 + 851 + seq_printf(m, "%d\n", test_bit(RTW_FLAG_RESTARTING, rtwdev->flags)); 852 + return 0; 853 + } 854 + 822 855 #define rtw_debug_impl_mac(page, addr) \ 823 856 static struct rtw_debugfs_priv rtw_debug_priv_mac_ ##page = { \ 824 857 .cb_read = rtw_debug_get_mac_page, \ ··· 956 921 .cb_read = rtw_debugfs_get_coex_info, 957 922 }; 958 923 924 + static struct rtw_debugfs_priv rtw_debug_priv_fw_crash = { 925 + .cb_write = rtw_debugfs_set_fw_crash, 926 + .cb_read = rtw_debugfs_get_fw_crash, 927 + }; 928 + 959 929 #define rtw_debugfs_add_core(name, mode, fopname, parent) \ 960 930 do { \ 961 931 rtw_debug_priv_ ##name.rtwdev = rtwdev; \ ··· 1034 994 } 1035 995 rtw_debugfs_add_r(rf_dump); 1036 996 rtw_debugfs_add_r(tx_pwr_tbl); 997 + rtw_debugfs_add_rw(fw_crash); 1037 998 } 1038 999 1039 1000 #endif /* CONFIG_RTW88_DEBUGFS */
+16
drivers/net/wireless/realtek/rtw88/hci.h
··· 11 11 struct rtw_tx_pkt_info *pkt_info, 12 12 struct sk_buff *skb); 13 13 void (*tx_kick_off)(struct rtw_dev *rtwdev); 14 + void (*flush_queues)(struct rtw_dev *rtwdev, u32 queues, bool drop); 14 15 int (*setup)(struct rtw_dev *rtwdev); 15 16 int (*start)(struct rtw_dev *rtwdev); 16 17 void (*stop)(struct rtw_dev *rtwdev); ··· 257 256 static inline enum rtw_hci_type rtw_hci_type(struct rtw_dev *rtwdev) 258 257 { 259 258 return rtwdev->hci.type; 259 + } 260 + 261 + static inline void rtw_hci_flush_queues(struct rtw_dev *rtwdev, u32 queues, 262 + bool drop) 263 + { 264 + if (rtwdev->hci.ops->flush_queues) 265 + rtwdev->hci.ops->flush_queues(rtwdev, queues, drop); 266 + } 267 + 268 + static inline void rtw_hci_flush_all_queues(struct rtw_dev *rtwdev, bool drop) 269 + { 270 + if (rtwdev->hci.ops->flush_queues) 271 + rtwdev->hci.ops->flush_queues(rtwdev, 272 + BIT(rtwdev->hw->queues) - 1, 273 + drop); 260 274 } 261 275 262 276 #endif
+19
drivers/net/wireless/realtek/rtw88/mac.c
··· 530 530 return 0; 531 531 } 532 532 533 + int rtw_ddma_to_fw_fifo(struct rtw_dev *rtwdev, u32 ocp_src, u32 size) 534 + { 535 + u32 ch0_ctrl = BIT_DDMACH0_OWN | BIT_DDMACH0_DDMA_MODE; 536 + 537 + if (!check_hw_ready(rtwdev, REG_DDMA_CH0CTRL, BIT_DDMACH0_OWN, 0)) { 538 + rtw_dbg(rtwdev, RTW_DBG_FW, "busy to start ddma\n"); 539 + return -EBUSY; 540 + } 541 + 542 + ch0_ctrl |= size & BIT_MASK_DDMACH0_DLEN; 543 + 544 + if (iddma_enable(rtwdev, ocp_src, OCPBASE_RXBUF_FW_88XX, ch0_ctrl)) { 545 + rtw_dbg(rtwdev, RTW_DBG_FW, "busy to complete ddma\n"); 546 + return -EBUSY; 547 + } 548 + 549 + return 0; 550 + } 551 + 533 552 static bool 534 553 check_fw_checksum(struct rtw_dev *rtwdev, u32 addr) 535 554 {
+4
drivers/net/wireless/realtek/rtw88/mac.h
··· 15 15 #define ILLEGAL_KEY_GROUP 0xFAAAAA00 16 16 17 17 /* HW memory address */ 18 + #define OCPBASE_RXBUF_FW_88XX 0x18680000 18 19 #define OCPBASE_TXBUF_88XX 0x18780000 20 + #define OCPBASE_ROM_88XX 0x00000000 21 + #define OCPBASE_IMEM_88XX 0x00030000 19 22 #define OCPBASE_DMEM_88XX 0x00200000 20 23 #define OCPBASE_EMEM_88XX 0x00100000 21 24 ··· 36 33 int rtw_download_firmware(struct rtw_dev *rtwdev, struct rtw_fw_state *fw); 37 34 int rtw_mac_init(struct rtw_dev *rtwdev); 38 35 void rtw_mac_flush_queues(struct rtw_dev *rtwdev, u32 queues, bool drop); 36 + int rtw_ddma_to_fw_fifo(struct rtw_dev *rtwdev, u32 ocp_src, u32 size); 39 37 40 38 static inline void rtw_mac_flush_all_queues(struct rtw_dev *rtwdev, bool drop) 41 39 {
+2
drivers/net/wireless/realtek/rtw88/mac80211.c
··· 520 520 hw_key_type, hw_key_idx); 521 521 break; 522 522 case DISABLE_KEY: 523 + rtw_hci_flush_all_queues(rtwdev, false); 523 524 rtw_mac_flush_all_queues(rtwdev, false); 524 525 rtw_sec_clear_cam(rtwdev, sec, key->hw_key_idx); 525 526 break; ··· 671 670 mutex_lock(&rtwdev->mutex); 672 671 rtw_leave_lps_deep(rtwdev); 673 672 673 + rtw_hci_flush_queues(rtwdev, queues, drop); 674 674 rtw_mac_flush_queues(rtwdev, queues, drop); 675 675 mutex_unlock(&rtwdev->mutex); 676 676 }
+88 -16
drivers/net/wireless/realtek/rtw88/main.c
··· 345 345 "fw crash dump's seq is wrong: %d\n", seq); 346 346 goto free_buf; 347 347 } 348 - if (seq == 0 && 349 - (GET_FW_DUMP_TLV_TYPE(buf) != FW_CD_TYPE || 350 - GET_FW_DUMP_TLV_LEN(buf) != FW_CD_LEN || 351 - GET_FW_DUMP_TLV_VAL(buf) != FW_CD_VAL)) { 352 - rtw_dbg(rtwdev, RTW_DBG_FW, "fw crash dump's tlv is wrong\n"); 353 - goto free_buf; 354 - } 355 348 356 - print_hex_dump_bytes("rtw88 fw dump: ", DUMP_PREFIX_OFFSET, buf, size); 349 + print_hex_dump(KERN_ERR, "rtw88 fw dump: ", DUMP_PREFIX_OFFSET, 16, 1, 350 + buf, size, true); 357 351 358 352 if (GET_FW_DUMP_MORE(buf) == 1) { 359 353 rtwdev->fw.prev_dump_seq = seq; ··· 361 367 362 368 return ret; 363 369 } 370 + 371 + int rtw_dump_fw(struct rtw_dev *rtwdev, const u32 ocp_src, u32 size, 372 + const char *prefix_str) 373 + { 374 + u32 rxff = rtwdev->chip->fw_rxff_size; 375 + u32 dump_size, done_size = 0; 376 + u8 *buf; 377 + int ret; 378 + 379 + buf = vzalloc(size); 380 + if (!buf) 381 + return -ENOMEM; 382 + 383 + while (size) { 384 + dump_size = size > rxff ? rxff : size; 385 + 386 + ret = rtw_ddma_to_fw_fifo(rtwdev, ocp_src + done_size, 387 + dump_size); 388 + if (ret) { 389 + rtw_err(rtwdev, 390 + "ddma fw 0x%x [+0x%x] to fw fifo fail\n", 391 + ocp_src, done_size); 392 + goto exit; 393 + } 394 + 395 + ret = rtw_fw_dump_fifo(rtwdev, RTW_FW_FIFO_SEL_RXBUF_FW, 0, 396 + dump_size, (u32 *)(buf + done_size)); 397 + if (ret) { 398 + rtw_err(rtwdev, 399 + "dump fw 0x%x [+0x%x] from fw fifo fail\n", 400 + ocp_src, done_size); 401 + goto exit; 402 + } 403 + 404 + size -= dump_size; 405 + done_size += dump_size; 406 + } 407 + 408 + print_hex_dump(KERN_ERR, prefix_str, DUMP_PREFIX_OFFSET, 16, 1, 409 + buf, done_size, true); 410 + 411 + exit: 412 + vfree(buf); 413 + return ret; 414 + } 415 + EXPORT_SYMBOL(rtw_dump_fw); 416 + 417 + int rtw_dump_reg(struct rtw_dev *rtwdev, const u32 addr, const u32 size, 418 + const char *prefix_str) 419 + { 420 + u8 *buf; 421 + u32 i; 422 + 423 + if (addr & 0x3) { 424 + WARN(1, "should be 4-byte aligned, addr = 0x%08x\n", addr); 425 + return -EINVAL; 426 + } 427 + 428 + buf = vzalloc(size); 429 + if (!buf) 430 + return -ENOMEM; 431 + 432 + for (i = 0; i < size; i += 4) 433 + *(u32 *)(buf + i) = rtw_read32(rtwdev, addr + i); 434 + 435 + print_hex_dump(KERN_ERR, prefix_str, DUMP_PREFIX_OFFSET, 16, 4, buf, 436 + size, true); 437 + 438 + vfree(buf); 439 + return 0; 440 + } 441 + EXPORT_SYMBOL(rtw_dump_reg); 364 442 365 443 void rtw_vif_assoc_changed(struct rtw_vif *rtwvif, 366 444 struct ieee80211_bss_conf *conf) ··· 485 419 ieee80211_queue_work(rtwdev->hw, &rtwdev->fw_recovery_work); 486 420 } 487 421 488 - static void rtw_fw_recovery_work(struct work_struct *work) 422 + static void __fw_recovery_work(struct rtw_dev *rtwdev) 489 423 { 490 - struct rtw_dev *rtwdev = container_of(work, struct rtw_dev, 491 - fw_recovery_work); 492 424 493 425 /* rtw_fw_dump_crash_log() returns false indicates that there are 494 426 * still more log to dump. Driver set 0x1cf[7:0] = 0x1 to tell firmware ··· 499 435 } 500 436 rtwdev->fw.prev_dump_seq = 0; 501 437 438 + set_bit(RTW_FLAG_RESTARTING, rtwdev->flags); 439 + rtw_chip_dump_fw_crash(rtwdev); 440 + 502 441 WARN(1, "firmware crash, start reset and recover\n"); 503 442 504 - mutex_lock(&rtwdev->mutex); 505 - 506 - set_bit(RTW_FLAG_RESTARTING, rtwdev->flags); 507 443 rcu_read_lock(); 508 444 rtw_iterate_keys_rcu(rtwdev, NULL, rtw_reset_key_iter, rtwdev); 509 445 rcu_read_unlock(); 510 446 rtw_iterate_stas_atomic(rtwdev, rtw_reset_sta_iter, rtwdev); 511 447 rtw_iterate_vifs_atomic(rtwdev, rtw_reset_vif_iter, rtwdev); 512 448 rtw_enter_ips(rtwdev); 449 + } 513 450 451 + static void rtw_fw_recovery_work(struct work_struct *work) 452 + { 453 + struct rtw_dev *rtwdev = container_of(work, struct rtw_dev, 454 + fw_recovery_work); 455 + 456 + mutex_lock(&rtwdev->mutex); 457 + __fw_recovery_work(rtwdev); 514 458 mutex_unlock(&rtwdev->mutex); 515 459 516 460 ieee80211_restart_hw(rtwdev->hw); ··· 1210 1138 static void rtw_power_off(struct rtw_dev *rtwdev) 1211 1139 { 1212 1140 rtw_hci_stop(rtwdev); 1141 + rtw_coex_power_off_setting(rtwdev); 1213 1142 rtw_mac_power_off(rtwdev); 1214 1143 } 1215 1144 ··· 1466 1393 struct rtw_chip_info *chip = rtwdev->chip; 1467 1394 struct rtw_hal *hal = &rtwdev->hal; 1468 1395 struct rtw_efuse *efuse = &rtwdev->efuse; 1469 - int ret = 0; 1470 1396 1471 1397 switch (rtw_hci_type(rtwdev)) { 1472 1398 case RTW_HCI_TYPE_PCIE: ··· 1503 1431 1504 1432 hal->bfee_sts_cap = 3; 1505 1433 1506 - return ret; 1434 + return 0; 1507 1435 } 1508 1436 1509 1437 static int rtw_chip_efuse_enable(struct rtw_dev *rtwdev)
+13
drivers/net/wireless/realtek/rtw88/main.h
··· 805 805 806 806 struct rtw_chip_ops { 807 807 int (*mac_init)(struct rtw_dev *rtwdev); 808 + void (*dump_fw_crash)(struct rtw_dev *rtwdev); 808 809 void (*shutdown)(struct rtw_dev *rtwdev); 809 810 int (*read_efuse)(struct rtw_dev *rtwdev, u8 *map); 810 811 void (*phy_set_param)(struct rtw_dev *rtwdev); ··· 1167 1166 bool en_dis_dpd; 1168 1167 u16 dpd_ratemask; 1169 1168 u8 iqk_threshold; 1169 + u8 lck_threshold; 1170 1170 const struct rtw_pwr_track_tbl *pwr_track_tbl; 1171 1171 1172 1172 u8 bfer_su_max_num; ··· 1536 1534 u32 rrsr_mask_min; 1537 1535 u8 thermal_avg[RTW_RF_PATH_MAX]; 1538 1536 u8 thermal_meter_k; 1537 + u8 thermal_meter_lck; 1539 1538 s8 delta_power_index[RTW_RF_PATH_MAX]; 1540 1539 s8 delta_power_index_last[RTW_RF_PATH_MAX]; 1541 1540 u8 default_ofdm_index; ··· 1879 1876 clear_bit(mac_id, rtwdev->mac_id_map); 1880 1877 } 1881 1878 1879 + static inline void rtw_chip_dump_fw_crash(struct rtw_dev *rtwdev) 1880 + { 1881 + if (rtwdev->chip->ops->dump_fw_crash) 1882 + rtwdev->chip->ops->dump_fw_crash(rtwdev); 1883 + } 1884 + 1882 1885 void rtw_get_channel_params(struct cfg80211_chan_def *chandef, 1883 1886 struct rtw_channel_params *ch_param); 1884 1887 bool check_hw_ready(struct rtw_dev *rtwdev, u32 addr, u32 mask, u32 target); ··· 1914 1905 void rtw_sta_remove(struct rtw_dev *rtwdev, struct ieee80211_sta *sta, 1915 1906 bool fw_exist); 1916 1907 void rtw_fw_recovery(struct rtw_dev *rtwdev); 1908 + int rtw_dump_fw(struct rtw_dev *rtwdev, const u32 ocp_src, u32 size, 1909 + const char *prefix_str); 1910 + int rtw_dump_reg(struct rtw_dev *rtwdev, const u32 addr, const u32 size, 1911 + const char *prefix_str); 1917 1912 1918 1913 #endif
+69
drivers/net/wireless/realtek/rtw88/pci.c
··· 671 671 [IEEE80211_AC_BK] = RTW_TX_QUEUE_BK, 672 672 }; 673 673 674 + static_assert(ARRAY_SIZE(ac_to_hwq) == IEEE80211_NUM_ACS); 675 + 674 676 static u8 rtw_hw_queue_mapping(struct sk_buff *skb) 675 677 { 676 678 struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data; ··· 727 725 rtw_warn(rtwdev, "pci bus timeout, check dma status\n"); 728 726 729 727 rtwpci->rx_tag = (rtwpci->rx_tag + 1) % RX_TAG_MAX; 728 + } 729 + 730 + static u32 __pci_get_hw_tx_ring_rp(struct rtw_dev *rtwdev, u8 pci_q) 731 + { 732 + u32 bd_idx_addr = rtw_pci_tx_queue_idx_addr[pci_q]; 733 + u32 bd_idx = rtw_read16(rtwdev, bd_idx_addr + 2); 734 + 735 + return FIELD_GET(TRX_BD_IDX_MASK, bd_idx); 736 + } 737 + 738 + static void __pci_flush_queue(struct rtw_dev *rtwdev, u8 pci_q, bool drop) 739 + { 740 + struct rtw_pci *rtwpci = (struct rtw_pci *)rtwdev->priv; 741 + struct rtw_pci_tx_ring *ring = &rtwpci->tx_rings[pci_q]; 742 + u32 cur_rp; 743 + u8 i; 744 + 745 + /* Because the time taked by the I/O in __pci_get_hw_tx_ring_rp is a 746 + * bit dynamic, it's hard to define a reasonable fixed total timeout to 747 + * use read_poll_timeout* helper. Instead, we can ensure a reasonable 748 + * polling times, so we just use for loop with udelay here. 749 + */ 750 + for (i = 0; i < 30; i++) { 751 + cur_rp = __pci_get_hw_tx_ring_rp(rtwdev, pci_q); 752 + if (cur_rp == ring->r.wp) 753 + return; 754 + 755 + udelay(1); 756 + } 757 + 758 + if (!drop) 759 + rtw_warn(rtwdev, "timed out to flush pci tx ring[%d]\n", pci_q); 760 + } 761 + 762 + static void __rtw_pci_flush_queues(struct rtw_dev *rtwdev, u32 pci_queues, 763 + bool drop) 764 + { 765 + u8 q; 766 + 767 + for (q = 0; q < RTK_MAX_TX_QUEUE_NUM; q++) { 768 + /* It may be not necessary to flush BCN and H2C tx queues. */ 769 + if (q == RTW_TX_QUEUE_BCN || q == RTW_TX_QUEUE_H2C) 770 + continue; 771 + 772 + if (pci_queues & BIT(q)) 773 + __pci_flush_queue(rtwdev, q, drop); 774 + } 775 + } 776 + 777 + static void rtw_pci_flush_queues(struct rtw_dev *rtwdev, u32 queues, bool drop) 778 + { 779 + u32 pci_queues = 0; 780 + u8 i; 781 + 782 + /* If all of the hardware queues are requested to flush, 783 + * flush all of the pci queues. 784 + */ 785 + if (queues == BIT(rtwdev->hw->queues) - 1) { 786 + pci_queues = BIT(RTK_MAX_TX_QUEUE_NUM) - 1; 787 + } else { 788 + for (i = 0; i < rtwdev->hw->queues; i++) 789 + if (queues & BIT(i)) 790 + pci_queues |= BIT(ac_to_hwq[i]); 791 + } 792 + 793 + __rtw_pci_flush_queues(rtwdev, pci_queues, drop); 730 794 } 731 795 732 796 static void rtw_pci_tx_kick_off_queue(struct rtw_dev *rtwdev, u8 queue) ··· 1558 1490 static struct rtw_hci_ops rtw_pci_ops = { 1559 1491 .tx_write = rtw_pci_tx_write, 1560 1492 .tx_kick_off = rtw_pci_tx_kick_off, 1493 + .flush_queues = rtw_pci_flush_queues, 1561 1494 .setup = rtw_pci_setup, 1562 1495 .start = rtw_pci_start, 1563 1496 .stop = rtw_pci_stop,
+19 -4
drivers/net/wireless/realtek/rtw88/phy.c
··· 316 316 return damping; 317 317 } 318 318 319 - static void rtw_phy_dig_get_boundary(struct rtw_dm_info *dm_info, 319 + static void rtw_phy_dig_get_boundary(struct rtw_dev *rtwdev, 320 + struct rtw_dm_info *dm_info, 320 321 u8 *upper, u8 *lower, bool linked) 321 322 { 322 323 u8 dig_max, dig_min, dig_mid; ··· 326 325 if (linked) { 327 326 dig_max = DIG_PERF_MAX; 328 327 dig_mid = DIG_PERF_MID; 329 - /* 22B=0x1c, 22C=0x20 */ 330 - dig_min = 0x1c; 328 + dig_min = rtwdev->chip->dig_min; 331 329 min_rssi = max_t(u8, dm_info->min_rssi, dig_min); 332 330 } else { 333 331 dig_max = DIG_CVRG_MAX; ··· 437 437 * the peers connected with us, meanwhile make sure the igi value does 438 438 * not beyond the hardware limitation 439 439 */ 440 - rtw_phy_dig_get_boundary(dm_info, &upper_bound, &lower_bound, linked); 440 + rtw_phy_dig_get_boundary(rtwdev, dm_info, &upper_bound, &lower_bound, 441 + linked); 441 442 cur_igi = clamp_t(u8, cur_igi, lower_bound, upper_bound); 442 443 443 444 /* record current igi value and false alarm statistics for further ··· 2219 2218 return -delta_swing_table_idx_neg[delta]; 2220 2219 } 2221 2220 EXPORT_SYMBOL(rtw_phy_pwrtrack_get_pwridx); 2221 + 2222 + bool rtw_phy_pwrtrack_need_lck(struct rtw_dev *rtwdev) 2223 + { 2224 + struct rtw_dm_info *dm_info = &rtwdev->dm_info; 2225 + u8 delta_lck; 2226 + 2227 + delta_lck = abs(dm_info->thermal_avg[0] - dm_info->thermal_meter_lck); 2228 + if (delta_lck >= rtwdev->chip->lck_threshold) { 2229 + dm_info->thermal_meter_lck = dm_info->thermal_avg[0]; 2230 + return true; 2231 + } 2232 + return false; 2233 + } 2234 + EXPORT_SYMBOL(rtw_phy_pwrtrack_need_lck); 2222 2235 2223 2236 bool rtw_phy_pwrtrack_need_iqk(struct rtw_dev *rtwdev) 2224 2237 {
+1
drivers/net/wireless/realtek/rtw88/phy.h
··· 55 55 s8 rtw_phy_pwrtrack_get_pwridx(struct rtw_dev *rtwdev, 56 56 struct rtw_swing_table *swing_table, 57 57 u8 tbl_path, u8 therm_path, u8 delta); 58 + bool rtw_phy_pwrtrack_need_lck(struct rtw_dev *rtwdev); 58 59 bool rtw_phy_pwrtrack_need_iqk(struct rtw_dev *rtwdev); 59 60 void rtw_phy_config_swing_table(struct rtw_dev *rtwdev, 60 61 struct rtw_swing_table *swing_table);
+6
drivers/net/wireless/realtek/rtw88/reg.h
··· 534 534 #define BIT_DDMACH0_OWN BIT(31) 535 535 #define BIT_DDMACH0_CHKSUM_EN BIT(29) 536 536 #define BIT_DDMACH0_CHKSUM_STS BIT(27) 537 + #define BIT_DDMACH0_DDMA_MODE BIT(26) 537 538 #define BIT_DDMACH0_RESET_CHKSUM_STS BIT(25) 538 539 #define BIT_DDMACH0_CHKSUM_CONT BIT(24) 539 540 #define BIT_MASK_DDMACH0_DLEN 0x3ffff ··· 653 652 #define RF_TXATANK 0x64 654 653 #define RF_TRXIQ 0x66 655 654 #define RF_RXIQGEN 0x8d 655 + #define RF_SYN_PFD 0xb0 656 656 #define RF_XTALX2 0xb8 657 + #define RF_SYN_CTRL 0xbb 657 658 #define RF_MALSEL 0xbe 659 + #define RF_SYN_AAC 0xc9 660 + #define RF_AAC_CTRL 0xca 661 + #define RF_FAST_LCK 0xcc 658 662 #define RF_RCKD 0xde 659 663 #define RF_TXADBG 0xde 660 664 #define RF_LUTDBG 0xdf
+36 -3
drivers/net/wireless/realtek/rtw88/rtw8822c.c
··· 1126 1126 1127 1127 dm_info->pwr_trk_triggered = false; 1128 1128 dm_info->thermal_meter_k = rtwdev->efuse.thermal_meter_k; 1129 + dm_info->thermal_meter_lck = rtwdev->efuse.thermal_meter_k; 1129 1130 } 1130 1131 1131 1132 static void rtw8822c_phy_set_param(struct rtw_dev *rtwdev) ··· 1395 1394 rtw_write32(rtwdev, REG_INT_MIG, WLAN_MAC_INT_MIG_CFG); 1396 1395 1397 1396 return 0; 1397 + } 1398 + 1399 + static void rtw8822c_dump_fw_crash(struct rtw_dev *rtwdev) 1400 + { 1401 + rtw_dump_reg(rtwdev, 0x0, 0x2000, "rtw8822c reg_"); 1402 + rtw_dump_fw(rtwdev, OCPBASE_DMEM_88XX, 0x10000, "rtw8822c DMEM_"); 1403 + rtw_dump_fw(rtwdev, OCPBASE_IMEM_88XX, 0x10000, "rtw8822c IMEM_"); 1404 + rtw_dump_fw(rtwdev, OCPBASE_EMEM_88XX, 0x20000, "rtw8822c EMEM_"); 1405 + rtw_dump_fw(rtwdev, OCPBASE_ROM_88XX, 0x10000, "rtw8822c ROM_"); 1398 1406 } 1399 1407 1400 1408 static void rtw8822c_rstb_3wire(struct rtw_dev *rtwdev, bool enable) ··· 2116 2106 rtw_write32_set(rtwdev, REG_CNT_CTRL, BIT_ALL_CNT_RST); 2117 2107 rtw_write32_clr(rtwdev, REG_CNT_CTRL, BIT_ALL_CNT_RST); 2118 2108 rtw_write32_set(rtwdev, REG_RX_BREAK, BIT_COM_RX_GCK_EN); 2109 + } 2110 + 2111 + static void rtw8822c_do_lck(struct rtw_dev *rtwdev) 2112 + { 2113 + u32 val; 2114 + 2115 + rtw_write_rf(rtwdev, RF_PATH_A, RF_SYN_CTRL, RFREG_MASK, 0x80010); 2116 + rtw_write_rf(rtwdev, RF_PATH_A, RF_SYN_PFD, RFREG_MASK, 0x1F0FA); 2117 + fsleep(1); 2118 + rtw_write_rf(rtwdev, RF_PATH_A, RF_AAC_CTRL, RFREG_MASK, 0x80000); 2119 + rtw_write_rf(rtwdev, RF_PATH_A, RF_SYN_AAC, RFREG_MASK, 0x80001); 2120 + read_poll_timeout(rtw_read_rf, val, val != 0x1, 1000, 100000, 2121 + true, rtwdev, RF_PATH_A, RF_AAC_CTRL, 0x1000); 2122 + rtw_write_rf(rtwdev, RF_PATH_A, RF_SYN_PFD, RFREG_MASK, 0x1F0F8); 2123 + rtw_write_rf(rtwdev, RF_PATH_B, RF_SYN_CTRL, RFREG_MASK, 0x80010); 2124 + 2125 + rtw_write_rf(rtwdev, RF_PATH_A, RF_FAST_LCK, RFREG_MASK, 0x0f000); 2126 + rtw_write_rf(rtwdev, RF_PATH_A, RF_FAST_LCK, RFREG_MASK, 0x4f000); 2127 + fsleep(1); 2128 + rtw_write_rf(rtwdev, RF_PATH_A, RF_FAST_LCK, RFREG_MASK, 0x0f000); 2119 2129 } 2120 2130 2121 2131 static void rtw8822c_do_iqk(struct rtw_dev *rtwdev) ··· 3568 3538 3569 3539 rtw_phy_config_swing_table(rtwdev, &swing_table); 3570 3540 3541 + if (rtw_phy_pwrtrack_need_lck(rtwdev)) 3542 + rtw8822c_do_lck(rtwdev); 3543 + 3571 3544 for (i = 0; i < rtwdev->hal.rf_path_num; i++) 3572 3545 rtw8822c_pwr_track_path(rtwdev, &swing_table, i); 3573 3546 3574 - if (rtw_phy_pwrtrack_need_iqk(rtwdev)) 3575 - rtw8822c_do_iqk(rtwdev); 3576 3547 } 3577 3548 3578 3549 static void rtw8822c_pwr_track(struct rtw_dev *rtwdev) ··· 4002 3971 .query_rx_desc = rtw8822c_query_rx_desc, 4003 3972 .set_channel = rtw8822c_set_channel, 4004 3973 .mac_init = rtw8822c_mac_init, 3974 + .dump_fw_crash = rtw8822c_dump_fw_crash, 4005 3975 .read_rf = rtw_phy_read_rf, 4006 3976 .write_rf = rtw_phy_write_rf_reg_mix, 4007 3977 .set_tx_power_index = rtw8822c_set_tx_power_index, ··· 4383 4351 .dpd_ratemask = DIS_DPD_RATEALL, 4384 4352 .pwr_track_tbl = &rtw8822c_rtw_pwr_track_tbl, 4385 4353 .iqk_threshold = 8, 4354 + .lck_threshold = 8, 4386 4355 .bfer_su_max_num = 2, 4387 4356 .bfer_mu_max_num = 1, 4388 4357 .rx_ldpc = true, ··· 4393 4360 .wowlan_stub = &rtw_wowlan_stub_8822c, 4394 4361 .max_sched_scan_ssids = 4, 4395 4362 #endif 4396 - .coex_para_ver = 0x201029, 4363 + .coex_para_ver = 0x2103181c, 4397 4364 .bt_desired_ver = 0x1c, 4398 4365 .scbd_support = true, 4399 4366 .new_scbd10_def = true,
+343 -343
drivers/net/wireless/realtek/rtw88/rtw8822c_table.c
··· 40863 40863 { 8, 1, 0, 1, 144, 76, }, 40864 40864 { 9, 1, 0, 1, 144, 127, }, 40865 40865 { 0, 1, 0, 1, 149, 76, }, 40866 - { 2, 1, 0, 1, 149, -128, }, 40866 + { 2, 1, 0, 1, 149, 54, }, 40867 40867 { 1, 1, 0, 1, 149, 127, }, 40868 40868 { 3, 1, 0, 1, 149, 76, }, 40869 40869 { 4, 1, 0, 1, 149, 74, }, ··· 40871 40871 { 6, 1, 0, 1, 149, 76, }, 40872 40872 { 7, 1, 0, 1, 149, 54, }, 40873 40873 { 8, 1, 0, 1, 149, 76, }, 40874 - { 9, 1, 0, 1, 149, -128, }, 40874 + { 9, 1, 0, 1, 149, 54, }, 40875 40875 { 0, 1, 0, 1, 153, 76, }, 40876 - { 2, 1, 0, 1, 153, -128, }, 40876 + { 2, 1, 0, 1, 153, 54, }, 40877 40877 { 1, 1, 0, 1, 153, 127, }, 40878 40878 { 3, 1, 0, 1, 153, 76, }, 40879 40879 { 4, 1, 0, 1, 153, 74, }, ··· 40881 40881 { 6, 1, 0, 1, 153, 76, }, 40882 40882 { 7, 1, 0, 1, 153, 54, }, 40883 40883 { 8, 1, 0, 1, 153, 76, }, 40884 - { 9, 1, 0, 1, 153, -128, }, 40884 + { 9, 1, 0, 1, 153, 54, }, 40885 40885 { 0, 1, 0, 1, 157, 76, }, 40886 - { 2, 1, 0, 1, 157, -128, }, 40886 + { 2, 1, 0, 1, 157, 54, }, 40887 40887 { 1, 1, 0, 1, 157, 127, }, 40888 40888 { 3, 1, 0, 1, 157, 76, }, 40889 40889 { 4, 1, 0, 1, 157, 74, }, ··· 40891 40891 { 6, 1, 0, 1, 157, 76, }, 40892 40892 { 7, 1, 0, 1, 157, 54, }, 40893 40893 { 8, 1, 0, 1, 157, 76, }, 40894 - { 9, 1, 0, 1, 157, -128, }, 40894 + { 9, 1, 0, 1, 157, 54, }, 40895 40895 { 0, 1, 0, 1, 161, 76, }, 40896 - { 2, 1, 0, 1, 161, -128, }, 40896 + { 2, 1, 0, 1, 161, 54, }, 40897 40897 { 1, 1, 0, 1, 161, 127, }, 40898 40898 { 3, 1, 0, 1, 161, 76, }, 40899 40899 { 4, 1, 0, 1, 161, 74, }, ··· 40901 40901 { 6, 1, 0, 1, 161, 76, }, 40902 40902 { 7, 1, 0, 1, 161, 54, }, 40903 40903 { 8, 1, 0, 1, 161, 76, }, 40904 - { 9, 1, 0, 1, 161, -128, }, 40904 + { 9, 1, 0, 1, 161, 54, }, 40905 40905 { 0, 1, 0, 1, 165, 76, }, 40906 - { 2, 1, 0, 1, 165, -128, }, 40906 + { 2, 1, 0, 1, 165, 54, }, 40907 40907 { 1, 1, 0, 1, 165, 127, }, 40908 40908 { 3, 1, 0, 1, 165, 76, }, 40909 40909 { 4, 1, 0, 1, 165, 74, }, ··· 40911 40911 { 6, 1, 0, 1, 165, 76, }, 40912 40912 { 7, 1, 0, 1, 165, 54, }, 40913 40913 { 8, 1, 0, 1, 165, 76, }, 40914 - { 9, 1, 0, 1, 165, -128, }, 40914 + { 9, 1, 0, 1, 165, 54, }, 40915 40915 { 0, 1, 0, 2, 36, 72, }, 40916 40916 { 2, 1, 0, 2, 36, 62, }, 40917 40917 { 1, 1, 0, 2, 36, 62, }, ··· 41113 41113 { 8, 1, 0, 2, 144, 76, }, 41114 41114 { 9, 1, 0, 2, 144, 127, }, 41115 41115 { 0, 1, 0, 2, 149, 76, }, 41116 - { 2, 1, 0, 2, 149, -128, }, 41116 + { 2, 1, 0, 2, 149, 54, }, 41117 41117 { 1, 1, 0, 2, 149, 127, }, 41118 41118 { 3, 1, 0, 2, 149, 76, }, 41119 41119 { 4, 1, 0, 2, 149, 74, }, ··· 41121 41121 { 6, 1, 0, 2, 149, 76, }, 41122 41122 { 7, 1, 0, 2, 149, 54, }, 41123 41123 { 8, 1, 0, 2, 149, 76, }, 41124 - { 9, 1, 0, 2, 149, -128, }, 41124 + { 9, 1, 0, 2, 149, 54, }, 41125 41125 { 0, 1, 0, 2, 153, 76, }, 41126 - { 2, 1, 0, 2, 153, -128, }, 41126 + { 2, 1, 0, 2, 153, 54, }, 41127 41127 { 1, 1, 0, 2, 153, 127, }, 41128 41128 { 3, 1, 0, 2, 153, 76, }, 41129 41129 { 4, 1, 0, 2, 153, 74, }, ··· 41131 41131 { 6, 1, 0, 2, 153, 76, }, 41132 41132 { 7, 1, 0, 2, 153, 54, }, 41133 41133 { 8, 1, 0, 2, 153, 76, }, 41134 - { 9, 1, 0, 2, 153, -128, }, 41134 + { 9, 1, 0, 2, 153, 54, }, 41135 41135 { 0, 1, 0, 2, 157, 76, }, 41136 - { 2, 1, 0, 2, 157, -128, }, 41136 + { 2, 1, 0, 2, 157, 54, }, 41137 41137 { 1, 1, 0, 2, 157, 127, }, 41138 41138 { 3, 1, 0, 2, 157, 76, }, 41139 41139 { 4, 1, 0, 2, 157, 74, }, ··· 41141 41141 { 6, 1, 0, 2, 157, 76, }, 41142 41142 { 7, 1, 0, 2, 157, 54, }, 41143 41143 { 8, 1, 0, 2, 157, 76, }, 41144 - { 9, 1, 0, 2, 157, -128, }, 41144 + { 9, 1, 0, 2, 157, 54, }, 41145 41145 { 0, 1, 0, 2, 161, 76, }, 41146 - { 2, 1, 0, 2, 161, -128, }, 41146 + { 2, 1, 0, 2, 161, 54, }, 41147 41147 { 1, 1, 0, 2, 161, 127, }, 41148 41148 { 3, 1, 0, 2, 161, 76, }, 41149 41149 { 4, 1, 0, 2, 161, 74, }, ··· 41151 41151 { 6, 1, 0, 2, 161, 76, }, 41152 41152 { 7, 1, 0, 2, 161, 54, }, 41153 41153 { 8, 1, 0, 2, 161, 76, }, 41154 - { 9, 1, 0, 2, 161, -128, }, 41154 + { 9, 1, 0, 2, 161, 54, }, 41155 41155 { 0, 1, 0, 2, 165, 76, }, 41156 - { 2, 1, 0, 2, 165, -128, }, 41156 + { 2, 1, 0, 2, 165, 54, }, 41157 41157 { 1, 1, 0, 2, 165, 127, }, 41158 41158 { 3, 1, 0, 2, 165, 76, }, 41159 41159 { 4, 1, 0, 2, 165, 74, }, ··· 41161 41161 { 6, 1, 0, 2, 165, 76, }, 41162 41162 { 7, 1, 0, 2, 165, 54, }, 41163 41163 { 8, 1, 0, 2, 165, 76, }, 41164 - { 9, 1, 0, 2, 165, -128, }, 41164 + { 9, 1, 0, 2, 165, 54, }, 41165 41165 { 0, 1, 0, 3, 36, 68, }, 41166 41166 { 2, 1, 0, 3, 36, 38, }, 41167 41167 { 1, 1, 0, 3, 36, 50, }, ··· 41363 41363 { 8, 1, 0, 3, 144, 68, }, 41364 41364 { 9, 1, 0, 3, 144, 127, }, 41365 41365 { 0, 1, 0, 3, 149, 76, }, 41366 - { 2, 1, 0, 3, 149, -128, }, 41366 + { 2, 1, 0, 3, 149, 30, }, 41367 41367 { 1, 1, 0, 3, 149, 127, }, 41368 41368 { 3, 1, 0, 3, 149, 76, }, 41369 41369 { 4, 1, 0, 3, 149, 60, }, ··· 41371 41371 { 6, 1, 0, 3, 149, 76, }, 41372 41372 { 7, 1, 0, 3, 149, 30, }, 41373 41373 { 8, 1, 0, 3, 149, 72, }, 41374 - { 9, 1, 0, 3, 149, -128, }, 41374 + { 9, 1, 0, 3, 149, 30, }, 41375 41375 { 0, 1, 0, 3, 153, 76, }, 41376 - { 2, 1, 0, 3, 153, -128, }, 41376 + { 2, 1, 0, 3, 153, 30, }, 41377 41377 { 1, 1, 0, 3, 153, 127, }, 41378 41378 { 3, 1, 0, 3, 153, 76, }, 41379 41379 { 4, 1, 0, 3, 153, 60, }, ··· 41381 41381 { 6, 1, 0, 3, 153, 76, }, 41382 41382 { 7, 1, 0, 3, 153, 30, }, 41383 41383 { 8, 1, 0, 3, 153, 76, }, 41384 - { 9, 1, 0, 3, 153, -128, }, 41384 + { 9, 1, 0, 3, 153, 30, }, 41385 41385 { 0, 1, 0, 3, 157, 76, }, 41386 - { 2, 1, 0, 3, 157, -128, }, 41386 + { 2, 1, 0, 3, 157, 30, }, 41387 41387 { 1, 1, 0, 3, 157, 127, }, 41388 41388 { 3, 1, 0, 3, 157, 76, }, 41389 41389 { 4, 1, 0, 3, 157, 60, }, ··· 41391 41391 { 6, 1, 0, 3, 157, 76, }, 41392 41392 { 7, 1, 0, 3, 157, 30, }, 41393 41393 { 8, 1, 0, 3, 157, 76, }, 41394 - { 9, 1, 0, 3, 157, -128, }, 41394 + { 9, 1, 0, 3, 157, 30, }, 41395 41395 { 0, 1, 0, 3, 161, 76, }, 41396 - { 2, 1, 0, 3, 161, -128, }, 41396 + { 2, 1, 0, 3, 161, 30, }, 41397 41397 { 1, 1, 0, 3, 161, 127, }, 41398 41398 { 3, 1, 0, 3, 161, 76, }, 41399 41399 { 4, 1, 0, 3, 161, 60, }, ··· 41401 41401 { 6, 1, 0, 3, 161, 76, }, 41402 41402 { 7, 1, 0, 3, 161, 30, }, 41403 41403 { 8, 1, 0, 3, 161, 76, }, 41404 - { 9, 1, 0, 3, 161, -128, }, 41404 + { 9, 1, 0, 3, 161, 30, }, 41405 41405 { 0, 1, 0, 3, 165, 76, }, 41406 - { 2, 1, 0, 3, 165, -128, }, 41406 + { 2, 1, 0, 3, 165, 30, }, 41407 41407 { 1, 1, 0, 3, 165, 127, }, 41408 41408 { 3, 1, 0, 3, 165, 76, }, 41409 41409 { 4, 1, 0, 3, 165, 60, }, ··· 41411 41411 { 6, 1, 0, 3, 165, 76, }, 41412 41412 { 7, 1, 0, 3, 165, 30, }, 41413 41413 { 8, 1, 0, 3, 165, 76, }, 41414 - { 9, 1, 0, 3, 165, -128, }, 41414 + { 9, 1, 0, 3, 165, 30, }, 41415 41415 { 0, 1, 1, 2, 38, 66, }, 41416 41416 { 2, 1, 1, 2, 38, 64, }, 41417 41417 { 1, 1, 1, 2, 38, 62, }, ··· 41513 41513 { 8, 1, 1, 2, 142, 72, }, 41514 41514 { 9, 1, 1, 2, 142, 127, }, 41515 41515 { 0, 1, 1, 2, 151, 72, }, 41516 - { 2, 1, 1, 2, 151, -128, }, 41516 + { 2, 1, 1, 2, 151, 54, }, 41517 41517 { 1, 1, 1, 2, 151, 127, }, 41518 41518 { 3, 1, 1, 2, 151, 72, }, 41519 41519 { 4, 1, 1, 2, 151, 72, }, ··· 41521 41521 { 6, 1, 1, 2, 151, 72, }, 41522 41522 { 7, 1, 1, 2, 151, 54, }, 41523 41523 { 8, 1, 1, 2, 151, 72, }, 41524 - { 9, 1, 1, 2, 151, -128, }, 41524 + { 9, 1, 1, 2, 151, 54, }, 41525 41525 { 0, 1, 1, 2, 159, 72, }, 41526 - { 2, 1, 1, 2, 159, -128, }, 41526 + { 2, 1, 1, 2, 159, 54, }, 41527 41527 { 1, 1, 1, 2, 159, 127, }, 41528 41528 { 3, 1, 1, 2, 159, 72, }, 41529 41529 { 4, 1, 1, 2, 159, 72, }, ··· 41531 41531 { 6, 1, 1, 2, 159, 72, }, 41532 41532 { 7, 1, 1, 2, 159, 54, }, 41533 41533 { 8, 1, 1, 2, 159, 72, }, 41534 - { 9, 1, 1, 2, 159, -128, }, 41534 + { 9, 1, 1, 2, 159, 54, }, 41535 41535 { 0, 1, 1, 3, 38, 60, }, 41536 41536 { 2, 1, 1, 3, 38, 40, }, 41537 41537 { 1, 1, 1, 3, 38, 50, }, ··· 41633 41633 { 8, 1, 1, 3, 142, 68, }, 41634 41634 { 9, 1, 1, 3, 142, 127, }, 41635 41635 { 0, 1, 1, 3, 151, 72, }, 41636 - { 2, 1, 1, 3, 151, -128, }, 41636 + { 2, 1, 1, 3, 151, 30, }, 41637 41637 { 1, 1, 1, 3, 151, 127, }, 41638 41638 { 3, 1, 1, 3, 151, 72, }, 41639 41639 { 4, 1, 1, 3, 151, 66, }, ··· 41641 41641 { 6, 1, 1, 3, 151, 72, }, 41642 41642 { 7, 1, 1, 3, 151, 30, }, 41643 41643 { 8, 1, 1, 3, 151, 68, }, 41644 - { 9, 1, 1, 3, 151, -128, }, 41644 + { 9, 1, 1, 3, 151, 30, }, 41645 41645 { 0, 1, 1, 3, 159, 72, }, 41646 - { 2, 1, 1, 3, 159, -128, }, 41646 + { 2, 1, 1, 3, 159, 30, }, 41647 41647 { 1, 1, 1, 3, 159, 127, }, 41648 41648 { 3, 1, 1, 3, 159, 72, }, 41649 41649 { 4, 1, 1, 3, 159, 66, }, ··· 41651 41651 { 6, 1, 1, 3, 159, 72, }, 41652 41652 { 7, 1, 1, 3, 159, 30, }, 41653 41653 { 8, 1, 1, 3, 159, 72, }, 41654 - { 9, 1, 1, 3, 159, -128, }, 41654 + { 9, 1, 1, 3, 159, 30, }, 41655 41655 { 0, 1, 2, 4, 42, 64, }, 41656 41656 { 2, 1, 2, 4, 42, 64, }, 41657 41657 { 1, 1, 2, 4, 42, 64, }, ··· 41703 41703 { 8, 1, 2, 4, 138, 72, }, 41704 41704 { 9, 1, 2, 4, 138, 127, }, 41705 41705 { 0, 1, 2, 4, 155, 72, }, 41706 - { 2, 1, 2, 4, 155, -128, }, 41706 + { 2, 1, 2, 4, 155, 54, }, 41707 41707 { 1, 1, 2, 4, 155, 127, }, 41708 41708 { 3, 1, 2, 4, 155, 72, }, 41709 41709 { 4, 1, 2, 4, 155, 68, }, ··· 41711 41711 { 6, 1, 2, 4, 155, 72, }, 41712 41712 { 7, 1, 2, 4, 155, 54, }, 41713 41713 { 8, 1, 2, 4, 155, 68, }, 41714 - { 9, 1, 2, 4, 155, -128, }, 41714 + { 9, 1, 2, 4, 155, 54, }, 41715 41715 { 0, 1, 2, 5, 42, 54, }, 41716 41716 { 2, 1, 2, 5, 42, 40, }, 41717 41717 { 1, 1, 2, 5, 42, 50, }, ··· 41763 41763 { 8, 1, 2, 5, 138, 66, }, 41764 41764 { 9, 1, 2, 5, 138, 127, }, 41765 41765 { 0, 1, 2, 5, 155, 62, }, 41766 - { 2, 1, 2, 5, 155, -128, }, 41766 + { 2, 1, 2, 5, 155, 30, }, 41767 41767 { 1, 1, 2, 5, 155, 127, }, 41768 41768 { 3, 1, 2, 5, 155, 62, }, 41769 41769 { 4, 1, 2, 5, 155, 58, }, ··· 41771 41771 { 6, 1, 2, 5, 155, 62, }, 41772 41772 { 7, 1, 2, 5, 155, 30, }, 41773 41773 { 8, 1, 2, 5, 155, 62, }, 41774 - { 9, 1, 2, 5, 155, -128, }, 41774 + { 9, 1, 2, 5, 155, 30, }, 41775 41775 }; 41776 41776 41777 41777 RTW_DECL_TABLE_TXPWR_LMT(rtw8822c_txpwr_lmt_type0); 41778 41778 41779 41779 static const struct rtw_txpwr_lmt_cfg_pair rtw8822c_txpwr_lmt_type5[] = { 41780 41780 { 0, 0, 0, 0, 1, 72, }, 41781 - { 2, 0, 0, 0, 1, 60, }, 41782 - { 1, 0, 0, 0, 1, 68, }, 41781 + { 2, 0, 0, 0, 1, 56, }, 41782 + { 1, 0, 0, 0, 1, 72, }, 41783 41783 { 3, 0, 0, 0, 1, 72, }, 41784 41784 { 4, 0, 0, 0, 1, 76, }, 41785 - { 5, 0, 0, 0, 1, 60, }, 41785 + { 5, 0, 0, 0, 1, 56, }, 41786 41786 { 6, 0, 0, 0, 1, 72, }, 41787 41787 { 7, 0, 0, 0, 1, 60, }, 41788 41788 { 8, 0, 0, 0, 1, 72, }, 41789 41789 { 9, 0, 0, 0, 1, 60, }, 41790 41790 { 0, 0, 0, 0, 2, 72, }, 41791 - { 2, 0, 0, 0, 2, 60, }, 41792 - { 1, 0, 0, 0, 2, 68, }, 41791 + { 2, 0, 0, 0, 2, 56, }, 41792 + { 1, 0, 0, 0, 2, 72, }, 41793 41793 { 3, 0, 0, 0, 2, 72, }, 41794 41794 { 4, 0, 0, 0, 2, 76, }, 41795 - { 5, 0, 0, 0, 2, 60, }, 41795 + { 5, 0, 0, 0, 2, 56, }, 41796 41796 { 6, 0, 0, 0, 2, 72, }, 41797 41797 { 7, 0, 0, 0, 2, 60, }, 41798 41798 { 8, 0, 0, 0, 2, 72, }, 41799 41799 { 9, 0, 0, 0, 2, 60, }, 41800 41800 { 0, 0, 0, 0, 3, 76, }, 41801 - { 2, 0, 0, 0, 3, 60, }, 41802 - { 1, 0, 0, 0, 3, 68, }, 41801 + { 2, 0, 0, 0, 3, 56, }, 41802 + { 1, 0, 0, 0, 3, 72, }, 41803 41803 { 3, 0, 0, 0, 3, 76, }, 41804 41804 { 4, 0, 0, 0, 3, 76, }, 41805 - { 5, 0, 0, 0, 3, 60, }, 41805 + { 5, 0, 0, 0, 3, 56, }, 41806 41806 { 6, 0, 0, 0, 3, 76, }, 41807 41807 { 7, 0, 0, 0, 3, 60, }, 41808 41808 { 8, 0, 0, 0, 3, 76, }, 41809 41809 { 9, 0, 0, 0, 3, 60, }, 41810 41810 { 0, 0, 0, 0, 4, 76, }, 41811 - { 2, 0, 0, 0, 4, 60, }, 41812 - { 1, 0, 0, 0, 4, 68, }, 41811 + { 2, 0, 0, 0, 4, 56, }, 41812 + { 1, 0, 0, 0, 4, 72, }, 41813 41813 { 3, 0, 0, 0, 4, 76, }, 41814 41814 { 4, 0, 0, 0, 4, 76, }, 41815 - { 5, 0, 0, 0, 4, 60, }, 41815 + { 5, 0, 0, 0, 4, 56, }, 41816 41816 { 6, 0, 0, 0, 4, 76, }, 41817 41817 { 7, 0, 0, 0, 4, 60, }, 41818 41818 { 8, 0, 0, 0, 4, 76, }, 41819 41819 { 9, 0, 0, 0, 4, 60, }, 41820 41820 { 0, 0, 0, 0, 5, 76, }, 41821 - { 2, 0, 0, 0, 5, 60, }, 41822 - { 1, 0, 0, 0, 5, 68, }, 41821 + { 2, 0, 0, 0, 5, 56, }, 41822 + { 1, 0, 0, 0, 5, 72, }, 41823 41823 { 3, 0, 0, 0, 5, 76, }, 41824 41824 { 4, 0, 0, 0, 5, 76, }, 41825 - { 5, 0, 0, 0, 5, 60, }, 41825 + { 5, 0, 0, 0, 5, 56, }, 41826 41826 { 6, 0, 0, 0, 5, 76, }, 41827 41827 { 7, 0, 0, 0, 5, 60, }, 41828 41828 { 8, 0, 0, 0, 5, 76, }, 41829 41829 { 9, 0, 0, 0, 5, 60, }, 41830 41830 { 0, 0, 0, 0, 6, 76, }, 41831 - { 2, 0, 0, 0, 6, 60, }, 41832 - { 1, 0, 0, 0, 6, 68, }, 41831 + { 2, 0, 0, 0, 6, 56, }, 41832 + { 1, 0, 0, 0, 6, 72, }, 41833 41833 { 3, 0, 0, 0, 6, 76, }, 41834 41834 { 4, 0, 0, 0, 6, 76, }, 41835 - { 5, 0, 0, 0, 6, 60, }, 41835 + { 5, 0, 0, 0, 6, 56, }, 41836 41836 { 6, 0, 0, 0, 6, 76, }, 41837 41837 { 7, 0, 0, 0, 6, 60, }, 41838 41838 { 8, 0, 0, 0, 6, 76, }, 41839 41839 { 9, 0, 0, 0, 6, 60, }, 41840 41840 { 0, 0, 0, 0, 7, 76, }, 41841 - { 2, 0, 0, 0, 7, 60, }, 41842 - { 1, 0, 0, 0, 7, 68, }, 41841 + { 2, 0, 0, 0, 7, 56, }, 41842 + { 1, 0, 0, 0, 7, 72, }, 41843 41843 { 3, 0, 0, 0, 7, 76, }, 41844 41844 { 4, 0, 0, 0, 7, 76, }, 41845 - { 5, 0, 0, 0, 7, 60, }, 41845 + { 5, 0, 0, 0, 7, 56, }, 41846 41846 { 6, 0, 0, 0, 7, 76, }, 41847 41847 { 7, 0, 0, 0, 7, 60, }, 41848 41848 { 8, 0, 0, 0, 7, 76, }, 41849 41849 { 9, 0, 0, 0, 7, 60, }, 41850 41850 { 0, 0, 0, 0, 8, 76, }, 41851 - { 2, 0, 0, 0, 8, 60, }, 41852 - { 1, 0, 0, 0, 8, 68, }, 41851 + { 2, 0, 0, 0, 8, 56, }, 41852 + { 1, 0, 0, 0, 8, 72, }, 41853 41853 { 3, 0, 0, 0, 8, 76, }, 41854 41854 { 4, 0, 0, 0, 8, 76, }, 41855 - { 5, 0, 0, 0, 8, 60, }, 41855 + { 5, 0, 0, 0, 8, 56, }, 41856 41856 { 6, 0, 0, 0, 8, 76, }, 41857 41857 { 7, 0, 0, 0, 8, 60, }, 41858 41858 { 8, 0, 0, 0, 8, 76, }, 41859 41859 { 9, 0, 0, 0, 8, 60, }, 41860 41860 { 0, 0, 0, 0, 9, 76, }, 41861 - { 2, 0, 0, 0, 9, 60, }, 41862 - { 1, 0, 0, 0, 9, 68, }, 41861 + { 2, 0, 0, 0, 9, 56, }, 41862 + { 1, 0, 0, 0, 9, 72, }, 41863 41863 { 3, 0, 0, 0, 9, 76, }, 41864 41864 { 4, 0, 0, 0, 9, 76, }, 41865 - { 5, 0, 0, 0, 9, 60, }, 41865 + { 5, 0, 0, 0, 9, 56, }, 41866 41866 { 6, 0, 0, 0, 9, 76, }, 41867 41867 { 7, 0, 0, 0, 9, 60, }, 41868 41868 { 8, 0, 0, 0, 9, 76, }, 41869 41869 { 9, 0, 0, 0, 9, 60, }, 41870 41870 { 0, 0, 0, 0, 10, 72, }, 41871 - { 2, 0, 0, 0, 10, 60, }, 41872 - { 1, 0, 0, 0, 10, 68, }, 41871 + { 2, 0, 0, 0, 10, 56, }, 41872 + { 1, 0, 0, 0, 10, 72, }, 41873 41873 { 3, 0, 0, 0, 10, 72, }, 41874 41874 { 4, 0, 0, 0, 10, 76, }, 41875 - { 5, 0, 0, 0, 10, 60, }, 41875 + { 5, 0, 0, 0, 10, 56, }, 41876 41876 { 6, 0, 0, 0, 10, 72, }, 41877 41877 { 7, 0, 0, 0, 10, 60, }, 41878 41878 { 8, 0, 0, 0, 10, 72, }, 41879 41879 { 9, 0, 0, 0, 10, 60, }, 41880 41880 { 0, 0, 0, 0, 11, 72, }, 41881 - { 2, 0, 0, 0, 11, 60, }, 41882 - { 1, 0, 0, 0, 11, 68, }, 41881 + { 2, 0, 0, 0, 11, 56, }, 41882 + { 1, 0, 0, 0, 11, 72, }, 41883 41883 { 3, 0, 0, 0, 11, 72, }, 41884 41884 { 4, 0, 0, 0, 11, 76, }, 41885 - { 5, 0, 0, 0, 11, 60, }, 41885 + { 5, 0, 0, 0, 11, 56, }, 41886 41886 { 6, 0, 0, 0, 11, 72, }, 41887 41887 { 7, 0, 0, 0, 11, 60, }, 41888 41888 { 8, 0, 0, 0, 11, 72, }, 41889 41889 { 9, 0, 0, 0, 11, 60, }, 41890 41890 { 0, 0, 0, 0, 12, 44, }, 41891 - { 2, 0, 0, 0, 12, 60, }, 41892 - { 1, 0, 0, 0, 12, 68, }, 41891 + { 2, 0, 0, 0, 12, 56, }, 41892 + { 1, 0, 0, 0, 12, 72, }, 41893 41893 { 3, 0, 0, 0, 12, 52, }, 41894 41894 { 4, 0, 0, 0, 12, 76, }, 41895 - { 5, 0, 0, 0, 12, 60, }, 41895 + { 5, 0, 0, 0, 12, 56, }, 41896 41896 { 6, 0, 0, 0, 12, 52, }, 41897 41897 { 7, 0, 0, 0, 12, 60, }, 41898 41898 { 8, 0, 0, 0, 12, 52, }, 41899 41899 { 9, 0, 0, 0, 12, 60, }, 41900 41900 { 0, 0, 0, 0, 13, 40, }, 41901 - { 2, 0, 0, 0, 13, 60, }, 41902 - { 1, 0, 0, 0, 13, 68, }, 41901 + { 2, 0, 0, 0, 13, 56, }, 41902 + { 1, 0, 0, 0, 13, 72, }, 41903 41903 { 3, 0, 0, 0, 13, 48, }, 41904 41904 { 4, 0, 0, 0, 13, 76, }, 41905 - { 5, 0, 0, 0, 13, 60, }, 41905 + { 5, 0, 0, 0, 13, 56, }, 41906 41906 { 6, 0, 0, 0, 13, 48, }, 41907 41907 { 7, 0, 0, 0, 13, 60, }, 41908 41908 { 8, 0, 0, 0, 13, 48, }, 41909 41909 { 9, 0, 0, 0, 13, 60, }, 41910 41910 { 0, 0, 0, 0, 14, 127, }, 41911 41911 { 2, 0, 0, 0, 14, 127, }, 41912 - { 1, 0, 0, 0, 14, 68, }, 41912 + { 1, 0, 0, 0, 14, 72, }, 41913 41913 { 3, 0, 0, 0, 14, 127, }, 41914 41914 { 4, 0, 0, 0, 14, 127, }, 41915 41915 { 5, 0, 0, 0, 14, 127, }, ··· 42041 42041 { 2, 0, 0, 1, 13, 60, }, 42042 42042 { 1, 0, 0, 1, 13, 76, }, 42043 42043 { 3, 0, 0, 1, 13, 28, }, 42044 - { 4, 0, 0, 1, 13, 70, }, 42044 + { 4, 0, 0, 1, 13, 74, }, 42045 42045 { 5, 0, 0, 1, 13, 60, }, 42046 42046 { 6, 0, 0, 1, 13, 28, }, 42047 42047 { 7, 0, 0, 1, 13, 60, }, ··· 42181 42181 { 2, 0, 0, 2, 13, 60, }, 42182 42182 { 1, 0, 0, 2, 13, 76, }, 42183 42183 { 3, 0, 0, 2, 13, 28, }, 42184 - { 4, 0, 0, 2, 13, 72, }, 42184 + { 4, 0, 0, 2, 13, 74, }, 42185 42185 { 5, 0, 0, 2, 13, 60, }, 42186 42186 { 6, 0, 0, 2, 13, 28, }, 42187 42187 { 7, 0, 0, 2, 13, 60, }, ··· 42201 42201 { 2, 0, 0, 3, 1, 36, }, 42202 42202 { 1, 0, 0, 3, 1, 66, }, 42203 42203 { 3, 0, 0, 3, 1, 52, }, 42204 - { 4, 0, 0, 3, 1, 68, }, 42204 + { 4, 0, 0, 3, 1, 72, }, 42205 42205 { 5, 0, 0, 3, 1, 36, }, 42206 42206 { 6, 0, 0, 3, 1, 52, }, 42207 42207 { 7, 0, 0, 3, 1, 36, }, ··· 42211 42211 { 2, 0, 0, 3, 2, 36, }, 42212 42212 { 1, 0, 0, 3, 2, 66, }, 42213 42213 { 3, 0, 0, 3, 2, 60, }, 42214 - { 4, 0, 0, 3, 2, 70, }, 42214 + { 4, 0, 0, 3, 2, 72, }, 42215 42215 { 5, 0, 0, 3, 2, 36, }, 42216 42216 { 6, 0, 0, 3, 2, 60, }, 42217 42217 { 7, 0, 0, 3, 2, 36, }, ··· 42221 42221 { 2, 0, 0, 3, 3, 36, }, 42222 42222 { 1, 0, 0, 3, 3, 66, }, 42223 42223 { 3, 0, 0, 3, 3, 64, }, 42224 - { 4, 0, 0, 3, 3, 70, }, 42224 + { 4, 0, 0, 3, 3, 72, }, 42225 42225 { 5, 0, 0, 3, 3, 36, }, 42226 42226 { 6, 0, 0, 3, 3, 64, }, 42227 42227 { 7, 0, 0, 3, 3, 36, }, ··· 42231 42231 { 2, 0, 0, 3, 4, 36, }, 42232 42232 { 1, 0, 0, 3, 4, 66, }, 42233 42233 { 3, 0, 0, 3, 4, 68, }, 42234 - { 4, 0, 0, 3, 4, 70, }, 42234 + { 4, 0, 0, 3, 4, 72, }, 42235 42235 { 5, 0, 0, 3, 4, 36, }, 42236 42236 { 6, 0, 0, 3, 4, 68, }, 42237 42237 { 7, 0, 0, 3, 4, 36, }, ··· 42241 42241 { 2, 0, 0, 3, 5, 36, }, 42242 42242 { 1, 0, 0, 3, 5, 66, }, 42243 42243 { 3, 0, 0, 3, 5, 76, }, 42244 - { 4, 0, 0, 3, 5, 70, }, 42244 + { 4, 0, 0, 3, 5, 72, }, 42245 42245 { 5, 0, 0, 3, 5, 36, }, 42246 42246 { 6, 0, 0, 3, 5, 76, }, 42247 42247 { 7, 0, 0, 3, 5, 36, }, ··· 42251 42251 { 2, 0, 0, 3, 6, 36, }, 42252 42252 { 1, 0, 0, 3, 6, 66, }, 42253 42253 { 3, 0, 0, 3, 6, 76, }, 42254 - { 4, 0, 0, 3, 6, 70, }, 42254 + { 4, 0, 0, 3, 6, 72, }, 42255 42255 { 5, 0, 0, 3, 6, 36, }, 42256 42256 { 6, 0, 0, 3, 6, 76, }, 42257 42257 { 7, 0, 0, 3, 6, 36, }, ··· 42261 42261 { 2, 0, 0, 3, 7, 36, }, 42262 42262 { 1, 0, 0, 3, 7, 66, }, 42263 42263 { 3, 0, 0, 3, 7, 76, }, 42264 - { 4, 0, 0, 3, 7, 70, }, 42264 + { 4, 0, 0, 3, 7, 72, }, 42265 42265 { 5, 0, 0, 3, 7, 36, }, 42266 42266 { 6, 0, 0, 3, 7, 76, }, 42267 42267 { 7, 0, 0, 3, 7, 36, }, ··· 42271 42271 { 2, 0, 0, 3, 8, 36, }, 42272 42272 { 1, 0, 0, 3, 8, 66, }, 42273 42273 { 3, 0, 0, 3, 8, 68, }, 42274 - { 4, 0, 0, 3, 8, 70, }, 42274 + { 4, 0, 0, 3, 8, 72, }, 42275 42275 { 5, 0, 0, 3, 8, 36, }, 42276 42276 { 6, 0, 0, 3, 8, 68, }, 42277 42277 { 7, 0, 0, 3, 8, 36, }, ··· 42281 42281 { 2, 0, 0, 3, 9, 36, }, 42282 42282 { 1, 0, 0, 3, 9, 66, }, 42283 42283 { 3, 0, 0, 3, 9, 64, }, 42284 - { 4, 0, 0, 3, 9, 70, }, 42284 + { 4, 0, 0, 3, 9, 72, }, 42285 42285 { 5, 0, 0, 3, 9, 36, }, 42286 42286 { 6, 0, 0, 3, 9, 64, }, 42287 42287 { 7, 0, 0, 3, 9, 36, }, ··· 42291 42291 { 2, 0, 0, 3, 10, 36, }, 42292 42292 { 1, 0, 0, 3, 10, 66, }, 42293 42293 { 3, 0, 0, 3, 10, 60, }, 42294 - { 4, 0, 0, 3, 10, 70, }, 42294 + { 4, 0, 0, 3, 10, 72, }, 42295 42295 { 5, 0, 0, 3, 10, 36, }, 42296 42296 { 6, 0, 0, 3, 10, 60, }, 42297 42297 { 7, 0, 0, 3, 10, 36, }, ··· 42301 42301 { 2, 0, 0, 3, 11, 36, }, 42302 42302 { 1, 0, 0, 3, 11, 66, }, 42303 42303 { 3, 0, 0, 3, 11, 52, }, 42304 - { 4, 0, 0, 3, 11, 70, }, 42304 + { 4, 0, 0, 3, 11, 72, }, 42305 42305 { 5, 0, 0, 3, 11, 36, }, 42306 42306 { 6, 0, 0, 3, 11, 52, }, 42307 42307 { 7, 0, 0, 3, 11, 36, }, ··· 42311 42311 { 2, 0, 0, 3, 12, 36, }, 42312 42312 { 1, 0, 0, 3, 12, 66, }, 42313 42313 { 3, 0, 0, 3, 12, 40, }, 42314 - { 4, 0, 0, 3, 12, 70, }, 42314 + { 4, 0, 0, 3, 12, 72, }, 42315 42315 { 5, 0, 0, 3, 12, 36, }, 42316 42316 { 6, 0, 0, 3, 12, 40, }, 42317 42317 { 7, 0, 0, 3, 12, 36, }, ··· 42321 42321 { 2, 0, 0, 3, 13, 36, }, 42322 42322 { 1, 0, 0, 3, 13, 66, }, 42323 42323 { 3, 0, 0, 3, 13, 28, }, 42324 - { 4, 0, 0, 3, 13, 62, }, 42324 + { 4, 0, 0, 3, 13, 68, }, 42325 42325 { 5, 0, 0, 3, 13, 36, }, 42326 42326 { 6, 0, 0, 3, 13, 28, }, 42327 42327 { 7, 0, 0, 3, 13, 36, }, ··· 42501 42501 { 2, 0, 1, 3, 3, 36, }, 42502 42502 { 1, 0, 1, 3, 3, 66, }, 42503 42503 { 3, 0, 1, 3, 3, 48, }, 42504 - { 4, 0, 1, 3, 3, 66, }, 42504 + { 4, 0, 1, 3, 3, 68, }, 42505 42505 { 5, 0, 1, 3, 3, 36, }, 42506 42506 { 6, 0, 1, 3, 3, 48, }, 42507 42507 { 7, 0, 1, 3, 3, 36, }, ··· 42618 42618 { 8, 0, 1, 3, 14, 127, }, 42619 42619 { 9, 0, 1, 3, 14, 127, }, 42620 42620 { 0, 1, 0, 1, 36, 74, }, 42621 - { 2, 1, 0, 1, 36, 62, }, 42622 - { 1, 1, 0, 1, 36, 60, }, 42621 + { 2, 1, 0, 1, 36, 58, }, 42622 + { 1, 1, 0, 1, 36, 62, }, 42623 42623 { 3, 1, 0, 1, 36, 62, }, 42624 - { 4, 1, 0, 1, 36, 76, }, 42625 - { 5, 1, 0, 1, 36, 62, }, 42624 + { 4, 1, 0, 1, 36, 74, }, 42625 + { 5, 1, 0, 1, 36, 58, }, 42626 42626 { 6, 1, 0, 1, 36, 64, }, 42627 42627 { 7, 1, 0, 1, 36, 54, }, 42628 42628 { 8, 1, 0, 1, 36, 62, }, 42629 42629 { 9, 1, 0, 1, 36, 62, }, 42630 42630 { 0, 1, 0, 1, 40, 76, }, 42631 - { 2, 1, 0, 1, 40, 62, }, 42631 + { 2, 1, 0, 1, 40, 58, }, 42632 42632 { 1, 1, 0, 1, 40, 62, }, 42633 42633 { 3, 1, 0, 1, 40, 62, }, 42634 42634 { 4, 1, 0, 1, 40, 76, }, 42635 - { 5, 1, 0, 1, 40, 62, }, 42635 + { 5, 1, 0, 1, 40, 58, }, 42636 42636 { 6, 1, 0, 1, 40, 64, }, 42637 42637 { 7, 1, 0, 1, 40, 54, }, 42638 42638 { 8, 1, 0, 1, 40, 62, }, 42639 42639 { 9, 1, 0, 1, 40, 62, }, 42640 42640 { 0, 1, 0, 1, 44, 76, }, 42641 - { 2, 1, 0, 1, 44, 62, }, 42641 + { 2, 1, 0, 1, 44, 58, }, 42642 42642 { 1, 1, 0, 1, 44, 62, }, 42643 42643 { 3, 1, 0, 1, 44, 62, }, 42644 42644 { 4, 1, 0, 1, 44, 76, }, 42645 - { 5, 1, 0, 1, 44, 62, }, 42645 + { 5, 1, 0, 1, 44, 58, }, 42646 42646 { 6, 1, 0, 1, 44, 64, }, 42647 42647 { 7, 1, 0, 1, 44, 54, }, 42648 42648 { 8, 1, 0, 1, 44, 62, }, 42649 42649 { 9, 1, 0, 1, 44, 62, }, 42650 42650 { 0, 1, 0, 1, 48, 76, }, 42651 - { 2, 1, 0, 1, 48, 62, }, 42651 + { 2, 1, 0, 1, 48, 58, }, 42652 42652 { 1, 1, 0, 1, 48, 62, }, 42653 42653 { 3, 1, 0, 1, 48, 62, }, 42654 - { 4, 1, 0, 1, 48, 54, }, 42655 - { 5, 1, 0, 1, 48, 62, }, 42654 + { 4, 1, 0, 1, 48, 58, }, 42655 + { 5, 1, 0, 1, 48, 58, }, 42656 42656 { 6, 1, 0, 1, 48, 64, }, 42657 42657 { 7, 1, 0, 1, 48, 54, }, 42658 42658 { 8, 1, 0, 1, 48, 62, }, 42659 42659 { 9, 1, 0, 1, 48, 62, }, 42660 42660 { 0, 1, 0, 1, 52, 76, }, 42661 - { 2, 1, 0, 1, 52, 62, }, 42661 + { 2, 1, 0, 1, 52, 58, }, 42662 42662 { 1, 1, 0, 1, 52, 62, }, 42663 42663 { 3, 1, 0, 1, 52, 64, }, 42664 42664 { 4, 1, 0, 1, 52, 76, }, 42665 - { 5, 1, 0, 1, 52, 62, }, 42665 + { 5, 1, 0, 1, 52, 58, }, 42666 42666 { 6, 1, 0, 1, 52, 76, }, 42667 42667 { 7, 1, 0, 1, 52, 54, }, 42668 42668 { 8, 1, 0, 1, 52, 76, }, 42669 42669 { 9, 1, 0, 1, 52, 62, }, 42670 42670 { 0, 1, 0, 1, 56, 76, }, 42671 - { 2, 1, 0, 1, 56, 62, }, 42671 + { 2, 1, 0, 1, 56, 58, }, 42672 42672 { 1, 1, 0, 1, 56, 62, }, 42673 42673 { 3, 1, 0, 1, 56, 64, }, 42674 42674 { 4, 1, 0, 1, 56, 76, }, 42675 - { 5, 1, 0, 1, 56, 62, }, 42675 + { 5, 1, 0, 1, 56, 58, }, 42676 42676 { 6, 1, 0, 1, 56, 76, }, 42677 42677 { 7, 1, 0, 1, 56, 54, }, 42678 42678 { 8, 1, 0, 1, 56, 76, }, 42679 42679 { 9, 1, 0, 1, 56, 62, }, 42680 42680 { 0, 1, 0, 1, 60, 76, }, 42681 - { 2, 1, 0, 1, 60, 62, }, 42681 + { 2, 1, 0, 1, 60, 58, }, 42682 42682 { 1, 1, 0, 1, 60, 62, }, 42683 42683 { 3, 1, 0, 1, 60, 64, }, 42684 42684 { 4, 1, 0, 1, 60, 76, }, 42685 - { 5, 1, 0, 1, 60, 62, }, 42685 + { 5, 1, 0, 1, 60, 58, }, 42686 42686 { 6, 1, 0, 1, 60, 76, }, 42687 42687 { 7, 1, 0, 1, 60, 54, }, 42688 42688 { 8, 1, 0, 1, 60, 76, }, 42689 42689 { 9, 1, 0, 1, 60, 62, }, 42690 - { 0, 1, 0, 1, 64, 74, }, 42691 - { 2, 1, 0, 1, 64, 62, }, 42692 - { 1, 1, 0, 1, 64, 60, }, 42690 + { 0, 1, 0, 1, 64, 76, }, 42691 + { 2, 1, 0, 1, 64, 58, }, 42692 + { 1, 1, 0, 1, 64, 62, }, 42693 42693 { 3, 1, 0, 1, 64, 64, }, 42694 42694 { 4, 1, 0, 1, 64, 76, }, 42695 - { 5, 1, 0, 1, 64, 62, }, 42695 + { 5, 1, 0, 1, 64, 58, }, 42696 42696 { 6, 1, 0, 1, 64, 74, }, 42697 42697 { 7, 1, 0, 1, 64, 54, }, 42698 42698 { 8, 1, 0, 1, 64, 74, }, 42699 42699 { 9, 1, 0, 1, 64, 62, }, 42700 - { 0, 1, 0, 1, 100, 72, }, 42701 - { 2, 1, 0, 1, 100, 62, }, 42700 + { 0, 1, 0, 1, 100, 68, }, 42701 + { 2, 1, 0, 1, 100, 58, }, 42702 42702 { 1, 1, 0, 1, 100, 76, }, 42703 - { 3, 1, 0, 1, 100, 72, }, 42703 + { 3, 1, 0, 1, 100, 68, }, 42704 42704 { 4, 1, 0, 1, 100, 76, }, 42705 - { 5, 1, 0, 1, 100, 62, }, 42705 + { 5, 1, 0, 1, 100, 58, }, 42706 42706 { 6, 1, 0, 1, 100, 72, }, 42707 42707 { 7, 1, 0, 1, 100, 54, }, 42708 42708 { 8, 1, 0, 1, 100, 72, }, 42709 42709 { 9, 1, 0, 1, 100, 127, }, 42710 42710 { 0, 1, 0, 1, 104, 76, }, 42711 - { 2, 1, 0, 1, 104, 62, }, 42711 + { 2, 1, 0, 1, 104, 58, }, 42712 42712 { 1, 1, 0, 1, 104, 76, }, 42713 42713 { 3, 1, 0, 1, 104, 76, }, 42714 42714 { 4, 1, 0, 1, 104, 76, }, 42715 - { 5, 1, 0, 1, 104, 62, }, 42715 + { 5, 1, 0, 1, 104, 58, }, 42716 42716 { 6, 1, 0, 1, 104, 76, }, 42717 42717 { 7, 1, 0, 1, 104, 54, }, 42718 42718 { 8, 1, 0, 1, 104, 76, }, 42719 42719 { 9, 1, 0, 1, 104, 127, }, 42720 42720 { 0, 1, 0, 1, 108, 76, }, 42721 - { 2, 1, 0, 1, 108, 62, }, 42721 + { 2, 1, 0, 1, 108, 58, }, 42722 42722 { 1, 1, 0, 1, 108, 76, }, 42723 42723 { 3, 1, 0, 1, 108, 76, }, 42724 42724 { 4, 1, 0, 1, 108, 76, }, 42725 - { 5, 1, 0, 1, 108, 62, }, 42725 + { 5, 1, 0, 1, 108, 58, }, 42726 42726 { 6, 1, 0, 1, 108, 76, }, 42727 42727 { 7, 1, 0, 1, 108, 54, }, 42728 42728 { 8, 1, 0, 1, 108, 76, }, 42729 42729 { 9, 1, 0, 1, 108, 127, }, 42730 42730 { 0, 1, 0, 1, 112, 76, }, 42731 - { 2, 1, 0, 1, 112, 62, }, 42731 + { 2, 1, 0, 1, 112, 58, }, 42732 42732 { 1, 1, 0, 1, 112, 76, }, 42733 42733 { 3, 1, 0, 1, 112, 76, }, 42734 42734 { 4, 1, 0, 1, 112, 76, }, 42735 - { 5, 1, 0, 1, 112, 62, }, 42735 + { 5, 1, 0, 1, 112, 58, }, 42736 42736 { 6, 1, 0, 1, 112, 76, }, 42737 42737 { 7, 1, 0, 1, 112, 54, }, 42738 42738 { 8, 1, 0, 1, 112, 76, }, 42739 42739 { 9, 1, 0, 1, 112, 127, }, 42740 42740 { 0, 1, 0, 1, 116, 76, }, 42741 - { 2, 1, 0, 1, 116, 62, }, 42741 + { 2, 1, 0, 1, 116, 58, }, 42742 42742 { 1, 1, 0, 1, 116, 76, }, 42743 42743 { 3, 1, 0, 1, 116, 76, }, 42744 42744 { 4, 1, 0, 1, 116, 76, }, 42745 - { 5, 1, 0, 1, 116, 62, }, 42745 + { 5, 1, 0, 1, 116, 58, }, 42746 42746 { 6, 1, 0, 1, 116, 76, }, 42747 42747 { 7, 1, 0, 1, 116, 54, }, 42748 42748 { 8, 1, 0, 1, 116, 76, }, 42749 42749 { 9, 1, 0, 1, 116, 127, }, 42750 42750 { 0, 1, 0, 1, 120, 76, }, 42751 - { 2, 1, 0, 1, 120, 62, }, 42751 + { 2, 1, 0, 1, 120, 58, }, 42752 42752 { 1, 1, 0, 1, 120, 76, }, 42753 42753 { 3, 1, 0, 1, 120, 127, }, 42754 42754 { 4, 1, 0, 1, 120, 76, }, ··· 42758 42758 { 8, 1, 0, 1, 120, 76, }, 42759 42759 { 9, 1, 0, 1, 120, 127, }, 42760 42760 { 0, 1, 0, 1, 124, 76, }, 42761 - { 2, 1, 0, 1, 124, 62, }, 42761 + { 2, 1, 0, 1, 124, 58, }, 42762 42762 { 1, 1, 0, 1, 124, 76, }, 42763 42763 { 3, 1, 0, 1, 124, 127, }, 42764 42764 { 4, 1, 0, 1, 124, 76, }, ··· 42768 42768 { 8, 1, 0, 1, 124, 76, }, 42769 42769 { 9, 1, 0, 1, 124, 127, }, 42770 42770 { 0, 1, 0, 1, 128, 76, }, 42771 - { 2, 1, 0, 1, 128, 62, }, 42771 + { 2, 1, 0, 1, 128, 58, }, 42772 42772 { 1, 1, 0, 1, 128, 76, }, 42773 42773 { 3, 1, 0, 1, 128, 127, }, 42774 42774 { 4, 1, 0, 1, 128, 76, }, ··· 42778 42778 { 8, 1, 0, 1, 128, 76, }, 42779 42779 { 9, 1, 0, 1, 128, 127, }, 42780 42780 { 0, 1, 0, 1, 132, 76, }, 42781 - { 2, 1, 0, 1, 132, 62, }, 42781 + { 2, 1, 0, 1, 132, 58, }, 42782 42782 { 1, 1, 0, 1, 132, 76, }, 42783 42783 { 3, 1, 0, 1, 132, 76, }, 42784 42784 { 4, 1, 0, 1, 132, 76, }, 42785 - { 5, 1, 0, 1, 132, 62, }, 42785 + { 5, 1, 0, 1, 132, 58, }, 42786 42786 { 6, 1, 0, 1, 132, 76, }, 42787 42787 { 7, 1, 0, 1, 132, 54, }, 42788 42788 { 8, 1, 0, 1, 132, 76, }, 42789 42789 { 9, 1, 0, 1, 132, 127, }, 42790 42790 { 0, 1, 0, 1, 136, 76, }, 42791 - { 2, 1, 0, 1, 136, 62, }, 42791 + { 2, 1, 0, 1, 136, 58, }, 42792 42792 { 1, 1, 0, 1, 136, 76, }, 42793 42793 { 3, 1, 0, 1, 136, 76, }, 42794 42794 { 4, 1, 0, 1, 136, 76, }, 42795 - { 5, 1, 0, 1, 136, 62, }, 42795 + { 5, 1, 0, 1, 136, 58, }, 42796 42796 { 6, 1, 0, 1, 136, 76, }, 42797 42797 { 7, 1, 0, 1, 136, 54, }, 42798 42798 { 8, 1, 0, 1, 136, 76, }, 42799 42799 { 9, 1, 0, 1, 136, 127, }, 42800 - { 0, 1, 0, 1, 140, 72, }, 42801 - { 2, 1, 0, 1, 140, 62, }, 42800 + { 0, 1, 0, 1, 140, 74, }, 42801 + { 2, 1, 0, 1, 140, 58, }, 42802 42802 { 1, 1, 0, 1, 140, 76, }, 42803 - { 3, 1, 0, 1, 140, 72, }, 42803 + { 3, 1, 0, 1, 140, 74, }, 42804 42804 { 4, 1, 0, 1, 140, 76, }, 42805 - { 5, 1, 0, 1, 140, 62, }, 42805 + { 5, 1, 0, 1, 140, 58, }, 42806 42806 { 6, 1, 0, 1, 140, 72, }, 42807 42807 { 7, 1, 0, 1, 140, 54, }, 42808 42808 { 8, 1, 0, 1, 140, 72, }, 42809 42809 { 9, 1, 0, 1, 140, 127, }, 42810 42810 { 0, 1, 0, 1, 144, 76, }, 42811 42811 { 2, 1, 0, 1, 144, 127, }, 42812 - { 1, 1, 0, 1, 144, 127, }, 42812 + { 1, 1, 0, 1, 144, 76, }, 42813 42813 { 3, 1, 0, 1, 144, 76, }, 42814 42814 { 4, 1, 0, 1, 144, 76, }, 42815 42815 { 5, 1, 0, 1, 144, 127, }, ··· 42818 42818 { 8, 1, 0, 1, 144, 76, }, 42819 42819 { 9, 1, 0, 1, 144, 127, }, 42820 42820 { 0, 1, 0, 1, 149, 76, }, 42821 - { 2, 1, 0, 1, 149, -128, }, 42821 + { 2, 1, 0, 1, 149, 28, }, 42822 42822 { 1, 1, 0, 1, 149, 127, }, 42823 42823 { 3, 1, 0, 1, 149, 76, }, 42824 42824 { 4, 1, 0, 1, 149, 74, }, ··· 42826 42826 { 6, 1, 0, 1, 149, 76, }, 42827 42827 { 7, 1, 0, 1, 149, 54, }, 42828 42828 { 8, 1, 0, 1, 149, 76, }, 42829 - { 9, 1, 0, 1, 149, -128, }, 42829 + { 9, 1, 0, 1, 149, 28, }, 42830 42830 { 0, 1, 0, 1, 153, 76, }, 42831 - { 2, 1, 0, 1, 153, -128, }, 42831 + { 2, 1, 0, 1, 153, 28, }, 42832 42832 { 1, 1, 0, 1, 153, 127, }, 42833 42833 { 3, 1, 0, 1, 153, 76, }, 42834 42834 { 4, 1, 0, 1, 153, 74, }, ··· 42836 42836 { 6, 1, 0, 1, 153, 76, }, 42837 42837 { 7, 1, 0, 1, 153, 54, }, 42838 42838 { 8, 1, 0, 1, 153, 76, }, 42839 - { 9, 1, 0, 1, 153, -128, }, 42839 + { 9, 1, 0, 1, 153, 28, }, 42840 42840 { 0, 1, 0, 1, 157, 76, }, 42841 - { 2, 1, 0, 1, 157, -128, }, 42841 + { 2, 1, 0, 1, 157, 28, }, 42842 42842 { 1, 1, 0, 1, 157, 127, }, 42843 42843 { 3, 1, 0, 1, 157, 76, }, 42844 42844 { 4, 1, 0, 1, 157, 74, }, ··· 42846 42846 { 6, 1, 0, 1, 157, 76, }, 42847 42847 { 7, 1, 0, 1, 157, 54, }, 42848 42848 { 8, 1, 0, 1, 157, 76, }, 42849 - { 9, 1, 0, 1, 157, -128, }, 42849 + { 9, 1, 0, 1, 157, 28, }, 42850 42850 { 0, 1, 0, 1, 161, 76, }, 42851 - { 2, 1, 0, 1, 161, -128, }, 42851 + { 2, 1, 0, 1, 161, 28, }, 42852 42852 { 1, 1, 0, 1, 161, 127, }, 42853 42853 { 3, 1, 0, 1, 161, 76, }, 42854 42854 { 4, 1, 0, 1, 161, 74, }, ··· 42856 42856 { 6, 1, 0, 1, 161, 76, }, 42857 42857 { 7, 1, 0, 1, 161, 54, }, 42858 42858 { 8, 1, 0, 1, 161, 76, }, 42859 - { 9, 1, 0, 1, 161, -128, }, 42859 + { 9, 1, 0, 1, 161, 28, }, 42860 42860 { 0, 1, 0, 1, 165, 76, }, 42861 - { 2, 1, 0, 1, 165, -128, }, 42861 + { 2, 1, 0, 1, 165, 28, }, 42862 42862 { 1, 1, 0, 1, 165, 127, }, 42863 42863 { 3, 1, 0, 1, 165, 76, }, 42864 42864 { 4, 1, 0, 1, 165, 74, }, ··· 42866 42866 { 6, 1, 0, 1, 165, 76, }, 42867 42867 { 7, 1, 0, 1, 165, 54, }, 42868 42868 { 8, 1, 0, 1, 165, 76, }, 42869 - { 9, 1, 0, 1, 165, -128, }, 42870 - { 0, 1, 0, 2, 36, 72, }, 42871 - { 2, 1, 0, 2, 36, 62, }, 42872 - { 1, 1, 0, 2, 36, 62, }, 42869 + { 9, 1, 0, 1, 165, 28, }, 42870 + { 0, 1, 0, 2, 36, 70, }, 42871 + { 2, 1, 0, 2, 36, 58, }, 42872 + { 1, 1, 0, 2, 36, 64, }, 42873 42873 { 3, 1, 0, 2, 36, 62, }, 42874 42874 { 4, 1, 0, 2, 36, 76, }, 42875 - { 5, 1, 0, 2, 36, 62, }, 42875 + { 5, 1, 0, 2, 36, 58, }, 42876 42876 { 6, 1, 0, 2, 36, 64, }, 42877 42877 { 7, 1, 0, 2, 36, 54, }, 42878 42878 { 8, 1, 0, 2, 36, 62, }, 42879 42879 { 9, 1, 0, 2, 36, 62, }, 42880 42880 { 0, 1, 0, 2, 40, 76, }, 42881 - { 2, 1, 0, 2, 40, 62, }, 42881 + { 2, 1, 0, 2, 40, 58, }, 42882 42882 { 1, 1, 0, 2, 40, 62, }, 42883 42883 { 3, 1, 0, 2, 40, 62, }, 42884 42884 { 4, 1, 0, 2, 40, 76, }, 42885 - { 5, 1, 0, 2, 40, 62, }, 42885 + { 5, 1, 0, 2, 40, 58, }, 42886 42886 { 6, 1, 0, 2, 40, 64, }, 42887 42887 { 7, 1, 0, 2, 40, 54, }, 42888 42888 { 8, 1, 0, 2, 40, 62, }, 42889 42889 { 9, 1, 0, 2, 40, 62, }, 42890 42890 { 0, 1, 0, 2, 44, 76, }, 42891 - { 2, 1, 0, 2, 44, 62, }, 42891 + { 2, 1, 0, 2, 44, 58, }, 42892 42892 { 1, 1, 0, 2, 44, 62, }, 42893 42893 { 3, 1, 0, 2, 44, 62, }, 42894 42894 { 4, 1, 0, 2, 44, 76, }, 42895 - { 5, 1, 0, 2, 44, 62, }, 42895 + { 5, 1, 0, 2, 44, 58, }, 42896 42896 { 6, 1, 0, 2, 44, 64, }, 42897 42897 { 7, 1, 0, 2, 44, 54, }, 42898 42898 { 8, 1, 0, 2, 44, 62, }, 42899 42899 { 9, 1, 0, 2, 44, 62, }, 42900 42900 { 0, 1, 0, 2, 48, 76, }, 42901 - { 2, 1, 0, 2, 48, 62, }, 42901 + { 2, 1, 0, 2, 48, 58, }, 42902 42902 { 1, 1, 0, 2, 48, 62, }, 42903 42903 { 3, 1, 0, 2, 48, 62, }, 42904 - { 4, 1, 0, 2, 48, 54, }, 42905 - { 5, 1, 0, 2, 48, 62, }, 42904 + { 4, 1, 0, 2, 48, 58, }, 42905 + { 5, 1, 0, 2, 48, 58, }, 42906 42906 { 6, 1, 0, 2, 48, 64, }, 42907 42907 { 7, 1, 0, 2, 48, 54, }, 42908 42908 { 8, 1, 0, 2, 48, 62, }, 42909 42909 { 9, 1, 0, 2, 48, 62, }, 42910 42910 { 0, 1, 0, 2, 52, 76, }, 42911 - { 2, 1, 0, 2, 52, 62, }, 42911 + { 2, 1, 0, 2, 52, 58, }, 42912 42912 { 1, 1, 0, 2, 52, 62, }, 42913 42913 { 3, 1, 0, 2, 52, 64, }, 42914 42914 { 4, 1, 0, 2, 52, 76, }, 42915 - { 5, 1, 0, 2, 52, 62, }, 42915 + { 5, 1, 0, 2, 52, 58, }, 42916 42916 { 6, 1, 0, 2, 52, 76, }, 42917 42917 { 7, 1, 0, 2, 52, 54, }, 42918 42918 { 8, 1, 0, 2, 52, 76, }, 42919 42919 { 9, 1, 0, 2, 52, 62, }, 42920 42920 { 0, 1, 0, 2, 56, 76, }, 42921 - { 2, 1, 0, 2, 56, 62, }, 42921 + { 2, 1, 0, 2, 56, 58, }, 42922 42922 { 1, 1, 0, 2, 56, 62, }, 42923 42923 { 3, 1, 0, 2, 56, 64, }, 42924 42924 { 4, 1, 0, 2, 56, 76, }, 42925 - { 5, 1, 0, 2, 56, 62, }, 42925 + { 5, 1, 0, 2, 56, 58, }, 42926 42926 { 6, 1, 0, 2, 56, 76, }, 42927 42927 { 7, 1, 0, 2, 56, 54, }, 42928 42928 { 8, 1, 0, 2, 56, 76, }, 42929 42929 { 9, 1, 0, 2, 56, 62, }, 42930 42930 { 0, 1, 0, 2, 60, 76, }, 42931 - { 2, 1, 0, 2, 60, 62, }, 42931 + { 2, 1, 0, 2, 60, 58, }, 42932 42932 { 1, 1, 0, 2, 60, 62, }, 42933 42933 { 3, 1, 0, 2, 60, 64, }, 42934 42934 { 4, 1, 0, 2, 60, 76, }, 42935 - { 5, 1, 0, 2, 60, 62, }, 42935 + { 5, 1, 0, 2, 60, 58, }, 42936 42936 { 6, 1, 0, 2, 60, 76, }, 42937 42937 { 7, 1, 0, 2, 60, 54, }, 42938 42938 { 8, 1, 0, 2, 60, 76, }, 42939 42939 { 9, 1, 0, 2, 60, 62, }, 42940 - { 0, 1, 0, 2, 64, 74, }, 42941 - { 2, 1, 0, 2, 64, 62, }, 42942 - { 1, 1, 0, 2, 64, 60, }, 42940 + { 0, 1, 0, 2, 64, 70, }, 42941 + { 2, 1, 0, 2, 64, 58, }, 42942 + { 1, 1, 0, 2, 64, 62, }, 42943 42943 { 3, 1, 0, 2, 64, 64, }, 42944 42944 { 4, 1, 0, 2, 64, 74, }, 42945 - { 5, 1, 0, 2, 64, 62, }, 42945 + { 5, 1, 0, 2, 64, 58, }, 42946 42946 { 6, 1, 0, 2, 64, 74, }, 42947 42947 { 7, 1, 0, 2, 64, 54, }, 42948 42948 { 8, 1, 0, 2, 64, 74, }, 42949 42949 { 9, 1, 0, 2, 64, 62, }, 42950 - { 0, 1, 0, 2, 100, 70, }, 42951 - { 2, 1, 0, 2, 100, 62, }, 42950 + { 0, 1, 0, 2, 100, 66, }, 42951 + { 2, 1, 0, 2, 100, 58, }, 42952 42952 { 1, 1, 0, 2, 100, 76, }, 42953 - { 3, 1, 0, 2, 100, 70, }, 42953 + { 3, 1, 0, 2, 100, 66, }, 42954 42954 { 4, 1, 0, 2, 100, 76, }, 42955 - { 5, 1, 0, 2, 100, 62, }, 42955 + { 5, 1, 0, 2, 100, 58, }, 42956 42956 { 6, 1, 0, 2, 100, 70, }, 42957 42957 { 7, 1, 0, 2, 100, 54, }, 42958 42958 { 8, 1, 0, 2, 100, 70, }, 42959 42959 { 9, 1, 0, 2, 100, 127, }, 42960 42960 { 0, 1, 0, 2, 104, 76, }, 42961 - { 2, 1, 0, 2, 104, 62, }, 42961 + { 2, 1, 0, 2, 104, 58, }, 42962 42962 { 1, 1, 0, 2, 104, 76, }, 42963 42963 { 3, 1, 0, 2, 104, 76, }, 42964 42964 { 4, 1, 0, 2, 104, 76, }, 42965 - { 5, 1, 0, 2, 104, 62, }, 42965 + { 5, 1, 0, 2, 104, 58, }, 42966 42966 { 6, 1, 0, 2, 104, 76, }, 42967 42967 { 7, 1, 0, 2, 104, 54, }, 42968 42968 { 8, 1, 0, 2, 104, 76, }, 42969 42969 { 9, 1, 0, 2, 104, 127, }, 42970 42970 { 0, 1, 0, 2, 108, 76, }, 42971 - { 2, 1, 0, 2, 108, 62, }, 42971 + { 2, 1, 0, 2, 108, 58, }, 42972 42972 { 1, 1, 0, 2, 108, 76, }, 42973 42973 { 3, 1, 0, 2, 108, 76, }, 42974 42974 { 4, 1, 0, 2, 108, 76, }, 42975 - { 5, 1, 0, 2, 108, 62, }, 42975 + { 5, 1, 0, 2, 108, 58, }, 42976 42976 { 6, 1, 0, 2, 108, 76, }, 42977 42977 { 7, 1, 0, 2, 108, 54, }, 42978 42978 { 8, 1, 0, 2, 108, 76, }, 42979 42979 { 9, 1, 0, 2, 108, 127, }, 42980 42980 { 0, 1, 0, 2, 112, 76, }, 42981 - { 2, 1, 0, 2, 112, 62, }, 42981 + { 2, 1, 0, 2, 112, 58, }, 42982 42982 { 1, 1, 0, 2, 112, 76, }, 42983 42983 { 3, 1, 0, 2, 112, 76, }, 42984 42984 { 4, 1, 0, 2, 112, 76, }, 42985 - { 5, 1, 0, 2, 112, 62, }, 42985 + { 5, 1, 0, 2, 112, 58, }, 42986 42986 { 6, 1, 0, 2, 112, 76, }, 42987 42987 { 7, 1, 0, 2, 112, 54, }, 42988 42988 { 8, 1, 0, 2, 112, 76, }, 42989 42989 { 9, 1, 0, 2, 112, 127, }, 42990 42990 { 0, 1, 0, 2, 116, 76, }, 42991 - { 2, 1, 0, 2, 116, 62, }, 42991 + { 2, 1, 0, 2, 116, 58, }, 42992 42992 { 1, 1, 0, 2, 116, 76, }, 42993 42993 { 3, 1, 0, 2, 116, 76, }, 42994 42994 { 4, 1, 0, 2, 116, 76, }, 42995 - { 5, 1, 0, 2, 116, 62, }, 42995 + { 5, 1, 0, 2, 116, 58, }, 42996 42996 { 6, 1, 0, 2, 116, 76, }, 42997 42997 { 7, 1, 0, 2, 116, 54, }, 42998 42998 { 8, 1, 0, 2, 116, 76, }, 42999 42999 { 9, 1, 0, 2, 116, 127, }, 43000 43000 { 0, 1, 0, 2, 120, 76, }, 43001 - { 2, 1, 0, 2, 120, 62, }, 43001 + { 2, 1, 0, 2, 120, 58, }, 43002 43002 { 1, 1, 0, 2, 120, 76, }, 43003 43003 { 3, 1, 0, 2, 120, 127, }, 43004 43004 { 4, 1, 0, 2, 120, 76, }, ··· 43008 43008 { 8, 1, 0, 2, 120, 76, }, 43009 43009 { 9, 1, 0, 2, 120, 127, }, 43010 43010 { 0, 1, 0, 2, 124, 76, }, 43011 - { 2, 1, 0, 2, 124, 62, }, 43011 + { 2, 1, 0, 2, 124, 58, }, 43012 43012 { 1, 1, 0, 2, 124, 76, }, 43013 43013 { 3, 1, 0, 2, 124, 127, }, 43014 43014 { 4, 1, 0, 2, 124, 76, }, ··· 43018 43018 { 8, 1, 0, 2, 124, 76, }, 43019 43019 { 9, 1, 0, 2, 124, 127, }, 43020 43020 { 0, 1, 0, 2, 128, 76, }, 43021 - { 2, 1, 0, 2, 128, 62, }, 43021 + { 2, 1, 0, 2, 128, 58, }, 43022 43022 { 1, 1, 0, 2, 128, 76, }, 43023 43023 { 3, 1, 0, 2, 128, 127, }, 43024 43024 { 4, 1, 0, 2, 128, 76, }, ··· 43028 43028 { 8, 1, 0, 2, 128, 76, }, 43029 43029 { 9, 1, 0, 2, 128, 127, }, 43030 43030 { 0, 1, 0, 2, 132, 76, }, 43031 - { 2, 1, 0, 2, 132, 62, }, 43031 + { 2, 1, 0, 2, 132, 58, }, 43032 43032 { 1, 1, 0, 2, 132, 76, }, 43033 43033 { 3, 1, 0, 2, 132, 76, }, 43034 43034 { 4, 1, 0, 2, 132, 76, }, 43035 - { 5, 1, 0, 2, 132, 62, }, 43035 + { 5, 1, 0, 2, 132, 58, }, 43036 43036 { 6, 1, 0, 2, 132, 76, }, 43037 43037 { 7, 1, 0, 2, 132, 54, }, 43038 43038 { 8, 1, 0, 2, 132, 76, }, 43039 43039 { 9, 1, 0, 2, 132, 127, }, 43040 43040 { 0, 1, 0, 2, 136, 76, }, 43041 - { 2, 1, 0, 2, 136, 62, }, 43041 + { 2, 1, 0, 2, 136, 58, }, 43042 43042 { 1, 1, 0, 2, 136, 76, }, 43043 43043 { 3, 1, 0, 2, 136, 76, }, 43044 43044 { 4, 1, 0, 2, 136, 76, }, 43045 - { 5, 1, 0, 2, 136, 62, }, 43045 + { 5, 1, 0, 2, 136, 58, }, 43046 43046 { 6, 1, 0, 2, 136, 76, }, 43047 43047 { 7, 1, 0, 2, 136, 54, }, 43048 43048 { 8, 1, 0, 2, 136, 76, }, 43049 43049 { 9, 1, 0, 2, 136, 127, }, 43050 - { 0, 1, 0, 2, 140, 70, }, 43051 - { 2, 1, 0, 2, 140, 62, }, 43050 + { 0, 1, 0, 2, 140, 66, }, 43051 + { 2, 1, 0, 2, 140, 58, }, 43052 43052 { 1, 1, 0, 2, 140, 76, }, 43053 - { 3, 1, 0, 2, 140, 70, }, 43053 + { 3, 1, 0, 2, 140, 66, }, 43054 43054 { 4, 1, 0, 2, 140, 76, }, 43055 - { 5, 1, 0, 2, 140, 62, }, 43055 + { 5, 1, 0, 2, 140, 58, }, 43056 43056 { 6, 1, 0, 2, 140, 70, }, 43057 43057 { 7, 1, 0, 2, 140, 54, }, 43058 43058 { 8, 1, 0, 2, 140, 70, }, 43059 43059 { 9, 1, 0, 2, 140, 127, }, 43060 43060 { 0, 1, 0, 2, 144, 76, }, 43061 43061 { 2, 1, 0, 2, 144, 127, }, 43062 - { 1, 1, 0, 2, 144, 127, }, 43062 + { 1, 1, 0, 2, 144, 76, }, 43063 43063 { 3, 1, 0, 2, 144, 76, }, 43064 43064 { 4, 1, 0, 2, 144, 76, }, 43065 43065 { 5, 1, 0, 2, 144, 127, }, ··· 43068 43068 { 8, 1, 0, 2, 144, 76, }, 43069 43069 { 9, 1, 0, 2, 144, 127, }, 43070 43070 { 0, 1, 0, 2, 149, 76, }, 43071 - { 2, 1, 0, 2, 149, -128, }, 43071 + { 2, 1, 0, 2, 149, 28, }, 43072 43072 { 1, 1, 0, 2, 149, 127, }, 43073 43073 { 3, 1, 0, 2, 149, 76, }, 43074 43074 { 4, 1, 0, 2, 149, 74, }, ··· 43076 43076 { 6, 1, 0, 2, 149, 76, }, 43077 43077 { 7, 1, 0, 2, 149, 54, }, 43078 43078 { 8, 1, 0, 2, 149, 76, }, 43079 - { 9, 1, 0, 2, 149, -128, }, 43079 + { 9, 1, 0, 2, 149, 28, }, 43080 43080 { 0, 1, 0, 2, 153, 76, }, 43081 - { 2, 1, 0, 2, 153, -128, }, 43081 + { 2, 1, 0, 2, 153, 28, }, 43082 43082 { 1, 1, 0, 2, 153, 127, }, 43083 43083 { 3, 1, 0, 2, 153, 76, }, 43084 43084 { 4, 1, 0, 2, 153, 74, }, ··· 43086 43086 { 6, 1, 0, 2, 153, 76, }, 43087 43087 { 7, 1, 0, 2, 153, 54, }, 43088 43088 { 8, 1, 0, 2, 153, 76, }, 43089 - { 9, 1, 0, 2, 153, -128, }, 43089 + { 9, 1, 0, 2, 153, 28, }, 43090 43090 { 0, 1, 0, 2, 157, 76, }, 43091 - { 2, 1, 0, 2, 157, -128, }, 43091 + { 2, 1, 0, 2, 157, 28, }, 43092 43092 { 1, 1, 0, 2, 157, 127, }, 43093 43093 { 3, 1, 0, 2, 157, 76, }, 43094 43094 { 4, 1, 0, 2, 157, 74, }, ··· 43096 43096 { 6, 1, 0, 2, 157, 76, }, 43097 43097 { 7, 1, 0, 2, 157, 54, }, 43098 43098 { 8, 1, 0, 2, 157, 76, }, 43099 - { 9, 1, 0, 2, 157, -128, }, 43099 + { 9, 1, 0, 2, 157, 28, }, 43100 43100 { 0, 1, 0, 2, 161, 76, }, 43101 - { 2, 1, 0, 2, 161, -128, }, 43101 + { 2, 1, 0, 2, 161, 28, }, 43102 43102 { 1, 1, 0, 2, 161, 127, }, 43103 43103 { 3, 1, 0, 2, 161, 76, }, 43104 43104 { 4, 1, 0, 2, 161, 74, }, ··· 43106 43106 { 6, 1, 0, 2, 161, 76, }, 43107 43107 { 7, 1, 0, 2, 161, 54, }, 43108 43108 { 8, 1, 0, 2, 161, 76, }, 43109 - { 9, 1, 0, 2, 161, -128, }, 43109 + { 9, 1, 0, 2, 161, 28, }, 43110 43110 { 0, 1, 0, 2, 165, 76, }, 43111 - { 2, 1, 0, 2, 165, -128, }, 43111 + { 2, 1, 0, 2, 165, 28, }, 43112 43112 { 1, 1, 0, 2, 165, 127, }, 43113 43113 { 3, 1, 0, 2, 165, 76, }, 43114 43114 { 4, 1, 0, 2, 165, 74, }, ··· 43116 43116 { 6, 1, 0, 2, 165, 76, }, 43117 43117 { 7, 1, 0, 2, 165, 54, }, 43118 43118 { 8, 1, 0, 2, 165, 76, }, 43119 - { 9, 1, 0, 2, 165, -128, }, 43120 - { 0, 1, 0, 3, 36, 68, }, 43121 - { 2, 1, 0, 3, 36, 38, }, 43119 + { 9, 1, 0, 2, 165, 28, }, 43120 + { 0, 1, 0, 3, 36, 64, }, 43121 + { 2, 1, 0, 3, 36, 36, }, 43122 43122 { 1, 1, 0, 3, 36, 50, }, 43123 43123 { 3, 1, 0, 3, 36, 38, }, 43124 43124 { 4, 1, 0, 3, 36, 66, }, 43125 - { 5, 1, 0, 3, 36, 38, }, 43125 + { 5, 1, 0, 3, 36, 36, }, 43126 43126 { 6, 1, 0, 3, 36, 52, }, 43127 43127 { 7, 1, 0, 3, 36, 30, }, 43128 43128 { 8, 1, 0, 3, 36, 50, }, 43129 43129 { 9, 1, 0, 3, 36, 38, }, 43130 43130 { 0, 1, 0, 3, 40, 68, }, 43131 - { 2, 1, 0, 3, 40, 38, }, 43131 + { 2, 1, 0, 3, 40, 36, }, 43132 43132 { 1, 1, 0, 3, 40, 50, }, 43133 43133 { 3, 1, 0, 3, 40, 38, }, 43134 43134 { 4, 1, 0, 3, 40, 66, }, 43135 - { 5, 1, 0, 3, 40, 38, }, 43135 + { 5, 1, 0, 3, 40, 36, }, 43136 43136 { 6, 1, 0, 3, 40, 52, }, 43137 43137 { 7, 1, 0, 3, 40, 30, }, 43138 43138 { 8, 1, 0, 3, 40, 50, }, 43139 43139 { 9, 1, 0, 3, 40, 38, }, 43140 43140 { 0, 1, 0, 3, 44, 68, }, 43141 - { 2, 1, 0, 3, 44, 38, }, 43141 + { 2, 1, 0, 3, 44, 36, }, 43142 43142 { 1, 1, 0, 3, 44, 50, }, 43143 43143 { 3, 1, 0, 3, 44, 38, }, 43144 43144 { 4, 1, 0, 3, 44, 66, }, 43145 - { 5, 1, 0, 3, 44, 38, }, 43145 + { 5, 1, 0, 3, 44, 36, }, 43146 43146 { 6, 1, 0, 3, 44, 52, }, 43147 43147 { 7, 1, 0, 3, 44, 30, }, 43148 43148 { 8, 1, 0, 3, 44, 50, }, 43149 43149 { 9, 1, 0, 3, 44, 38, }, 43150 43150 { 0, 1, 0, 3, 48, 68, }, 43151 - { 2, 1, 0, 3, 48, 38, }, 43151 + { 2, 1, 0, 3, 48, 36, }, 43152 43152 { 1, 1, 0, 3, 48, 50, }, 43153 43153 { 3, 1, 0, 3, 48, 38, }, 43154 - { 4, 1, 0, 3, 48, 36, }, 43155 - { 5, 1, 0, 3, 48, 38, }, 43154 + { 4, 1, 0, 3, 48, 42, }, 43155 + { 5, 1, 0, 3, 48, 36, }, 43156 43156 { 6, 1, 0, 3, 48, 52, }, 43157 43157 { 7, 1, 0, 3, 48, 30, }, 43158 43158 { 8, 1, 0, 3, 48, 50, }, 43159 43159 { 9, 1, 0, 3, 48, 38, }, 43160 43160 { 0, 1, 0, 3, 52, 68, }, 43161 - { 2, 1, 0, 3, 52, 38, }, 43161 + { 2, 1, 0, 3, 52, 36, }, 43162 43162 { 1, 1, 0, 3, 52, 50, }, 43163 43163 { 3, 1, 0, 3, 52, 40, }, 43164 43164 { 4, 1, 0, 3, 52, 66, }, 43165 - { 5, 1, 0, 3, 52, 38, }, 43165 + { 5, 1, 0, 3, 52, 36, }, 43166 43166 { 6, 1, 0, 3, 52, 68, }, 43167 43167 { 7, 1, 0, 3, 52, 30, }, 43168 43168 { 8, 1, 0, 3, 52, 68, }, 43169 43169 { 9, 1, 0, 3, 52, 38, }, 43170 43170 { 0, 1, 0, 3, 56, 68, }, 43171 - { 2, 1, 0, 3, 56, 38, }, 43171 + { 2, 1, 0, 3, 56, 36, }, 43172 43172 { 1, 1, 0, 3, 56, 50, }, 43173 43173 { 3, 1, 0, 3, 56, 40, }, 43174 43174 { 4, 1, 0, 3, 56, 66, }, 43175 - { 5, 1, 0, 3, 56, 38, }, 43175 + { 5, 1, 0, 3, 56, 36, }, 43176 43176 { 6, 1, 0, 3, 56, 68, }, 43177 43177 { 7, 1, 0, 3, 56, 30, }, 43178 43178 { 8, 1, 0, 3, 56, 68, }, 43179 43179 { 9, 1, 0, 3, 56, 38, }, 43180 - { 0, 1, 0, 3, 60, 66, }, 43181 - { 2, 1, 0, 3, 60, 38, }, 43180 + { 0, 1, 0, 3, 60, 68, }, 43181 + { 2, 1, 0, 3, 60, 36, }, 43182 43182 { 1, 1, 0, 3, 60, 50, }, 43183 43183 { 3, 1, 0, 3, 60, 40, }, 43184 43184 { 4, 1, 0, 3, 60, 66, }, 43185 - { 5, 1, 0, 3, 60, 38, }, 43185 + { 5, 1, 0, 3, 60, 36, }, 43186 43186 { 6, 1, 0, 3, 60, 66, }, 43187 43187 { 7, 1, 0, 3, 60, 30, }, 43188 43188 { 8, 1, 0, 3, 60, 66, }, 43189 43189 { 9, 1, 0, 3, 60, 38, }, 43190 - { 0, 1, 0, 3, 64, 68, }, 43191 - { 2, 1, 0, 3, 64, 38, }, 43190 + { 0, 1, 0, 3, 64, 66, }, 43191 + { 2, 1, 0, 3, 64, 36, }, 43192 43192 { 1, 1, 0, 3, 64, 50, }, 43193 43193 { 3, 1, 0, 3, 64, 40, }, 43194 43194 { 4, 1, 0, 3, 64, 66, }, 43195 - { 5, 1, 0, 3, 64, 38, }, 43195 + { 5, 1, 0, 3, 64, 36, }, 43196 43196 { 6, 1, 0, 3, 64, 68, }, 43197 43197 { 7, 1, 0, 3, 64, 30, }, 43198 43198 { 8, 1, 0, 3, 64, 68, }, 43199 43199 { 9, 1, 0, 3, 64, 38, }, 43200 - { 0, 1, 0, 3, 100, 60, }, 43201 - { 2, 1, 0, 3, 100, 38, }, 43200 + { 0, 1, 0, 3, 100, 64, }, 43201 + { 2, 1, 0, 3, 100, 36, }, 43202 43202 { 1, 1, 0, 3, 100, 70, }, 43203 - { 3, 1, 0, 3, 100, 60, }, 43204 - { 4, 1, 0, 3, 100, 64, }, 43205 - { 5, 1, 0, 3, 100, 38, }, 43203 + { 3, 1, 0, 3, 100, 64, }, 43204 + { 4, 1, 0, 3, 100, 66, }, 43205 + { 5, 1, 0, 3, 100, 36, }, 43206 43206 { 6, 1, 0, 3, 100, 60, }, 43207 43207 { 7, 1, 0, 3, 100, 30, }, 43208 43208 { 8, 1, 0, 3, 100, 60, }, 43209 43209 { 9, 1, 0, 3, 100, 127, }, 43210 43210 { 0, 1, 0, 3, 104, 68, }, 43211 - { 2, 1, 0, 3, 104, 38, }, 43211 + { 2, 1, 0, 3, 104, 36, }, 43212 43212 { 1, 1, 0, 3, 104, 70, }, 43213 43213 { 3, 1, 0, 3, 104, 68, }, 43214 - { 4, 1, 0, 3, 104, 64, }, 43215 - { 5, 1, 0, 3, 104, 38, }, 43214 + { 4, 1, 0, 3, 104, 66, }, 43215 + { 5, 1, 0, 3, 104, 36, }, 43216 43216 { 6, 1, 0, 3, 104, 68, }, 43217 43217 { 7, 1, 0, 3, 104, 30, }, 43218 43218 { 8, 1, 0, 3, 104, 68, }, 43219 43219 { 9, 1, 0, 3, 104, 127, }, 43220 43220 { 0, 1, 0, 3, 108, 68, }, 43221 - { 2, 1, 0, 3, 108, 38, }, 43221 + { 2, 1, 0, 3, 108, 36, }, 43222 43222 { 1, 1, 0, 3, 108, 70, }, 43223 43223 { 3, 1, 0, 3, 108, 68, }, 43224 - { 4, 1, 0, 3, 108, 64, }, 43225 - { 5, 1, 0, 3, 108, 38, }, 43224 + { 4, 1, 0, 3, 108, 66, }, 43225 + { 5, 1, 0, 3, 108, 36, }, 43226 43226 { 6, 1, 0, 3, 108, 68, }, 43227 43227 { 7, 1, 0, 3, 108, 30, }, 43228 43228 { 8, 1, 0, 3, 108, 68, }, 43229 43229 { 9, 1, 0, 3, 108, 127, }, 43230 43230 { 0, 1, 0, 3, 112, 68, }, 43231 - { 2, 1, 0, 3, 112, 38, }, 43231 + { 2, 1, 0, 3, 112, 36, }, 43232 43232 { 1, 1, 0, 3, 112, 70, }, 43233 43233 { 3, 1, 0, 3, 112, 68, }, 43234 - { 4, 1, 0, 3, 112, 64, }, 43235 - { 5, 1, 0, 3, 112, 38, }, 43234 + { 4, 1, 0, 3, 112, 66, }, 43235 + { 5, 1, 0, 3, 112, 36, }, 43236 43236 { 6, 1, 0, 3, 112, 68, }, 43237 43237 { 7, 1, 0, 3, 112, 30, }, 43238 43238 { 8, 1, 0, 3, 112, 68, }, 43239 43239 { 9, 1, 0, 3, 112, 127, }, 43240 43240 { 0, 1, 0, 3, 116, 68, }, 43241 - { 2, 1, 0, 3, 116, 38, }, 43241 + { 2, 1, 0, 3, 116, 36, }, 43242 43242 { 1, 1, 0, 3, 116, 70, }, 43243 43243 { 3, 1, 0, 3, 116, 68, }, 43244 - { 4, 1, 0, 3, 116, 64, }, 43245 - { 5, 1, 0, 3, 116, 38, }, 43244 + { 4, 1, 0, 3, 116, 66, }, 43245 + { 5, 1, 0, 3, 116, 36, }, 43246 43246 { 6, 1, 0, 3, 116, 68, }, 43247 43247 { 7, 1, 0, 3, 116, 30, }, 43248 43248 { 8, 1, 0, 3, 116, 68, }, 43249 43249 { 9, 1, 0, 3, 116, 127, }, 43250 43250 { 0, 1, 0, 3, 120, 68, }, 43251 - { 2, 1, 0, 3, 120, 38, }, 43251 + { 2, 1, 0, 3, 120, 36, }, 43252 43252 { 1, 1, 0, 3, 120, 70, }, 43253 43253 { 3, 1, 0, 3, 120, 127, }, 43254 - { 4, 1, 0, 3, 120, 64, }, 43254 + { 4, 1, 0, 3, 120, 66, }, 43255 43255 { 5, 1, 0, 3, 120, 127, }, 43256 43256 { 6, 1, 0, 3, 120, 68, }, 43257 43257 { 7, 1, 0, 3, 120, 30, }, 43258 43258 { 8, 1, 0, 3, 120, 68, }, 43259 43259 { 9, 1, 0, 3, 120, 127, }, 43260 43260 { 0, 1, 0, 3, 124, 68, }, 43261 - { 2, 1, 0, 3, 124, 38, }, 43261 + { 2, 1, 0, 3, 124, 36, }, 43262 43262 { 1, 1, 0, 3, 124, 70, }, 43263 43263 { 3, 1, 0, 3, 124, 127, }, 43264 - { 4, 1, 0, 3, 124, 64, }, 43264 + { 4, 1, 0, 3, 124, 66, }, 43265 43265 { 5, 1, 0, 3, 124, 127, }, 43266 43266 { 6, 1, 0, 3, 124, 68, }, 43267 43267 { 7, 1, 0, 3, 124, 30, }, 43268 43268 { 8, 1, 0, 3, 124, 68, }, 43269 43269 { 9, 1, 0, 3, 124, 127, }, 43270 43270 { 0, 1, 0, 3, 128, 68, }, 43271 - { 2, 1, 0, 3, 128, 38, }, 43271 + { 2, 1, 0, 3, 128, 36, }, 43272 43272 { 1, 1, 0, 3, 128, 70, }, 43273 43273 { 3, 1, 0, 3, 128, 127, }, 43274 - { 4, 1, 0, 3, 128, 64, }, 43274 + { 4, 1, 0, 3, 128, 66, }, 43275 43275 { 5, 1, 0, 3, 128, 127, }, 43276 43276 { 6, 1, 0, 3, 128, 68, }, 43277 43277 { 7, 1, 0, 3, 128, 30, }, 43278 43278 { 8, 1, 0, 3, 128, 68, }, 43279 43279 { 9, 1, 0, 3, 128, 127, }, 43280 43280 { 0, 1, 0, 3, 132, 68, }, 43281 - { 2, 1, 0, 3, 132, 38, }, 43281 + { 2, 1, 0, 3, 132, 36, }, 43282 43282 { 1, 1, 0, 3, 132, 70, }, 43283 43283 { 3, 1, 0, 3, 132, 68, }, 43284 - { 4, 1, 0, 3, 132, 64, }, 43285 - { 5, 1, 0, 3, 132, 38, }, 43284 + { 4, 1, 0, 3, 132, 66, }, 43285 + { 5, 1, 0, 3, 132, 36, }, 43286 43286 { 6, 1, 0, 3, 132, 68, }, 43287 43287 { 7, 1, 0, 3, 132, 30, }, 43288 43288 { 8, 1, 0, 3, 132, 68, }, 43289 43289 { 9, 1, 0, 3, 132, 127, }, 43290 43290 { 0, 1, 0, 3, 136, 68, }, 43291 - { 2, 1, 0, 3, 136, 38, }, 43291 + { 2, 1, 0, 3, 136, 36, }, 43292 43292 { 1, 1, 0, 3, 136, 70, }, 43293 43293 { 3, 1, 0, 3, 136, 68, }, 43294 - { 4, 1, 0, 3, 136, 64, }, 43295 - { 5, 1, 0, 3, 136, 38, }, 43294 + { 4, 1, 0, 3, 136, 66, }, 43295 + { 5, 1, 0, 3, 136, 36, }, 43296 43296 { 6, 1, 0, 3, 136, 68, }, 43297 43297 { 7, 1, 0, 3, 136, 30, }, 43298 43298 { 8, 1, 0, 3, 136, 68, }, 43299 43299 { 9, 1, 0, 3, 136, 127, }, 43300 - { 0, 1, 0, 3, 140, 60, }, 43301 - { 2, 1, 0, 3, 140, 38, }, 43300 + { 0, 1, 0, 3, 140, 58, }, 43301 + { 2, 1, 0, 3, 140, 36, }, 43302 43302 { 1, 1, 0, 3, 140, 70, }, 43303 - { 3, 1, 0, 3, 140, 60, }, 43304 - { 4, 1, 0, 3, 140, 64, }, 43305 - { 5, 1, 0, 3, 140, 38, }, 43303 + { 3, 1, 0, 3, 140, 58, }, 43304 + { 4, 1, 0, 3, 140, 66, }, 43305 + { 5, 1, 0, 3, 140, 36, }, 43306 43306 { 6, 1, 0, 3, 140, 60, }, 43307 43307 { 7, 1, 0, 3, 140, 30, }, 43308 43308 { 8, 1, 0, 3, 140, 60, }, 43309 43309 { 9, 1, 0, 3, 140, 127, }, 43310 43310 { 0, 1, 0, 3, 144, 68, }, 43311 43311 { 2, 1, 0, 3, 144, 127, }, 43312 - { 1, 1, 0, 3, 144, 127, }, 43312 + { 1, 1, 0, 3, 144, 70, }, 43313 43313 { 3, 1, 0, 3, 144, 68, }, 43314 - { 4, 1, 0, 3, 144, 64, }, 43314 + { 4, 1, 0, 3, 144, 66, }, 43315 43315 { 5, 1, 0, 3, 144, 127, }, 43316 43316 { 6, 1, 0, 3, 144, 68, }, 43317 43317 { 7, 1, 0, 3, 144, 127, }, 43318 43318 { 8, 1, 0, 3, 144, 68, }, 43319 43319 { 9, 1, 0, 3, 144, 127, }, 43320 43320 { 0, 1, 0, 3, 149, 76, }, 43321 - { 2, 1, 0, 3, 149, -128, }, 43321 + { 2, 1, 0, 3, 149, 4, }, 43322 43322 { 1, 1, 0, 3, 149, 127, }, 43323 43323 { 3, 1, 0, 3, 149, 76, }, 43324 - { 4, 1, 0, 3, 149, 60, }, 43324 + { 4, 1, 0, 3, 149, 62, }, 43325 43325 { 5, 1, 0, 3, 149, 76, }, 43326 43326 { 6, 1, 0, 3, 149, 76, }, 43327 43327 { 7, 1, 0, 3, 149, 30, }, 43328 43328 { 8, 1, 0, 3, 149, 72, }, 43329 - { 9, 1, 0, 3, 149, -128, }, 43329 + { 9, 1, 0, 3, 149, 4, }, 43330 43330 { 0, 1, 0, 3, 153, 76, }, 43331 - { 2, 1, 0, 3, 153, -128, }, 43331 + { 2, 1, 0, 3, 153, 4, }, 43332 43332 { 1, 1, 0, 3, 153, 127, }, 43333 43333 { 3, 1, 0, 3, 153, 76, }, 43334 - { 4, 1, 0, 3, 153, 60, }, 43334 + { 4, 1, 0, 3, 153, 62, }, 43335 43335 { 5, 1, 0, 3, 153, 76, }, 43336 43336 { 6, 1, 0, 3, 153, 76, }, 43337 43337 { 7, 1, 0, 3, 153, 30, }, 43338 43338 { 8, 1, 0, 3, 153, 76, }, 43339 - { 9, 1, 0, 3, 153, -128, }, 43339 + { 9, 1, 0, 3, 153, 4, }, 43340 43340 { 0, 1, 0, 3, 157, 76, }, 43341 - { 2, 1, 0, 3, 157, -128, }, 43341 + { 2, 1, 0, 3, 157, 4, }, 43342 43342 { 1, 1, 0, 3, 157, 127, }, 43343 43343 { 3, 1, 0, 3, 157, 76, }, 43344 - { 4, 1, 0, 3, 157, 60, }, 43344 + { 4, 1, 0, 3, 157, 62, }, 43345 43345 { 5, 1, 0, 3, 157, 76, }, 43346 43346 { 6, 1, 0, 3, 157, 76, }, 43347 43347 { 7, 1, 0, 3, 157, 30, }, 43348 43348 { 8, 1, 0, 3, 157, 76, }, 43349 - { 9, 1, 0, 3, 157, -128, }, 43349 + { 9, 1, 0, 3, 157, 4, }, 43350 43350 { 0, 1, 0, 3, 161, 76, }, 43351 - { 2, 1, 0, 3, 161, -128, }, 43351 + { 2, 1, 0, 3, 161, 4, }, 43352 43352 { 1, 1, 0, 3, 161, 127, }, 43353 43353 { 3, 1, 0, 3, 161, 76, }, 43354 - { 4, 1, 0, 3, 161, 60, }, 43354 + { 4, 1, 0, 3, 161, 62, }, 43355 43355 { 5, 1, 0, 3, 161, 76, }, 43356 43356 { 6, 1, 0, 3, 161, 76, }, 43357 43357 { 7, 1, 0, 3, 161, 30, }, 43358 43358 { 8, 1, 0, 3, 161, 76, }, 43359 - { 9, 1, 0, 3, 161, -128, }, 43359 + { 9, 1, 0, 3, 161, 4, }, 43360 43360 { 0, 1, 0, 3, 165, 76, }, 43361 - { 2, 1, 0, 3, 165, -128, }, 43361 + { 2, 1, 0, 3, 165, 4, }, 43362 43362 { 1, 1, 0, 3, 165, 127, }, 43363 43363 { 3, 1, 0, 3, 165, 76, }, 43364 - { 4, 1, 0, 3, 165, 60, }, 43364 + { 4, 1, 0, 3, 165, 62, }, 43365 43365 { 5, 1, 0, 3, 165, 76, }, 43366 43366 { 6, 1, 0, 3, 165, 76, }, 43367 43367 { 7, 1, 0, 3, 165, 30, }, 43368 43368 { 8, 1, 0, 3, 165, 76, }, 43369 - { 9, 1, 0, 3, 165, -128, }, 43369 + { 9, 1, 0, 3, 165, 4, }, 43370 43370 { 0, 1, 1, 2, 38, 66, }, 43371 43371 { 2, 1, 1, 2, 38, 64, }, 43372 - { 1, 1, 1, 2, 38, 62, }, 43372 + { 1, 1, 1, 2, 38, 64, }, 43373 43373 { 3, 1, 1, 2, 38, 64, }, 43374 - { 4, 1, 1, 2, 38, 72, }, 43374 + { 4, 1, 1, 2, 38, 64, }, 43375 43375 { 5, 1, 1, 2, 38, 64, }, 43376 43376 { 6, 1, 1, 2, 38, 64, }, 43377 43377 { 7, 1, 1, 2, 38, 54, }, ··· 43379 43379 { 9, 1, 1, 2, 38, 64, }, 43380 43380 { 0, 1, 1, 2, 46, 72, }, 43381 43381 { 2, 1, 1, 2, 46, 64, }, 43382 - { 1, 1, 1, 2, 46, 62, }, 43382 + { 1, 1, 1, 2, 46, 64, }, 43383 43383 { 3, 1, 1, 2, 46, 64, }, 43384 - { 4, 1, 1, 2, 46, 60, }, 43384 + { 4, 1, 1, 2, 46, 70, }, 43385 43385 { 5, 1, 1, 2, 46, 64, }, 43386 43386 { 6, 1, 1, 2, 46, 64, }, 43387 43387 { 7, 1, 1, 2, 46, 54, }, ··· 43389 43389 { 9, 1, 1, 2, 46, 64, }, 43390 43390 { 0, 1, 1, 2, 54, 72, }, 43391 43391 { 2, 1, 1, 2, 54, 64, }, 43392 - { 1, 1, 1, 2, 54, 62, }, 43392 + { 1, 1, 1, 2, 54, 64, }, 43393 43393 { 3, 1, 1, 2, 54, 64, }, 43394 43394 { 4, 1, 1, 2, 54, 72, }, 43395 43395 { 5, 1, 1, 2, 54, 64, }, ··· 43397 43397 { 7, 1, 1, 2, 54, 54, }, 43398 43398 { 8, 1, 1, 2, 54, 72, }, 43399 43399 { 9, 1, 1, 2, 54, 64, }, 43400 - { 0, 1, 1, 2, 62, 64, }, 43400 + { 0, 1, 1, 2, 62, 60, }, 43401 43401 { 2, 1, 1, 2, 62, 64, }, 43402 43402 { 1, 1, 1, 2, 62, 62, }, 43403 - { 3, 1, 1, 2, 62, 64, }, 43404 - { 4, 1, 1, 2, 62, 70, }, 43403 + { 3, 1, 1, 2, 62, 60, }, 43404 + { 4, 1, 1, 2, 62, 60, }, 43405 43405 { 5, 1, 1, 2, 62, 64, }, 43406 43406 { 6, 1, 1, 2, 62, 64, }, 43407 43407 { 7, 1, 1, 2, 62, 54, }, 43408 43408 { 8, 1, 1, 2, 62, 64, }, 43409 43409 { 9, 1, 1, 2, 62, 64, }, 43410 - { 0, 1, 1, 2, 102, 58, }, 43410 + { 0, 1, 1, 2, 102, 60, }, 43411 43411 { 2, 1, 1, 2, 102, 64, }, 43412 43412 { 1, 1, 1, 2, 102, 72, }, 43413 - { 3, 1, 1, 2, 102, 58, }, 43414 - { 4, 1, 1, 2, 102, 72, }, 43413 + { 3, 1, 1, 2, 102, 60, }, 43414 + { 4, 1, 1, 2, 102, 64, }, 43415 43415 { 5, 1, 1, 2, 102, 64, }, 43416 43416 { 6, 1, 1, 2, 102, 58, }, 43417 43417 { 7, 1, 1, 2, 102, 54, }, ··· 43459 43459 { 9, 1, 1, 2, 134, 127, }, 43460 43460 { 0, 1, 1, 2, 142, 72, }, 43461 43461 { 2, 1, 1, 2, 142, 127, }, 43462 - { 1, 1, 1, 2, 142, 127, }, 43462 + { 1, 1, 1, 2, 142, 72, }, 43463 43463 { 3, 1, 1, 2, 142, 72, }, 43464 43464 { 4, 1, 1, 2, 142, 72, }, 43465 43465 { 5, 1, 1, 2, 142, 127, }, ··· 43468 43468 { 8, 1, 1, 2, 142, 72, }, 43469 43469 { 9, 1, 1, 2, 142, 127, }, 43470 43470 { 0, 1, 1, 2, 151, 72, }, 43471 - { 2, 1, 1, 2, 151, -128, }, 43471 + { 2, 1, 1, 2, 151, 28, }, 43472 43472 { 1, 1, 1, 2, 151, 127, }, 43473 43473 { 3, 1, 1, 2, 151, 72, }, 43474 43474 { 4, 1, 1, 2, 151, 72, }, ··· 43476 43476 { 6, 1, 1, 2, 151, 72, }, 43477 43477 { 7, 1, 1, 2, 151, 54, }, 43478 43478 { 8, 1, 1, 2, 151, 72, }, 43479 - { 9, 1, 1, 2, 151, -128, }, 43479 + { 9, 1, 1, 2, 151, 28, }, 43480 43480 { 0, 1, 1, 2, 159, 72, }, 43481 - { 2, 1, 1, 2, 159, -128, }, 43481 + { 2, 1, 1, 2, 159, 28, }, 43482 43482 { 1, 1, 1, 2, 159, 127, }, 43483 43483 { 3, 1, 1, 2, 159, 72, }, 43484 43484 { 4, 1, 1, 2, 159, 72, }, ··· 43486 43486 { 6, 1, 1, 2, 159, 72, }, 43487 43487 { 7, 1, 1, 2, 159, 54, }, 43488 43488 { 8, 1, 1, 2, 159, 72, }, 43489 - { 9, 1, 1, 2, 159, -128, }, 43489 + { 9, 1, 1, 2, 159, 28, }, 43490 43490 { 0, 1, 1, 3, 38, 60, }, 43491 43491 { 2, 1, 1, 3, 38, 40, }, 43492 43492 { 1, 1, 1, 3, 38, 50, }, 43493 43493 { 3, 1, 1, 3, 38, 40, }, 43494 - { 4, 1, 1, 3, 38, 62, }, 43494 + { 4, 1, 1, 3, 38, 54, }, 43495 43495 { 5, 1, 1, 3, 38, 40, }, 43496 43496 { 6, 1, 1, 3, 38, 52, }, 43497 43497 { 7, 1, 1, 3, 38, 30, }, ··· 43501 43501 { 2, 1, 1, 3, 46, 40, }, 43502 43502 { 1, 1, 1, 3, 46, 50, }, 43503 43503 { 3, 1, 1, 3, 46, 40, }, 43504 - { 4, 1, 1, 3, 46, 46, }, 43504 + { 4, 1, 1, 3, 46, 54, }, 43505 43505 { 5, 1, 1, 3, 46, 40, }, 43506 43506 { 6, 1, 1, 3, 46, 52, }, 43507 43507 { 7, 1, 1, 3, 46, 30, }, ··· 43511 43511 { 2, 1, 1, 3, 54, 40, }, 43512 43512 { 1, 1, 1, 3, 54, 50, }, 43513 43513 { 3, 1, 1, 3, 54, 40, }, 43514 - { 4, 1, 1, 3, 54, 62, }, 43514 + { 4, 1, 1, 3, 54, 66, }, 43515 43515 { 5, 1, 1, 3, 54, 40, }, 43516 43516 { 6, 1, 1, 3, 54, 68, }, 43517 43517 { 7, 1, 1, 3, 54, 30, }, ··· 43521 43521 { 2, 1, 1, 3, 62, 40, }, 43522 43522 { 1, 1, 1, 3, 62, 48, }, 43523 43523 { 3, 1, 1, 3, 62, 40, }, 43524 - { 4, 1, 1, 3, 62, 58, }, 43524 + { 4, 1, 1, 3, 62, 50, }, 43525 43525 { 5, 1, 1, 3, 62, 40, }, 43526 43526 { 6, 1, 1, 3, 62, 58, }, 43527 43527 { 7, 1, 1, 3, 62, 30, }, 43528 43528 { 8, 1, 1, 3, 62, 58, }, 43529 43529 { 9, 1, 1, 3, 62, 40, }, 43530 - { 0, 1, 1, 3, 102, 54, }, 43530 + { 0, 1, 1, 3, 102, 56, }, 43531 43531 { 2, 1, 1, 3, 102, 40, }, 43532 43532 { 1, 1, 1, 3, 102, 70, }, 43533 - { 3, 1, 1, 3, 102, 54, }, 43534 - { 4, 1, 1, 3, 102, 64, }, 43533 + { 3, 1, 1, 3, 102, 56, }, 43534 + { 4, 1, 1, 3, 102, 54, }, 43535 43535 { 5, 1, 1, 3, 102, 40, }, 43536 43536 { 6, 1, 1, 3, 102, 54, }, 43537 43537 { 7, 1, 1, 3, 102, 30, }, ··· 43541 43541 { 2, 1, 1, 3, 110, 40, }, 43542 43542 { 1, 1, 1, 3, 110, 70, }, 43543 43543 { 3, 1, 1, 3, 110, 68, }, 43544 - { 4, 1, 1, 3, 110, 64, }, 43544 + { 4, 1, 1, 3, 110, 66, }, 43545 43545 { 5, 1, 1, 3, 110, 40, }, 43546 43546 { 6, 1, 1, 3, 110, 68, }, 43547 43547 { 7, 1, 1, 3, 110, 30, }, ··· 43551 43551 { 2, 1, 1, 3, 118, 40, }, 43552 43552 { 1, 1, 1, 3, 118, 70, }, 43553 43553 { 3, 1, 1, 3, 118, 127, }, 43554 - { 4, 1, 1, 3, 118, 64, }, 43554 + { 4, 1, 1, 3, 118, 66, }, 43555 43555 { 5, 1, 1, 3, 118, 127, }, 43556 43556 { 6, 1, 1, 3, 118, 68, }, 43557 43557 { 7, 1, 1, 3, 118, 30, }, ··· 43561 43561 { 2, 1, 1, 3, 126, 40, }, 43562 43562 { 1, 1, 1, 3, 126, 70, }, 43563 43563 { 3, 1, 1, 3, 126, 127, }, 43564 - { 4, 1, 1, 3, 126, 64, }, 43564 + { 4, 1, 1, 3, 126, 66, }, 43565 43565 { 5, 1, 1, 3, 126, 127, }, 43566 43566 { 6, 1, 1, 3, 126, 68, }, 43567 43567 { 7, 1, 1, 3, 126, 30, }, ··· 43571 43571 { 2, 1, 1, 3, 134, 40, }, 43572 43572 { 1, 1, 1, 3, 134, 70, }, 43573 43573 { 3, 1, 1, 3, 134, 68, }, 43574 - { 4, 1, 1, 3, 134, 64, }, 43574 + { 4, 1, 1, 3, 134, 66, }, 43575 43575 { 5, 1, 1, 3, 134, 40, }, 43576 43576 { 6, 1, 1, 3, 134, 68, }, 43577 43577 { 7, 1, 1, 3, 134, 30, }, ··· 43579 43579 { 9, 1, 1, 3, 134, 127, }, 43580 43580 { 0, 1, 1, 3, 142, 68, }, 43581 43581 { 2, 1, 1, 3, 142, 127, }, 43582 - { 1, 1, 1, 3, 142, 127, }, 43582 + { 1, 1, 1, 3, 142, 70, }, 43583 43583 { 3, 1, 1, 3, 142, 68, }, 43584 - { 4, 1, 1, 3, 142, 64, }, 43584 + { 4, 1, 1, 3, 142, 66, }, 43585 43585 { 5, 1, 1, 3, 142, 127, }, 43586 43586 { 6, 1, 1, 3, 142, 68, }, 43587 43587 { 7, 1, 1, 3, 142, 127, }, 43588 43588 { 8, 1, 1, 3, 142, 68, }, 43589 43589 { 9, 1, 1, 3, 142, 127, }, 43590 43590 { 0, 1, 1, 3, 151, 72, }, 43591 - { 2, 1, 1, 3, 151, -128, }, 43591 + { 2, 1, 1, 3, 151, 4, }, 43592 43592 { 1, 1, 1, 3, 151, 127, }, 43593 43593 { 3, 1, 1, 3, 151, 72, }, 43594 43594 { 4, 1, 1, 3, 151, 66, }, ··· 43596 43596 { 6, 1, 1, 3, 151, 72, }, 43597 43597 { 7, 1, 1, 3, 151, 30, }, 43598 43598 { 8, 1, 1, 3, 151, 68, }, 43599 - { 9, 1, 1, 3, 151, -128, }, 43599 + { 9, 1, 1, 3, 151, 4, }, 43600 43600 { 0, 1, 1, 3, 159, 72, }, 43601 - { 2, 1, 1, 3, 159, -128, }, 43601 + { 2, 1, 1, 3, 159, 4, }, 43602 43602 { 1, 1, 1, 3, 159, 127, }, 43603 43603 { 3, 1, 1, 3, 159, 72, }, 43604 43604 { 4, 1, 1, 3, 159, 66, }, ··· 43606 43606 { 6, 1, 1, 3, 159, 72, }, 43607 43607 { 7, 1, 1, 3, 159, 30, }, 43608 43608 { 8, 1, 1, 3, 159, 72, }, 43609 - { 9, 1, 1, 3, 159, -128, }, 43610 - { 0, 1, 2, 4, 42, 64, }, 43609 + { 9, 1, 1, 3, 159, 4, }, 43610 + { 0, 1, 2, 4, 42, 68, }, 43611 43611 { 2, 1, 2, 4, 42, 64, }, 43612 43612 { 1, 1, 2, 4, 42, 64, }, 43613 43613 { 3, 1, 2, 4, 42, 64, }, 43614 - { 4, 1, 2, 4, 42, 68, }, 43614 + { 4, 1, 2, 4, 42, 60, }, 43615 43615 { 5, 1, 2, 4, 42, 64, }, 43616 43616 { 6, 1, 2, 4, 42, 64, }, 43617 43617 { 7, 1, 2, 4, 42, 54, }, 43618 43618 { 8, 1, 2, 4, 42, 62, }, 43619 43619 { 9, 1, 2, 4, 42, 64, }, 43620 - { 0, 1, 2, 4, 58, 62, }, 43620 + { 0, 1, 2, 4, 58, 60, }, 43621 43621 { 2, 1, 2, 4, 58, 64, }, 43622 43622 { 1, 1, 2, 4, 58, 64, }, 43623 - { 3, 1, 2, 4, 58, 62, }, 43624 - { 4, 1, 2, 4, 58, 64, }, 43623 + { 3, 1, 2, 4, 58, 60, }, 43624 + { 4, 1, 2, 4, 58, 56, }, 43625 43625 { 5, 1, 2, 4, 58, 64, }, 43626 43626 { 6, 1, 2, 4, 58, 62, }, 43627 43627 { 7, 1, 2, 4, 58, 54, }, 43628 43628 { 8, 1, 2, 4, 58, 62, }, 43629 43629 { 9, 1, 2, 4, 58, 64, }, 43630 - { 0, 1, 2, 4, 106, 58, }, 43630 + { 0, 1, 2, 4, 106, 60, }, 43631 43631 { 2, 1, 2, 4, 106, 64, }, 43632 43632 { 1, 1, 2, 4, 106, 72, }, 43633 - { 3, 1, 2, 4, 106, 58, }, 43634 - { 4, 1, 2, 4, 106, 66, }, 43633 + { 3, 1, 2, 4, 106, 60, }, 43634 + { 4, 1, 2, 4, 106, 58, }, 43635 43635 { 5, 1, 2, 4, 106, 64, }, 43636 43636 { 6, 1, 2, 4, 106, 58, }, 43637 43637 { 7, 1, 2, 4, 106, 54, }, ··· 43649 43649 { 9, 1, 2, 4, 122, 127, }, 43650 43650 { 0, 1, 2, 4, 138, 72, }, 43651 43651 { 2, 1, 2, 4, 138, 127, }, 43652 - { 1, 1, 2, 4, 138, 127, }, 43652 + { 1, 1, 2, 4, 138, 72, }, 43653 43653 { 3, 1, 2, 4, 138, 72, }, 43654 - { 4, 1, 2, 4, 138, 68, }, 43654 + { 4, 1, 2, 4, 138, 70, }, 43655 43655 { 5, 1, 2, 4, 138, 127, }, 43656 43656 { 6, 1, 2, 4, 138, 72, }, 43657 43657 { 7, 1, 2, 4, 138, 127, }, 43658 43658 { 8, 1, 2, 4, 138, 72, }, 43659 43659 { 9, 1, 2, 4, 138, 127, }, 43660 43660 { 0, 1, 2, 4, 155, 72, }, 43661 - { 2, 1, 2, 4, 155, -128, }, 43661 + { 2, 1, 2, 4, 155, 28, }, 43662 43662 { 1, 1, 2, 4, 155, 127, }, 43663 43663 { 3, 1, 2, 4, 155, 72, }, 43664 - { 4, 1, 2, 4, 155, 68, }, 43664 + { 4, 1, 2, 4, 155, 62, }, 43665 43665 { 5, 1, 2, 4, 155, 72, }, 43666 43666 { 6, 1, 2, 4, 155, 72, }, 43667 43667 { 7, 1, 2, 4, 155, 54, }, 43668 43668 { 8, 1, 2, 4, 155, 68, }, 43669 - { 9, 1, 2, 4, 155, -128, }, 43670 - { 0, 1, 2, 5, 42, 54, }, 43669 + { 9, 1, 2, 4, 155, 28, }, 43670 + { 0, 1, 2, 5, 42, 56, }, 43671 43671 { 2, 1, 2, 5, 42, 40, }, 43672 43672 { 1, 1, 2, 5, 42, 50, }, 43673 43673 { 3, 1, 2, 5, 42, 40, }, 43674 - { 4, 1, 2, 5, 42, 58, }, 43674 + { 4, 1, 2, 5, 42, 50, }, 43675 43675 { 5, 1, 2, 5, 42, 40, }, 43676 43676 { 6, 1, 2, 5, 42, 52, }, 43677 43677 { 7, 1, 2, 5, 42, 30, }, 43678 43678 { 8, 1, 2, 5, 42, 50, }, 43679 43679 { 9, 1, 2, 5, 42, 40, }, 43680 - { 0, 1, 2, 5, 58, 52, }, 43680 + { 0, 1, 2, 5, 58, 54, }, 43681 43681 { 2, 1, 2, 5, 58, 40, }, 43682 43682 { 1, 1, 2, 5, 58, 50, }, 43683 43683 { 3, 1, 2, 5, 58, 40, }, 43684 - { 4, 1, 2, 5, 58, 56, }, 43684 + { 4, 1, 2, 5, 58, 46, }, 43685 43685 { 5, 1, 2, 5, 58, 40, }, 43686 43686 { 6, 1, 2, 5, 58, 52, }, 43687 43687 { 7, 1, 2, 5, 58, 30, }, 43688 43688 { 8, 1, 2, 5, 58, 52, }, 43689 43689 { 9, 1, 2, 5, 58, 40, }, 43690 - { 0, 1, 2, 5, 106, 50, }, 43690 + { 0, 1, 2, 5, 106, 48, }, 43691 43691 { 2, 1, 2, 5, 106, 40, }, 43692 43692 { 1, 1, 2, 5, 106, 72, }, 43693 - { 3, 1, 2, 5, 106, 50, }, 43694 - { 4, 1, 2, 5, 106, 56, }, 43693 + { 3, 1, 2, 5, 106, 48, }, 43694 + { 4, 1, 2, 5, 106, 50, }, 43695 43695 { 5, 1, 2, 5, 106, 40, }, 43696 43696 { 6, 1, 2, 5, 106, 50, }, 43697 43697 { 7, 1, 2, 5, 106, 30, }, 43698 43698 { 8, 1, 2, 5, 106, 50, }, 43699 43699 { 9, 1, 2, 5, 106, 127, }, 43700 - { 0, 1, 2, 5, 122, 66, }, 43700 + { 0, 1, 2, 5, 122, 70, }, 43701 43701 { 2, 1, 2, 5, 122, 40, }, 43702 43702 { 1, 1, 2, 5, 122, 72, }, 43703 43703 { 3, 1, 2, 5, 122, 127, }, 43704 - { 4, 1, 2, 5, 122, 56, }, 43704 + { 4, 1, 2, 5, 122, 62, }, 43705 43705 { 5, 1, 2, 5, 122, 127, }, 43706 43706 { 6, 1, 2, 5, 122, 66, }, 43707 43707 { 7, 1, 2, 5, 122, 30, }, 43708 43708 { 8, 1, 2, 5, 122, 66, }, 43709 43709 { 9, 1, 2, 5, 122, 127, }, 43710 - { 0, 1, 2, 5, 138, 66, }, 43710 + { 0, 1, 2, 5, 138, 70, }, 43711 43711 { 2, 1, 2, 5, 138, 127, }, 43712 - { 1, 1, 2, 5, 138, 127, }, 43713 - { 3, 1, 2, 5, 138, 66, }, 43714 - { 4, 1, 2, 5, 138, 58, }, 43712 + { 1, 1, 2, 5, 138, 72, }, 43713 + { 3, 1, 2, 5, 138, 70, }, 43714 + { 4, 1, 2, 5, 138, 62, }, 43715 43715 { 5, 1, 2, 5, 138, 127, }, 43716 43716 { 6, 1, 2, 5, 138, 66, }, 43717 43717 { 7, 1, 2, 5, 138, 127, }, 43718 43718 { 8, 1, 2, 5, 138, 66, }, 43719 43719 { 9, 1, 2, 5, 138, 127, }, 43720 - { 0, 1, 2, 5, 155, 62, }, 43721 - { 2, 1, 2, 5, 155, -128, }, 43720 + { 0, 1, 2, 5, 155, 72, }, 43721 + { 2, 1, 2, 5, 155, 4, }, 43722 43722 { 1, 1, 2, 5, 155, 127, }, 43723 - { 3, 1, 2, 5, 155, 62, }, 43724 - { 4, 1, 2, 5, 155, 58, }, 43723 + { 3, 1, 2, 5, 155, 72, }, 43724 + { 4, 1, 2, 5, 155, 52, }, 43725 43725 { 5, 1, 2, 5, 155, 72, }, 43726 43726 { 6, 1, 2, 5, 155, 62, }, 43727 43727 { 7, 1, 2, 5, 155, 30, }, 43728 43728 { 8, 1, 2, 5, 155, 62, }, 43729 - { 9, 1, 2, 5, 155, -128, }, 43729 + { 9, 1, 2, 5, 155, 4, }, 43730 43730 }; 43731 43731 43732 43732 RTW_DECL_TABLE_TXPWR_LMT(rtw8822c_txpwr_lmt_type5);