CC: [email protected] In-Reply-To: <[email protected]> References: <[email protected]> TO: "Toke Høiland-Jørgensen" <[email protected]> TO: [email protected] CC: "Toke Høiland-Jørgensen" <[email protected]> CC: [email protected] CC: Felix Fietkau <[email protected]> CC: Rajkumar Manoharan <[email protected]> CC: Kan Yan <[email protected]> CC: Yibo Zhao <[email protected]>
Hi "Toke, I love your patch! Perhaps something to improve: [auto build test WARNING on mac80211-next/master] [also build test WARNING on next-20210505] [cannot apply to mac80211/master v5.12] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Toke-H-iland-J-rgensen/mac80211-Switch-to-a-virtual-time-based-airtime-scheduler/20210505-224557 base: https://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next.git master :::::: branch date: 5 hours ago :::::: commit date: 5 hours ago config: x86_64-randconfig-m001-20210505 (attached as .config) compiler: gcc-9 (Debian 9.3.0-22) 9.3.0 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <[email protected]> Reported-by: Dan Carpenter <[email protected]> New smatch warnings: net/mac80211/debugfs.c:258 aql_txq_limit_write() warn: potential spectre issue 'local->airtime' [r] (local cap) Old smatch warnings: net/mac80211/debugfs.c:269 aql_txq_limit_write() warn: potential spectre issue 'sta->airtime' [w] (local cap) vim +258 net/mac80211/debugfs.c 3ace10f5b5ad94 Kan Yan 2019-11-18 230 3ace10f5b5ad94 Kan Yan 2019-11-18 231 static ssize_t aql_txq_limit_write(struct file *file, 3ace10f5b5ad94 Kan Yan 2019-11-18 232 const char __user *user_buf, 3ace10f5b5ad94 Kan Yan 2019-11-18 233 size_t count, 3ace10f5b5ad94 Kan Yan 2019-11-18 234 loff_t *ppos) 3ace10f5b5ad94 Kan Yan 2019-11-18 235 { 3ace10f5b5ad94 Kan Yan 2019-11-18 236 struct ieee80211_local *local = file->private_data; 3ace10f5b5ad94 Kan Yan 2019-11-18 237 char buf[100]; 3ace10f5b5ad94 Kan Yan 2019-11-18 238 u32 ac, q_limit_low, q_limit_high, q_limit_low_old, q_limit_high_old; 3ace10f5b5ad94 Kan Yan 2019-11-18 239 struct sta_info *sta; 3ace10f5b5ad94 Kan Yan 2019-11-18 240 6020d534fa012b Shayne Chen 2021-01-12 241 if (count >= sizeof(buf)) 3ace10f5b5ad94 Kan Yan 2019-11-18 242 return -EINVAL; 3ace10f5b5ad94 Kan Yan 2019-11-18 243 3ace10f5b5ad94 Kan Yan 2019-11-18 244 if (copy_from_user(buf, user_buf, count)) 3ace10f5b5ad94 Kan Yan 2019-11-18 245 return -EFAULT; 3ace10f5b5ad94 Kan Yan 2019-11-18 246 6020d534fa012b Shayne Chen 2021-01-12 247 if (count && buf[count - 1] == '\n') 6020d534fa012b Shayne Chen 2021-01-12 248 buf[count - 1] = '\0'; 6020d534fa012b Shayne Chen 2021-01-12 249 else 6020d534fa012b Shayne Chen 2021-01-12 250 buf[count] = '\0'; 3ace10f5b5ad94 Kan Yan 2019-11-18 251 3ace10f5b5ad94 Kan Yan 2019-11-18 252 if (sscanf(buf, "%u %u %u", &ac, &q_limit_low, &q_limit_high) != 3) 3ace10f5b5ad94 Kan Yan 2019-11-18 253 return -EINVAL; 3ace10f5b5ad94 Kan Yan 2019-11-18 254 3ace10f5b5ad94 Kan Yan 2019-11-18 255 if (ac >= IEEE80211_NUM_ACS) 3ace10f5b5ad94 Kan Yan 2019-11-18 256 return -EINVAL; 3ace10f5b5ad94 Kan Yan 2019-11-18 257 4ff38b3940e58b Toke Høiland-Jørgensen 2021-05-05 @258 q_limit_low_old = local->airtime[ac].aql_txq_limit_low; 4ff38b3940e58b Toke Høiland-Jørgensen 2021-05-05 259 q_limit_high_old = local->airtime[ac].aql_txq_limit_high; 3ace10f5b5ad94 Kan Yan 2019-11-18 260 4ff38b3940e58b Toke Høiland-Jørgensen 2021-05-05 261 local->airtime[ac].aql_txq_limit_low = q_limit_low; 4ff38b3940e58b Toke Høiland-Jørgensen 2021-05-05 262 local->airtime[ac].aql_txq_limit_high = q_limit_high; 3ace10f5b5ad94 Kan Yan 2019-11-18 263 3ace10f5b5ad94 Kan Yan 2019-11-18 264 mutex_lock(&local->sta_mtx); 3ace10f5b5ad94 Kan Yan 2019-11-18 265 list_for_each_entry(sta, &local->sta_list, list) { 3ace10f5b5ad94 Kan Yan 2019-11-18 266 /* If a sta has customized queue limits, keep it */ 3ace10f5b5ad94 Kan Yan 2019-11-18 267 if (sta->airtime[ac].aql_limit_low == q_limit_low_old && 3ace10f5b5ad94 Kan Yan 2019-11-18 268 sta->airtime[ac].aql_limit_high == q_limit_high_old) { 3ace10f5b5ad94 Kan Yan 2019-11-18 269 sta->airtime[ac].aql_limit_low = q_limit_low; 3ace10f5b5ad94 Kan Yan 2019-11-18 270 sta->airtime[ac].aql_limit_high = q_limit_high; 3ace10f5b5ad94 Kan Yan 2019-11-18 271 } 3ace10f5b5ad94 Kan Yan 2019-11-18 272 } 3ace10f5b5ad94 Kan Yan 2019-11-18 273 mutex_unlock(&local->sta_mtx); 3ace10f5b5ad94 Kan Yan 2019-11-18 274 return count; 3ace10f5b5ad94 Kan Yan 2019-11-18 275 } 3ace10f5b5ad94 Kan Yan 2019-11-18 276 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/[email protected]
.config.gz
Description: application/gzip
_______________________________________________ kbuild mailing list -- [email protected] To unsubscribe send an email to [email protected]
