Lines Matching +full:convert +full:- +full:rate

1 // SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause
3 * Copyright (C) 2021-2022 Intel Corporation
8 #include "iwl-drv.h"
9 #include "iwl-config.h"
96 int rate = rate_n_flags & RATE_LEGACY_RATE_MSK_V1; in iwl_legacy_rate_to_fw_idx() local
103 if (iwl_fw_rate_idx_to_plcp(idx) == rate) in iwl_legacy_rate_to_fw_idx()
104 return idx - offset; in iwl_legacy_rate_to_fw_idx()
115 /* convert rate */ in iwl_new_rate_from_v1()
142 /* the new rate have an additional bit to in iwl_new_rate_from_v1()
144 * bit for this purpose - as it was done in the old in iwl_new_rate_from_v1()
145 * rate */ in iwl_new_rate_from_v1()
170 /* convert flags */ in iwl_new_rate_from_v1()
192 int rs_pretty_print_rate(char *buf, int bufsz, const u32 rate) in rs_pretty_print_rate() argument
196 u8 ant = (rate & RATE_MCS_ANT_AB_MSK) >> RATE_MCS_ANT_POS; in rs_pretty_print_rate()
197 u32 bw = (rate & RATE_MCS_CHAN_WIDTH_MSK) >> in rs_pretty_print_rate()
199 u32 format = rate & RATE_MCS_MOD_TYPE_MSK; in rs_pretty_print_rate()
204 int legacy_rate = rate & RATE_LEGACY_RATE_MSK; in rs_pretty_print_rate()
209 return scnprintf(buf, bufsz, "Legacy | ANT: %s Rate: %s Mbps", in rs_pretty_print_rate()
211 iwl_rate_mcs(index)->mbps); in rs_pretty_print_rate()
226 RATE_HT_MCS_INDEX(rate) : in rs_pretty_print_rate()
227 rate & RATE_MCS_CODE_MSK; in rs_pretty_print_rate()
228 nss = ((rate & RATE_MCS_NSS_MSK) in rs_pretty_print_rate()
231 iwl_he_is_sgi(rate) : in rs_pretty_print_rate()
232 rate & RATE_MCS_SGI_MSK; in rs_pretty_print_rate()
236 rate, type, iwl_rs_pretty_ant(ant), iwl_rs_pretty_bw(bw), mcs, nss, in rs_pretty_print_rate()
238 (rate & RATE_MCS_STBC_MSK) ? "STBC " : "", in rs_pretty_print_rate()
239 (rate & RATE_MCS_LDPC_MSK) ? "LDPC " : "", in rs_pretty_print_rate()
240 (rate & RATE_HE_DUAL_CARRIER_MODE_MSK) ? "DCM " : "", in rs_pretty_print_rate()
241 (rate & RATE_MCS_BF_MSK) ? "BF " : ""); in rs_pretty_print_rate()