mac80211: fix overflow issues in airtime fairness code
PATCH 1/2 mac80211: fix overflow issues in airtime fairness code
The airtime weight calculation overflows with a default weight value of 256 whenever more than 8ms worth of airtime is reported.
Bigger weight values impose even smaller limits on maximum airtime values. This can mess up airtime based calculations for drivers that don't report per-PPDU airtime values, but batch up values instead.
Fix this by reordering multiplications/shifts and by reducing unnecessary intermediate precision (which was lost in a later stage anyway).
The new shift value limits the maximum weight to 4096, which should be more than enough. Any values bigger than that will be clamped to the upper limit.
--- net/mac80211/ieee80211_i.h | 42 ++++++++++++-------------------------- net/mac80211/sta_info.c | 11 ++++------ 2 files changed, 17 insertions(+), 36 deletions(-)
net/mac80211/ieee80211_i.h +13 -29
@@ -1677,50 +1677,34 @@ static inline struct airtime_info *to_airtime_info(struct ieee80211_txq *txq)/* To avoid divisions in the fast path, we keep pre-computed reciprocals for * airtime weight calculations. There are two different weights to keep track * of: The per-station weight and the sum of weights per phy. -* -* For the per-station weights (kept in airtime_info below), we use 32-bit -* reciprocals with a devisor of 2^19. This lets us keep the multiplications and -* divisions for the station weights as 32-bit operations at the cost of a bit -* of rounding error for high weights; but the choice of divisor keeps rounding -* errors <10% for weights <2^15, assuming no more than 8ms of airtime is -* reported at a time. -* -* For the per-phy sum of weights the values can get higher, so we use 64-bit -* operations for those with a 32-bit divisor, which should avoid any -* significant rounding errors. +* The per-sta shift value supports weight values of 1-4096 */ -#define IEEE80211_RECIPROCAL_DIVISOR_64 0x100000000ULL -#define IEEE80211_RECIPROCAL_SHIFT_64 32 -#define IEEE80211_RECIPROCAL_DIVISOR_32 0x80000U -#define IEEE80211_RECIPROCAL_SHIFT_32 19 +#define IEEE80211_RECIPROCAL_SHIFT_SUM 24 +#define IEEE80211_RECIPROCAL_SHIFT_STA 12 +#define IEEE80211_WEIGHT_SHIFT 8 -static inline void airtime_weight_set (struct airtime_info *air_info,u16 weight) +static inline void airtime_weight_set (struct airtime_info *air_info,u32 weight) { + weight =min_t (u32, weight,BIT (IEEE80211_RECIPROCAL_SHIFT_STA ));if (air_info->weight == weight)return ; air_info->weight = weight; -if (weight) { - air_info->weight_reciprocal = -IEEE80211_RECIPROCAL_DIVISOR_32 / weight; - }else { - air_info->weight_reciprocal =0 ; - } +if (weight) + weight =BIT (IEEE80211_RECIPROCAL_SHIFT_STA ) / weight; + air_info->weight_reciprocal = weight; }static inline void airtime_weight_sum_set (struct airtime_sched_info *air_sched, -int weight_sum) +u32 weight_sum) {if (air_sched->weight_sum == weight_sum)return ; air_sched->weight_sum = weight_sum; -if (air_sched->weight_sum) { - air_sched->weight_sum_reciprocal =IEEE80211_RECIPROCAL_DIVISOR_64 ; -do_div (air_sched->weight_sum_reciprocal, air_sched->weight_sum); - }else { - air_sched->weight_sum_reciprocal =0 ; - } +if (weight_sum) + weight_sum =BIT (IEEE80211_RECIPROCAL_SHIFT_SUM ) / weight_sum; + air_sched->weight_sum_reciprocal = weight_sum; }/* A problem when trying to enforce airtime fairness is that we want to divide
net/mac80211/sta_info.c +4 -7
@@ -1919,9 +1919,6 @@ void ieee80211_register_airtime(struct ieee80211_txq *txq,if (local->airtime_flags &AIRTIME_USE_RX ) airtime += rx_airtime; -/* Weights scale so the unit weight is 256 */ - airtime <<=8 ; -spin_lock_bh (&air_sched->lock); air_info->tx_airtime += tx_airtime;
@@ -1936,10 +1933,10 @@ void ieee80211_register_airtime(struct ieee80211_txq *txq, }/* Round the calculation of global vt */ - air_sched->v_t += (u64)((airtime + (weight_sum >>1 )) * - weight_sum_reciprocal) >>IEEE80211_RECIPROCAL_SHIFT_64 ; - air_info->v_t += (u32)((airtime + (air_info->weight >>1 )) * - air_info->weight_reciprocal) >>IEEE80211_RECIPROCAL_SHIFT_32 ; + air_sched->v_t += ((u64 )airtime * weight_sum_reciprocal) >> + (IEEE80211_RECIPROCAL_SHIFT_SUM -IEEE80211_WEIGHT_SHIFT ); + air_info->v_t += (airtime * air_info->weight_reciprocal) >> + (IEEE80211_RECIPROCAL_SHIFT_STA -IEEE80211_WEIGHT_SHIFT );ieee80211_resort_txq (&local->hw, txq);spin_unlock_bh (&air_sched->lock);
Signature · 1 line
2.36.1
PATCH 2/2 mac80211: rework the airtime fairness implementation
The current ATF implementation has a number of issues which have shown up during testing. Since it does not take into account the AQL budget of pending packets, the implementation might queue up large amounts of packets for a single txq until airtime gets reported after tx completion. The same then happens to the next txq afterwards. While the end result could still be considered fair, the bursty behavior introduces a large amount of latency.
The current code also tries to avoid frequent re-sorting of txq entries in order to avoid having to re-balance the rbtree often.
In order to fix these issues, introduce skip lists as a data structure, which offer similar lookup/insert/delete times as rbtree, but avoids the need for rebalacing by being probabilistic.
Use this to keep tx entries sorted by virtual time + pending AQL budget and re-sort after each ieee80211_return_txq call.
Since multiple txqs share a single air_time struct with a virtual time value, switch the active_txqs list to queue up air_time structs instead of queues. This helps avoid imbalance between shared txqs by servicing them round robin.
ieee80211_next_txq now only dequeues the first element of active_txqs. To make that work for non-AQL or non-ATF drivers as well, add estimated tx airtime directly to air_info virtual time if either AQL or ATF is not supported.
--- include/linux/skiplist.h | 242 ++++++++++++++++++++++++++++++++++++ net/mac80211/cfg.c | 5 - net/mac80211/ieee80211_i.h | 33 ++++- net/mac80211/main.c | 2 +- net/mac80211/sta_info.c | 3 +- net/mac80211/sta_info.h | 4 + net/mac80211/tx.c | 244 ++++++++++++++++++------------------- 7 files changed, 393 insertions(+), 140 deletions(-) create mode 100644 include/linux/skiplist.h
include/linux/skiplist.h new file +242 -0
@@ -0,0 +1,242 @@ +/* SPDX-License-Identifier: GPL-2.0-or-later */ +/* +* A skip list is a probabilistic alternative to balanced trees. Unlike the +* red-black tree, it does not require rebalancing. +* +* This implementation uses only unidirectional next pointers and is optimized +* for use in a priority queue where elements are mostly deleted from the front +* of the queue. +* +* When storing up to 2^n elements in a n-level skiplist. lookup and deletion +* for the first element happens in O(1) time, other than that, insertion and +* deletion takes O(log n) time, assuming that the number of elements for an +* n-level list does not exceed 2^n. +* +* Usage: +* DECLARE_SKIPLIST_TYPE(foo, 5) will define the data types for a 5-level list: +* struct foo_list: the list data type +* struct foo_node: the node data for an element in the list +* +* DECLARE_SKIPLIST_IMPL(foo, foo_cmp_fn, foo_seed_fn) +* +* Adds the skip list implementation. It depends on two provided functions: +* int foo_cmp_fn(struct foo_list *list, struct foo_node *n1, struct foo_node *n2) +* This compares two elements given by their node pointers, returning values <0 +* if n1 is less than n2, =0 and >0 for equal or bigger than respectively. +* +* u32 foo_seed_fn(struct foo_list *list) +* returns a random 32 bit value. It is used by the list implementation to +* determine the level of a newly added list member +* +* This macro implements the following functions: +* +* void foo_list_init(struct foo_list *list) +* initializes the skip list +* +* void foo_node_init(struct foo_node *node) +* initializes a node. must be called before adding the node to the list +* +* struct foo_node *foo_node_next(struct foo_node *node) +* gets the node directly after the provided node, or NULL if it was the last +* element in the list. +* +* bool foo_is_queued(struct foo_node *node) +* returns true if the node is on a list +* +* struct foo_node *foo_dequeue(struct foo_list *list) +* deletes and returns the first element of the list (or returns NULL if empty) +* +* struct foo_node *foo_peek(struct foo_list *list) +* returns the first element of the list +* +* void foo_insert(struct foo_list *list, struct foo_node *node) +* inserts the node into the list. the node must be initialized and not on a +* list already. +* +* void foo_delete(struct foo_list *list, struct foo_node *node) +* deletes the node from the list, or does nothing if it's not on the list +*/ +#ifndef __SKIPLIST_H +#define __SKIPLIST_H + +#include <linux/bits.h> +#include <linux/minmax.h> +#include <linux/bug.h> + +#define SKIPLIST_POISON ((void *)1) + +#define DECLARE_SKIPLIST_TYPE (name, levels) \ +struct name##_node { \ + struct name##_node *next[levels]; \ +}; \ +struct name##_list { \ + struct name##_node head; \ + unsigned int max_level; \ + unsigned int count; \ +}; + +#define DECLARE_SKIPLIST_IMPL (name, cmp_fn, seed_fn) \ +static inline void \ +name##_list_init(struct name##_list *list) \ +{ \ + memset(list, 0, sizeof(*list)); \ +} \ +static inline void \ +name##_node_init(struct name##_node *node) \ +{ \ + node->next[0] = SKIPLIST_POISON; \ +} \ +static inline struct name##_node * \ +name##_node_next(struct name##_node *node) \ +{ \ + return node->next[0]; \ +} \ +static inline bool \ +name##_is_queued(struct name##_node *node) \ +{ \ + return node->next[0] != SKIPLIST_POISON; \ +} \ +static inline int \ +__skiplist_##name##_cmp_impl(void *head, void *n1, void *n2) \ +{ \ + return cmp_fn(head, n1, n2); \ +} \ +static inline void \ +__##name##_delete(struct name##_list *list) \ +{ \ + list->count--; \ + while (list->max_level && \ + !list->head.next[list->max_level]) \ + list->max_level--; \ +} \ +static inline struct name##_node * \ +name##_dequeue(struct name##_list *list) \ +{ \ + struct name##_node *ret; \ + unsigned int max_level = ARRAY_SIZE(list->head.next) - 1; \ + ret = (void *)__skiplist_dequeue((void **)&list->head, \ + max_level); \ + if (!ret) \ + return NULL; \ + __##name##_delete(list); \ + return ret; \ +} \ +static inline struct name##_node * \ +name##_peek(struct name##_list *list) \ +{ \ + return list->head.next[0]; \ +} \ +static inline void \ +name##_insert(struct name##_list *list, struct name##_node *node) \ +{ \ + int level = __skiplist_level(ARRAY_SIZE(list->head.next) - 1, \ + list->count, seed_fn(list)); \ + level = min_t(int, level, list->max_level + 1); \ + __skiplist_insert((void *)&list->head, (void *)node, level, \ + __skiplist_##name##_cmp_impl); \ + if (level > list->max_level) \ + list->max_level = level; \ + list->count++; \ +} \ +static inline void \ +name##_delete(struct name##_list *list, struct name##_node *node) \ +{ \ + if (node->next[0] == SKIPLIST_POISON) \ + return; \ + __skiplist_delete((void *)&list->head, (void *)node, \ + ARRAY_SIZE(list->head.next) - 1, \ + __skiplist_##name##_cmp_impl); \ + __##name##_delete(list); \ +} + + +typedef int (*__skiplist_cmp )(void *head,void *n1,void *n2); + +static inline void * +__skiplist_dequeue (void **list,int max_level) +{ +void **node = list[0 ]; +unsigned int i; + +if (!node) +return NULL ; + + list[0 ] = node[0 ]; +for (i =1 ; i <= max_level; i++) { +if (list[i] != node) +break ; + + list[i] = node[i]; + } + node[0 ] =SKIPLIST_POISON ; + +return node; +} + +static inline void +__skiplist_insert (void **list,void **node,int level,__skiplist_cmp cmp) +{ +void **head = list; + +if (WARN (node[0 ] !=SKIPLIST_POISON ,"Insert on already inserted or uninitialized node" )) +return ; +for (; level >=0 ; level--) { +while (list[level] &&cmp (head, list[level], node) <0 ) + list = list[level]; + + node[level] = list[level]; + list[level] = node; + } +} + + +static inline void +__skiplist_delete (void **list,void **node,int max_level,__skiplist_cmp cmp) +{ +void *head = list; +int i; + +for (i = max_level; i >=0 ; i--) { +while (list[i] &&cmp (head, list[i], node) <0 ) + list = list[i]; + +if (list[i] != node) +continue ; + + list[i] = node[i]; + } + node[0 ] =SKIPLIST_POISON ; +} + +static inline unsigned int +__skiplist_level (unsigned int max_level,unsigned int count,unsigned int seed) +{ +unsigned int level =0 ; + +if (max_level >=16 && !(seed &GENMASK (15 ,0 ))) { + level +=16 ; + seed >>=16 ; + } + +if (max_level >=8 && !(seed &GENMASK (7 ,0 ))) { + level +=8 ; + seed >>=8 ; + } + +if (max_level >=4 && !(seed &GENMASK (3 ,0 ))) { + level +=4 ; + seed >>=4 ; + } + +if (!(seed &GENMASK (1 ,0 ))) { + level +=2 ; + seed >>=2 ; + } + +if (!(seed &BIT (0 ))) + level++; + +return min (level, max_level); +} + +#endif
net/mac80211/cfg.c +0 -5
@@ -1580,7 +1580,6 @@ static void sta_apply_airtime_params(struct ieee80211_local *local,for (ac =0 ; ac <IEEE80211_NUM_ACS ; ac++) {struct airtime_sched_info *air_sched = &local->airtime[ac];struct airtime_info *air_info = &sta->airtime[ac]; -struct txq_info *txqi;u8 tid;spin_lock_bh (&air_sched->lock);
@@ -1592,10 +1591,6 @@ static void sta_apply_airtime_params(struct ieee80211_local *local,airtime_weight_set (air_info, params->airtime_weight); - txqi =to_txq_info (sta->sta.txq[tid]); -if (RB_EMPTY_NODE (&txqi->schedule_order)) -continue ; -ieee80211_update_airtime_weight (local, air_sched,0 , true); }
net/mac80211/ieee80211_i.h +27 -6
@@ -25,7 +25,8 @@#include <linux/leds.h> #include <linux/idr.h> #include <linux/rhashtable.h> -#include <linux/rbtree.h> +#include <linux/prandom.h> +#include <linux/skiplist.h> #include <net/ieee80211_radiotap.h> #include <net/cfg80211.h> #include <net/mac80211.h>
@@ -855,6 +856,7 @@ enum txq_info_flags {IEEE80211_TXQ_AMPDU ,IEEE80211_TXQ_NO_AMSDU ,IEEE80211_TXQ_STOP_NETIF_TX , + IEEE80211_TXQ_FORCE_ACTIVE, };/**
@@ -871,7 +873,6 @@ struct txq_info {struct fq_tin tin;struct codel_vars def_cvars;struct codel_stats cstats; -struct rb_node schedule_order;struct sk_buff_head frags;unsigned long flags;
@@ -1191,8 +1192,7 @@ enum mac80211_scan_state {* * @lock: spinlock that protects all the fields in this struct * @active_txqs: rbtree of currently backlogged queues, sorted by virtual time -* @schedule_pos: the current position maintained while a driver walks the tree -* with ieee80211_next_txq() +* @schedule_pos: last used airtime_info node while a driver walks the tree * @active_list: list of struct airtime_info structs that were active within * the last AIRTIME_ACTIVE_DURATION (100 ms), used to compute * weight_sum
@@ -1213,8 +1213,8 @@ enum mac80211_scan_state {*/ struct airtime_sched_info {spinlock_t lock; -struct rb_root_cached active_txqs; -struct rb_node *schedule_pos; +struct airtime_sched_list active_txqs; +struct airtime_sched_node *schedule_pos;struct list_head active_list;u64 last_weight_update;u64 last_schedule_activity;
@@ -1674,6 +1674,26 @@ static inline struct airtime_info *to_airtime_info(struct ieee80211_txq *txq)return &sdata->airtime[txq->ac]; } +static inline int +airtime_sched_cmp (struct airtime_sched_list *list, +struct airtime_sched_node *n1,struct airtime_sched_node *n2) +{ +struct airtime_info *a1, *a2; + + a1 = container_of(n1, struct airtime_info, schedule_order); + a2 = container_of(n2, struct airtime_info, schedule_order); + +return a1->v_t_cur - a2->v_t_cur; +} + +static inline unsigned int +airtime_sched_seed (struct airtime_sched_list *list) +{ +return prandom_u32 (); +} + +DECLARE_SKIPLIST_IMPL (airtime_sched, airtime_sched_cmp, airtime_sched_seed); +/* To avoid divisions in the fast path, we keep pre-computed reciprocals for * airtime weight calculations. There are two different weights to keep track * of: The per-station weight and the sum of weights per phy.
@@ -1761,6 +1781,7 @@ static inline void init_airtime_info(struct airtime_info *air_info, air_info->aql_limit_high = air_sched->aql_txq_limit_high;airtime_weight_set (air_info,IEEE80211_DEFAULT_AIRTIME_WEIGHT );INIT_LIST_HEAD (&air_info->list); +airtime_sched_node_init (&air_info->schedule_order); }static inline int ieee80211_bssid_match (const u8 *raddr,const u8 *addr)
net/mac80211/main.c +1 -1
@@ -709,7 +709,7 @@ struct ieee80211_hw *ieee80211_alloc_hw_nm(size_t priv_data_len,for (i =0 ; i <IEEE80211_NUM_ACS ; i++) {struct airtime_sched_info *air_sched = &local->airtime[i]; - air_sched->active_txqs =RB_ROOT_CACHED ; +airtime_sched_list_init (&air_sched->active_txqs);INIT_LIST_HEAD (&air_sched->active_list);spin_lock_init (&air_sched->lock); air_sched->aql_txq_limit_low =IEEE80211_DEFAULT_AQL_TXQ_LIMIT_L ;
net/mac80211/sta_info.c +1 -2
@@ -1914,8 +1914,7 @@ void ieee80211_register_airtime(struct ieee80211_txq *txq, air_sched = &local->airtime[txq->ac]; air_info =to_airtime_info (txq); -if (local->airtime_flags &AIRTIME_USE_TX ) - airtime += tx_airtime; + airtime += tx_airtime;if (local->airtime_flags &AIRTIME_USE_RX ) airtime += rx_airtime;
net/mac80211/sta_info.h +4 -0
@@ -135,8 +135,11 @@ enum ieee80211_agg_stop_reason {#define AIRTIME_USE_TX BIT(0)#define AIRTIME_USE_RX BIT(1) +DECLARE_SKIPLIST_TYPE (airtime_sched,5 );struct airtime_info { +struct airtime_sched_node schedule_order; +struct ieee80211_txq *txq[3 ];u64 rx_airtime;u64 tx_airtime;u64 v_t;
@@ -147,6 +150,7 @@ struct airtime_info {u32 aql_limit_high;u32 weight_reciprocal;u16 weight; +u8 txq_idx; }; void ieee80211_sta_update_pending_airtime(struct ieee80211_local *local,
net/mac80211/tx.c +118 -126
403 lines not on this page · raw message
Signature · 1 line
2.36.1
kernel test robot
build botRe: [RFC/RFT 2/2] mac80211: rework the airtime fairness implementation
[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]
Hi Felix,
[FYI, it's a private test report for your RFC patch.]
[auto build test ERROR on wireless-next/main]
[also build test ERROR on wireless/main linus/master v5.18 next-20220527] [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/intel-lab-lkp/linux/commits/Felix-Fietkau/mac80211-fix-overflow-issues-in-airtime-fairness-code/20220529-030959 base: https://git.kernel.org/pub/scm/linux/kernel/git/wireless/wireless-next.git main config: x86_64-randconfig-a003 (https://download.01.org/0day-ci/archive/20220529/[email protected]/config) compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project 0fbe3f3f486e01448121f7931a4ca29fac1504ab)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# https://github.com/intel-lab-lkp/linux/commit/cf2b510572e85ecfada3512dbdf30efd02d882fa
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Felix-Fietkau/mac80211-fix-overflow-issues-in-airtime-fairness-code/20220529-030959 git checkout cf2b510572e85ecfada3512dbdf30efd02d882fa
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash net/
If you fix the issue, kindly add following tag where applicable
All errors (new ones prefixed by >>):
In file included from net/mac80211/main.c:28:
>> net/mac80211/ieee80211_i.h:1686:13: error: no member named 'v_t_cur' in 'struct airtime_info'
return a1->v_t_cur - a2->v_t_cur;
~~ ^
net/mac80211/ieee80211_i.h:1686:27: error: no member named 'v_t_cur' in 'struct airtime_info'
return a1->v_t_cur - a2->v_t_cur;
~~ ^
2 errors generated.
--
In file included from net/mac80211/sta_info.c:23:
>> net/mac80211/ieee80211_i.h:1686:13: error: no member named 'v_t_cur' in 'struct airtime_info'
return a1->v_t_cur - a2->v_t_cur;
~~ ^
net/mac80211/ieee80211_i.h:1686:27: error: no member named 'v_t_cur' in 'struct airtime_info'
return a1->v_t_cur - a2->v_t_cur;
~~ ^
net/mac80211/sta_info.c:1909:6: warning: variable 'weight_sum' set but not used [-Wunused-but-set-variable]
u64 weight_sum, weight_sum_reciprocal;
^
1 warning and 2 errors generated.
--
In file included from net/mac80211/tx.c:32:
>> net/mac80211/ieee80211_i.h:1686:13: error: no member named 'v_t_cur' in 'struct airtime_info'
return a1->v_t_cur - a2->v_t_cur;
~~ ^
net/mac80211/ieee80211_i.h:1686:27: error: no member named 'v_t_cur' in 'struct airtime_info'
return a1->v_t_cur - a2->v_t_cur;
~~ ^
>> net/mac80211/tx.c:3888:16: error: no member named 'v_t_cur' in 'struct airtime_info'
if (air_info->v_t_cur > air_sched->v_t) {
~~~~~~~~ ^
net/mac80211/tx.c:3890:45: error: no member named 'v_t_cur' in 'struct airtime_info'
airtime_catchup_v_t(air_sched, air_info->v_t_cur, now);
~~~~~~~~ ^
net/mac80211/tx.c:3915:12: error: no member named 'v_t_cur' in 'struct airtime_info'
air_info->v_t_cur = air_info->v_t + aql_time;
~~~~~~~~ ^ 5 errors generated.
--
In file included from net/mac80211/rc80211_minstrel_ht.c:14:
In file included from net/mac80211/rate.h:15:
>> net/mac80211/ieee80211_i.h:1686:13: error: no member named 'v_t_cur' in 'struct airtime_info'
return a1->v_t_cur - a2->v_t_cur;
~~ ^
net/mac80211/ieee80211_i.h:1686:27: error: no member named 'v_t_cur' in 'struct airtime_info'
return a1->v_t_cur - a2->v_t_cur;
~~ ^
net/mac80211/rc80211_minstrel_ht.c:1708:6: warning: variable 'n_supported' set but not used [-Wunused-but-set-variable]
int n_supported = 0;
^ 1 warning and 2 errors generated.
--
In file included from net/mac80211/trace.c:8:
In file included from net/mac80211/driver-ops.h:12:
>> net/mac80211/ieee80211_i.h:1686:13: error: no member named 'v_t_cur' in 'struct airtime_info'
return a1->v_t_cur - a2->v_t_cur;
~~ ^
net/mac80211/ieee80211_i.h:1686:27: error: no member named 'v_t_cur' in 'struct airtime_info'
return a1->v_t_cur - a2->v_t_cur;
~~ ^
In file included from net/mac80211/trace.c:11:
In file included from net/mac80211/trace.h:2908:
include/trace/define_trace.h:95:10: fatal error: './trace.h' file not found
#include TRACE_INCLUDE(TRACE_INCLUDE_FILE)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/define_trace.h:90:32: note: expanded from macro 'TRACE_INCLUDE'
# define TRACE_INCLUDE(system) __TRACE_INCLUDE(system)
^~~~~~~~~~~~~~~~~~~~~~~
include/trace/define_trace.h:87:34: note: expanded from macro '__TRACE_INCLUDE'
# define __TRACE_INCLUDE(system) __stringify(TRACE_INCLUDE_PATH/system.h)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/stringify.h:10:27: note: expanded from macro '__stringify'
#define __stringify(x...) __stringify_1(x)
^~~~~~~~~~~~~~~~
include/linux/stringify.h:9:29: note: expanded from macro '__stringify_1'
#define __stringify_1(x...) #x
^~
<scratch space>:123:1: note: expanded from here
"./trace.h"
^~~~~~~~~~~
3 errors generated.vim +1686 net/mac80211/ieee80211_i.h
1676
1677 static inline int
1678 airtime_sched_cmp(struct airtime_sched_list *list,
1679 struct airtime_sched_node *n1, struct airtime_sched_node *n2)
1680 {
1681 struct airtime_info *a1, *a2;
1682
1683 a1 = container_of(n1, struct airtime_info, schedule_order);
1684 a2 = container_of(n2, struct airtime_info, schedule_order);
1685
> 1686 return a1->v_t_cur - a2->v_t_cur;
1687 }
1688
Signature · 2 lines
0-DAY CI Kernel Test Service https://01.org/lkp