Re: [PATCH net] udp_tunnel: drop packets when hibernating
From: kernel test robot
Date: Fri Oct 09 2026 - 00:08:38 EST
Hi Jason,
kernel test robot noticed the following build errors:
[auto build test ERROR on net/main]
url: https://github.com/intel-lab-lkp/linux/commits/Jason-A-Donenfeld/udp_tunnel-drop-packets-when-hibernating/20261008-144021
base: net/main
patch link: https://lore.kernel.org/r/20261008124106.665014-1-Jason%40zx2c4.com
patch subject: [PATCH net] udp_tunnel: drop packets when hibernating
config: s390-randconfig-1000-20261009 (https://download.01.org/0day-ci/archive/20261009/202610091149.zThf8fez-lkp@xxxxxxxxx/config)
compiler: clang version 20.1.8 (https://github.com/llvm/llvm-project 87f0227cb60147a26a1eeb4fb06e3b505e9c7261)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20261009/202610091149.zThf8fez-lkp@xxxxxxxxx/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202610091149.zThf8fez-lkp@xxxxxxxxx/
All errors (new ones prefixed by >>):
>> drivers/char/virtio_console.c:636:33: error: expected identifier
636 | if (smp_load_acquire(&portdev->pm_freezing)) /* pairs with freeze/restore */
| ^
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
>> drivers/char/virtio_console.c:636:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
>> drivers/char/virtio_console.c:636:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
>> drivers/char/virtio_console.c:636:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
>> drivers/char/virtio_console.c:636:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
>> drivers/char/virtio_console.c:636:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
>> drivers/char/virtio_console.c:636:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
>> drivers/char/virtio_console.c:636:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
>> drivers/char/virtio_console.c:636:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
>> drivers/char/virtio_console.c:636:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
>> drivers/char/virtio_console.c:636:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
>> drivers/char/virtio_console.c:636:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
drivers/char/virtio_console.c:1173:33: error: expected identifier
1173 | smp_load_acquire(&portdev->pm_freezing)) /* pairs with freeze/restore */
| ^
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
drivers/char/virtio_console.c:1173:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
drivers/char/virtio_console.c:1173:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
drivers/char/virtio_console.c:1173:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
drivers/char/virtio_console.c:1173:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
drivers/char/virtio_console.c:1173:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
drivers/char/virtio_console.c:1173:33: error: expected identifier
include/linux/freezer.h:79:21: note: expanded from macro 'pm_freezing'
79 | #define pm_freezing (false)
| ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
vim +636 drivers/char/virtio_console.c
cdfadfc1adb87fc Amit Shah 2010-05-19 608
eb5e89fc70bb3f1 Masami Hiramatsu 2012-08-09 609 static ssize_t __send_to_port(struct port *port, struct scatterlist *sg,
eb5e89fc70bb3f1 Masami Hiramatsu 2012-08-09 610 int nents, size_t in_count,
fc220d6be3c7e48 Sungho Bae 2026-06-04 611 struct port_buffer *buf, bool nonblock)
f997f00bf8c3ddf Amit Shah 2009-12-21 612 {
f997f00bf8c3ddf Amit Shah 2009-12-21 613 struct virtqueue *out_vq;
589575a23562b58 Rusty Russell 2012-10-16 614 int err;
cdfadfc1adb87fc Amit Shah 2010-05-19 615 unsigned long flags;
f997f00bf8c3ddf Amit Shah 2009-12-21 616 unsigned int len;
a616ad344d9f7fe Sungho Bae 2026-06-04 617 struct ports_device *portdev;
f997f00bf8c3ddf Amit Shah 2009-12-21 618
cdfadfc1adb87fc Amit Shah 2010-05-19 619 spin_lock_irqsave(&port->outvq_lock, flags);
cdfadfc1adb87fc Amit Shah 2010-05-19 620
a616ad344d9f7fe Sungho Bae 2026-06-04 621 portdev = READ_ONCE(port->portdev);
a616ad344d9f7fe Sungho Bae 2026-06-04 622
a616ad344d9f7fe Sungho Bae 2026-06-04 623 if (!portdev) {
a616ad344d9f7fe Sungho Bae 2026-06-04 624 in_count = 0;
a616ad344d9f7fe Sungho Bae 2026-06-04 625 goto free_and_done;
a616ad344d9f7fe Sungho Bae 2026-06-04 626 }
a616ad344d9f7fe Sungho Bae 2026-06-04 627
b187532ac6dba56 Sungho Bae 2026-06-04 628 /*
b187532ac6dba56 Sungho Bae 2026-06-04 629 * Check freeze flag under the lock so that the flag check and
b187532ac6dba56 Sungho Bae 2026-06-04 630 * virtqueue_add_outbuf() are atomic with respect to
b187532ac6dba56 Sungho Bae 2026-06-04 631 * remove_port_data() which also takes outvq_lock. This
b187532ac6dba56 Sungho Bae 2026-06-04 632 * guarantees that once remove_port_data() returns, no new
b187532ac6dba56 Sungho Bae 2026-06-04 633 * buffers can be added before remove_vqs() tears down the vq.
b187532ac6dba56 Sungho Bae 2026-06-04 634 * Pairs with smp_store_release() in virtcons_freeze/restore.
b187532ac6dba56 Sungho Bae 2026-06-04 635 */
b187532ac6dba56 Sungho Bae 2026-06-04 @636 if (smp_load_acquire(&portdev->pm_freezing)) /* pairs with freeze/restore */
b187532ac6dba56 Sungho Bae 2026-06-04 637 goto free_and_done;
b187532ac6dba56 Sungho Bae 2026-06-04 638
a616ad344d9f7fe Sungho Bae 2026-06-04 639 out_vq = port->out_vq;
a616ad344d9f7fe Sungho Bae 2026-06-04 640
cdfadfc1adb87fc Amit Shah 2010-05-19 641 reclaim_consumed_buffers(port);
cdfadfc1adb87fc Amit Shah 2010-05-19 642
fc220d6be3c7e48 Sungho Bae 2026-06-04 643 err = virtqueue_add_outbuf(out_vq, sg, nents, buf, GFP_ATOMIC);
f997f00bf8c3ddf Amit Shah 2009-12-21 644
f997f00bf8c3ddf Amit Shah 2009-12-21 645 /* Tell Host to go! */
505b0451c47699c Michael S. Tsirkin 2010-04-12 646 virtqueue_kick(out_vq);
f997f00bf8c3ddf Amit Shah 2009-12-21 647
589575a23562b58 Rusty Russell 2012-10-16 648 if (err) {
9ff4cfab82d27e9 Rusty Russell 2010-04-08 649 in_count = 0;
fc220d6be3c7e48 Sungho Bae 2026-06-04 650 goto free_and_done;
f997f00bf8c3ddf Amit Shah 2009-12-21 651 }
f997f00bf8c3ddf Amit Shah 2009-12-21 652
589575a23562b58 Rusty Russell 2012-10-16 653 if (out_vq->num_free == 0)
cdfadfc1adb87fc Amit Shah 2010-05-19 654 port->outvq_full = true;
cdfadfc1adb87fc Amit Shah 2010-05-19 655
cdfadfc1adb87fc Amit Shah 2010-05-19 656 if (nonblock)
cdfadfc1adb87fc Amit Shah 2010-05-19 657 goto done;
cdfadfc1adb87fc Amit Shah 2010-05-19 658
cdfadfc1adb87fc Amit Shah 2010-05-19 659 /*
cdfadfc1adb87fc Amit Shah 2010-05-19 660 * Wait till the host acknowledges it pushed out the data we
531295e63be8c2b Amit Shah 2010-10-20 661 * sent. This is done for data from the hvc_console; the tty
531295e63be8c2b Amit Shah 2010-10-20 662 * operations are performed with spinlocks held so we can't
531295e63be8c2b Amit Shah 2010-10-20 663 * sleep here. An alternative would be to copy the data to a
531295e63be8c2b Amit Shah 2010-10-20 664 * buffer and relax the spinning requirement. The downside is
531295e63be8c2b Amit Shah 2010-10-20 665 * we need to kmalloc a GFP_ATOMIC buffer each time the
531295e63be8c2b Amit Shah 2010-10-20 666 * console driver writes something out.
fc220d6be3c7e48 Sungho Bae 2026-06-04 667 *
fc220d6be3c7e48 Sungho Bae 2026-06-04 668 * Spin until host returns the buffer.
fc220d6be3c7e48 Sungho Bae 2026-06-04 669 * Capture the returned buf so we can free it.
fc220d6be3c7e48 Sungho Bae 2026-06-04 670 * If broken, buf == NULL and buf stays in the vq;
fc220d6be3c7e48 Sungho Bae 2026-06-04 671 * remove_vqs() will call virtqueue_detach_unused_buf() -> free_buf().
cdfadfc1adb87fc Amit Shah 2010-05-19 672 */
fc220d6be3c7e48 Sungho Bae 2026-06-04 673 while (!(buf = virtqueue_get_buf(out_vq, &len))
40e4dc530118dbb Heinz Graalfs 2013-10-29 674 && !virtqueue_is_broken(out_vq))
f997f00bf8c3ddf Amit Shah 2009-12-21 675 cpu_relax();
fc220d6be3c7e48 Sungho Bae 2026-06-04 676
fc220d6be3c7e48 Sungho Bae 2026-06-04 677 free_and_done:
fc220d6be3c7e48 Sungho Bae 2026-06-04 678 if (buf)
fc220d6be3c7e48 Sungho Bae 2026-06-04 679 free_buf(buf, false);
cdfadfc1adb87fc Amit Shah 2010-05-19 680 done:
cdfadfc1adb87fc Amit Shah 2010-05-19 681 spin_unlock_irqrestore(&port->outvq_lock, flags);
17e5b4f20adbe28 Amit Shah 2011-09-14 682
17e5b4f20adbe28 Amit Shah 2011-09-14 683 port->stats.bytes_sent += in_count;
cdfadfc1adb87fc Amit Shah 2010-05-19 684 /*
cdfadfc1adb87fc Amit Shah 2010-05-19 685 * We're expected to return the amount of data we wrote -- all
cdfadfc1adb87fc Amit Shah 2010-05-19 686 * of it
cdfadfc1adb87fc Amit Shah 2010-05-19 687 */
9ff4cfab82d27e9 Rusty Russell 2010-04-08 688 return in_count;
f997f00bf8c3ddf Amit Shah 2009-12-21 689 }
f997f00bf8c3ddf Amit Shah 2009-12-21 690
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki