lkml.org 
[lkml]   [2021]   [Nov]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectdrivers/net/wireless/intel/iwlwifi/mvm/rs-fw.c:314 iwl_mvm_tlc_update_notif() warn: inconsistent indenting
tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 923dcc5eb0c111eccd51cc7ce1658537e3c38b25
commit: 82cdbd11b60a19e59f7991350b0c4e901c48c687 iwlwifi: mvm: Support version 3 of tlc_update_notif.
date: 4 weeks ago
config: mips-randconfig-m031-20211104 (attached as .config)
compiler: mips-linux-gcc (GCC) 11.2.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

smatch warnings:
drivers/net/wireless/intel/iwlwifi/mvm/rs-fw.c:314 iwl_mvm_tlc_update_notif() warn: inconsistent indenting

vim +314 drivers/net/wireless/intel/iwlwifi/mvm/rs-fw.c

278
279 void iwl_mvm_tlc_update_notif(struct iwl_mvm *mvm,
280 struct iwl_rx_cmd_buffer *rxb)
281 {
282 struct iwl_rx_packet *pkt = rxb_addr(rxb);
283 struct iwl_tlc_update_notif *notif;
284 struct ieee80211_sta *sta;
285 struct iwl_mvm_sta *mvmsta;
286 struct iwl_lq_sta_rs_fw *lq_sta;
287 u32 flags;
288
289 rcu_read_lock();
290
291 notif = (void *)pkt->data;
292 sta = rcu_dereference(mvm->fw_id_to_mac_id[notif->sta_id]);
293 if (IS_ERR_OR_NULL(sta)) {
294 IWL_ERR(mvm, "Invalid sta id (%d) in FW TLC notification\n",
295 notif->sta_id);
296 goto out;
297 }
298
299 mvmsta = iwl_mvm_sta_from_mac80211(sta);
300
301 if (!mvmsta) {
302 IWL_ERR(mvm, "Invalid sta id (%d) in FW TLC notification\n",
303 notif->sta_id);
304 goto out;
305 }
306
307 flags = le32_to_cpu(notif->flags);
308
309 lq_sta = &mvmsta->lq_sta.rs_fw;
310
311 if (flags & IWL_TLC_NOTIF_FLAG_RATE) {
312 char pretty_rate[100];
313
> 314 if (iwl_fw_lookup_notif_ver(mvm->fw, DATA_PATH_GROUP,
315 TLC_MNG_UPDATE_NOTIF, 0) < 3) {
316 rs_pretty_print_rate_v1(pretty_rate, sizeof(pretty_rate),
317 le32_to_cpu(notif->rate));
318 IWL_DEBUG_RATE(mvm,
319 "Got rate in old format. Rate: %s. Converting.\n",
320 pretty_rate);
321 lq_sta->last_rate_n_flags =
322 iwl_new_rate_from_v1(le32_to_cpu(notif->rate));
323 } else {
324 lq_sta->last_rate_n_flags = le32_to_cpu(notif->rate);
325 }
326 rs_pretty_print_rate(pretty_rate, sizeof(pretty_rate),
327 lq_sta->last_rate_n_flags);
328 IWL_DEBUG_RATE(mvm, "new rate: %s\n", pretty_rate);
329 }
330
331 if (flags & IWL_TLC_NOTIF_FLAG_AMSDU && !mvmsta->orig_amsdu_len) {
332 u16 size = le32_to_cpu(notif->amsdu_size);
333 int i;
334
335 if (sta->max_amsdu_len < size) {
336 /*
337 * In debug sta->max_amsdu_len < size
338 * so also check with orig_amsdu_len which holds the
339 * original data before debugfs changed the value
340 */
341 WARN_ON(mvmsta->orig_amsdu_len < size);
342 goto out;
343 }
344
345 mvmsta->amsdu_enabled = le32_to_cpu(notif->amsdu_enabled);
346 mvmsta->max_amsdu_len = size;
347 sta->max_rc_amsdu_len = mvmsta->max_amsdu_len;
348
349 for (i = 0; i < IWL_MAX_TID_COUNT; i++) {
350 if (mvmsta->amsdu_enabled & BIT(i))
351 sta->max_tid_amsdu_len[i] =
352 iwl_mvm_max_amsdu_size(mvm, sta, i);
353 else
354 /*
355 * Not so elegant, but this will effectively
356 * prevent AMSDU on this TID
357 */
358 sta->max_tid_amsdu_len[i] = 1;
359 }
360
361 IWL_DEBUG_RATE(mvm,
362 "AMSDU update. AMSDU size: %d, AMSDU selected size: %d, AMSDU TID bitmap 0x%X\n",
363 le32_to_cpu(notif->amsdu_size), size,
364 mvmsta->amsdu_enabled);
365 }
366 out:
367 rcu_read_unlock();
368 }
369

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[unhandled content-type:application/gzip]
\
 
 \ /
  Last update: 2021-11-21 07:15    [W:0.068 / U:0.612 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site