[net-next:master 40/65] net/bridge/br_input.c:135:8: error: too many arguments to function 'br_multicast_is_router'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master
head: ea89c862f01e02ec459932c7c3113fa37aedd09a
commit: 1a3065a26807b4cdd65d3b696ddb18385610f7da [40/65] net: bridge: mcast: prepare is-router function for mcast router split
config: um-randconfig-s032-20210514 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git/commit...
git remote add net-next https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git
git fetch --no-tags net-next master
git checkout 1a3065a26807b4cdd65d3b696ddb18385610f7da
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' W=1 ARCH=um
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
net/bridge/br_input.c: In function 'br_handle_frame_finish':
>> net/bridge/br_input.c:135:8: error: too many arguments to function 'br_multicast_is_router'
135 | br_multicast_is_router(br, skb)) {
| ^~~~~~~~~~~~~~~~~~~~~~
In file included from net/bridge/br_input.c:23:
net/bridge/br_private.h:1059:20: note: declared here
1059 | static inline bool br_multicast_is_router(struct net_bridge *br)
| ^~~~~~~~~~~~~~~~~~~~~~
Kconfig warnings: (for reference only)
WARNING: unmet direct dependencies detected for LOCKDEP
Depends on DEBUG_KERNEL && LOCK_DEBUGGING_SUPPORT && (FRAME_POINTER || MIPS || PPC || S390 || MICROBLAZE || ARM || ARC || X86)
Selected by
- LOCK_STAT && DEBUG_KERNEL && LOCK_DEBUGGING_SUPPORT
- DEBUG_LOCK_ALLOC && DEBUG_KERNEL && LOCK_DEBUGGING_SUPPORT
vim +/br_multicast_is_router +135 net/bridge/br_input.c
65
66 /* note: already called with rcu_read_lock */
67 int br_handle_frame_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
68 {
69 struct net_bridge_port *p = br_port_get_rcu(skb->dev);
70 enum br_pkt_type pkt_type = BR_PKT_UNICAST;
71 struct net_bridge_fdb_entry *dst = NULL;
72 struct net_bridge_mdb_entry *mdst;
73 bool local_rcv, mcast_hit = false;
74 struct net_bridge *br;
75 u16 vid = 0;
76 u8 state;
77
78 if (!p || p->state == BR_STATE_DISABLED)
79 goto drop;
80
81 state = p->state;
82 if (!br_allowed_ingress(p->br, nbp_vlan_group_rcu(p), skb, &vid,
83 &state))
84 goto out;
85
86 nbp_switchdev_frame_mark(p, skb);
87
88 /* insert into forwarding database after filtering to avoid spoofing */
89 br = p->br;
90 if (p->flags & BR_LEARNING)
91 br_fdb_update(br, p, eth_hdr(skb)->h_source, vid, 0);
92
93 local_rcv = !!(br->dev->flags & IFF_PROMISC);
94 if (is_multicast_ether_addr(eth_hdr(skb)->h_dest)) {
95 /* by definition the broadcast is also a multicast address */
96 if (is_broadcast_ether_addr(eth_hdr(skb)->h_dest)) {
97 pkt_type = BR_PKT_BROADCAST;
98 local_rcv = true;
99 } else {
100 pkt_type = BR_PKT_MULTICAST;
101 if (br_multicast_rcv(br, p, skb, vid))
102 goto drop;
103 }
104 }
105
106 if (state == BR_STATE_LEARNING)
107 goto drop;
108
109 BR_INPUT_SKB_CB(skb)->brdev = br->dev;
110 BR_INPUT_SKB_CB(skb)->src_port_isolated = !!(p->flags & BR_ISOLATED);
111
112 if (IS_ENABLED(CONFIG_INET) &&
113 (skb->protocol == htons(ETH_P_ARP) ||
114 skb->protocol == htons(ETH_P_RARP))) {
115 br_do_proxy_suppress_arp(skb, br, vid, p);
116 } else if (IS_ENABLED(CONFIG_IPV6) &&
117 skb->protocol == htons(ETH_P_IPV6) &&
118 br_opt_get(br, BROPT_NEIGH_SUPPRESS_ENABLED) &&
119 pskb_may_pull(skb, sizeof(struct ipv6hdr) +
120 sizeof(struct nd_msg)) &&
121 ipv6_hdr(skb)->nexthdr == IPPROTO_ICMPV6) {
122 struct nd_msg *msg, _msg;
123
124 msg = br_is_nd_neigh_msg(skb, &_msg);
125 if (msg)
126 br_do_suppress_nd(skb, br, vid, p, msg);
127 }
128
129 switch (pkt_type) {
130 case BR_PKT_MULTICAST:
131 mdst = br_mdb_get(br, skb, vid);
132 if ((mdst || BR_INPUT_SKB_CB_MROUTERS_ONLY(skb)) &&
133 br_multicast_querier_exists(br, eth_hdr(skb), mdst)) {
134 if ((mdst && mdst->host_joined) ||
> 135 br_multicast_is_router(br, skb)) {
136 local_rcv = true;
137 br->dev->stats.multicast++;
138 }
139 mcast_hit = true;
140 } else {
141 local_rcv = true;
142 br->dev->stats.multicast++;
143 }
144 break;
145 case BR_PKT_UNICAST:
146 dst = br_fdb_find_rcu(br, eth_hdr(skb)->h_dest, vid);
147 break;
148 default:
149 break;
150 }
151
152 if (dst) {
153 unsigned long now = jiffies;
154
155 if (test_bit(BR_FDB_LOCAL, &dst->flags))
156 return br_pass_frame_up(skb);
157
158 if (now != dst->used)
159 dst->used = now;
160 br_forward(dst->dst, skb, local_rcv, false);
161 } else {
162 if (!mcast_hit)
163 br_flood(br, skb, pkt_type, local_rcv, false);
164 else
165 br_multicast_flood(mdst, skb, local_rcv, false);
166 }
167
168 if (local_rcv)
169 return br_pass_frame_up(skb);
170
171 out:
172 return 0;
173 drop:
174 kfree_skb(skb);
175 goto out;
176 }
177 EXPORT_SYMBOL_GPL(br_handle_frame_finish);
178
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 4 months
[PATCH 0/2] KVM: arm64: Mark a couple of variables static
by Quentin Perret
The kernel test bot is complaining (and rightfully so) about variables
introduced by the host stage-2 series that should be static. This series
fixes all of them.
Thanks!
Quentin Perret (2):
KVM: arm64: Mark pkvm_pgtable_mm_ops static
KVM: arm64: Mark the host stage-2 memory pools static
arch/arm64/kvm/hyp/nvhe/mem_protect.c | 4 ++--
arch/arm64/kvm/hyp/nvhe/setup.c | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
--
2.31.1.751.gd2f1c929bd-goog
1 year, 4 months
[arm-platforms:irq/domain_cleanup 14/20] include/linux/irqdesc.h:56:25: error: field has incomplete type 'struct irq_common_data'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms.git irq/domain_cleanup
head: 76a98e310bbd7bada3f24d6fda08858460fd6cd4
commit: 5dd760fc3140b85b7d8cf1ad003238c5a223fc76 [14/20] irqdomain: Introduce irq_resolve_mapping()
config: mips-randconfig-r004-20210514 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 425781bce01f2f1d5f553d3b2bf9ebbd6e15068c)
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
# install mips cross compiling tool for clang build
# apt-get install binutils-mips-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms.git/com...
git remote add arm-platforms https://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms.git
git fetch --no-tags arm-platforms irq/domain_cleanup
git checkout 5dd760fc3140b85b7d8cf1ad003238c5a223fc76
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=mips
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
>> include/linux/irqdesc.h:56:25: error: field has incomplete type 'struct irq_common_data'
struct irq_common_data irq_common_data;
^
include/linux/irqdesc.h:56:9: note: forward declaration of 'struct irq_common_data'
struct irq_common_data irq_common_data;
^
>> include/linux/irqdesc.h:57:19: error: field has incomplete type 'struct irq_data'
struct irq_data irq_data;
^
include/linux/irqhandler.h:11:8: note: forward declaration of 'struct irq_data'
struct irq_data;
^
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
>> include/linux/irqdesc.h:113:33: error: use of undeclared identifier 'NR_IRQS'
extern struct irq_desc irq_desc[NR_IRQS];
^
>> include/linux/irqdesc.h:124:26: error: incomplete definition of type 'struct irq_data'
return container_of(data->common, struct irq_desc, irq_common_data);
~~~~^
include/linux/kernel.h:703:26: note: expanded from macro 'container_of'
void *__mptr = (void *)(ptr); \
^~~
include/linux/irqhandler.h:11:8: note: forward declaration of 'struct irq_data'
struct irq_data;
^
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
>> include/linux/irqdesc.h:124:26: error: incomplete definition of type 'struct irq_data'
return container_of(data->common, struct irq_desc, irq_common_data);
~~~~^
include/linux/kernel.h:704:34: note: expanded from macro 'container_of'
BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \
^~~
include/linux/compiler_types.h:264:63: note: expanded from macro '__same_type'
#define __same_type(a, b) __builtin_types_compatible_p(typeof(a), typeof(b))
^
include/linux/build_bug.h:39:58: note: expanded from macro 'BUILD_BUG_ON_MSG'
#define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
^~~~
include/linux/compiler_types.h:328:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:316:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:308:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
include/linux/irqhandler.h:11:8: note: forward declaration of 'struct irq_data'
struct irq_data;
^
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
>> include/linux/irqdesc.h:124:26: error: incomplete definition of type 'struct irq_data'
return container_of(data->common, struct irq_desc, irq_common_data);
~~~~^
include/linux/kernel.h:705:20: note: expanded from macro 'container_of'
!__same_type(*(ptr), void), \
^~~
include/linux/compiler_types.h:264:63: note: expanded from macro '__same_type'
#define __same_type(a, b) __builtin_types_compatible_p(typeof(a), typeof(b))
^
include/linux/build_bug.h:39:58: note: expanded from macro 'BUILD_BUG_ON_MSG'
#define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
^~~~
include/linux/compiler_types.h:328:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:316:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:308:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
include/linux/irqhandler.h:11:8: note: forward declaration of 'struct irq_data'
struct irq_data;
^
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
include/linux/irqdesc.h:229:6: error: incomplete definition of type 'struct irq_data'
data->chip = chip;
~~~~^
include/linux/irqhandler.h:11:8: note: forward declaration of 'struct irq_data'
struct irq_data;
^
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
>> include/linux/irqdesc.h:236:35: error: use of undeclared identifier 'IRQ_NO_BALANCING_MASK'
return irq_check_status_bit(irq, IRQ_NO_BALANCING_MASK);
^
>> include/linux/irqdesc.h:241:35: error: use of undeclared identifier 'IRQ_PER_CPU'
return irq_check_status_bit(irq, IRQ_PER_CPU);
^
>> include/linux/irqdesc.h:246:35: error: use of undeclared identifier 'IRQ_PER_CPU_DEVID'
return irq_check_status_bit(irq, IRQ_PER_CPU_DEVID);
^
arch/mips/kernel/asm-offsets.c:26:6: warning: no previous prototype for function 'output_ptreg_defines' [-Wmissing-prototypes]
void output_ptreg_defines(void)
^
arch/mips/kernel/asm-offsets.c:26:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_ptreg_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:78:6: warning: no previous prototype for function 'output_task_defines' [-Wmissing-prototypes]
void output_task_defines(void)
^
arch/mips/kernel/asm-offsets.c:78:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_task_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:93:6: warning: no previous prototype for function 'output_thread_info_defines' [-Wmissing-prototypes]
void output_thread_info_defines(void)
^
arch/mips/kernel/asm-offsets.c:93:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_thread_info_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:109:6: warning: no previous prototype for function 'output_thread_defines' [-Wmissing-prototypes]
void output_thread_defines(void)
^
arch/mips/kernel/asm-offsets.c:109:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_thread_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:180:6: warning: no previous prototype for function 'output_mm_defines' [-Wmissing-prototypes]
void output_mm_defines(void)
^
arch/mips/kernel/asm-offsets.c:180:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_mm_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:219:6: warning: no previous prototype for function 'output_sc_defines' [-Wmissing-prototypes]
void output_sc_defines(void)
^
arch/mips/kernel/asm-offsets.c:219:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_sc_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:254:6: warning: no previous prototype for function 'output_signal_defined' [-Wmissing-prototypes]
void output_signal_defined(void)
^
arch/mips/kernel/asm-offsets.c:254:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_signal_defined(void)
^
static
arch/mips/kernel/asm-offsets.c:391:6: warning: no previous prototype for function 'output_cps_defines' [-Wmissing-prototypes]
void output_cps_defines(void)
^
arch/mips/kernel/asm-offsets.c:391:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_cps_defines(void)
^
static
8 warnings and 10 errors generated.
--
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
>> include/linux/irqdesc.h:56:25: error: field has incomplete type 'struct irq_common_data'
struct irq_common_data irq_common_data;
^
include/linux/irqdesc.h:56:9: note: forward declaration of 'struct irq_common_data'
struct irq_common_data irq_common_data;
^
>> include/linux/irqdesc.h:57:19: error: field has incomplete type 'struct irq_data'
struct irq_data irq_data;
^
include/linux/irqhandler.h:11:8: note: forward declaration of 'struct irq_data'
struct irq_data;
^
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
>> include/linux/irqdesc.h:113:33: error: use of undeclared identifier 'NR_IRQS'
extern struct irq_desc irq_desc[NR_IRQS];
^
>> include/linux/irqdesc.h:124:26: error: incomplete definition of type 'struct irq_data'
return container_of(data->common, struct irq_desc, irq_common_data);
~~~~^
include/linux/kernel.h:703:26: note: expanded from macro 'container_of'
void *__mptr = (void *)(ptr); \
^~~
include/linux/irqhandler.h:11:8: note: forward declaration of 'struct irq_data'
struct irq_data;
^
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
>> include/linux/irqdesc.h:124:26: error: incomplete definition of type 'struct irq_data'
return container_of(data->common, struct irq_desc, irq_common_data);
~~~~^
include/linux/kernel.h:704:34: note: expanded from macro 'container_of'
BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \
^~~
include/linux/compiler_types.h:264:63: note: expanded from macro '__same_type'
#define __same_type(a, b) __builtin_types_compatible_p(typeof(a), typeof(b))
^
include/linux/build_bug.h:39:58: note: expanded from macro 'BUILD_BUG_ON_MSG'
#define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
^~~~
include/linux/compiler_types.h:328:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:316:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:308:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
include/linux/irqhandler.h:11:8: note: forward declaration of 'struct irq_data'
struct irq_data;
^
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
>> include/linux/irqdesc.h:124:26: error: incomplete definition of type 'struct irq_data'
return container_of(data->common, struct irq_desc, irq_common_data);
~~~~^
include/linux/kernel.h:705:20: note: expanded from macro 'container_of'
!__same_type(*(ptr), void), \
^~~
include/linux/compiler_types.h:264:63: note: expanded from macro '__same_type'
#define __same_type(a, b) __builtin_types_compatible_p(typeof(a), typeof(b))
^
include/linux/build_bug.h:39:58: note: expanded from macro 'BUILD_BUG_ON_MSG'
#define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
^~~~
include/linux/compiler_types.h:328:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:316:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:308:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
include/linux/irqhandler.h:11:8: note: forward declaration of 'struct irq_data'
struct irq_data;
^
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
include/linux/irqdesc.h:229:6: error: incomplete definition of type 'struct irq_data'
data->chip = chip;
~~~~^
include/linux/irqhandler.h:11:8: note: forward declaration of 'struct irq_data'
struct irq_data;
^
In file included from arch/mips/kernel/asm-offsets.c:17:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:13:
In file included from include/linux/cgroup.h:26:
In file included from include/linux/kernel_stat.h:9:
In file included from include/linux/interrupt.h:11:
In file included from include/linux/hardirq.h:11:
In file included from arch/mips/include/asm/hardirq.h:16:
In file included from include/asm-generic/hardirq.h:17:
In file included from include/linux/irq.h:23:
In file included from arch/mips/include/asm/irq.h:14:
In file included from include/linux/irqdomain.h:35:
>> include/linux/irqdesc.h:236:35: error: use of undeclared identifier 'IRQ_NO_BALANCING_MASK'
return irq_check_status_bit(irq, IRQ_NO_BALANCING_MASK);
^
>> include/linux/irqdesc.h:241:35: error: use of undeclared identifier 'IRQ_PER_CPU'
return irq_check_status_bit(irq, IRQ_PER_CPU);
^
>> include/linux/irqdesc.h:246:35: error: use of undeclared identifier 'IRQ_PER_CPU_DEVID'
return irq_check_status_bit(irq, IRQ_PER_CPU_DEVID);
^
arch/mips/kernel/asm-offsets.c:26:6: warning: no previous prototype for function 'output_ptreg_defines' [-Wmissing-prototypes]
void output_ptreg_defines(void)
^
arch/mips/kernel/asm-offsets.c:26:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_ptreg_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:78:6: warning: no previous prototype for function 'output_task_defines' [-Wmissing-prototypes]
void output_task_defines(void)
^
arch/mips/kernel/asm-offsets.c:78:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_task_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:93:6: warning: no previous prototype for function 'output_thread_info_defines' [-Wmissing-prototypes]
void output_thread_info_defines(void)
^
arch/mips/kernel/asm-offsets.c:93:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_thread_info_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:109:6: warning: no previous prototype for function 'output_thread_defines' [-Wmissing-prototypes]
void output_thread_defines(void)
^
arch/mips/kernel/asm-offsets.c:109:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_thread_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:180:6: warning: no previous prototype for function 'output_mm_defines' [-Wmissing-prototypes]
void output_mm_defines(void)
^
arch/mips/kernel/asm-offsets.c:180:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_mm_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:219:6: warning: no previous prototype for function 'output_sc_defines' [-Wmissing-prototypes]
void output_sc_defines(void)
^
arch/mips/kernel/asm-offsets.c:219:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_sc_defines(void)
^
static
arch/mips/kernel/asm-offsets.c:254:6: warning: no previous prototype for function 'output_signal_defined' [-Wmissing-prototypes]
void output_signal_defined(void)
^
arch/mips/kernel/asm-offsets.c:254:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_signal_defined(void)
^
static
arch/mips/kernel/asm-offsets.c:391:6: warning: no previous prototype for function 'output_cps_defines' [-Wmissing-prototypes]
void output_cps_defines(void)
^
arch/mips/kernel/asm-offsets.c:391:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void output_cps_defines(void)
^
static
8 warnings and 10 errors generated.
make[2]: *** [scripts/Makefile.build:117: arch/mips/kernel/asm-offsets.s] Error 1
make[2]: Target '__build' not remade because of errors.
make[1]: *** [Makefile:1227: prepare0] Error 2
make[1]: Target 'modules_prepare' not remade because of errors.
make: *** [Makefile:215: __sub-make] Error 2
make: Target 'modules_prepare' not remade because of errors.
..
vim +56 include/linux/irqdesc.h
293a7a0a165c4f Thomas Gleixner 2012-10-16 19
e144710b302525 Thomas Gleixner 2010-10-01 20 /**
e144710b302525 Thomas Gleixner 2010-10-01 21 * struct irq_desc - interrupt descriptor
0d0b4c866bcce6 Jiang Liu 2015-06-01 22 * @irq_common_data: per irq and chip data passed down to chip functions
e144710b302525 Thomas Gleixner 2010-10-01 23 * @kstat_irqs: irq stats per cpu
770767787c2304 Geert Uytterhoeven 2011-04-10 24 * @handle_irq: highlevel irq-events handler
e144710b302525 Thomas Gleixner 2010-10-01 25 * @action: the irq action chain
80ebc420ec59a7 Yunfeng Ye 2019-09-18 26 * @status_use_accessors: status information
dbec07bac614a6 Thomas Gleixner 2011-02-07 27 * @core_internal_state__do_not_mess_with_it: core internal status information
e144710b302525 Thomas Gleixner 2010-10-01 28 * @depth: disable-depth, for nested irq_disable() calls
0911f124bf5535 Geert Uytterhoeven 2011-04-10 29 * @wake_depth: enable depth, for multiple irq_set_irq_wake() callers
030fc443aef663 Waiman Long 2019-02-12 30 * @tot_count: stats field for non-percpu irqs
e144710b302525 Thomas Gleixner 2010-10-01 31 * @irq_count: stats field to detect stalled irqs
e144710b302525 Thomas Gleixner 2010-10-01 32 * @last_unhandled: aging timer for unhandled count
e144710b302525 Thomas Gleixner 2010-10-01 33 * @irqs_unhandled: stats field for spurious unhandled interrupts
1e77d0a1ed7417 Thomas Gleixner 2013-03-07 34 * @threads_handled: stats field for deferred spurious detection of threaded handlers
a359f757965aaf Ingo Molnar 2021-03-22 35 * @threads_handled_last: comparator field for deferred spurious detection of threaded handlers
e144710b302525 Thomas Gleixner 2010-10-01 36 * @lock: locking for SMP
770767787c2304 Geert Uytterhoeven 2011-04-10 37 * @affinity_hint: hint to user space for preferred irq affinity
cd7eab44e9946c Ben Hutchings 2011-01-19 38 * @affinity_notify: context for notification of affinity changes
e144710b302525 Thomas Gleixner 2010-10-01 39 * @pending_mask: pending rebalanced interrupts
b5faba21a6805c Thomas Gleixner 2011-02-23 40 * @threads_oneshot: bitfield to handle shared oneshot threads
e144710b302525 Thomas Gleixner 2010-10-01 41 * @threads_active: number of irqaction threads currently running
e144710b302525 Thomas Gleixner 2010-10-01 42 * @wait_for_threads: wait queue for sync_irq to wait for threaded handlers
cab303be91dc47 Thomas Gleixner 2014-08-28 43 * @nr_actions: number of installed actions on this descriptor
cab303be91dc47 Thomas Gleixner 2014-08-28 44 * @no_suspend_depth: number of irqactions on a irq descriptor with
cab303be91dc47 Thomas Gleixner 2014-08-28 45 * IRQF_NO_SUSPEND set
cab303be91dc47 Thomas Gleixner 2014-08-28 46 * @force_resume_depth: number of irqactions on a irq descriptor with
cab303be91dc47 Thomas Gleixner 2014-08-28 47 * IRQF_FORCE_RESUME set
425a5072dcd1bd Thomas Gleixner 2015-12-13 48 * @rcu: rcu head for delayed free
ecb3f394c5dba8 Craig Gallek 2016-09-13 49 * @kobj: kobject used to represent this struct in sysfs
9114014cf4e6df Thomas Gleixner 2017-06-29 50 * @request_mutex: mutex to protect request/free before locking desc->lock
e144710b302525 Thomas Gleixner 2010-10-01 51 * @dir: /proc/irq/ procfs entry
087cdfb662ae50 Thomas Gleixner 2017-06-20 52 * @debugfs_file: dentry for the debugfs file
e144710b302525 Thomas Gleixner 2010-10-01 53 * @name: flow handler name for /proc/interrupts output
e144710b302525 Thomas Gleixner 2010-10-01 54 */
e144710b302525 Thomas Gleixner 2010-10-01 55 struct irq_desc {
0d0b4c866bcce6 Jiang Liu 2015-06-01 @56 struct irq_common_data irq_common_data;
e144710b302525 Thomas Gleixner 2010-10-01 @57 struct irq_data irq_data;
6c9ae009b29875 Eric Dumazet 2011-01-13 58 unsigned int __percpu *kstat_irqs;
e144710b302525 Thomas Gleixner 2010-10-01 59 irq_flow_handler_t handle_irq;
e144710b302525 Thomas Gleixner 2010-10-01 60 struct irqaction *action; /* IRQ action list */
a6967caf00ebbb Thomas Gleixner 2011-02-10 61 unsigned int status_use_accessors;
dbec07bac614a6 Thomas Gleixner 2011-02-07 62 unsigned int core_internal_state__do_not_mess_with_it;
e144710b302525 Thomas Gleixner 2010-10-01 63 unsigned int depth; /* nested irq disables */
e144710b302525 Thomas Gleixner 2010-10-01 64 unsigned int wake_depth; /* nested wake enables */
1136b072896990 Thomas Gleixner 2019-02-08 65 unsigned int tot_count;
e144710b302525 Thomas Gleixner 2010-10-01 66 unsigned int irq_count; /* For detecting broken IRQs */
e144710b302525 Thomas Gleixner 2010-10-01 67 unsigned long last_unhandled; /* Aging timer for unhandled count */
e144710b302525 Thomas Gleixner 2010-10-01 68 unsigned int irqs_unhandled;
1e77d0a1ed7417 Thomas Gleixner 2013-03-07 69 atomic_t threads_handled;
1e77d0a1ed7417 Thomas Gleixner 2013-03-07 70 int threads_handled_last;
e144710b302525 Thomas Gleixner 2010-10-01 71 raw_spinlock_t lock;
31d9d9b6d83030 Marc Zyngier 2011-09-23 72 struct cpumask *percpu_enabled;
222df54fd8b764 Marc Zyngier 2016-04-11 73 const struct cpumask *percpu_affinity;
e144710b302525 Thomas Gleixner 2010-10-01 74 #ifdef CONFIG_SMP
e144710b302525 Thomas Gleixner 2010-10-01 75 const struct cpumask *affinity_hint;
cd7eab44e9946c Ben Hutchings 2011-01-19 76 struct irq_affinity_notify *affinity_notify;
e144710b302525 Thomas Gleixner 2010-10-01 77 #ifdef CONFIG_GENERIC_PENDING_IRQ
e144710b302525 Thomas Gleixner 2010-10-01 78 cpumask_var_t pending_mask;
e144710b302525 Thomas Gleixner 2010-10-01 79 #endif
e144710b302525 Thomas Gleixner 2010-10-01 80 #endif
b5faba21a6805c Thomas Gleixner 2011-02-23 81 unsigned long threads_oneshot;
e144710b302525 Thomas Gleixner 2010-10-01 82 atomic_t threads_active;
e144710b302525 Thomas Gleixner 2010-10-01 83 wait_queue_head_t wait_for_threads;
cab303be91dc47 Thomas Gleixner 2014-08-28 84 #ifdef CONFIG_PM_SLEEP
cab303be91dc47 Thomas Gleixner 2014-08-28 85 unsigned int nr_actions;
cab303be91dc47 Thomas Gleixner 2014-08-28 86 unsigned int no_suspend_depth;
17f480342026e5 Rafael J. Wysocki 2015-02-27 87 unsigned int cond_suspend_depth;
cab303be91dc47 Thomas Gleixner 2014-08-28 88 unsigned int force_resume_depth;
cab303be91dc47 Thomas Gleixner 2014-08-28 89 #endif
e144710b302525 Thomas Gleixner 2010-10-01 90 #ifdef CONFIG_PROC_FS
e144710b302525 Thomas Gleixner 2010-10-01 91 struct proc_dir_entry *dir;
425a5072dcd1bd Thomas Gleixner 2015-12-13 92 #endif
087cdfb662ae50 Thomas Gleixner 2017-06-20 93 #ifdef CONFIG_GENERIC_IRQ_DEBUGFS
087cdfb662ae50 Thomas Gleixner 2017-06-20 94 struct dentry *debugfs_file;
07557ccb8c83f3 Thomas Gleixner 2017-09-13 95 const char *dev_name;
087cdfb662ae50 Thomas Gleixner 2017-06-20 96 #endif
425a5072dcd1bd Thomas Gleixner 2015-12-13 97 #ifdef CONFIG_SPARSE_IRQ
425a5072dcd1bd Thomas Gleixner 2015-12-13 98 struct rcu_head rcu;
ecb3f394c5dba8 Craig Gallek 2016-09-13 99 struct kobject kobj;
e144710b302525 Thomas Gleixner 2010-10-01 100 #endif
9114014cf4e6df Thomas Gleixner 2017-06-29 101 struct mutex request_mutex;
293a7a0a165c4f Thomas Gleixner 2012-10-16 102 int parent_irq;
b6873807a7143b Sebastian Andrzej Siewior 2011-07-11 103 struct module *owner;
e144710b302525 Thomas Gleixner 2010-10-01 104 const char *name;
e144710b302525 Thomas Gleixner 2010-10-01 105 } ____cacheline_internodealigned_in_smp;
e144710b302525 Thomas Gleixner 2010-10-01 106
a899418167264c Thomas Gleixner 2015-07-05 107 #ifdef CONFIG_SPARSE_IRQ
a899418167264c Thomas Gleixner 2015-07-05 108 extern void irq_lock_sparse(void);
a899418167264c Thomas Gleixner 2015-07-05 109 extern void irq_unlock_sparse(void);
a899418167264c Thomas Gleixner 2015-07-05 110 #else
a899418167264c Thomas Gleixner 2015-07-05 111 static inline void irq_lock_sparse(void) { }
a899418167264c Thomas Gleixner 2015-07-05 112 static inline void irq_unlock_sparse(void) { }
e144710b302525 Thomas Gleixner 2010-10-01 @113 extern struct irq_desc irq_desc[NR_IRQS];
e144710b302525 Thomas Gleixner 2010-10-01 114 #endif
e144710b302525 Thomas Gleixner 2010-10-01 115
501e2db67fa426 Thomas Gleixner 2020-12-10 116 static inline unsigned int irq_desc_kstat_cpu(struct irq_desc *desc,
501e2db67fa426 Thomas Gleixner 2020-12-10 117 unsigned int cpu)
501e2db67fa426 Thomas Gleixner 2020-12-10 118 {
501e2db67fa426 Thomas Gleixner 2020-12-10 119 return desc->kstat_irqs ? *per_cpu_ptr(desc->kstat_irqs, cpu) : 0;
501e2db67fa426 Thomas Gleixner 2020-12-10 120 }
501e2db67fa426 Thomas Gleixner 2020-12-10 121
7bbf1dd24b17b9 Jiang Liu 2015-06-01 122 static inline struct irq_desc *irq_data_to_desc(struct irq_data *data)
7bbf1dd24b17b9 Jiang Liu 2015-06-01 123 {
755d119a620497 Thomas Gleixner 2015-09-16 @124 return container_of(data->common, struct irq_desc, irq_common_data);
7bbf1dd24b17b9 Jiang Liu 2015-06-01 125 }
7bbf1dd24b17b9 Jiang Liu 2015-06-01 126
304adf8a8fff97 Jiang Liu 2015-06-04 127 static inline unsigned int irq_desc_get_irq(struct irq_desc *desc)
304adf8a8fff97 Jiang Liu 2015-06-04 128 {
304adf8a8fff97 Jiang Liu 2015-06-04 129 return desc->irq_data.irq;
304adf8a8fff97 Jiang Liu 2015-06-04 130 }
304adf8a8fff97 Jiang Liu 2015-06-04 131
d9936bb3952a08 Thomas Gleixner 2011-03-11 132 static inline struct irq_data *irq_desc_get_irq_data(struct irq_desc *desc)
d9936bb3952a08 Thomas Gleixner 2011-03-11 133 {
d9936bb3952a08 Thomas Gleixner 2011-03-11 134 return &desc->irq_data;
d9936bb3952a08 Thomas Gleixner 2011-03-11 135 }
d9936bb3952a08 Thomas Gleixner 2011-03-11 136
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 137 static inline struct irq_chip *irq_desc_get_chip(struct irq_desc *desc)
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 138 {
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 139 return desc->irq_data.chip;
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 140 }
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 141
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 142 static inline void *irq_desc_get_chip_data(struct irq_desc *desc)
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 143 {
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 144 return desc->irq_data.chip_data;
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 145 }
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 146
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 147 static inline void *irq_desc_get_handler_data(struct irq_desc *desc)
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 148 {
af7080e040d223 Jiang Liu 2015-06-01 149 return desc->irq_common_data.handler_data;
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 150 }
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 151
e144710b302525 Thomas Gleixner 2010-10-01 152 /*
e144710b302525 Thomas Gleixner 2010-10-01 153 * Architectures call this to let the generic IRQ layer
6584d84c3e504c Huang Shijie 2015-09-01 154 * handle an interrupt.
e144710b302525 Thomas Gleixner 2010-10-01 155 */
bd0b9ac405e179 Thomas Gleixner 2015-09-14 156 static inline void generic_handle_irq_desc(struct irq_desc *desc)
e144710b302525 Thomas Gleixner 2010-10-01 157 {
bd0b9ac405e179 Thomas Gleixner 2015-09-14 158 desc->handle_irq(desc);
e144710b302525 Thomas Gleixner 2010-10-01 159 }
e144710b302525 Thomas Gleixner 2010-10-01 160
fe12bc2c996d3e Thomas Gleixner 2011-05-18 161 int generic_handle_irq(unsigned int irq);
e144710b302525 Thomas Gleixner 2010-10-01 162
76ba59f8366f2d Marc Zyngier 2014-08-26 163 #ifdef CONFIG_HANDLE_DOMAIN_IRQ
76ba59f8366f2d Marc Zyngier 2014-08-26 164 /*
76ba59f8366f2d Marc Zyngier 2014-08-26 165 * Convert a HW interrupt number to a logical one using a IRQ domain,
76ba59f8366f2d Marc Zyngier 2014-08-26 166 * and handle the result interrupt number. Return -EINVAL if
76ba59f8366f2d Marc Zyngier 2014-08-26 167 * conversion failed. Providing a NULL domain indicates that the
76ba59f8366f2d Marc Zyngier 2014-08-26 168 * conversion has already been done.
76ba59f8366f2d Marc Zyngier 2014-08-26 169 */
76ba59f8366f2d Marc Zyngier 2014-08-26 170 int __handle_domain_irq(struct irq_domain *domain, unsigned int hwirq,
76ba59f8366f2d Marc Zyngier 2014-08-26 171 bool lookup, struct pt_regs *regs);
76ba59f8366f2d Marc Zyngier 2014-08-26 172
76ba59f8366f2d Marc Zyngier 2014-08-26 173 static inline int handle_domain_irq(struct irq_domain *domain,
76ba59f8366f2d Marc Zyngier 2014-08-26 174 unsigned int hwirq, struct pt_regs *regs)
76ba59f8366f2d Marc Zyngier 2014-08-26 175 {
76ba59f8366f2d Marc Zyngier 2014-08-26 176 return __handle_domain_irq(domain, hwirq, true, regs);
76ba59f8366f2d Marc Zyngier 2014-08-26 177 }
6e4933a0066163 Julien Thierry 2019-01-31 178
6e4933a0066163 Julien Thierry 2019-01-31 179 #ifdef CONFIG_IRQ_DOMAIN
6e4933a0066163 Julien Thierry 2019-01-31 180 int handle_domain_nmi(struct irq_domain *domain, unsigned int hwirq,
6e4933a0066163 Julien Thierry 2019-01-31 181 struct pt_regs *regs);
6e4933a0066163 Julien Thierry 2019-01-31 182 #endif
76ba59f8366f2d Marc Zyngier 2014-08-26 183 #endif
76ba59f8366f2d Marc Zyngier 2014-08-26 184
e144710b302525 Thomas Gleixner 2010-10-01 185 /* Test to see if a driver has successfully requested an irq */
f61ae4fb66a4f7 Thomas Gleixner 2015-08-02 186 static inline int irq_desc_has_action(struct irq_desc *desc)
e144710b302525 Thomas Gleixner 2010-10-01 187 {
a313357e704f26 Thomas Gleixner 2020-12-10 188 return desc && desc->action != NULL;
f61ae4fb66a4f7 Thomas Gleixner 2015-08-02 189 }
f61ae4fb66a4f7 Thomas Gleixner 2015-08-02 190
bbc9d21fc0071c Thomas Gleixner 2015-06-23 191 /**
bbc9d21fc0071c Thomas Gleixner 2015-06-23 192 * irq_set_handler_locked - Set irq handler from a locked region
bbc9d21fc0071c Thomas Gleixner 2015-06-23 193 * @data: Pointer to the irq_data structure which identifies the irq
bbc9d21fc0071c Thomas Gleixner 2015-06-23 194 * @handler: Flow control handler function for this interrupt
bbc9d21fc0071c Thomas Gleixner 2015-06-23 195 *
bbc9d21fc0071c Thomas Gleixner 2015-06-23 196 * Sets the handler in the irq descriptor associated to @data.
bbc9d21fc0071c Thomas Gleixner 2015-06-23 197 *
bbc9d21fc0071c Thomas Gleixner 2015-06-23 198 * Must be called with irq_desc locked and valid parameters. Typical
bbc9d21fc0071c Thomas Gleixner 2015-06-23 199 * call site is the irq_set_type() callback.
bbc9d21fc0071c Thomas Gleixner 2015-06-23 200 */
bbc9d21fc0071c Thomas Gleixner 2015-06-23 201 static inline void irq_set_handler_locked(struct irq_data *data,
bbc9d21fc0071c Thomas Gleixner 2015-06-23 202 irq_flow_handler_t handler)
bbc9d21fc0071c Thomas Gleixner 2015-06-23 203 {
bbc9d21fc0071c Thomas Gleixner 2015-06-23 204 struct irq_desc *desc = irq_data_to_desc(data);
bbc9d21fc0071c Thomas Gleixner 2015-06-23 205
bbc9d21fc0071c Thomas Gleixner 2015-06-23 206 desc->handle_irq = handler;
bbc9d21fc0071c Thomas Gleixner 2015-06-23 207 }
bbc9d21fc0071c Thomas Gleixner 2015-06-23 208
bbc9d21fc0071c Thomas Gleixner 2015-06-23 209 /**
bbc9d21fc0071c Thomas Gleixner 2015-06-23 210 * irq_set_chip_handler_name_locked - Set chip, handler and name from a locked region
bbc9d21fc0071c Thomas Gleixner 2015-06-23 211 * @data: Pointer to the irq_data structure for which the chip is set
bbc9d21fc0071c Thomas Gleixner 2015-06-23 212 * @chip: Pointer to the new irq chip
bbc9d21fc0071c Thomas Gleixner 2015-06-23 213 * @handler: Flow control handler function for this interrupt
bbc9d21fc0071c Thomas Gleixner 2015-06-23 214 * @name: Name of the interrupt
bbc9d21fc0071c Thomas Gleixner 2015-06-23 215 *
bbc9d21fc0071c Thomas Gleixner 2015-06-23 216 * Replace the irq chip at the proper hierarchy level in @data and
bbc9d21fc0071c Thomas Gleixner 2015-06-23 217 * sets the handler and name in the associated irq descriptor.
bbc9d21fc0071c Thomas Gleixner 2015-06-23 218 *
bbc9d21fc0071c Thomas Gleixner 2015-06-23 219 * Must be called with irq_desc locked and valid parameters.
bbc9d21fc0071c Thomas Gleixner 2015-06-23 220 */
bbc9d21fc0071c Thomas Gleixner 2015-06-23 221 static inline void
bbc9d21fc0071c Thomas Gleixner 2015-06-23 222 irq_set_chip_handler_name_locked(struct irq_data *data, struct irq_chip *chip,
bbc9d21fc0071c Thomas Gleixner 2015-06-23 223 irq_flow_handler_t handler, const char *name)
bbc9d21fc0071c Thomas Gleixner 2015-06-23 224 {
bbc9d21fc0071c Thomas Gleixner 2015-06-23 225 struct irq_desc *desc = irq_data_to_desc(data);
bbc9d21fc0071c Thomas Gleixner 2015-06-23 226
bbc9d21fc0071c Thomas Gleixner 2015-06-23 227 desc->handle_irq = handler;
bbc9d21fc0071c Thomas Gleixner 2015-06-23 228 desc->name = name;
bbc9d21fc0071c Thomas Gleixner 2015-06-23 229 data->chip = chip;
bbc9d21fc0071c Thomas Gleixner 2015-06-23 230 }
bbc9d21fc0071c Thomas Gleixner 2015-06-23 231
fdd029630434b4 Thomas Gleixner 2020-12-10 232 bool irq_check_status_bit(unsigned int irq, unsigned int bitmask);
fdd029630434b4 Thomas Gleixner 2020-12-10 233
4ce413d1840b25 Will Deacon 2017-12-01 234 static inline bool irq_balancing_disabled(unsigned int irq)
e144710b302525 Thomas Gleixner 2010-10-01 235 {
fdd029630434b4 Thomas Gleixner 2020-12-10 @236 return irq_check_status_bit(irq, IRQ_NO_BALANCING_MASK);
e144710b302525 Thomas Gleixner 2010-10-01 237 }
781295762defc7 Thomas Gleixner 2011-02-10 238
4ce413d1840b25 Will Deacon 2017-12-01 239 static inline bool irq_is_percpu(unsigned int irq)
7f4a8e7b1943c1 Vinayak Kale 2013-12-04 240 {
fdd029630434b4 Thomas Gleixner 2020-12-10 @241 return irq_check_status_bit(irq, IRQ_PER_CPU);
7f4a8e7b1943c1 Vinayak Kale 2013-12-04 242 }
7f4a8e7b1943c1 Vinayak Kale 2013-12-04 243
4ce413d1840b25 Will Deacon 2017-12-01 244 static inline bool irq_is_percpu_devid(unsigned int irq)
08395c7f4d9f58 Julien Thierry 2017-10-13 245 {
fdd029630434b4 Thomas Gleixner 2020-12-10 @246 return irq_check_status_bit(irq, IRQ_PER_CPU_DEVID);
08395c7f4d9f58 Julien Thierry 2017-10-13 247 }
08395c7f4d9f58 Julien Thierry 2017-10-13 248
:::::: The code at line 56 was first introduced by commit
:::::: 0d0b4c866bcce647f40d73efe5e90aeeb079050a genirq: Introduce struct irq_common_data to host shared irq data
:::::: TO: Jiang Liu <jiang.liu(a)linux.intel.com>
:::::: CC: Thomas Gleixner <tglx(a)linutronix.de>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 4 months
[intel-gvt-linux:gvt-staging 435/441] drivers/gpu/drm/i915/i915_active.c:1156:19: error: expected ';' before 'static'
by kernel test robot
tree: https://github.com/intel/gvt-linux.git gvt-staging
head: a1b6427f07677e5f9816fcc638d73975f004951d
commit: 5fa29bf7d7be41399a5ca289a3cba31d61d88d56 [435/441] Merge remote-tracking branch 'drm-intel/drm-intel-gt-next' into drm-tip
config: x86_64-rhel-8.3-kselftests (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
# https://github.com/intel/gvt-linux/commit/5fa29bf7d7be41399a5ca289a3cba31...
git remote add intel-gvt-linux https://github.com/intel/gvt-linux.git
git fetch --no-tags intel-gvt-linux gvt-staging
git checkout 5fa29bf7d7be41399a5ca289a3cba31d61d88d56
# save the attached .config to linux build tree
make W=1 W=1 ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> drivers/gpu/drm/i915/i915_active.c:1156:19: error: expected ';' before 'static'
1156 | __i915_active_call static void
| ^~~~~~~
| ;
vim +1156 drivers/gpu/drm/i915/i915_active.c
229007e02d697b Chris Wilson 2020-03-27 1155
402be8a1011909 Stéphane Marchesin 2021-04-29 @1156 __i915_active_call static void
402be8a1011909 Stéphane Marchesin 2021-04-29 1157 auto_retire(struct i915_active *ref)
229007e02d697b Chris Wilson 2020-03-27 1158 {
229007e02d697b Chris Wilson 2020-03-27 1159 i915_active_put(ref);
229007e02d697b Chris Wilson 2020-03-27 1160 }
229007e02d697b Chris Wilson 2020-03-27 1161
:::::: The code at line 1156 was first introduced by commit
:::::: 402be8a101190969fc7ff122d07e262df86e132b drm/i915: Fix crash in auto_retire
:::::: TO: Stéphane Marchesin <marcheu(a)chromium.org>
:::::: CC: Jani Nikula <jani.nikula(a)intel.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 4 months
[arm-platforms:irq/domain_cleanup 14/20] include/linux/irqdesc.h:56:25: error: field 'irq_common_data' has incomplete type
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms.git irq/domain_cleanup
head: 76a98e310bbd7bada3f24d6fda08858460fd6cd4
commit: 5dd760fc3140b85b7d8cf1ad003238c5a223fc76 [14/20] irqdomain: Introduce irq_resolve_mapping()
config: mips-randconfig-m031-20210514 (attached as .config)
compiler: mips-linux-gcc (GCC) 9.3.0
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://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms.git/com...
git remote add arm-platforms https://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms.git
git fetch --no-tags arm-platforms irq/domain_cleanup
git checkout 5dd760fc3140b85b7d8cf1ad003238c5a223fc76
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross W=1 ARCH=mips
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from include/linux/irqdomain.h:35,
from arch/mips/include/asm/irq.h:14,
from include/linux/irq.h:23,
from include/asm-generic/hardirq.h:17,
from arch/mips/include/asm/hardirq.h:16,
from include/linux/hardirq.h:11,
from include/linux/interrupt.h:11,
from include/linux/kernel_stat.h:9,
from include/linux/cgroup.h:26,
from include/linux/memcontrol.h:13,
from include/linux/swap.h:9,
from include/linux/suspend.h:5,
from arch/mips/kernel/asm-offsets.c:17:
>> include/linux/irqdesc.h:56:25: error: field 'irq_common_data' has incomplete type
56 | struct irq_common_data irq_common_data;
| ^~~~~~~~~~~~~~~
>> include/linux/irqdesc.h:57:19: error: field 'irq_data' has incomplete type
57 | struct irq_data irq_data;
| ^~~~~~~~
>> include/linux/irqdesc.h:113:33: error: 'NR_IRQS' undeclared here (not in a function)
113 | extern struct irq_desc irq_desc[NR_IRQS];
| ^~~~~~~
In file included from include/linux/list.h:9,
from include/linux/smp.h:12,
from arch/mips/include/asm/cpu-type.h:12,
from arch/mips/include/asm/timex.h:19,
from include/linux/timex.h:65,
from include/linux/time32.h:13,
from include/linux/time.h:60,
from include/linux/compat.h:10,
from arch/mips/kernel/asm-offsets.c:12:
include/linux/irqdesc.h: In function 'irq_data_to_desc':
>> include/linux/irqdesc.h:124:26: error: dereferencing pointer to incomplete type 'struct irq_data'
124 | return container_of(data->common, struct irq_desc, irq_common_data);
| ^~
include/linux/kernel.h:703:26: note: in definition of macro 'container_of'
703 | void *__mptr = (void *)(ptr); \
| ^~~
In file included from include/linux/irqdomain.h:35,
from arch/mips/include/asm/irq.h:14,
from include/linux/irq.h:23,
from include/asm-generic/hardirq.h:17,
from arch/mips/include/asm/hardirq.h:16,
from include/linux/hardirq.h:11,
from include/linux/interrupt.h:11,
from include/linux/kernel_stat.h:9,
from include/linux/cgroup.h:26,
from include/linux/memcontrol.h:13,
from include/linux/swap.h:9,
from include/linux/suspend.h:5,
from arch/mips/kernel/asm-offsets.c:17:
include/linux/irqdesc.h: In function 'irq_balancing_disabled':
>> include/linux/irqdesc.h:236:35: error: 'IRQ_NO_BALANCING_MASK' undeclared (first use in this function)
236 | return irq_check_status_bit(irq, IRQ_NO_BALANCING_MASK);
| ^~~~~~~~~~~~~~~~~~~~~
include/linux/irqdesc.h:236:35: note: each undeclared identifier is reported only once for each function it appears in
include/linux/irqdesc.h: In function 'irq_is_percpu':
>> include/linux/irqdesc.h:241:35: error: 'IRQ_PER_CPU' undeclared (first use in this function)
241 | return irq_check_status_bit(irq, IRQ_PER_CPU);
| ^~~~~~~~~~~
include/linux/irqdesc.h: In function 'irq_is_percpu_devid':
>> include/linux/irqdesc.h:246:35: error: 'IRQ_PER_CPU_DEVID' undeclared (first use in this function)
246 | return irq_check_status_bit(irq, IRQ_PER_CPU_DEVID);
| ^~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c: At top level:
arch/mips/kernel/asm-offsets.c:26:6: warning: no previous prototype for 'output_ptreg_defines' [-Wmissing-prototypes]
26 | void output_ptreg_defines(void)
| ^~~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:78:6: warning: no previous prototype for 'output_task_defines' [-Wmissing-prototypes]
78 | void output_task_defines(void)
| ^~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:93:6: warning: no previous prototype for 'output_thread_info_defines' [-Wmissing-prototypes]
93 | void output_thread_info_defines(void)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:109:6: warning: no previous prototype for 'output_thread_defines' [-Wmissing-prototypes]
109 | void output_thread_defines(void)
| ^~~~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:137:6: warning: no previous prototype for 'output_thread_fpu_defines' [-Wmissing-prototypes]
137 | void output_thread_fpu_defines(void)
| ^~~~~~~~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:180:6: warning: no previous prototype for 'output_mm_defines' [-Wmissing-prototypes]
180 | void output_mm_defines(void)
| ^~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:219:6: warning: no previous prototype for 'output_sc_defines' [-Wmissing-prototypes]
219 | void output_sc_defines(void)
| ^~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:254:6: warning: no previous prototype for 'output_signal_defined' [-Wmissing-prototypes]
254 | void output_signal_defined(void)
| ^~~~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:333:6: warning: no previous prototype for 'output_pm_defines' [-Wmissing-prototypes]
333 | void output_pm_defines(void)
| ^~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:347:6: warning: no previous prototype for 'output_kvm_defines' [-Wmissing-prototypes]
347 | void output_kvm_defines(void)
| ^~~~~~~~~~~~~~~~~~
--
In file included from include/linux/irqdomain.h:35,
from arch/mips/include/asm/irq.h:14,
from include/linux/irq.h:23,
from include/asm-generic/hardirq.h:17,
from arch/mips/include/asm/hardirq.h:16,
from include/linux/hardirq.h:11,
from include/linux/interrupt.h:11,
from include/linux/kernel_stat.h:9,
from include/linux/cgroup.h:26,
from include/linux/memcontrol.h:13,
from include/linux/swap.h:9,
from include/linux/suspend.h:5,
from arch/mips/kernel/asm-offsets.c:17:
>> include/linux/irqdesc.h:56:25: error: field 'irq_common_data' has incomplete type
56 | struct irq_common_data irq_common_data;
| ^~~~~~~~~~~~~~~
>> include/linux/irqdesc.h:57:19: error: field 'irq_data' has incomplete type
57 | struct irq_data irq_data;
| ^~~~~~~~
>> include/linux/irqdesc.h:113:33: error: 'NR_IRQS' undeclared here (not in a function)
113 | extern struct irq_desc irq_desc[NR_IRQS];
| ^~~~~~~
In file included from include/linux/list.h:9,
from include/linux/smp.h:12,
from arch/mips/include/asm/cpu-type.h:12,
from arch/mips/include/asm/timex.h:19,
from include/linux/timex.h:65,
from include/linux/time32.h:13,
from include/linux/time.h:60,
from include/linux/compat.h:10,
from arch/mips/kernel/asm-offsets.c:12:
include/linux/irqdesc.h: In function 'irq_data_to_desc':
>> include/linux/irqdesc.h:124:26: error: dereferencing pointer to incomplete type 'struct irq_data'
124 | return container_of(data->common, struct irq_desc, irq_common_data);
| ^~
include/linux/kernel.h:703:26: note: in definition of macro 'container_of'
703 | void *__mptr = (void *)(ptr); \
| ^~~
In file included from include/linux/irqdomain.h:35,
from arch/mips/include/asm/irq.h:14,
from include/linux/irq.h:23,
from include/asm-generic/hardirq.h:17,
from arch/mips/include/asm/hardirq.h:16,
from include/linux/hardirq.h:11,
from include/linux/interrupt.h:11,
from include/linux/kernel_stat.h:9,
from include/linux/cgroup.h:26,
from include/linux/memcontrol.h:13,
from include/linux/swap.h:9,
from include/linux/suspend.h:5,
from arch/mips/kernel/asm-offsets.c:17:
include/linux/irqdesc.h: In function 'irq_balancing_disabled':
>> include/linux/irqdesc.h:236:35: error: 'IRQ_NO_BALANCING_MASK' undeclared (first use in this function)
236 | return irq_check_status_bit(irq, IRQ_NO_BALANCING_MASK);
| ^~~~~~~~~~~~~~~~~~~~~
include/linux/irqdesc.h:236:35: note: each undeclared identifier is reported only once for each function it appears in
include/linux/irqdesc.h: In function 'irq_is_percpu':
>> include/linux/irqdesc.h:241:35: error: 'IRQ_PER_CPU' undeclared (first use in this function)
241 | return irq_check_status_bit(irq, IRQ_PER_CPU);
| ^~~~~~~~~~~
include/linux/irqdesc.h: In function 'irq_is_percpu_devid':
>> include/linux/irqdesc.h:246:35: error: 'IRQ_PER_CPU_DEVID' undeclared (first use in this function)
246 | return irq_check_status_bit(irq, IRQ_PER_CPU_DEVID);
| ^~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c: At top level:
arch/mips/kernel/asm-offsets.c:26:6: warning: no previous prototype for 'output_ptreg_defines' [-Wmissing-prototypes]
26 | void output_ptreg_defines(void)
| ^~~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:78:6: warning: no previous prototype for 'output_task_defines' [-Wmissing-prototypes]
78 | void output_task_defines(void)
| ^~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:93:6: warning: no previous prototype for 'output_thread_info_defines' [-Wmissing-prototypes]
93 | void output_thread_info_defines(void)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:109:6: warning: no previous prototype for 'output_thread_defines' [-Wmissing-prototypes]
109 | void output_thread_defines(void)
| ^~~~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:137:6: warning: no previous prototype for 'output_thread_fpu_defines' [-Wmissing-prototypes]
137 | void output_thread_fpu_defines(void)
| ^~~~~~~~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:180:6: warning: no previous prototype for 'output_mm_defines' [-Wmissing-prototypes]
180 | void output_mm_defines(void)
| ^~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:219:6: warning: no previous prototype for 'output_sc_defines' [-Wmissing-prototypes]
219 | void output_sc_defines(void)
| ^~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:254:6: warning: no previous prototype for 'output_signal_defined' [-Wmissing-prototypes]
254 | void output_signal_defined(void)
| ^~~~~~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:333:6: warning: no previous prototype for 'output_pm_defines' [-Wmissing-prototypes]
333 | void output_pm_defines(void)
| ^~~~~~~~~~~~~~~~~
arch/mips/kernel/asm-offsets.c:347:6: warning: no previous prototype for 'output_kvm_defines' [-Wmissing-prototypes]
347 | void output_kvm_defines(void)
| ^~~~~~~~~~~~~~~~~~
make[2]: *** [scripts/Makefile.build:117: arch/mips/kernel/asm-offsets.s] Error 1
make[2]: Target '__build' not remade because of errors.
make[1]: *** [Makefile:1227: prepare0] Error 2
make[1]: Target 'prepare' not remade because of errors.
make: *** [Makefile:215: __sub-make] Error 2
make: Target 'prepare' not remade because of errors.
vim +/irq_common_data +56 include/linux/irqdesc.h
293a7a0a165c4f Thomas Gleixner 2012-10-16 19
e144710b302525 Thomas Gleixner 2010-10-01 20 /**
e144710b302525 Thomas Gleixner 2010-10-01 21 * struct irq_desc - interrupt descriptor
0d0b4c866bcce6 Jiang Liu 2015-06-01 22 * @irq_common_data: per irq and chip data passed down to chip functions
e144710b302525 Thomas Gleixner 2010-10-01 23 * @kstat_irqs: irq stats per cpu
770767787c2304 Geert Uytterhoeven 2011-04-10 24 * @handle_irq: highlevel irq-events handler
e144710b302525 Thomas Gleixner 2010-10-01 25 * @action: the irq action chain
80ebc420ec59a7 Yunfeng Ye 2019-09-18 26 * @status_use_accessors: status information
dbec07bac614a6 Thomas Gleixner 2011-02-07 27 * @core_internal_state__do_not_mess_with_it: core internal status information
e144710b302525 Thomas Gleixner 2010-10-01 28 * @depth: disable-depth, for nested irq_disable() calls
0911f124bf5535 Geert Uytterhoeven 2011-04-10 29 * @wake_depth: enable depth, for multiple irq_set_irq_wake() callers
030fc443aef663 Waiman Long 2019-02-12 30 * @tot_count: stats field for non-percpu irqs
e144710b302525 Thomas Gleixner 2010-10-01 31 * @irq_count: stats field to detect stalled irqs
e144710b302525 Thomas Gleixner 2010-10-01 32 * @last_unhandled: aging timer for unhandled count
e144710b302525 Thomas Gleixner 2010-10-01 33 * @irqs_unhandled: stats field for spurious unhandled interrupts
1e77d0a1ed7417 Thomas Gleixner 2013-03-07 34 * @threads_handled: stats field for deferred spurious detection of threaded handlers
a359f757965aaf Ingo Molnar 2021-03-22 35 * @threads_handled_last: comparator field for deferred spurious detection of threaded handlers
e144710b302525 Thomas Gleixner 2010-10-01 36 * @lock: locking for SMP
770767787c2304 Geert Uytterhoeven 2011-04-10 37 * @affinity_hint: hint to user space for preferred irq affinity
cd7eab44e9946c Ben Hutchings 2011-01-19 38 * @affinity_notify: context for notification of affinity changes
e144710b302525 Thomas Gleixner 2010-10-01 39 * @pending_mask: pending rebalanced interrupts
b5faba21a6805c Thomas Gleixner 2011-02-23 40 * @threads_oneshot: bitfield to handle shared oneshot threads
e144710b302525 Thomas Gleixner 2010-10-01 41 * @threads_active: number of irqaction threads currently running
e144710b302525 Thomas Gleixner 2010-10-01 42 * @wait_for_threads: wait queue for sync_irq to wait for threaded handlers
cab303be91dc47 Thomas Gleixner 2014-08-28 43 * @nr_actions: number of installed actions on this descriptor
cab303be91dc47 Thomas Gleixner 2014-08-28 44 * @no_suspend_depth: number of irqactions on a irq descriptor with
cab303be91dc47 Thomas Gleixner 2014-08-28 45 * IRQF_NO_SUSPEND set
cab303be91dc47 Thomas Gleixner 2014-08-28 46 * @force_resume_depth: number of irqactions on a irq descriptor with
cab303be91dc47 Thomas Gleixner 2014-08-28 47 * IRQF_FORCE_RESUME set
425a5072dcd1bd Thomas Gleixner 2015-12-13 48 * @rcu: rcu head for delayed free
ecb3f394c5dba8 Craig Gallek 2016-09-13 49 * @kobj: kobject used to represent this struct in sysfs
9114014cf4e6df Thomas Gleixner 2017-06-29 50 * @request_mutex: mutex to protect request/free before locking desc->lock
e144710b302525 Thomas Gleixner 2010-10-01 51 * @dir: /proc/irq/ procfs entry
087cdfb662ae50 Thomas Gleixner 2017-06-20 52 * @debugfs_file: dentry for the debugfs file
e144710b302525 Thomas Gleixner 2010-10-01 53 * @name: flow handler name for /proc/interrupts output
e144710b302525 Thomas Gleixner 2010-10-01 54 */
e144710b302525 Thomas Gleixner 2010-10-01 55 struct irq_desc {
0d0b4c866bcce6 Jiang Liu 2015-06-01 @56 struct irq_common_data irq_common_data;
e144710b302525 Thomas Gleixner 2010-10-01 @57 struct irq_data irq_data;
6c9ae009b29875 Eric Dumazet 2011-01-13 58 unsigned int __percpu *kstat_irqs;
e144710b302525 Thomas Gleixner 2010-10-01 59 irq_flow_handler_t handle_irq;
e144710b302525 Thomas Gleixner 2010-10-01 60 struct irqaction *action; /* IRQ action list */
a6967caf00ebbb Thomas Gleixner 2011-02-10 61 unsigned int status_use_accessors;
dbec07bac614a6 Thomas Gleixner 2011-02-07 62 unsigned int core_internal_state__do_not_mess_with_it;
e144710b302525 Thomas Gleixner 2010-10-01 63 unsigned int depth; /* nested irq disables */
e144710b302525 Thomas Gleixner 2010-10-01 64 unsigned int wake_depth; /* nested wake enables */
1136b072896990 Thomas Gleixner 2019-02-08 65 unsigned int tot_count;
e144710b302525 Thomas Gleixner 2010-10-01 66 unsigned int irq_count; /* For detecting broken IRQs */
e144710b302525 Thomas Gleixner 2010-10-01 67 unsigned long last_unhandled; /* Aging timer for unhandled count */
e144710b302525 Thomas Gleixner 2010-10-01 68 unsigned int irqs_unhandled;
1e77d0a1ed7417 Thomas Gleixner 2013-03-07 69 atomic_t threads_handled;
1e77d0a1ed7417 Thomas Gleixner 2013-03-07 70 int threads_handled_last;
e144710b302525 Thomas Gleixner 2010-10-01 71 raw_spinlock_t lock;
31d9d9b6d83030 Marc Zyngier 2011-09-23 72 struct cpumask *percpu_enabled;
222df54fd8b764 Marc Zyngier 2016-04-11 73 const struct cpumask *percpu_affinity;
e144710b302525 Thomas Gleixner 2010-10-01 74 #ifdef CONFIG_SMP
e144710b302525 Thomas Gleixner 2010-10-01 75 const struct cpumask *affinity_hint;
cd7eab44e9946c Ben Hutchings 2011-01-19 76 struct irq_affinity_notify *affinity_notify;
e144710b302525 Thomas Gleixner 2010-10-01 77 #ifdef CONFIG_GENERIC_PENDING_IRQ
e144710b302525 Thomas Gleixner 2010-10-01 78 cpumask_var_t pending_mask;
e144710b302525 Thomas Gleixner 2010-10-01 79 #endif
e144710b302525 Thomas Gleixner 2010-10-01 80 #endif
b5faba21a6805c Thomas Gleixner 2011-02-23 81 unsigned long threads_oneshot;
e144710b302525 Thomas Gleixner 2010-10-01 82 atomic_t threads_active;
e144710b302525 Thomas Gleixner 2010-10-01 83 wait_queue_head_t wait_for_threads;
cab303be91dc47 Thomas Gleixner 2014-08-28 84 #ifdef CONFIG_PM_SLEEP
cab303be91dc47 Thomas Gleixner 2014-08-28 85 unsigned int nr_actions;
cab303be91dc47 Thomas Gleixner 2014-08-28 86 unsigned int no_suspend_depth;
17f480342026e5 Rafael J. Wysocki 2015-02-27 87 unsigned int cond_suspend_depth;
cab303be91dc47 Thomas Gleixner 2014-08-28 88 unsigned int force_resume_depth;
cab303be91dc47 Thomas Gleixner 2014-08-28 89 #endif
e144710b302525 Thomas Gleixner 2010-10-01 90 #ifdef CONFIG_PROC_FS
e144710b302525 Thomas Gleixner 2010-10-01 91 struct proc_dir_entry *dir;
425a5072dcd1bd Thomas Gleixner 2015-12-13 92 #endif
087cdfb662ae50 Thomas Gleixner 2017-06-20 93 #ifdef CONFIG_GENERIC_IRQ_DEBUGFS
087cdfb662ae50 Thomas Gleixner 2017-06-20 94 struct dentry *debugfs_file;
07557ccb8c83f3 Thomas Gleixner 2017-09-13 95 const char *dev_name;
087cdfb662ae50 Thomas Gleixner 2017-06-20 96 #endif
425a5072dcd1bd Thomas Gleixner 2015-12-13 97 #ifdef CONFIG_SPARSE_IRQ
425a5072dcd1bd Thomas Gleixner 2015-12-13 98 struct rcu_head rcu;
ecb3f394c5dba8 Craig Gallek 2016-09-13 99 struct kobject kobj;
e144710b302525 Thomas Gleixner 2010-10-01 100 #endif
9114014cf4e6df Thomas Gleixner 2017-06-29 101 struct mutex request_mutex;
293a7a0a165c4f Thomas Gleixner 2012-10-16 102 int parent_irq;
b6873807a7143b Sebastian Andrzej Siewior 2011-07-11 103 struct module *owner;
e144710b302525 Thomas Gleixner 2010-10-01 104 const char *name;
e144710b302525 Thomas Gleixner 2010-10-01 105 } ____cacheline_internodealigned_in_smp;
e144710b302525 Thomas Gleixner 2010-10-01 106
a899418167264c Thomas Gleixner 2015-07-05 107 #ifdef CONFIG_SPARSE_IRQ
a899418167264c Thomas Gleixner 2015-07-05 108 extern void irq_lock_sparse(void);
a899418167264c Thomas Gleixner 2015-07-05 109 extern void irq_unlock_sparse(void);
a899418167264c Thomas Gleixner 2015-07-05 110 #else
a899418167264c Thomas Gleixner 2015-07-05 111 static inline void irq_lock_sparse(void) { }
a899418167264c Thomas Gleixner 2015-07-05 112 static inline void irq_unlock_sparse(void) { }
e144710b302525 Thomas Gleixner 2010-10-01 @113 extern struct irq_desc irq_desc[NR_IRQS];
e144710b302525 Thomas Gleixner 2010-10-01 114 #endif
e144710b302525 Thomas Gleixner 2010-10-01 115
501e2db67fa426 Thomas Gleixner 2020-12-10 116 static inline unsigned int irq_desc_kstat_cpu(struct irq_desc *desc,
501e2db67fa426 Thomas Gleixner 2020-12-10 117 unsigned int cpu)
501e2db67fa426 Thomas Gleixner 2020-12-10 118 {
501e2db67fa426 Thomas Gleixner 2020-12-10 119 return desc->kstat_irqs ? *per_cpu_ptr(desc->kstat_irqs, cpu) : 0;
501e2db67fa426 Thomas Gleixner 2020-12-10 120 }
501e2db67fa426 Thomas Gleixner 2020-12-10 121
7bbf1dd24b17b9 Jiang Liu 2015-06-01 122 static inline struct irq_desc *irq_data_to_desc(struct irq_data *data)
7bbf1dd24b17b9 Jiang Liu 2015-06-01 123 {
755d119a620497 Thomas Gleixner 2015-09-16 @124 return container_of(data->common, struct irq_desc, irq_common_data);
7bbf1dd24b17b9 Jiang Liu 2015-06-01 125 }
7bbf1dd24b17b9 Jiang Liu 2015-06-01 126
304adf8a8fff97 Jiang Liu 2015-06-04 127 static inline unsigned int irq_desc_get_irq(struct irq_desc *desc)
304adf8a8fff97 Jiang Liu 2015-06-04 128 {
304adf8a8fff97 Jiang Liu 2015-06-04 129 return desc->irq_data.irq;
304adf8a8fff97 Jiang Liu 2015-06-04 130 }
304adf8a8fff97 Jiang Liu 2015-06-04 131
d9936bb3952a08 Thomas Gleixner 2011-03-11 132 static inline struct irq_data *irq_desc_get_irq_data(struct irq_desc *desc)
d9936bb3952a08 Thomas Gleixner 2011-03-11 133 {
d9936bb3952a08 Thomas Gleixner 2011-03-11 134 return &desc->irq_data;
d9936bb3952a08 Thomas Gleixner 2011-03-11 135 }
d9936bb3952a08 Thomas Gleixner 2011-03-11 136
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 137 static inline struct irq_chip *irq_desc_get_chip(struct irq_desc *desc)
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 138 {
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 139 return desc->irq_data.chip;
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 140 }
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 141
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 142 static inline void *irq_desc_get_chip_data(struct irq_desc *desc)
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 143 {
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 144 return desc->irq_data.chip_data;
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 145 }
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 146
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 147 static inline void *irq_desc_get_handler_data(struct irq_desc *desc)
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 148 {
af7080e040d223 Jiang Liu 2015-06-01 149 return desc->irq_common_data.handler_data;
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 150 }
a0cd9ca2b907d7 Thomas Gleixner 2011-02-10 151
e144710b302525 Thomas Gleixner 2010-10-01 152 /*
e144710b302525 Thomas Gleixner 2010-10-01 153 * Architectures call this to let the generic IRQ layer
6584d84c3e504c Huang Shijie 2015-09-01 154 * handle an interrupt.
e144710b302525 Thomas Gleixner 2010-10-01 155 */
bd0b9ac405e179 Thomas Gleixner 2015-09-14 156 static inline void generic_handle_irq_desc(struct irq_desc *desc)
e144710b302525 Thomas Gleixner 2010-10-01 157 {
bd0b9ac405e179 Thomas Gleixner 2015-09-14 158 desc->handle_irq(desc);
e144710b302525 Thomas Gleixner 2010-10-01 159 }
e144710b302525 Thomas Gleixner 2010-10-01 160
fe12bc2c996d3e Thomas Gleixner 2011-05-18 161 int generic_handle_irq(unsigned int irq);
e144710b302525 Thomas Gleixner 2010-10-01 162
76ba59f8366f2d Marc Zyngier 2014-08-26 163 #ifdef CONFIG_HANDLE_DOMAIN_IRQ
76ba59f8366f2d Marc Zyngier 2014-08-26 164 /*
76ba59f8366f2d Marc Zyngier 2014-08-26 165 * Convert a HW interrupt number to a logical one using a IRQ domain,
76ba59f8366f2d Marc Zyngier 2014-08-26 166 * and handle the result interrupt number. Return -EINVAL if
76ba59f8366f2d Marc Zyngier 2014-08-26 167 * conversion failed. Providing a NULL domain indicates that the
76ba59f8366f2d Marc Zyngier 2014-08-26 168 * conversion has already been done.
76ba59f8366f2d Marc Zyngier 2014-08-26 169 */
76ba59f8366f2d Marc Zyngier 2014-08-26 170 int __handle_domain_irq(struct irq_domain *domain, unsigned int hwirq,
76ba59f8366f2d Marc Zyngier 2014-08-26 171 bool lookup, struct pt_regs *regs);
76ba59f8366f2d Marc Zyngier 2014-08-26 172
76ba59f8366f2d Marc Zyngier 2014-08-26 173 static inline int handle_domain_irq(struct irq_domain *domain,
76ba59f8366f2d Marc Zyngier 2014-08-26 174 unsigned int hwirq, struct pt_regs *regs)
76ba59f8366f2d Marc Zyngier 2014-08-26 175 {
76ba59f8366f2d Marc Zyngier 2014-08-26 176 return __handle_domain_irq(domain, hwirq, true, regs);
76ba59f8366f2d Marc Zyngier 2014-08-26 177 }
6e4933a0066163 Julien Thierry 2019-01-31 178
6e4933a0066163 Julien Thierry 2019-01-31 179 #ifdef CONFIG_IRQ_DOMAIN
6e4933a0066163 Julien Thierry 2019-01-31 180 int handle_domain_nmi(struct irq_domain *domain, unsigned int hwirq,
6e4933a0066163 Julien Thierry 2019-01-31 181 struct pt_regs *regs);
6e4933a0066163 Julien Thierry 2019-01-31 182 #endif
76ba59f8366f2d Marc Zyngier 2014-08-26 183 #endif
76ba59f8366f2d Marc Zyngier 2014-08-26 184
e144710b302525 Thomas Gleixner 2010-10-01 185 /* Test to see if a driver has successfully requested an irq */
f61ae4fb66a4f7 Thomas Gleixner 2015-08-02 186 static inline int irq_desc_has_action(struct irq_desc *desc)
e144710b302525 Thomas Gleixner 2010-10-01 187 {
a313357e704f26 Thomas Gleixner 2020-12-10 188 return desc && desc->action != NULL;
f61ae4fb66a4f7 Thomas Gleixner 2015-08-02 189 }
f61ae4fb66a4f7 Thomas Gleixner 2015-08-02 190
bbc9d21fc0071c Thomas Gleixner 2015-06-23 191 /**
bbc9d21fc0071c Thomas Gleixner 2015-06-23 192 * irq_set_handler_locked - Set irq handler from a locked region
bbc9d21fc0071c Thomas Gleixner 2015-06-23 193 * @data: Pointer to the irq_data structure which identifies the irq
bbc9d21fc0071c Thomas Gleixner 2015-06-23 194 * @handler: Flow control handler function for this interrupt
bbc9d21fc0071c Thomas Gleixner 2015-06-23 195 *
bbc9d21fc0071c Thomas Gleixner 2015-06-23 196 * Sets the handler in the irq descriptor associated to @data.
bbc9d21fc0071c Thomas Gleixner 2015-06-23 197 *
bbc9d21fc0071c Thomas Gleixner 2015-06-23 198 * Must be called with irq_desc locked and valid parameters. Typical
bbc9d21fc0071c Thomas Gleixner 2015-06-23 199 * call site is the irq_set_type() callback.
bbc9d21fc0071c Thomas Gleixner 2015-06-23 200 */
bbc9d21fc0071c Thomas Gleixner 2015-06-23 201 static inline void irq_set_handler_locked(struct irq_data *data,
bbc9d21fc0071c Thomas Gleixner 2015-06-23 202 irq_flow_handler_t handler)
bbc9d21fc0071c Thomas Gleixner 2015-06-23 203 {
bbc9d21fc0071c Thomas Gleixner 2015-06-23 204 struct irq_desc *desc = irq_data_to_desc(data);
bbc9d21fc0071c Thomas Gleixner 2015-06-23 205
bbc9d21fc0071c Thomas Gleixner 2015-06-23 206 desc->handle_irq = handler;
bbc9d21fc0071c Thomas Gleixner 2015-06-23 207 }
bbc9d21fc0071c Thomas Gleixner 2015-06-23 208
bbc9d21fc0071c Thomas Gleixner 2015-06-23 209 /**
bbc9d21fc0071c Thomas Gleixner 2015-06-23 210 * irq_set_chip_handler_name_locked - Set chip, handler and name from a locked region
bbc9d21fc0071c Thomas Gleixner 2015-06-23 211 * @data: Pointer to the irq_data structure for which the chip is set
bbc9d21fc0071c Thomas Gleixner 2015-06-23 212 * @chip: Pointer to the new irq chip
bbc9d21fc0071c Thomas Gleixner 2015-06-23 213 * @handler: Flow control handler function for this interrupt
bbc9d21fc0071c Thomas Gleixner 2015-06-23 214 * @name: Name of the interrupt
bbc9d21fc0071c Thomas Gleixner 2015-06-23 215 *
bbc9d21fc0071c Thomas Gleixner 2015-06-23 216 * Replace the irq chip at the proper hierarchy level in @data and
bbc9d21fc0071c Thomas Gleixner 2015-06-23 217 * sets the handler and name in the associated irq descriptor.
bbc9d21fc0071c Thomas Gleixner 2015-06-23 218 *
bbc9d21fc0071c Thomas Gleixner 2015-06-23 219 * Must be called with irq_desc locked and valid parameters.
bbc9d21fc0071c Thomas Gleixner 2015-06-23 220 */
bbc9d21fc0071c Thomas Gleixner 2015-06-23 221 static inline void
bbc9d21fc0071c Thomas Gleixner 2015-06-23 222 irq_set_chip_handler_name_locked(struct irq_data *data, struct irq_chip *chip,
bbc9d21fc0071c Thomas Gleixner 2015-06-23 223 irq_flow_handler_t handler, const char *name)
bbc9d21fc0071c Thomas Gleixner 2015-06-23 224 {
bbc9d21fc0071c Thomas Gleixner 2015-06-23 225 struct irq_desc *desc = irq_data_to_desc(data);
bbc9d21fc0071c Thomas Gleixner 2015-06-23 226
bbc9d21fc0071c Thomas Gleixner 2015-06-23 227 desc->handle_irq = handler;
bbc9d21fc0071c Thomas Gleixner 2015-06-23 228 desc->name = name;
bbc9d21fc0071c Thomas Gleixner 2015-06-23 229 data->chip = chip;
bbc9d21fc0071c Thomas Gleixner 2015-06-23 230 }
bbc9d21fc0071c Thomas Gleixner 2015-06-23 231
fdd029630434b4 Thomas Gleixner 2020-12-10 232 bool irq_check_status_bit(unsigned int irq, unsigned int bitmask);
fdd029630434b4 Thomas Gleixner 2020-12-10 233
4ce413d1840b25 Will Deacon 2017-12-01 234 static inline bool irq_balancing_disabled(unsigned int irq)
e144710b302525 Thomas Gleixner 2010-10-01 235 {
fdd029630434b4 Thomas Gleixner 2020-12-10 @236 return irq_check_status_bit(irq, IRQ_NO_BALANCING_MASK);
e144710b302525 Thomas Gleixner 2010-10-01 237 }
781295762defc7 Thomas Gleixner 2011-02-10 238
4ce413d1840b25 Will Deacon 2017-12-01 239 static inline bool irq_is_percpu(unsigned int irq)
7f4a8e7b1943c1 Vinayak Kale 2013-12-04 240 {
fdd029630434b4 Thomas Gleixner 2020-12-10 @241 return irq_check_status_bit(irq, IRQ_PER_CPU);
7f4a8e7b1943c1 Vinayak Kale 2013-12-04 242 }
7f4a8e7b1943c1 Vinayak Kale 2013-12-04 243
4ce413d1840b25 Will Deacon 2017-12-01 244 static inline bool irq_is_percpu_devid(unsigned int irq)
08395c7f4d9f58 Julien Thierry 2017-10-13 245 {
fdd029630434b4 Thomas Gleixner 2020-12-10 @246 return irq_check_status_bit(irq, IRQ_PER_CPU_DEVID);
08395c7f4d9f58 Julien Thierry 2017-10-13 247 }
08395c7f4d9f58 Julien Thierry 2017-10-13 248
:::::: The code at line 56 was first introduced by commit
:::::: 0d0b4c866bcce647f40d73efe5e90aeeb079050a genirq: Introduce struct irq_common_data to host shared irq data
:::::: TO: Jiang Liu <jiang.liu(a)linux.intel.com>
:::::: CC: Thomas Gleixner <tglx(a)linutronix.de>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 4 months
[linux-next:master 2999/3150] arch/arm64/mm/mmu.c:1340:5: error: redefinition of 'pud_set_huge'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: cd557f1c605fc5a2c0eb0b540610f50dc67dd849
commit: fc3883f43885e02525a495377573ed948f73755a [2999/3150] mm/pgtable: add stubs for {pmd/pub}_{set/clear}_huge
config: arm64-randconfig-r031-20210514 (attached as .config)
compiler: aarch64-linux-gcc (GCC) 9.3.0
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://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commi...
git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
git fetch --no-tags linux-next master
git checkout fc3883f43885e02525a495377573ed948f73755a
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross W=1 ARCH=arm64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> arch/arm64/mm/mmu.c:1340:5: error: redefinition of 'pud_set_huge'
1340 | int pud_set_huge(pud_t *pudp, phys_addr_t phys, pgprot_t prot)
| ^~~~~~~~~~~~
In file included from include/linux/mm.h:33,
from include/linux/pid_namespace.h:7,
from include/linux/ptrace.h:10,
from include/linux/elfcore.h:11,
from include/linux/crash_core.h:6,
from include/linux/kexec.h:18,
from arch/arm64/mm/mmu.c:15:
include/linux/pgtable.h:1378:19: note: previous definition of 'pud_set_huge' was here
1378 | static inline int pud_set_huge(pud_t *pud, phys_addr_t addr, pgprot_t prot)
| ^~~~~~~~~~~~
>> arch/arm64/mm/mmu.c:1368:5: error: redefinition of 'pud_clear_huge'
1368 | int pud_clear_huge(pud_t *pudp)
| ^~~~~~~~~~~~~~
In file included from include/linux/mm.h:33,
from include/linux/pid_namespace.h:7,
from include/linux/ptrace.h:10,
from include/linux/elfcore.h:11,
from include/linux/crash_core.h:6,
from include/linux/kexec.h:18,
from arch/arm64/mm/mmu.c:15:
include/linux/pgtable.h:1382:19: note: previous definition of 'pud_clear_huge' was here
1382 | static inline int pud_clear_huge(pud_t *pud)
| ^~~~~~~~~~~~~~
vim +/pud_set_huge +1340 arch/arm64/mm/mmu.c
61bd93ce801bb6 Ard Biesheuvel 2015-06-01 1339
20a004e7b017cc Will Deacon 2018-02-15 @1340 int pud_set_huge(pud_t *pudp, phys_addr_t phys, pgprot_t prot)
324420bf91f605 Ard Biesheuvel 2016-02-16 1341 {
f7f0097af67c3c Anshuman Khandual 2019-05-27 1342 pud_t new_pud = pfn_pud(__phys_to_pfn(phys), mk_pud_sect_prot(prot));
15122ee2c515a2 Will Deacon 2018-02-21 1343
82034c23fcbc23 Laura Abbott 2018-05-23 1344 /* Only allow permission changes for now */
82034c23fcbc23 Laura Abbott 2018-05-23 1345 if (!pgattr_change_is_safe(READ_ONCE(pud_val(*pudp)),
82034c23fcbc23 Laura Abbott 2018-05-23 1346 pud_val(new_pud)))
15122ee2c515a2 Will Deacon 2018-02-21 1347 return 0;
15122ee2c515a2 Will Deacon 2018-02-21 1348
87dedf7c61ab07 Anshuman Khandual 2019-05-27 1349 VM_BUG_ON(phys & ~PUD_MASK);
82034c23fcbc23 Laura Abbott 2018-05-23 1350 set_pud(pudp, new_pud);
324420bf91f605 Ard Biesheuvel 2016-02-16 1351 return 1;
324420bf91f605 Ard Biesheuvel 2016-02-16 1352 }
324420bf91f605 Ard Biesheuvel 2016-02-16 1353
20a004e7b017cc Will Deacon 2018-02-15 1354 int pmd_set_huge(pmd_t *pmdp, phys_addr_t phys, pgprot_t prot)
324420bf91f605 Ard Biesheuvel 2016-02-16 1355 {
f7f0097af67c3c Anshuman Khandual 2019-05-27 1356 pmd_t new_pmd = pfn_pmd(__phys_to_pfn(phys), mk_pmd_sect_prot(prot));
15122ee2c515a2 Will Deacon 2018-02-21 1357
82034c23fcbc23 Laura Abbott 2018-05-23 1358 /* Only allow permission changes for now */
82034c23fcbc23 Laura Abbott 2018-05-23 1359 if (!pgattr_change_is_safe(READ_ONCE(pmd_val(*pmdp)),
82034c23fcbc23 Laura Abbott 2018-05-23 1360 pmd_val(new_pmd)))
15122ee2c515a2 Will Deacon 2018-02-21 1361 return 0;
15122ee2c515a2 Will Deacon 2018-02-21 1362
87dedf7c61ab07 Anshuman Khandual 2019-05-27 1363 VM_BUG_ON(phys & ~PMD_MASK);
82034c23fcbc23 Laura Abbott 2018-05-23 1364 set_pmd(pmdp, new_pmd);
324420bf91f605 Ard Biesheuvel 2016-02-16 1365 return 1;
324420bf91f605 Ard Biesheuvel 2016-02-16 1366 }
324420bf91f605 Ard Biesheuvel 2016-02-16 1367
20a004e7b017cc Will Deacon 2018-02-15 @1368 int pud_clear_huge(pud_t *pudp)
324420bf91f605 Ard Biesheuvel 2016-02-16 1369 {
20a004e7b017cc Will Deacon 2018-02-15 1370 if (!pud_sect(READ_ONCE(*pudp)))
324420bf91f605 Ard Biesheuvel 2016-02-16 1371 return 0;
20a004e7b017cc Will Deacon 2018-02-15 1372 pud_clear(pudp);
324420bf91f605 Ard Biesheuvel 2016-02-16 1373 return 1;
324420bf91f605 Ard Biesheuvel 2016-02-16 1374 }
324420bf91f605 Ard Biesheuvel 2016-02-16 1375
:::::: The code at line 1340 was first introduced by commit
:::::: 20a004e7b017cce282a46ac5d02c2b9c6b9bb1fa arm64: mm: Use READ_ONCE/WRITE_ONCE when accessing page tables
:::::: TO: Will Deacon <will.deacon(a)arm.com>
:::::: CC: Catalin Marinas <catalin.marinas(a)arm.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 4 months
[intel-linux-intel-lts:5.4/yocto 15/1142] drivers/crypto/keembay/keembay-ocs-hcu-core.c:218:31: sparse: sparse: Using plain integer as NULL pointer
by kernel test robot
tree: https://github.com/intel/linux-intel-lts.git 5.4/yocto
head: eeb611e5394c56d45c5cc8f7dc484c9f19e93143
commit: 9b07a958f2eb496c88faf0bd749eb600357f4190 [15/1142] crypto: keembay: Add Keem Bay OCS HCU
config: i386-randconfig-s002-20210514 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
# https://github.com/intel/linux-intel-lts/commit/9b07a958f2eb496c88faf0bd7...
git remote add intel-linux-intel-lts https://github.com/intel/linux-intel-lts.git
git fetch --no-tags intel-linux-intel-lts 5.4/yocto
git checkout 9b07a958f2eb496c88faf0bd749eb600357f4190
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' W=1 ARCH=i386
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
iwyu warnings: (new ones prefixed by >>)
vim +218 drivers/crypto/keembay/keembay-ocs-hcu-core.c
202
203 static void kmb_ocs_free_dma_list(struct ocs_hcu_rctx *rctx)
204 {
205 struct ocs_hcu_dev *hcu_dev = rctx->hcu_dev;
206 struct device *dev = hcu_dev->dev;
207
208 if (!rctx->dma_list_head || !rctx->dma_list_tail)
209 return;
210
211 if (rctx->sg_dma_nents > 0)
212 dma_unmap_sg(dev, hcu_dev->req->src, rctx->sg_dma_nents,
213 DMA_TO_DEVICE);
214
215 dma_free_coherent(dev, rctx->dma_list_size, rctx->dma_list_head,
216 rctx->ll_dma_addr);
217
> 218 rctx->dma_list_head = 0;
219 rctx->dma_list_tail = 0;
220 rctx->ll_dma_addr = 0;
221 }
222
223 static int kmb_ocs_add_dma_tail(struct ocs_hcu_rctx *rctx,
224 dma_addr_t addr, size_t len)
225 {
> 226 if (addr & KMB_OCS_HCU_ALIGN_MASK || addr > OCS_HCU_DMA_MAX_ADDR_MASK)
227 return -EINVAL;
228
229 if (!len)
230 return 0;
231
232 rctx->dma_list_tail->src_adr = (u32)addr;
233 rctx->dma_list_tail->src_len = (u32)len;
234 rctx->dma_list_tail->ll_flags = 0;
235 rctx->dma_list_tail->nxt_desc = rctx->ll_dma_addr +
236 (virt_to_phys(rctx->dma_list_tail) -
237 virt_to_phys(rctx->dma_list_head)) +
238 sizeof(*rctx->dma_list_tail);
239
240 rctx->dma_list_tail++;
241
242 return 0;
243 }
244
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 4 months
[linux-next:master 2711/3150] net/bridge/br_multicast.c:1743:3: error: implicit declaration of function 'br_ip6_multicast_add_router'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: cd557f1c605fc5a2c0eb0b540610f50dc67dd849
commit: a3c02e769efe66dce5e2c716862b60c8d44d191e [2711/3150] net: bridge: mcast: split multicast router state for IPv4 and IPv6
config: x86_64-randconfig-r015-20210514 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 425781bce01f2f1d5f553d3b2bf9ebbd6e15068c)
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
# install x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commi...
git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
git fetch --no-tags linux-next master
git checkout a3c02e769efe66dce5e2c716862b60c8d44d191e
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Note: the linux-next/master HEAD cd557f1c605fc5a2c0eb0b540610f50dc67dd849 builds fine.
It may have been fixed somewhere.
All errors (new ones prefixed by >>):
>> net/bridge/br_multicast.c:1743:3: error: implicit declaration of function 'br_ip6_multicast_add_router' [-Werror,-Wimplicit-function-declaration]
br_ip6_multicast_add_router(br, port);
^
net/bridge/br_multicast.c:1743:3: note: did you mean 'br_ip4_multicast_add_router'?
net/bridge/br_multicast.c:54:13: note: 'br_ip4_multicast_add_router' declared here
static void br_ip4_multicast_add_router(struct net_bridge *br,
^
net/bridge/br_multicast.c:2804:13: error: static declaration of 'br_ip6_multicast_add_router' follows non-static declaration
static void br_ip6_multicast_add_router(struct net_bridge *br,
^
net/bridge/br_multicast.c:1743:3: note: previous implicit declaration is here
br_ip6_multicast_add_router(br, port);
^
2 errors generated.
vim +/br_ip6_multicast_add_router +1743 net/bridge/br_multicast.c
1729
1730 static void __br_multicast_enable_port(struct net_bridge_port *port)
1731 {
1732 struct net_bridge *br = port->br;
1733
1734 if (!br_opt_get(br, BROPT_MULTICAST_ENABLED) || !netif_running(br->dev))
1735 return;
1736
1737 br_multicast_enable(&port->ip4_own_query);
1738 #if IS_ENABLED(CONFIG_IPV6)
1739 br_multicast_enable(&port->ip6_own_query);
1740 #endif
1741 if (port->multicast_router == MDB_RTR_TYPE_PERM) {
1742 br_ip4_multicast_add_router(br, port);
> 1743 br_ip6_multicast_add_router(br, port);
1744 }
1745 }
1746
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 4 months
[robh:user-perf-event-v8 6/8] arch/arm64/kernel/perf_event.c:918:6: warning: no previous prototype for function 'armv8pmu_sched_task'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git user-perf-event-v8
head: 6c21e13845aa482461c6c2bb5dfb5fa6210cf3ae
commit: 587bbcc77cad781c93747a5dda66584df9326a07 [6/8] arm64: perf: Enable PMU counter userspace access for perf event
config: arm64-randconfig-r011-20210514 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 425781bce01f2f1d5f553d3b2bf9ebbd6e15068c)
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
# install arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git/commit/?id...
git remote add robh https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git
git fetch --no-tags robh user-perf-event-v8
git checkout 587bbcc77cad781c93747a5dda66584df9326a07
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=arm64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:40:31: note: expanded from macro 'PERF_CACHE_MAP_ALL_UNSUPPORTED'
[0 ... C(RESULT_MAX) - 1] = CACHE_OP_UNSUPPORTED, \
^~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:32:31: note: expanded from macro 'CACHE_OP_UNSUPPORTED'
#define CACHE_OP_UNSUPPORTED 0xFFFF
^~~~~~
arch/arm64/kernel/perf_event.c:147:44: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
[C(DTLB)][C(OP_READ)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_RD,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:122:44: note: expanded from macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_RD'
#define ARMV8_IMPDEF_PERFCTR_L1D_TLB_RD 0x4E
^~~~
arch/arm64/kernel/perf_event.c:140:2: note: previous initialization is here
PERF_CACHE_MAP_ALL_UNSUPPORTED,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:40:31: note: expanded from macro 'PERF_CACHE_MAP_ALL_UNSUPPORTED'
[0 ... C(RESULT_MAX) - 1] = CACHE_OP_UNSUPPORTED, \
^~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:32:31: note: expanded from macro 'CACHE_OP_UNSUPPORTED'
#define CACHE_OP_UNSUPPORTED 0xFFFF
^~~~~~
arch/arm64/kernel/perf_event.c:148:45: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
[C(DTLB)][C(OP_WRITE)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_WR,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:123:44: note: expanded from macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_WR'
#define ARMV8_IMPDEF_PERFCTR_L1D_TLB_WR 0x4F
^~~~
arch/arm64/kernel/perf_event.c:140:2: note: previous initialization is here
PERF_CACHE_MAP_ALL_UNSUPPORTED,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:40:31: note: expanded from macro 'PERF_CACHE_MAP_ALL_UNSUPPORTED'
[0 ... C(RESULT_MAX) - 1] = CACHE_OP_UNSUPPORTED, \
^~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:32:31: note: expanded from macro 'CACHE_OP_UNSUPPORTED'
#define CACHE_OP_UNSUPPORTED 0xFFFF
^~~~~~
arch/arm64/kernel/perf_event.c:149:42: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
[C(DTLB)][C(OP_READ)][C(RESULT_MISS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_RD,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:120:50: note: expanded from macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_RD'
#define ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_RD 0x4C
^~~~
arch/arm64/kernel/perf_event.c:140:2: note: previous initialization is here
PERF_CACHE_MAP_ALL_UNSUPPORTED,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:40:31: note: expanded from macro 'PERF_CACHE_MAP_ALL_UNSUPPORTED'
[0 ... C(RESULT_MAX) - 1] = CACHE_OP_UNSUPPORTED, \
^~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:32:31: note: expanded from macro 'CACHE_OP_UNSUPPORTED'
#define CACHE_OP_UNSUPPORTED 0xFFFF
^~~~~~
arch/arm64/kernel/perf_event.c:150:43: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
[C(DTLB)][C(OP_WRITE)][C(RESULT_MISS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_WR,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:121:50: note: expanded from macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_WR'
#define ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_WR 0x4D
^~~~
arch/arm64/kernel/perf_event.c:140:2: note: previous initialization is here
PERF_CACHE_MAP_ALL_UNSUPPORTED,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:40:31: note: expanded from macro 'PERF_CACHE_MAP_ALL_UNSUPPORTED'
[0 ... C(RESULT_MAX) - 1] = CACHE_OP_UNSUPPORTED, \
^~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:32:31: note: expanded from macro 'CACHE_OP_UNSUPPORTED'
#define CACHE_OP_UNSUPPORTED 0xFFFF
^~~~~~
arch/arm64/kernel/perf_event.c:152:44: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
[C(NODE)][C(OP_READ)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_RD,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:137:46: note: expanded from macro 'ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_RD'
#define ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_RD 0x60
^~~~
arch/arm64/kernel/perf_event.c:140:2: note: previous initialization is here
PERF_CACHE_MAP_ALL_UNSUPPORTED,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:40:31: note: expanded from macro 'PERF_CACHE_MAP_ALL_UNSUPPORTED'
[0 ... C(RESULT_MAX) - 1] = CACHE_OP_UNSUPPORTED, \
^~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:32:31: note: expanded from macro 'CACHE_OP_UNSUPPORTED'
#define CACHE_OP_UNSUPPORTED 0xFFFF
^~~~~~
arch/arm64/kernel/perf_event.c:153:45: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
[C(NODE)][C(OP_WRITE)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_WR,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:138:46: note: expanded from macro 'ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_WR'
#define ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_WR 0x61
^~~~
arch/arm64/kernel/perf_event.c:140:2: note: previous initialization is here
PERF_CACHE_MAP_ALL_UNSUPPORTED,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:40:31: note: expanded from macro 'PERF_CACHE_MAP_ALL_UNSUPPORTED'
[0 ... C(RESULT_MAX) - 1] = CACHE_OP_UNSUPPORTED, \
^~~~~~~~~~~~~~~~~~~~
include/linux/perf/arm_pmu.h:32:31: note: expanded from macro 'CACHE_OP_UNSUPPORTED'
#define CACHE_OP_UNSUPPORTED 0xFFFF
^~~~~~
arch/arm64/kernel/perf_event.c:920:40: error: no member named 'attr_rdpmc' in 'struct arm_pmu'
if (sched_in && to_arm_pmu(ctx->pmu)->attr_rdpmc && atomic_read(&ctx->nr_user))
~~~~~~~~~~~~~~~~~~~~ ^
>> arch/arm64/kernel/perf_event.c:918:6: warning: no previous prototype for function 'armv8pmu_sched_task' [-Wmissing-prototypes]
void armv8pmu_sched_task(struct perf_event_context *ctx, bool sched_in)
^
arch/arm64/kernel/perf_event.c:918:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void armv8pmu_sched_task(struct perf_event_context *ctx, bool sched_in)
^
static
57 warnings and 1 error generated.
vim +/armv8pmu_sched_task +918 arch/arm64/kernel/perf_event.c
917
> 918 void armv8pmu_sched_task(struct perf_event_context *ctx, bool sched_in)
919 {
> 920 if (sched_in && to_arm_pmu(ctx->pmu)->attr_rdpmc && atomic_read(&ctx->nr_user))
921 armv8pmu_enable_user_access();
922 else
923 armv8pmu_disable_user_access();
924 }
925
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 4 months
[robh:user-perf-event-v8 6/8] arch/arm64/kernel/perf_event.c:918:6: warning: no previous prototype for 'armv8pmu_sched_task'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git user-perf-event-v8
head: 6c21e13845aa482461c6c2bb5dfb5fa6210cf3ae
commit: 587bbcc77cad781c93747a5dda66584df9326a07 [6/8] arm64: perf: Enable PMU counter userspace access for perf event
config: arm64-allyesconfig (attached as .config)
compiler: aarch64-linux-gcc (GCC) 9.3.0
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://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git/commit/?id...
git remote add robh https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git
git fetch --no-tags robh user-perf-event-v8
git checkout 587bbcc77cad781c93747a5dda66584df9326a07
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross W=1 ARCH=arm64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
| ^~~~
arch/arm64/kernel/perf_event.c:143:41: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_CACHE_REFILL_RD'
143 | [C(L1D)][C(OP_READ)][C(RESULT_MISS)] = ARMV8_IMPDEF_PERFCTR_L1D_CACHE_REFILL_RD,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:111:45: warning: initialized field overwritten [-Woverride-init]
111 | #define ARMV8_IMPDEF_PERFCTR_L1D_CACHE_WR 0x41
| ^~~~
arch/arm64/kernel/perf_event.c:144:44: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_CACHE_WR'
144 | [C(L1D)][C(OP_WRITE)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_L1D_CACHE_WR,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:111:45: note: (near initialization for 'armv8_vulcan_perf_cache_map[0][1][0]')
111 | #define ARMV8_IMPDEF_PERFCTR_L1D_CACHE_WR 0x41
| ^~~~
arch/arm64/kernel/perf_event.c:144:44: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_CACHE_WR'
144 | [C(L1D)][C(OP_WRITE)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_L1D_CACHE_WR,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:113:51: warning: initialized field overwritten [-Woverride-init]
113 | #define ARMV8_IMPDEF_PERFCTR_L1D_CACHE_REFILL_WR 0x43
| ^~~~
arch/arm64/kernel/perf_event.c:145:42: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_CACHE_REFILL_WR'
145 | [C(L1D)][C(OP_WRITE)][C(RESULT_MISS)] = ARMV8_IMPDEF_PERFCTR_L1D_CACHE_REFILL_WR,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:113:51: note: (near initialization for 'armv8_vulcan_perf_cache_map[0][1][1]')
113 | #define ARMV8_IMPDEF_PERFCTR_L1D_CACHE_REFILL_WR 0x43
| ^~~~
arch/arm64/kernel/perf_event.c:145:42: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_CACHE_REFILL_WR'
145 | [C(L1D)][C(OP_WRITE)][C(RESULT_MISS)] = ARMV8_IMPDEF_PERFCTR_L1D_CACHE_REFILL_WR,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:122:44: warning: initialized field overwritten [-Woverride-init]
122 | #define ARMV8_IMPDEF_PERFCTR_L1D_TLB_RD 0x4E
| ^~~~
arch/arm64/kernel/perf_event.c:147:44: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_RD'
147 | [C(DTLB)][C(OP_READ)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_RD,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:122:44: note: (near initialization for 'armv8_vulcan_perf_cache_map[3][0][0]')
122 | #define ARMV8_IMPDEF_PERFCTR_L1D_TLB_RD 0x4E
| ^~~~
arch/arm64/kernel/perf_event.c:147:44: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_RD'
147 | [C(DTLB)][C(OP_READ)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_RD,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:123:44: warning: initialized field overwritten [-Woverride-init]
123 | #define ARMV8_IMPDEF_PERFCTR_L1D_TLB_WR 0x4F
| ^~~~
arch/arm64/kernel/perf_event.c:148:45: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_WR'
148 | [C(DTLB)][C(OP_WRITE)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_WR,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:123:44: note: (near initialization for 'armv8_vulcan_perf_cache_map[3][1][0]')
123 | #define ARMV8_IMPDEF_PERFCTR_L1D_TLB_WR 0x4F
| ^~~~
arch/arm64/kernel/perf_event.c:148:45: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_WR'
148 | [C(DTLB)][C(OP_WRITE)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_WR,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:120:50: warning: initialized field overwritten [-Woverride-init]
120 | #define ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_RD 0x4C
| ^~~~
arch/arm64/kernel/perf_event.c:149:42: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_RD'
149 | [C(DTLB)][C(OP_READ)][C(RESULT_MISS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_RD,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:120:50: note: (near initialization for 'armv8_vulcan_perf_cache_map[3][0][1]')
120 | #define ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_RD 0x4C
| ^~~~
arch/arm64/kernel/perf_event.c:149:42: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_RD'
149 | [C(DTLB)][C(OP_READ)][C(RESULT_MISS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_RD,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:121:50: warning: initialized field overwritten [-Woverride-init]
121 | #define ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_WR 0x4D
| ^~~~
arch/arm64/kernel/perf_event.c:150:43: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_WR'
150 | [C(DTLB)][C(OP_WRITE)][C(RESULT_MISS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_WR,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:121:50: note: (near initialization for 'armv8_vulcan_perf_cache_map[3][1][1]')
121 | #define ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_WR 0x4D
| ^~~~
arch/arm64/kernel/perf_event.c:150:43: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_WR'
150 | [C(DTLB)][C(OP_WRITE)][C(RESULT_MISS)] = ARMV8_IMPDEF_PERFCTR_L1D_TLB_REFILL_WR,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:137:46: warning: initialized field overwritten [-Woverride-init]
137 | #define ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_RD 0x60
| ^~~~
arch/arm64/kernel/perf_event.c:152:44: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_RD'
152 | [C(NODE)][C(OP_READ)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_RD,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:137:46: note: (near initialization for 'armv8_vulcan_perf_cache_map[6][0][0]')
137 | #define ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_RD 0x60
| ^~~~
arch/arm64/kernel/perf_event.c:152:44: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_RD'
152 | [C(NODE)][C(OP_READ)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_RD,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:138:46: warning: initialized field overwritten [-Woverride-init]
138 | #define ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_WR 0x61
| ^~~~
arch/arm64/kernel/perf_event.c:153:45: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_WR'
153 | [C(NODE)][C(OP_WRITE)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_WR,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/arm64/include/asm/perf_event.h:138:46: note: (near initialization for 'armv8_vulcan_perf_cache_map[6][1][0]')
138 | #define ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_WR 0x61
| ^~~~
arch/arm64/kernel/perf_event.c:153:45: note: in expansion of macro 'ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_WR'
153 | [C(NODE)][C(OP_WRITE)][C(RESULT_ACCESS)] = ARMV8_IMPDEF_PERFCTR_BUS_ACCESS_WR,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> arch/arm64/kernel/perf_event.c:918:6: warning: no previous prototype for 'armv8pmu_sched_task' [-Wmissing-prototypes]
918 | void armv8pmu_sched_task(struct perf_event_context *ctx, bool sched_in)
| ^~~~~~~~~~~~~~~~~~~
arch/arm64/kernel/perf_event.c: In function 'armv8pmu_sched_task':
arch/arm64/kernel/perf_event.c:920:38: error: 'struct arm_pmu' has no member named 'attr_rdpmc'
920 | if (sched_in && to_arm_pmu(ctx->pmu)->attr_rdpmc && atomic_read(&ctx->nr_user))
| ^~
vim +/armv8pmu_sched_task +918 arch/arm64/kernel/perf_event.c
917
> 918 void armv8pmu_sched_task(struct perf_event_context *ctx, bool sched_in)
919 {
920 if (sched_in && to_arm_pmu(ctx->pmu)->attr_rdpmc && atomic_read(&ctx->nr_user))
921 armv8pmu_enable_user_access();
922 else
923 armv8pmu_disable_user_access();
924 }
925
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 4 months