Re: [PATCH 2/2] USB: misc: Add onboard_usb_hub driver
by kernel test robot
Hi Matthias,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on usb/usb-testing]
[also build test ERROR on robh/for-next balbi-usb/testing/next peter.chen-usb/ci-for-usb-next v5.9-rc5 next-20200914]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Matthias-Kaehlcke/dt-bindings-us...
base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-testing
config: sh-allmodconfig (attached as .config)
compiler: sh4-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
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=sh
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All error/warnings (new ones prefixed by >>):
drivers/usb/misc/onboard_usb_hub.c: In function 'onboard_hub_suspend':
>> drivers/usb/misc/onboard_usb_hub.c:98:12: error: invalid storage class for function 'onboard_hub_resume'
98 | static int onboard_hub_resume(struct platform_device *pdev)
| ^~~~~~~~~~~~~~~~~~
>> drivers/usb/misc/onboard_usb_hub.c:98:1: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
98 | static int onboard_hub_resume(struct platform_device *pdev)
| ^~~~~~
>> drivers/usb/misc/onboard_usb_hub.c:111:12: error: invalid storage class for function 'onboard_hub_add_usbdev'
111 | static int onboard_hub_add_usbdev(struct onboard_hub *hub, struct usb_device *udev)
| ^~~~~~~~~~~~~~~~~~~~~~
>> drivers/usb/misc/onboard_usb_hub.c:128:12: error: invalid storage class for function 'onboard_hub_remove_usbdev'
128 | static int onboard_hub_remove_usbdev(struct onboard_hub *hub, struct usb_device *udev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/usb/misc/onboard_usb_hub.c:150:12: error: invalid storage class for function 'onboard_hub_probe'
150 | static int onboard_hub_probe(struct platform_device *pdev)
| ^~~~~~~~~~~~~~~~~
>> drivers/usb/misc/onboard_usb_hub.c:175:12: error: invalid storage class for function 'onboard_hub_remove'
175 | static int onboard_hub_remove(struct platform_device *pdev)
| ^~~~~~~~~~~~~~~~~~
>> drivers/usb/misc/onboard_usb_hub.c:187:1: warning: 'alias' attribute ignored [-Wattributes]
187 | MODULE_DEVICE_TABLE(of, onboard_hub_match);
| ^~~~~~~~~~~~~~~~~~~
>> drivers/usb/misc/onboard_usb_hub.c:190:11: error: initializer element is not constant
190 | .probe = onboard_hub_probe,
| ^~~~~~~~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:190:11: note: (near initialization for 'onboard_hub_driver.probe')
drivers/usb/misc/onboard_usb_hub.c:191:12: error: initializer element is not constant
191 | .remove = onboard_hub_remove,
| ^~~~~~~~~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:191:12: note: (near initialization for 'onboard_hub_driver.remove')
drivers/usb/misc/onboard_usb_hub.c:194:12: error: initializer element is not constant
194 | .resume = onboard_hub_resume,
| ^~~~~~~~~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:194:12: note: (near initialization for 'onboard_hub_driver.resume')
>> drivers/usb/misc/onboard_usb_hub.c:206:28: error: invalid storage class for function '_find_onboard_hub'
206 | static struct onboard_hub *_find_onboard_hub(struct device *dev)
| ^~~~~~~~~~~~~~~~~
>> drivers/usb/misc/onboard_usb_hub.c:232:12: error: invalid storage class for function 'onboard_hub_usbdev_probe'
232 | static int onboard_hub_usbdev_probe(struct usb_device *udev)
| ^~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/usb/misc/onboard_usb_hub.c:252:13: error: invalid storage class for function 'onboard_hub_usbdev_disconnect'
252 | static void onboard_hub_usbdev_disconnect(struct usb_device *udev)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:271:1: warning: 'alias' attribute ignored [-Wattributes]
271 | MODULE_DEVICE_TABLE(usb, onboard_hub_id_table);
| ^~~~~~~~~~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:276:11: error: initializer element is not constant
276 | .probe = onboard_hub_usbdev_probe,
| ^~~~~~~~~~~~~~~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:276:11: note: (near initialization for 'onboard_hub_usbdev_driver.probe')
drivers/usb/misc/onboard_usb_hub.c:277:16: error: initializer element is not constant
277 | .disconnect = onboard_hub_usbdev_disconnect,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:277:16: note: (near initialization for 'onboard_hub_usbdev_driver.disconnect')
>> drivers/usb/misc/onboard_usb_hub.c:285:19: error: invalid storage class for function 'onboard_hub_init'
285 | static int __init onboard_hub_init(void)
| ^~~~~~~~~~~~~~~~
In file included from drivers/usb/misc/onboard_usb_hub.c:10:
include/linux/module.h:131:42: error: invalid storage class for function '__inittest'
131 | static inline initcall_t __maybe_unused __inittest(void) \
| ^~~~~~~~~~
include/linux/module.h:122:30: note: in expansion of macro 'module_init'
122 | #define device_initcall(fn) module_init(fn)
| ^~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:295:1: note: in expansion of macro 'device_initcall'
295 | device_initcall(onboard_hub_init);
| ^~~~~~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:295:1: warning: 'alias' attribute ignored [-Wattributes]
>> drivers/usb/misc/onboard_usb_hub.c:297:20: error: invalid storage class for function 'onboard_hub_exit'
297 | static void __exit onboard_hub_exit(void)
| ^~~~~~~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:297:1: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
297 | static void __exit onboard_hub_exit(void)
| ^~~~~~
In file included from drivers/usb/misc/onboard_usb_hub.c:10:
include/linux/module.h:137:42: error: invalid storage class for function '__exittest'
137 | static inline exitcall_t __maybe_unused __exittest(void) \
| ^~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:302:1: note: in expansion of macro 'module_exit'
302 | module_exit(onboard_hub_exit);
| ^~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:302:1: warning: 'alias' attribute ignored [-Wattributes]
In file included from include/linux/module.h:21,
from drivers/usb/misc/onboard_usb_hub.c:10:
include/linux/moduleparam.h:24:1: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
24 | static const char __UNIQUE_ID(name)[] \
| ^~~~~~
include/linux/module.h:162:32: note: in expansion of macro '__MODULE_INFO'
162 | #define MODULE_INFO(tag, info) __MODULE_INFO(tag, tag, info)
| ^~~~~~~~~~~~~
include/linux/module.h:232:32: note: in expansion of macro 'MODULE_INFO'
232 | #define MODULE_AUTHOR(_author) MODULE_INFO(author, _author)
| ^~~~~~~~~~~
drivers/usb/misc/onboard_usb_hub.c:304:1: note: in expansion of macro 'MODULE_AUTHOR'
304 | MODULE_AUTHOR("Matthias Kaehlcke <mka(a)chromium.org>");
| ^~~~~~~~~~~~~
>> drivers/usb/misc/onboard_usb_hub.c:306:1: error: expected declaration or statement at end of input
306 | MODULE_LICENSE("GPL v2");
| ^~~~~~~~~~~~~~
At top level:
drivers/usb/misc/onboard_usb_hub.c:68:12: warning: 'onboard_hub_suspend' defined but not used [-Wunused-function]
68 | static int onboard_hub_suspend(struct platform_device *pdev, pm_message_t msg)
| ^~~~~~~~~~~~~~~~~~~
# https://github.com/0day-ci/linux/commit/81bbd2f3188c281e1c2f3fccb36d53d6f...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Matthias-Kaehlcke/dt-bindings-usb-Add-binding-for-onboard-USB-hubs/20200915-024225
git checkout 81bbd2f3188c281e1c2f3fccb36d53d6ff3d9a89
vim +/onboard_hub_resume +98 drivers/usb/misc/onboard_usb_hub.c
97
> 98 static int onboard_hub_resume(struct platform_device *pdev)
99 {
100 struct onboard_hub *hub = dev_get_drvdata(&pdev->dev);
101 int rc = 0;
102
103 if (hub->cfg.power_off_in_suspend && !hub->has_wakeup_capable_descendants)
104 rc = onboard_hub_power_on(hub);
105
106 return rc;
107 }
108
109 #endif
110
> 111 static int onboard_hub_add_usbdev(struct onboard_hub *hub, struct usb_device *udev)
112 {
113 struct udev_node *node;
114
115 node = devm_kzalloc(hub->dev, sizeof(*node), GFP_KERNEL);
116 if (!node)
117 return -ENOMEM;
118
119 node->udev = udev;
120
121 mutex_lock(&hub->lock);
122 list_add(&node->list, &hub->udev_list);
123 mutex_unlock(&hub->lock);
124
125 return 0;
126 }
127
> 128 static int onboard_hub_remove_usbdev(struct onboard_hub *hub, struct usb_device *udev)
129 {
130 struct udev_node *node;
131
132 mutex_lock(&hub->lock);
133
134 list_for_each_entry(node, &hub->udev_list, list) {
135 if (node->udev == udev) {
136 list_del(&node->list);
137 devm_kfree(hub->dev, node);
138 break;
139 }
140 }
141
142 mutex_unlock(&hub->lock);
143
144 if (node == NULL)
145 return -EINVAL;
146
147 return 0;
148 }
149
> 150 static int onboard_hub_probe(struct platform_device *pdev)
151 {
152 struct device *dev = &pdev->dev;
153 struct onboard_hub *hub;
154
155 hub = devm_kzalloc(dev, sizeof(*hub), GFP_KERNEL);
156 if (!hub)
157 return -ENOMEM;
158
159 hub->vdd = devm_regulator_get(dev, "vdd");
160 if (IS_ERR(hub->vdd))
161 return PTR_ERR(hub->vdd);
162
163 hub->dev = dev;
164 mutex_init(&hub->lock);
165 INIT_LIST_HEAD(&hub->udev_list);
166
167 hub->cfg.power_off_in_suspend = of_property_read_bool(dev->of_node, "power-off-in-suspend");
168 hub->cfg.wakeup_source = of_property_read_bool(dev->of_node, "wakeup-source");
169
170 dev_set_drvdata(dev, hub);
171
172 return onboard_hub_power_on(hub);
173 }
174
> 175 static int onboard_hub_remove(struct platform_device *pdev)
176 {
177 struct onboard_hub *hub = dev_get_drvdata(&pdev->dev);
178
179 return onboard_hub_power_off(hub);
180 }
181
182 static const struct of_device_id onboard_hub_match[] = {
183 { .compatible = "onboard-usb-hub" },
184 { .compatible = "realtek,rts5411" },
185 {}
186 };
> 187 MODULE_DEVICE_TABLE(of, onboard_hub_match);
188
189 static struct platform_driver onboard_hub_driver = {
> 190 .probe = onboard_hub_probe,
> 191 .remove = onboard_hub_remove,
192 #ifdef CONFIG_PM
193 .suspend = onboard_hub_suspend,
> 194 .resume = onboard_hub_resume,
195 #endif
196 .driver = {
197 .name = "onboard-usb-hub",
198 .of_match_table = onboard_hub_match,
199 },
200 };
201
202 /************************** USB driver **************************/
203
204 #define VENDOR_ID_REALTEK 0x0bda
205
> 206 static struct onboard_hub *_find_onboard_hub(struct device *dev)
207 {
208 const phandle *ph;
209 struct device_node *np;
210 struct platform_device *pdev;
211
212 ph = of_get_property(dev->of_node, "hub", NULL);
213 if (!ph) {
214 dev_err(dev, "failed to read 'hub' property\n");
215 return ERR_PTR(-EINVAL);
216 }
217
218 np = of_find_node_by_phandle(be32_to_cpu(*ph));
219 if (!np) {
220 dev_err(dev, "failed find device node for onboard hub\n");
221 return ERR_PTR(-EINVAL);
222 }
223
224 pdev = of_find_device_by_node(np);
225 of_node_put(np);
226 if (!pdev)
227 return ERR_PTR(-EPROBE_DEFER);
228
229 return dev_get_drvdata(&pdev->dev);
230 }
231
> 232 static int onboard_hub_usbdev_probe(struct usb_device *udev)
233 {
234 struct device *dev = &udev->dev;
235 struct onboard_hub *hub;
236
237 /* ignore supported hubs without device tree node */
238 if (!dev->of_node)
239 return -ENODEV;
240
241 hub = _find_onboard_hub(dev);
242 if (IS_ERR(hub))
243 return PTR_ERR(dev);
244
245 dev_set_drvdata(dev, hub);
246
247 onboard_hub_add_usbdev(hub, udev);
248
249 return 0;
250 }
251
> 252 static void onboard_hub_usbdev_disconnect(struct usb_device *udev)
253 {
254 struct onboard_hub *hub = dev_get_drvdata(&udev->dev);
255
256 onboard_hub_remove_usbdev(hub, udev);
257
258 put_device(hub->dev);
259 }
260
261 static const struct usb_device_id onboard_hub_id_table[] = {
262 { .idVendor = VENDOR_ID_REALTEK,
263 .idProduct = 0x0411, /* RTS5411 USB 3.0 */
264 .match_flags = USB_DEVICE_ID_MATCH_DEVICE },
265 { .idVendor = VENDOR_ID_REALTEK,
266 .idProduct = 0x5411, /* RTS5411 USB 2.0 */
267 .match_flags = USB_DEVICE_ID_MATCH_DEVICE },
268 {},
269 };
270
271 MODULE_DEVICE_TABLE(usb, onboard_hub_id_table);
272
273 static struct usb_device_driver onboard_hub_usbdev_driver = {
274
275 .name = "onboard-usb-hub",
> 276 .probe = onboard_hub_usbdev_probe,
277 .disconnect = onboard_hub_usbdev_disconnect,
278 .generic_subclass = 1,
279 .supports_autosuspend = 1,
280 .id_table = onboard_hub_id_table,
281 };
282
283 /************************** Driver (de)registration **************************/
284
> 285 static int __init onboard_hub_init(void)
286 {
287 int rc;
288
289 rc = platform_driver_register(&onboard_hub_driver);
290 if (rc)
291 return rc;
292
293 return usb_register_device_driver(&onboard_hub_usbdev_driver, THIS_MODULE);
294 }
> 295 device_initcall(onboard_hub_init);
296
> 297 static void __exit onboard_hub_exit(void)
298 {
299 usb_deregister_device_driver(&onboard_hub_usbdev_driver);
300 platform_driver_unregister(&onboard_hub_driver);
301 }
302 module_exit(onboard_hub_exit);
303
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years
Re: [PATCH bpf-next v4 4/8] bpf: support attaching freplace programs to multiple attach points
by kernel test robot
Hi "Toke,
I love your patch! Yet something to improve:
[auto build test ERROR on bpf-next/master]
url: https://github.com/0day-ci/linux/commits/Toke-H-iland-J-rgensen/bpf-Suppo...
base: https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master
config: xtensa-allyesconfig (attached as .config)
compiler: xtensa-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
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=xtensa
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 kernel/bpf/syscall.c:4:
include/linux/bpf.h:680:15: error: unknown type name 'bpf_trampoline'
680 | static inline bpf_trampoline *bpf_trampoline_get(u64 key, void *addr,
| ^~~~~~~~~~~~~~
kernel/bpf/syscall.c: In function 'bpf_tracing_prog_attach':
>> kernel/bpf/syscall.c:2696:6: error: assignment to 'struct bpf_trampoline *' from incompatible pointer type 'int *' [-Werror=incompatible-pointer-types]
2696 | tr = bpf_trampoline_get(key, (void *)addr, &fmodel);
| ^
cc1: some warnings being treated as errors
# https://github.com/0day-ci/linux/commit/c4b0c615eb0ccf48f4f63941a5a67ccc6...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Toke-H-iland-J-rgensen/bpf-Support-multi-attach-for-freplace-programs/20200915-003428
git checkout c4b0c615eb0ccf48f4f63941a5a67ccc68d72a4c
vim +2696 kernel/bpf/syscall.c
2593
2594 static int bpf_tracing_prog_attach(struct bpf_prog *prog,
2595 int tgt_prog_fd,
2596 u32 btf_id)
2597 {
2598 struct bpf_link_primer link_primer;
2599 struct bpf_prog *tgt_prog = NULL;
2600 struct bpf_tracing_link *link;
2601 struct btf_func_model fmodel;
2602 bool restore_link = false;
2603 long addr;
2604 u64 key;
2605 int err;
2606
2607 switch (prog->type) {
2608 case BPF_PROG_TYPE_TRACING:
2609 if (prog->expected_attach_type != BPF_TRACE_FENTRY &&
2610 prog->expected_attach_type != BPF_TRACE_FEXIT &&
2611 prog->expected_attach_type != BPF_MODIFY_RETURN) {
2612 err = -EINVAL;
2613 goto out_put_prog;
2614 }
2615 break;
2616 case BPF_PROG_TYPE_EXT:
2617 if (prog->expected_attach_type != 0) {
2618 err = -EINVAL;
2619 goto out_put_prog;
2620 }
2621 break;
2622 case BPF_PROG_TYPE_LSM:
2623 if (prog->expected_attach_type != BPF_LSM_MAC) {
2624 err = -EINVAL;
2625 goto out_put_prog;
2626 }
2627 break;
2628 default:
2629 err = -EINVAL;
2630 goto out_put_prog;
2631 }
2632 if (tgt_prog_fd) {
2633 /* For now we only allow new targets for BPF_PROG_TYPE_EXT */
2634 if (prog->type != BPF_PROG_TYPE_EXT || !btf_id) {
2635 err = -EINVAL;
2636 goto out_put_prog;
2637 }
2638
2639 tgt_prog = bpf_prog_get(tgt_prog_fd);
2640 if (IS_ERR(tgt_prog)) {
2641 err = PTR_ERR(tgt_prog);
2642 goto out_put_prog;
2643 }
2644
2645 key = ((u64)tgt_prog->aux->id) << 32 | btf_id;
2646 } else if (btf_id) {
2647 err = -EINVAL;
2648 goto out_put_prog;
2649 }
2650
2651 link = xchg(&prog->aux->tgt_link, NULL);
2652 if (link && tgt_prog) {
2653 if (link->trampoline->key != key) {
2654 /* supplying a tgt_prog is always destructive of the
2655 * target ref from the extension prog, which means that
2656 * mixing old and new API is not supported.
2657 */
2658 bpf_tracing_link_free(link);
2659 link = NULL;
2660 } else {
2661 /* re-using link that already has ref on tgt_prog, don't
2662 * take another
2663 */
2664 bpf_prog_put(tgt_prog);
2665 tgt_prog = NULL;
2666 }
2667 } else if (link) {
2668 /* called without a target fd, so restore link on failure for
2669 * compatibility
2670 */
2671 restore_link = true;
2672 }
2673
2674 if (!link) {
2675 struct bpf_trampoline *tr;
2676
2677 if (!tgt_prog) {
2678 err = -ENOENT;
2679 goto out_put_prog;
2680 }
2681
2682 err = bpf_check_attach_target(NULL, prog, tgt_prog, btf_id,
2683 &fmodel, &addr, NULL, NULL);
2684 if (err) {
2685 bpf_prog_put(tgt_prog);
2686 goto out_put_prog;
2687 }
2688
2689 link = bpf_tracing_link_create(prog, tgt_prog);
2690 if (IS_ERR(link)) {
2691 bpf_prog_put(tgt_prog);
2692 err = PTR_ERR(link);
2693 goto out_put_prog;
2694 }
2695
> 2696 tr = bpf_trampoline_get(key, (void *)addr, &fmodel);
2697 if (IS_ERR(tr)) {
2698 err = PTR_ERR(tr);
2699 goto out_put_link;
2700 }
2701 link->trampoline = tr;
2702 }
2703
2704 err = bpf_link_prime(&link->link, &link_primer);
2705 if (err)
2706 goto out_put_link;
2707
2708 err = bpf_trampoline_link_prog(prog, link->trampoline);
2709 if (err) {
2710 bpf_trampoline_put(link->trampoline);
2711 link->trampoline = NULL;
2712 bpf_link_cleanup(&link_primer);
2713 goto out_put_prog;
2714 }
2715
2716 return bpf_link_settle(&link_primer);
2717 out_put_link:
2718 if (restore_link)
2719 WARN_ON_ONCE(cmpxchg(&prog->aux->tgt_link, NULL, link) != NULL);
2720 else
2721 bpf_tracing_link_free(link);
2722 out_put_prog:
2723 bpf_prog_put(prog);
2724 return err;
2725 }
2726
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years
[peterz-queue:sched/core 2/4] kernel/sched/core.c:3574:13: warning: 'balance_push' used but never defined
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git sched/core
head: e337f389dc4d3748ba4342bd2d1c2133346b8691
commit: 92318ca36a5876d444849ea850534488e843f077 [2/4] sched/hotplug: Ensure only per-cpu kthreads run during hotplug
config: i386-randconfig-r035-20200913 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
reproduce (this is a W=1 build):
git checkout 92318ca36a5876d444849ea850534488e843f077
# save the attached .config to linux build tree
make W=1 ARCH=i386
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 >>):
In file included from arch/x86/include/asm/bug.h:93,
from include/linux/bug.h:5,
from include/linux/thread_info.h:12,
from arch/x86/include/asm/preempt.h:7,
from include/linux/preempt.h:78,
from include/linux/rcupdate.h:27,
from include/linux/rculist.h:11,
from include/linux/pid.h:5,
from include/linux/sched.h:14,
from include/linux/sched/numa_balancing.h:10,
from include/trace/events/sched.h:8,
from kernel/sched/core.c:10:
kernel/sched/sched.h: In function 'rq_pin_lock':
kernel/sched/sched.h:1225:18: error: 'struct rq' has no member named 'balance_callback'
1225 | SCHED_WARN_ON(rq->balance_callback);
| ^~
include/asm-generic/bug.h:157:27: note: in definition of macro 'WARN_ONCE'
157 | int __ret_warn_once = !!(condition); \
| ^~~~~~~~~
kernel/sched/sched.h:1225:2: note: in expansion of macro 'SCHED_WARN_ON'
1225 | SCHED_WARN_ON(rq->balance_callback);
| ^~~~~~~~~~~~~
kernel/sched/core.c: In function 'ttwu_stat':
kernel/sched/core.c:2423:13: warning: variable 'rq' set but not used [-Wunused-but-set-variable]
2423 | struct rq *rq;
| ^~
In file included from arch/x86/include/asm/current.h:5,
from include/linux/sched.h:12,
from include/linux/sched/numa_balancing.h:10,
from include/trace/events/sched.h:8,
from kernel/sched/core.c:10:
kernel/sched/core.c: In function 'finish_lock_switch':
kernel/sched/core.c:3584:17: error: 'struct rq' has no member named 'balance_flags'
3584 | if (unlikely(rq->balance_flags)) {
| ^~
include/linux/compiler.h:78:42: note: in definition of macro 'unlikely'
78 | # define unlikely(x) __builtin_expect(!!(x), 0)
| ^
kernel/sched/core.c:3590:11: error: 'struct rq' has no member named 'balance_flags'
3590 | !(rq->balance_flags & BALANCE_PUSH) ||
| ^~
kernel/sched/core.c:3590:29: error: 'BALANCE_PUSH' undeclared (first use in this function)
3590 | !(rq->balance_flags & BALANCE_PUSH) ||
| ^~~~~~~~~~~~
kernel/sched/core.c:3590:29: note: each undeclared identifier is reported only once for each function it appears in
kernel/sched/core.c: In function 'schedule_tail':
kernel/sched/core.c:3742:13: warning: variable 'rq' set but not used [-Wunused-but-set-variable]
3742 | struct rq *rq;
| ^~
kernel/sched/core.c: At top level:
>> kernel/sched/core.c:3574:13: warning: 'balance_push' used but never defined
3574 | static bool balance_push(struct rq *rq);
| ^~~~~~~~~~~~
# https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git/commit/?...
git remote add peterz-queue https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git
git fetch --no-tags peterz-queue sched/core
git checkout 92318ca36a5876d444849ea850534488e843f077
vim +/balance_push +3574 kernel/sched/core.c
3573
> 3574 static bool balance_push(struct rq *rq);
3575
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years
drivers/hwspinlock/omap_hwspinlock.c:165:34: warning: unused variable 'omap_hwspinlock_of_match'
by kernel test robot
Hi Baolin,
First bad commit (maybe != root cause):
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 7fe10096c1508c7f033d34d0741809f8eecc1ed4
commit: ffd0bbfb378ecd56eac22bf932ccdbf89ac7f725 hwspinlock: Allow drivers to be built with COMPILE_TEST
date: 6 months ago
:::::: branch date: 23 hours ago
:::::: commit date: 6 months ago
config: x86_64-randconfig-a015-20200910 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 0a5dc7effb191eff740e0e7ae7bd8e1f6bdb3ad9)
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
git checkout ffd0bbfb378ecd56eac22bf932ccdbf89ac7f725
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
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 >>):
>> drivers/hwspinlock/omap_hwspinlock.c:165:34: warning: unused variable 'omap_hwspinlock_of_match' [-Wunused-const-variable]
static const struct of_device_id omap_hwspinlock_of_match[] = {
^
1 warning generated.
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout ffd0bbfb378ecd56eac22bf932ccdbf89ac7f725
vim +/omap_hwspinlock_of_match +165 drivers/hwspinlock/omap_hwspinlock.c
70ba4cc26b9f53 Simon Que 2011-02-17 164
65bd4341d61678 Suman Anna 2015-03-04 @165 static const struct of_device_id omap_hwspinlock_of_match[] = {
65bd4341d61678 Suman Anna 2015-03-04 166 { .compatible = "ti,omap4-hwspinlock", },
6fa154e282f9c8 Suman Anna 2019-05-30 167 { .compatible = "ti,am654-hwspinlock", },
65bd4341d61678 Suman Anna 2015-03-04 168 { /* end */ },
65bd4341d61678 Suman Anna 2015-03-04 169 };
65bd4341d61678 Suman Anna 2015-03-04 170 MODULE_DEVICE_TABLE(of, omap_hwspinlock_of_match);
65bd4341d61678 Suman Anna 2015-03-04 171
:::::: The code at line 165 was first introduced by commit
:::::: 65bd4341d61678494ea14994d0d7df73644ca014 hwspinlock/omap: add support for dt nodes
:::::: TO: Suman Anna <s-anna(a)ti.com>
:::::: CC: Ohad Ben-Cohen <ohad(a)wizery.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years
[peterz-queue:sched/core 2/4] kernel/sched/core.c:6883:43: sparse: sparse: incorrect type in initializer (different address spaces)
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git sched/core
head: e337f389dc4d3748ba4342bd2d1c2133346b8691
commit: 92318ca36a5876d444849ea850534488e843f077 [2/4] sched/hotplug: Ensure only per-cpu kthreads run during hotplug
config: x86_64-randconfig-s022-20200914 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.2-191-g10164920-dirty
git checkout 92318ca36a5876d444849ea850534488e843f077
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
kernel/sched/core.c:610:38: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected struct task_struct *curr @@ got struct task_struct [noderef] __rcu *curr @@
kernel/sched/core.c:610:38: sparse: expected struct task_struct *curr
kernel/sched/core.c:610:38: sparse: got struct task_struct [noderef] __rcu *curr
kernel/sched/core.c:1697:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct task_struct *p @@ got struct task_struct [noderef] __rcu *curr @@
kernel/sched/core.c:1697:33: sparse: expected struct task_struct *p
kernel/sched/core.c:1697:33: sparse: got struct task_struct [noderef] __rcu *curr
kernel/sched/core.c:1697:68: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct task_struct *tsk @@ got struct task_struct [noderef] __rcu *curr @@
kernel/sched/core.c:1697:68: sparse: expected struct task_struct *tsk
kernel/sched/core.c:1697:68: sparse: got struct task_struct [noderef] __rcu *curr
kernel/sched/core.c:2439:17: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct sched_domain *[assigned] sd @@ got struct sched_domain [noderef] __rcu *parent @@
kernel/sched/core.c:2439:17: sparse: expected struct sched_domain *[assigned] sd
kernel/sched/core.c:2439:17: sparse: got struct sched_domain [noderef] __rcu *parent
kernel/sched/core.c:2631:36: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct task_struct const *p @@ got struct task_struct [noderef] __rcu *curr @@
kernel/sched/core.c:2631:36: sparse: expected struct task_struct const *p
kernel/sched/core.c:2631:36: sparse: got struct task_struct [noderef] __rcu *curr
>> kernel/sched/core.c:6883:43: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected struct task_struct *push_task @@ got struct task_struct [noderef] __rcu *curr @@
>> kernel/sched/core.c:6883:43: sparse: expected struct task_struct *push_task
kernel/sched/core.c:6883:43: sparse: got struct task_struct [noderef] __rcu *curr
kernel/sched/core.c:4026:38: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected struct task_struct *curr @@ got struct task_struct [noderef] __rcu *curr @@
kernel/sched/core.c:4026:38: sparse: expected struct task_struct *curr
kernel/sched/core.c:4026:38: sparse: got struct task_struct [noderef] __rcu *curr
kernel/sched/core.c:4459:14: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct task_struct *prev @@ got struct task_struct [noderef] __rcu *curr @@
kernel/sched/core.c:4459:14: sparse: expected struct task_struct *prev
kernel/sched/core.c:4459:14: sparse: got struct task_struct [noderef] __rcu *curr
kernel/sched/core.c:4922:17: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/core.c:4922:17: sparse: struct task_struct *
kernel/sched/core.c:4922:17: sparse: struct task_struct [noderef] __rcu *
kernel/sched/core.c:5124:22: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/core.c:5124:22: sparse: struct task_struct [noderef] __rcu *
kernel/sched/core.c:5124:22: sparse: struct task_struct *
kernel/sched/core.c:8019:11: sparse: sparse: symbol 'max_cfs_quota_period' was not declared. Should it be static?
kernel/sched/core.c:8570:25: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct task_struct *p @@ got struct task_struct [noderef] __rcu *curr @@
kernel/sched/core.c:8570:25: sparse: expected struct task_struct *p
kernel/sched/core.c:8570:25: sparse: got struct task_struct [noderef] __rcu *curr
kernel/sched/core.c: note: in included file:
kernel/sched/pelt.h:85:13: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct task_struct const *p @@ got struct task_struct [noderef] __rcu *curr @@
kernel/sched/pelt.h:85:13: sparse: expected struct task_struct const *p
kernel/sched/pelt.h:85:13: sparse: got struct task_struct [noderef] __rcu *curr
kernel/sched/core.c:1688:33: sparse: sparse: dereference of noderef expression
kernel/sched/core.c:1689:19: sparse: sparse: dereference of noderef expression
kernel/sched/core.c:1690:37: sparse: sparse: dereference of noderef expression
kernel/sched/core.c: note: in included file:
kernel/sched/sched.h:1695:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1695:25: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1695:25: sparse: struct task_struct *
kernel/sched/sched.h:1840:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1840:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1840:9: sparse: struct task_struct *
kernel/sched/sched.h:1846:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1846:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1846:9: sparse: struct task_struct *
kernel/sched/core.c:1663:38: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/core.c:1663:38: sparse: struct task_struct [noderef] __rcu *
kernel/sched/core.c:1663:38: sparse: struct task_struct const *
kernel/sched/sched.h:1695:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1695:25: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1695:25: sparse: struct task_struct *
kernel/sched/sched.h:1840:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1840:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1840:9: sparse: struct task_struct *
kernel/sched/sched.h:1840:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1840:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1840:9: sparse: struct task_struct *
kernel/sched/sched.h:1695:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1695:25: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1695:25: sparse: struct task_struct *
kernel/sched/sched.h:1840:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1840:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1840:9: sparse: struct task_struct *
kernel/sched/sched.h:1846:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1846:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1846:9: sparse: struct task_struct *
kernel/sched/sched.h:1695:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1695:25: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1695:25: sparse: struct task_struct *
kernel/sched/sched.h:1840:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1840:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1840:9: sparse: struct task_struct *
kernel/sched/sched.h:1846:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1846:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1846:9: sparse: struct task_struct *
kernel/sched/sched.h:1695:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1695:25: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1695:25: sparse: struct task_struct *
kernel/sched/sched.h:1840:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1840:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1840:9: sparse: struct task_struct *
kernel/sched/sched.h:1846:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1846:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1846:9: sparse: struct task_struct *
kernel/sched/sched.h:1695:25: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1695:25: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1695:25: sparse: struct task_struct *
kernel/sched/sched.h:1840:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1840:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1840:9: sparse: struct task_struct *
kernel/sched/sched.h:1846:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/sched/sched.h:1846:9: sparse: struct task_struct [noderef] __rcu *
kernel/sched/sched.h:1846:9: sparse: struct task_struct *
# https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git/commit/?...
git remote add peterz-queue https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git
git fetch --no-tags peterz-queue sched/core
git checkout 92318ca36a5876d444849ea850534488e843f077
vim +6883 kernel/sched/core.c
6877
6878 /*
6879 * Ensure we only run per-cpu kthreads once the CPU goes !active.
6880 */
6881 static bool balance_push(struct rq *rq)
6882 {
> 6883 struct task_struct *push_task = rq->curr;
6884
6885 lockdep_assert_held(&rq->lock);
6886 SCHED_WARN_ON(rq->cpu != smp_processor_id());
6887
6888 /*
6889 * Both the cpu-hotplug and stop task are in this case and are
6890 * required to complete the hotplug process.
6891 */
6892 if (is_per_cpu_kthread(push_task))
6893 return false;
6894
6895 get_task_struct(push_task);
6896 /*
6897 * Temporarily drop rq->lock such that we can wake-up the stop task.
6898 * Both preemption and IRQs are still disabled.
6899 */
6900 raw_spin_unlock(&rq->lock);
6901 stop_one_cpu_nowait(rq->cpu, __balance_push_cpu_stop, push_task,
6902 this_cpu_ptr(&push_work));
6903 /*
6904 * At this point need_resched() is true and we'll take the loop in
6905 * schedule(). The next pick is obviously going to be the stop task
6906 * which is_per_cpu_kthread() and will push this task away.
6907 */
6908 raw_spin_lock(&rq->lock);
6909
6910 return true;
6911 }
6912
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years
[linux-review:UPDATE-20200915-064914/Nikolay-Aleksandrov/net-bridge-mcast-fix-unused-br-var-when-lockdep-isn-t-defined/20200908-151845 1/1] kernel/rcu/srcutree.c:922:36: error: 'struct srcu_struct' has no member named 'dep_map'
by kernel test robot
tree: https://github.com/0day-ci/linux/commits/UPDATE-20200915-064914/Nikolay-A...
head: 784cbfb5fbccf5af49aa79a65d53338137044d35
commit: 784cbfb5fbccf5af49aa79a65d53338137044d35 [1/1] rcu: prevent RCU_LOCKDEP_WARN() from swallowing the condition
config: arm-defconfig (attached as .config)
compiler: arm-linux-gnueabi-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
git checkout 784cbfb5fbccf5af49aa79a65d53338137044d35
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm
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/rcupdate_wait.h:9,
from kernel/rcu/srcutree.c:22:
kernel/rcu/srcutree.c: In function '__synchronize_srcu':
>> kernel/rcu/srcutree.c:922:36: error: 'struct srcu_struct' has no member named 'dep_map'
922 | RCU_LOCKDEP_WARN(lock_is_held(&ssp->dep_map) ||
| ^~
include/linux/rcupdate.h:324:52: note: in definition of macro 'RCU_LOCKDEP_WARN'
324 | #define RCU_LOCKDEP_WARN(c, s) do { } while (0 && (c))
| ^
# https://github.com/0day-ci/linux/commit/784cbfb5fbccf5af49aa79a65d5333813...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review UPDATE-20200915-064914/Nikolay-Aleksandrov/net-bridge-mcast-fix-unused-br-var-when-lockdep-isn-t-defined/20200908-151845
git checkout 784cbfb5fbccf5af49aa79a65d53338137044d35
vim +922 kernel/rcu/srcutree.c
dad81a2026841b Paul E. McKenney 2017-03-25 914
dad81a2026841b Paul E. McKenney 2017-03-25 915 /*
dad81a2026841b Paul E. McKenney 2017-03-25 916 * Helper function for synchronize_srcu() and synchronize_srcu_expedited().
dad81a2026841b Paul E. McKenney 2017-03-25 917 */
aacb5d91ab1bfb Paul E. McKenney 2018-10-28 918 static void __synchronize_srcu(struct srcu_struct *ssp, bool do_norm)
dad81a2026841b Paul E. McKenney 2017-03-25 919 {
dad81a2026841b Paul E. McKenney 2017-03-25 920 struct rcu_synchronize rcu;
dad81a2026841b Paul E. McKenney 2017-03-25 921
aacb5d91ab1bfb Paul E. McKenney 2018-10-28 @922 RCU_LOCKDEP_WARN(lock_is_held(&ssp->dep_map) ||
dad81a2026841b Paul E. McKenney 2017-03-25 923 lock_is_held(&rcu_bh_lock_map) ||
dad81a2026841b Paul E. McKenney 2017-03-25 924 lock_is_held(&rcu_lock_map) ||
dad81a2026841b Paul E. McKenney 2017-03-25 925 lock_is_held(&rcu_sched_lock_map),
dad81a2026841b Paul E. McKenney 2017-03-25 926 "Illegal synchronize_srcu() in same-type SRCU (or in RCU) read-side critical section");
dad81a2026841b Paul E. McKenney 2017-03-25 927
dad81a2026841b Paul E. McKenney 2017-03-25 928 if (rcu_scheduler_active == RCU_SCHEDULER_INACTIVE)
dad81a2026841b Paul E. McKenney 2017-03-25 929 return;
dad81a2026841b Paul E. McKenney 2017-03-25 930 might_sleep();
aacb5d91ab1bfb Paul E. McKenney 2018-10-28 931 check_init_srcu_struct(ssp);
dad81a2026841b Paul E. McKenney 2017-03-25 932 init_completion(&rcu.completion);
da915ad5cf25b5 Paul E. McKenney 2017-04-05 933 init_rcu_head_on_stack(&rcu.head);
aacb5d91ab1bfb Paul E. McKenney 2018-10-28 934 __call_srcu(ssp, &rcu.head, wakeme_after_rcu, do_norm);
dad81a2026841b Paul E. McKenney 2017-03-25 935 wait_for_completion(&rcu.completion);
da915ad5cf25b5 Paul E. McKenney 2017-04-05 936 destroy_rcu_head_on_stack(&rcu.head);
35732cf9dd38b1 Paul E. McKenney 2017-07-05 937
35732cf9dd38b1 Paul E. McKenney 2017-07-05 938 /*
35732cf9dd38b1 Paul E. McKenney 2017-07-05 939 * Make sure that later code is ordered after the SRCU grace
d633198088bd9e Paul E. McKenney 2017-10-10 940 * period. This pairs with the spin_lock_irq_rcu_node()
35732cf9dd38b1 Paul E. McKenney 2017-07-05 941 * in srcu_invoke_callbacks(). Unlike Tree RCU, this is needed
35732cf9dd38b1 Paul E. McKenney 2017-07-05 942 * because the current CPU might have been totally uninvolved with
35732cf9dd38b1 Paul E. McKenney 2017-07-05 943 * (and thus unordered against) that grace period.
35732cf9dd38b1 Paul E. McKenney 2017-07-05 944 */
35732cf9dd38b1 Paul E. McKenney 2017-07-05 945 smp_mb();
dad81a2026841b Paul E. McKenney 2017-03-25 946 }
dad81a2026841b Paul E. McKenney 2017-03-25 947
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years
Re: [Intel-gfx] [PATCH 2/3] dma-buf: Use struct dma_buf_map in dma_buf_vmap() interfaces
by kernel test robot
Hi Thomas,
I love your patch! Yet something to improve:
[auto build test ERROR on next-20200914]
[also build test ERROR on v5.9-rc5]
[cannot apply to linuxtv-media/master drm-intel/for-linux-next tegra/for-next linus/master v5.9-rc5 v5.9-rc4 v5.9-rc3]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Thomas-Zimmermann/dma-buf-Flag-v...
base: f965d3ec86fa89285db0fbb983da76ba9c398efa
config: i386-randconfig-r034-20200913 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
reproduce (this is a W=1 build):
# save the attached .config to linux build tree
make W=1 ARCH=i386
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 drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c:291:
>> drivers/gpu/drm/i915/gem/selftests/mock_dmabuf.c:89:10: error: initialization of 'int (*)(struct dma_buf *, struct dma_buf_map *)' from incompatible pointer type 'void * (*)(struct dma_buf *)' [-Werror=incompatible-pointer-types]
89 | .vmap = mock_dmabuf_vmap,
| ^~~~~~~~~~~~~~~~
drivers/gpu/drm/i915/gem/selftests/mock_dmabuf.c:89:10: note: (near initialization for 'mock_dmabuf_ops.vmap')
cc1: some warnings being treated as errors
# https://github.com/0day-ci/linux/commit/b9513704e28f25636f00827154183df60...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Thomas-Zimmermann/dma-buf-Flag-vmap-ed-memory-as-system-or-I-O-memory/20200914-192712
git checkout b9513704e28f25636f00827154183df60a80d95c
vim +89 drivers/gpu/drm/i915/gem/selftests/mock_dmabuf.c
6cca22ede8a448 drivers/gpu/drm/i915/selftests/mock_dmabuf.c Chris Wilson 2017-02-13 83
6cca22ede8a448 drivers/gpu/drm/i915/selftests/mock_dmabuf.c Chris Wilson 2017-02-13 84 static const struct dma_buf_ops mock_dmabuf_ops = {
6cca22ede8a448 drivers/gpu/drm/i915/selftests/mock_dmabuf.c Chris Wilson 2017-02-13 85 .map_dma_buf = mock_map_dma_buf,
6cca22ede8a448 drivers/gpu/drm/i915/selftests/mock_dmabuf.c Chris Wilson 2017-02-13 86 .unmap_dma_buf = mock_unmap_dma_buf,
6cca22ede8a448 drivers/gpu/drm/i915/selftests/mock_dmabuf.c Chris Wilson 2017-02-13 87 .release = mock_dmabuf_release,
6cca22ede8a448 drivers/gpu/drm/i915/selftests/mock_dmabuf.c Chris Wilson 2017-02-13 88 .mmap = mock_dmabuf_mmap,
6cca22ede8a448 drivers/gpu/drm/i915/selftests/mock_dmabuf.c Chris Wilson 2017-02-13 @89 .vmap = mock_dmabuf_vmap,
6cca22ede8a448 drivers/gpu/drm/i915/selftests/mock_dmabuf.c Chris Wilson 2017-02-13 90 .vunmap = mock_dmabuf_vunmap,
6cca22ede8a448 drivers/gpu/drm/i915/selftests/mock_dmabuf.c Chris Wilson 2017-02-13 91 };
6cca22ede8a448 drivers/gpu/drm/i915/selftests/mock_dmabuf.c Chris Wilson 2017-02-13 92
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years
[curro:intel_pstate-vlp-v3 7/16] include/asm-generic/vmlinux.lds.h:299: warning: "ACPI_PROBE_TABLE" redefined
by kernel test robot
tree: https://github.com/curro/linux intel_pstate-vlp-v3
head: 320f232d1770592e468b87a378dc08ede8f654dc
commit: 38a4edd698dc7ea425825088702686ee52294192 [7/16] cpufreq: intel_pstate: Implement VLP controller statistics and target range calculation.
config: x86_64-allyesconfig (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
reproduce (this is a W=1 build):
git checkout 38a4edd698dc7ea425825088702686ee52294192
# save the attached .config to linux build tree
make 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 warnings (new ones prefixed by >>):
In file included from drivers/cpufreq/../../kernel/sched/sched.h:70,
from drivers/cpufreq/intel_pstate.c:37:
>> include/asm-generic/vmlinux.lds.h:299: warning: "ACPI_PROBE_TABLE" redefined
299 | #define ACPI_PROBE_TABLE(name) \
|
In file included from drivers/cpufreq/intel_pstate.c:26:
include/linux/acpi.h:1177: note: this is the location of the previous definition
1177 | #define ACPI_PROBE_TABLE(name) __##name##_acpi_probe_table
|
drivers/cpufreq/intel_pstate.c:2314:13: warning: 'update_vlp_sample' defined but not used [-Wunused-function]
2314 | static bool update_vlp_sample(struct cpudata *cpu, u64 time, unsigned int flags)
| ^~~~~~~~~~~~~~~~~
drivers/cpufreq/intel_pstate.c:2190:39: warning: 'get_vlp_target_range' defined but not used [-Wunused-function]
2190 | static const struct vlp_target_range *get_vlp_target_range(struct cpudata *cpu)
| ^~~~~~~~~~~~~~~~~~~~
drivers/cpufreq/intel_pstate.c:2041:13: warning: 'intel_pstate_reset_vlp' defined but not used [-Wunused-function]
2041 | static void intel_pstate_reset_vlp(struct cpudata *cpu)
| ^~~~~~~~~~~~~~~~~~~~~~
# https://github.com/curro/linux/commit/38a4edd698dc7ea425825088702686ee522...
git remote add curro https://github.com/curro/linux
git fetch --no-tags curro intel_pstate-vlp-v3
git checkout 38a4edd698dc7ea425825088702686ee52294192
vim +/ACPI_PROBE_TABLE +299 include/asm-generic/vmlinux.lds.h
6c3ff8b11a16ec Stephen Boyd 2013-10-30 297
e647b532275bb3 Marc Zyngier 2015-09-28 298 #ifdef CONFIG_ACPI
e647b532275bb3 Marc Zyngier 2015-09-28 @299 #define ACPI_PROBE_TABLE(name) \
e647b532275bb3 Marc Zyngier 2015-09-28 300 . = ALIGN(8); \
a6214385005333 Masahiro Yamada 2018-05-09 301 __##name##_acpi_probe_table = .; \
4b89b7f7aad574 Nicholas Piggin 2016-11-24 302 KEEP(*(__##name##_acpi_probe_table)) \
a6214385005333 Masahiro Yamada 2018-05-09 303 __##name##_acpi_probe_table_end = .;
e647b532275bb3 Marc Zyngier 2015-09-28 304 #else
e647b532275bb3 Marc Zyngier 2015-09-28 305 #define ACPI_PROBE_TABLE(name)
e647b532275bb3 Marc Zyngier 2015-09-28 306 #endif
e647b532275bb3 Marc Zyngier 2015-09-28 307
:::::: The code at line 299 was first introduced by commit
:::::: e647b532275bb357e87272e052fccf5fcdb36a17 ACPI: Add early device probing infrastructure
:::::: TO: Marc Zyngier <Marc.Zyngier(a)arm.com>
:::::: CC: Rafael J. Wysocki <rafael.j.wysocki(a)intel.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years
[kdave-btrfs-devel:ext/aota/zoned-7 124/162] fs/btrfs/zoned.c:40:17: sparse: sparse: incompatible types in comparison expression (different address spaces):
by kernel test robot
tree: https://github.com/kdave/btrfs-devel.git ext/aota/zoned-7
head: 17046312f8c0a16a96b4b3a145f4b30be84e6ede
commit: 9779d03bb87f2ff3b408bb9c3ac475851dcfd1eb [124/162] btrfs: Get zone information of zoned block devices
config: i386-randconfig-s002-20200914 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.2-191-g10164920-dirty
git checkout 9779d03bb87f2ff3b408bb9c3ac475851dcfd1eb
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=i386
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
>> fs/btrfs/zoned.c:40:17: sparse: sparse: incompatible types in comparison expression (different address spaces):
>> fs/btrfs/zoned.c:40:17: sparse: struct rcu_string [noderef] __rcu *
>> fs/btrfs/zoned.c:40:17: sparse: struct rcu_string *
fs/btrfs/zoned.c:118:17: sparse: sparse: incompatible types in comparison expression (different address spaces):
fs/btrfs/zoned.c:118:17: sparse: struct rcu_string [noderef] __rcu *
fs/btrfs/zoned.c:118:17: sparse: struct rcu_string *
fs/btrfs/zoned.c:136:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
fs/btrfs/zoned.c:136:9: sparse: struct rcu_string [noderef] __rcu *
fs/btrfs/zoned.c:136:9: sparse: struct rcu_string *
# https://github.com/kdave/btrfs-devel/commit/9779d03bb87f2ff3b408bb9c3ac47...
git remote add kdave-btrfs-devel https://github.com/kdave/btrfs-devel.git
git fetch --no-tags kdave-btrfs-devel ext/aota/zoned-7
git checkout 9779d03bb87f2ff3b408bb9c3ac475851dcfd1eb
vim +40 fs/btrfs/zoned.c
28
29 static int btrfs_get_dev_zones(struct btrfs_device *device, u64 pos,
30 struct blk_zone *zones, unsigned int *nr_zones)
31 {
32 int ret;
33
34 if (!*nr_zones)
35 return 0;
36
37 ret = blkdev_report_zones(device->bdev, pos >> SECTOR_SHIFT, *nr_zones,
38 copy_zone_info_cb, zones);
39 if (ret < 0) {
> 40 btrfs_err_in_rcu(device->fs_info,
41 "get zone at %llu on %s failed %d", pos,
42 rcu_str_deref(device->name), ret);
43 return ret;
44 }
45 *nr_zones = ret;
46 if (!ret)
47 return -EIO;
48
49 return 0;
50 }
51
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years
[superna9999:amlogic/v5.9/ge2d 1/1] drivers/media/platform/meson/ge2d/ge2d.c:176:8: error: implicit declaration of function 'FIELD_PREP'
by kernel test robot
tree: https://github.com/superna9999/linux amlogic/v5.9/ge2d
head: b1a66509dd93057c3a3adb449e0a4417aebc1fe5
commit: b1a66509dd93057c3a3adb449e0a4417aebc1fe5 [1/1] media: meson: add Amlogic GE2D 2D Accelerator driver
config: riscv-allmodconfig (attached as .config)
compiler: riscv64-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
git checkout b1a66509dd93057c3a3adb449e0a4417aebc1fe5
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=riscv
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/media/platform/meson/ge2d/ge2d.c: In function 'ge2d_hw_start':
>> drivers/media/platform/meson/ge2d/ge2d.c:176:8: error: implicit declaration of function 'FIELD_PREP' [-Werror=implicit-function-declaration]
176 | FIELD_PREP(GE2D_INTERRUPT_CTRL, 2) |
| ^~~~~~~~~~
cc1: some warnings being treated as errors
# https://github.com/superna9999/linux/commit/b1a66509dd93057c3a3adb449e0a4...
git remote add superna9999 https://github.com/superna9999/linux
git fetch --no-tags superna9999 amlogic/v5.9/ge2d
git checkout b1a66509dd93057c3a3adb449e0a4417aebc1fe5
vim +/FIELD_PREP +176 drivers/media/platform/meson/ge2d/ge2d.c
146
147 static void ge2d_hw_start(struct meson_ge2d *ge2d)
148 {
149 struct ge2d_ctx *ctx = ge2d->curr;
150 u32 reg;
151
152 /* Reset */
153 regmap_update_bits(ge2d->map, GE2D_GEN_CTRL1 << 2,
154 GE2D_SOFT_RST, GE2D_SOFT_RST);
155 regmap_update_bits(ge2d->map, GE2D_GEN_CTRL1 << 2,
156 GE2D_SOFT_RST, 0);
157
158 udelay(100);
159
160 /* Implement CANVAS for non-AXG */
161 regmap_write(ge2d->map, GE2D_SRC1_BADDR_CTRL << 2,
162 (vb2_dma_contig_plane_dma_addr(&ctx->in.buf->vb2_buf, 0) + 7) >> 3);
163 regmap_write(ge2d->map, GE2D_SRC1_STRIDE_CTRL << 2,
164 (ctx->in.stride + 7) >> 3);
165 regmap_write(ge2d->map, GE2D_SRC2_BADDR_CTRL << 2,
166 (vb2_dma_contig_plane_dma_addr(&ctx->out.buf->vb2_buf, 0) + 7) >> 3);
167 regmap_write(ge2d->map, GE2D_SRC2_STRIDE_CTRL << 2,
168 (ctx->out.stride + 7) >> 3);
169 regmap_write(ge2d->map, GE2D_DST1_BADDR_CTRL << 2,
170 (vb2_dma_contig_plane_dma_addr(&ctx->out.buf->vb2_buf, 0) + 7) >> 3);
171 regmap_write(ge2d->map, GE2D_DST1_STRIDE_CTRL << 2,
172 (ctx->out.stride + 7) >> 3);
173
174 regmap_write(ge2d->map, GE2D_GEN_CTRL0 << 2, 0);
175 regmap_write(ge2d->map, GE2D_GEN_CTRL1 << 2,
> 176 FIELD_PREP(GE2D_INTERRUPT_CTRL, 2) |
177 FIELD_PREP(GE2D_SRC2_BURST_SIZE_CTRL, 3) |
178 FIELD_PREP(GE2D_SRC1_BURST_SIZE_CTRL, 0x3f));
179 regmap_write(ge2d->map, GE2D_GEN_CTRL2 << 2,
180 FIELD_PREP(GE2D_DST1_COLOR_MAP, ctx->out.fmt->hw_map) |
181 FIELD_PREP(GE2D_DST1_FORMAT, ctx->out.fmt->hw_fmt) |
182 FIELD_PREP(GE2D_SRC2_COLOR_MAP, ctx->out.fmt->hw_map) |
183 FIELD_PREP(GE2D_SRC2_FORMAT, ctx->out.fmt->hw_fmt) |
184 FIELD_PREP(GE2D_SRC1_COLOR_MAP, ctx->in.fmt->hw_map) |
185 FIELD_PREP(GE2D_SRC1_FORMAT, ctx->in.fmt->hw_fmt));
186 regmap_write(ge2d->map, GE2D_GEN_CTRL3 << 2,
187 GE2D_DST1_ENABLE);
188
189 regmap_write(ge2d->map, GE2D_SRC1_CLIPX_START_END << 2,
190 FIELD_PREP(GE2D_START, ctx->in.crop.top) |
191 FIELD_PREP(GE2D_END, ctx->in.crop.top + ctx->in.crop.height));
192 regmap_write(ge2d->map, GE2D_SRC1_CLIPY_START_END << 2,
193 FIELD_PREP(GE2D_START, ctx->in.crop.left) |
194 FIELD_PREP(GE2D_END, ctx->in.crop.left + ctx->in.crop.width));
195 regmap_write(ge2d->map, GE2D_SRC2_CLIPX_START_END << 2,
196 FIELD_PREP(GE2D_START, ctx->out.crop.top) |
197 FIELD_PREP(GE2D_END, ctx->out.crop.top + ctx->out.crop.height));
198 regmap_write(ge2d->map, GE2D_SRC2_CLIPY_START_END << 2,
199 FIELD_PREP(GE2D_START, ctx->out.crop.left) |
200 FIELD_PREP(GE2D_END, ctx->out.crop.left + ctx->out.crop.width));
201 regmap_write(ge2d->map, GE2D_DST_CLIPX_START_END << 2,
202 FIELD_PREP(GE2D_START, ctx->out.crop.top) |
203 FIELD_PREP(GE2D_END, ctx->out.crop.top + ctx->out.crop.height));
204 regmap_write(ge2d->map, GE2D_DST_CLIPY_START_END << 2,
205 FIELD_PREP(GE2D_START, ctx->out.crop.left) |
206 FIELD_PREP(GE2D_END, ctx->out.crop.left + ctx->out.crop.width));
207
208 regmap_write(ge2d->map, GE2D_SRC1_X_START_END << 2,
209 FIELD_PREP(GE2D_END, ctx->in.height));
210 regmap_write(ge2d->map, GE2D_SRC1_Y_START_END << 2,
211 FIELD_PREP(GE2D_END, ctx->in.width));
212 regmap_write(ge2d->map, GE2D_SRC2_X_START_END << 2,
213 FIELD_PREP(GE2D_END, ctx->out.height));
214 regmap_write(ge2d->map, GE2D_SRC2_Y_START_END << 2,
215 FIELD_PREP(GE2D_END, ctx->out.width));
216 regmap_write(ge2d->map, GE2D_DST_X_START_END << 2,
217 FIELD_PREP(GE2D_END, ctx->out.height));
218 regmap_write(ge2d->map, GE2D_DST_Y_START_END << 2,
219 FIELD_PREP(GE2D_END, ctx->out.width));
220
221 /* Color, no blend, use source color */
222 reg = GE2D_ALU_DO_COLOR_OPERATION_LOGIC(LOGIC_OPERATION_COPY,
223 COLOR_FACTOR_SRC_COLOR);
224
225 if (ctx->in.fmt->alpha && ctx->out.fmt->alpha)
226 /* Take source alpha */
227 reg |= GE2D_ALU_DO_ALPHA_OPERATION_LOGIC(LOGIC_OPERATION_COPY,
228 COLOR_FACTOR_SRC_ALPHA);
229 else if (!ctx->out.fmt->alpha)
230 /* Set alpha to 0 */
231 reg |= GE2D_ALU_DO_ALPHA_OPERATION_LOGIC(LOGIC_OPERATION_SET,
232 COLOR_FACTOR_ZERO);
233 else
234 /* Keep original alpha */
235 reg |= GE2D_ALU_DO_ALPHA_OPERATION_LOGIC(LOGIC_OPERATION_COPY,
236 COLOR_FACTOR_DST_ALPHA);
237
238 regmap_write(ge2d->map, GE2D_ALU_OP_CTRL << 2, reg);
239
240 /* Start */
241 regmap_write(ge2d->map, GE2D_CMD_CTRL << 2,
242 (ctx->hflip ? GE2D_SRC1_Y_REV : 0) |
243 (ctx->vflip ? GE2D_SRC1_X_REV : 0) |
244 GE2D_CBUS_CMD_WR);
245 }
246
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
2 years