[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202006250501.CZ3RyUCN%lkp@intel.com>
Date: Thu, 25 Jun 2020 05:37:27 +0800
From: kernel test robot <lkp@...el.com>
To: Justin Iurman <justin.iurman@...ege.be>, netdev@...r.kernel.org
Cc: kbuild-all@...ts.01.org, davem@...emloft.net,
justin.iurman@...ege.be
Subject: Re: [PATCH net-next 3/5] ipv6: ioam: Data plane support for
Pre-allocated Trace
Hi Justin,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on net-next/master]
url: https://github.com/0day-ci/linux/commits/Justin-Iurman/Data-plane-support-for-IOAM-Pre-allocated-Trace-with-IPv6/20200625-033536
base: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git 0558c396040734bc1d361919566a581fd41aa539
config: um-allmodconfig (attached as .config)
compiler: gcc-9 (Debian 9.3.0-13) 9.3.0
reproduce (this is a W=1 build):
# save the attached .config to linux build tree
make W=1 ARCH=um
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
All warnings (new ones prefixed by >>):
cc1: warning: arch/um/include/uapi: No such file or directory [-Wmissing-include-dirs]
In file included from include/linux/uaccess.h:11,
from include/linux/sched/task.h:11,
from include/linux/sched/signal.h:9,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from include/linux/net.h:23,
from net/ipv6/ioam6.c:12:
arch/um/include/asm/uaccess.h: In function '__access_ok':
arch/um/include/asm/uaccess.h:17:29: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
17 | (((unsigned long) (addr) >= FIXADDR_USER_START) && \
| ^~
arch/um/include/asm/uaccess.h:45:3: note: in expansion of macro '__access_ok_vsyscall'
45 | __access_ok_vsyscall(addr, size) ||
| ^~~~~~~~~~~~~~~~~~~~
In file included from include/linux/kernel.h:11,
from net/ipv6/ioam6.c:11:
include/asm-generic/fixmap.h: In function 'fix_to_virt':
include/asm-generic/fixmap.h:32:19: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
32 | BUILD_BUG_ON(idx >= __end_of_fixed_addresses);
| ^~
include/linux/compiler.h:372:9: note: in definition of macro '__compiletime_assert'
372 | if (!(condition)) \
| ^~~~~~~~~
include/linux/compiler.h:392:2: note: in expansion of macro '_compiletime_assert'
392 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^~~~~~~~~~~~~~~~~~~
include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert'
39 | #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
| ^~~~~~~~~~~~~~~~~~
include/linux/build_bug.h:50:2: note: in expansion of macro 'BUILD_BUG_ON_MSG'
50 | BUILD_BUG_ON_MSG(condition, "BUILD_BUG_ON failed: " #condition)
| ^~~~~~~~~~~~~~~~
include/asm-generic/fixmap.h:32:2: note: in expansion of macro 'BUILD_BUG_ON'
32 | BUILD_BUG_ON(idx >= __end_of_fixed_addresses);
| ^~~~~~~~~~~~
net/ipv6/ioam6.c: At top level:
>> net/ipv6/ioam6.c:81:6: warning: no previous prototype for 'ioam6_fill_trace_data_node' [-Wmissing-prototypes]
81 | void ioam6_fill_trace_data_node(struct sk_buff *skb, int nodeoff,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
vim +/ioam6_fill_trace_data_node +81 net/ipv6/ioam6.c
80
> 81 void ioam6_fill_trace_data_node(struct sk_buff *skb, int nodeoff,
82 u32 trace_type, struct ioam6_namespace *ns)
83 {
84 u8 *data = skb_network_header(skb) + nodeoff;
85 struct __kernel_sock_timeval ts;
86 u64 raw_u64;
87 u32 raw_u32;
88 u16 raw_u16;
89 u8 byte;
90
91 /* hop_lim and node_id */
92 if (trace_type & IOAM6_TRACE_TYPE0) {
93 byte = ipv6_hdr(skb)->hop_limit - 1;
94 raw_u32 = dev_net(skb->dev)->ipv6.sysctl.ioam6_id;
95 if (!raw_u32)
96 raw_u32 = IOAM6_EMPTY_FIELD_u24;
97 else
98 raw_u32 &= IOAM6_EMPTY_FIELD_u24;
99 *(__be32 *)data = cpu_to_be32((byte << 24) | raw_u32);
100 data += sizeof(__be32);
101 }
102
103 /* ingress_if_id and egress_if_id */
104 if (trace_type & IOAM6_TRACE_TYPE1) {
105 raw_u16 = __in6_dev_get(skb->dev)->cnf.ioam6_id;
106 if (!raw_u16)
107 raw_u16 = IOAM6_EMPTY_FIELD_u16;
108 *(__be16 *)data = cpu_to_be16(raw_u16);
109 data += sizeof(__be16);
110
111 raw_u16 = __in6_dev_get(skb_dst(skb)->dev)->cnf.ioam6_id;
112 if (!raw_u16)
113 raw_u16 = IOAM6_EMPTY_FIELD_u16;
114 *(__be16 *)data = cpu_to_be16(raw_u16);
115 data += sizeof(__be16);
116 }
117
118 /* timestamp seconds */
119 if (trace_type & IOAM6_TRACE_TYPE2) {
120 if (!skb->tstamp) {
121 *(__be32 *)data = cpu_to_be32(IOAM6_EMPTY_FIELD_u32);
122 } else {
123 skb_get_new_timestamp(skb, &ts);
124 *(__be32 *)data = cpu_to_be32((u32)ts.tv_sec);
125 }
126 data += sizeof(__be32);
127 }
128
129 /* timestamp subseconds */
130 if (trace_type & IOAM6_TRACE_TYPE3) {
131 if (!skb->tstamp) {
132 *(__be32 *)data = cpu_to_be32(IOAM6_EMPTY_FIELD_u32);
133 } else {
134 if (!(trace_type & IOAM6_TRACE_TYPE2))
135 skb_get_new_timestamp(skb, &ts);
136 *(__be32 *)data = cpu_to_be32((u32)ts.tv_usec);
137 }
138 data += sizeof(__be32);
139 }
140
141 /* transit delay */
142 if (trace_type & IOAM6_TRACE_TYPE4) {
143 *(__be32 *)data = cpu_to_be32(IOAM6_EMPTY_FIELD_u32);
144 data += sizeof(__be32);
145 }
146
147 /* namespace data */
148 if (trace_type & IOAM6_TRACE_TYPE5) {
149 *(__be32 *)data = (__be32)ns->data;
150 data += sizeof(__be32);
151 }
152
153 /* queue depth */
154 if (trace_type & IOAM6_TRACE_TYPE6) {
155 *(__be32 *)data = cpu_to_be32(IOAM6_EMPTY_FIELD_u32);
156 data += sizeof(__be32);
157 }
158
159 /* hop_lim and node_id (wide) */
160 if (trace_type & IOAM6_TRACE_TYPE7) {
161 byte = ipv6_hdr(skb)->hop_limit - 1;
162 raw_u64 = dev_net(skb->dev)->ipv6.sysctl.ioam6_id;
163 if (!raw_u64)
164 raw_u64 = IOAM6_EMPTY_FIELD_u56;
165 else
166 raw_u64 &= IOAM6_EMPTY_FIELD_u56;
167 *(__be64 *)data = cpu_to_be64(((u64)byte << 56) | raw_u64);
168 data += sizeof(__be64);
169 }
170
171 /* ingress_if_id and egress_if_id (wide) */
172 if (trace_type & IOAM6_TRACE_TYPE8) {
173 raw_u32 = __in6_dev_get(skb->dev)->cnf.ioam6_id;
174 if (!raw_u32)
175 raw_u32 = IOAM6_EMPTY_FIELD_u32;
176 *(__be32 *)data = cpu_to_be32(raw_u32);
177 data += sizeof(__be32);
178
179 raw_u32 = __in6_dev_get(skb_dst(skb)->dev)->cnf.ioam6_id;
180 if (!raw_u32)
181 raw_u32 = IOAM6_EMPTY_FIELD_u32;
182 *(__be32 *)data = cpu_to_be32(raw_u32);
183 data += sizeof(__be32);
184 }
185
186 /* namespace data (wide) */
187 if (trace_type & IOAM6_TRACE_TYPE9) {
188 *(__be64 *)data = ns->data;
189 data += sizeof(__be64);
190 }
191
192 /* buffer occupancy */
193 if (trace_type & IOAM6_TRACE_TYPE10) {
194 *(__be32 *)data = cpu_to_be32(IOAM6_EMPTY_FIELD_u32);
195 data += sizeof(__be32);
196 }
197
198 /* checksum complement */
199 if (trace_type & IOAM6_TRACE_TYPE11) {
200 *(__be32 *)data = cpu_to_be32(IOAM6_EMPTY_FIELD_u32);
201 data += sizeof(__be32);
202 }
203
204 /* opaque state snapshot */
205 if (trace_type & IOAM6_TRACE_TYPE22) {
206 if (!ns->schema) {
207 *(__be32 *)data = cpu_to_be32(IOAM6_EMPTY_FIELD_u24);
208 } else {
209 *(__be32 *)data = ns->schema->hdr;
210 data += sizeof(__be32);
211 memcpy(data, ns->schema->data, ns->schema->len);
212 }
213 }
214 }
215
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
Download attachment ".config.gz" of type "application/gzip" (22959 bytes)
Powered by blists - more mailing lists