================================================================================ UBSAN: shift-out-of-bounds in ./include/net/red.h:310:18 shift exponent 65 is too large for 64-bit type 'long unsigned int' CPU: 0 PID: 282 Comm: kworker/u4:4 Not tainted 5.10.0-rc7-next-20201210-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: wg-kex-wg2 wg_packet_handshake_send_worker Call Trace: __dump_stack lib/dump_stack.c:79 [inline] dump_stack+0x107/0x163 lib/dump_stack.c:120 ubsan_epilogue+0xb/0x5a lib/ubsan.c:148 __ubsan_handle_shift_out_of_bounds.cold+0xb1/0x181 lib/ubsan.c:395 red_calc_qavg_from_idle_time include/net/red.h:310 [inline] red_calc_qavg include/net/red.h:351 [inline] red_enqueue.cold+0x1a/0x475 net/sched/sch_red.c:77 __dev_xmit_skb net/core/dev.c:3789 [inline] __dev_queue_xmit+0x199e/0x2ec0 net/core/dev.c:4101 neigh_hh_output include/net/neighbour.h:499 [inline] neigh_output include/net/neighbour.h:508 [inline] ip6_finish_output2+0x8cc/0x1710 net/ipv6/ip6_output.c:117 __ip6_finish_output net/ipv6/ip6_output.c:143 [inline] __ip6_finish_output+0x4be/0xb80 net/ipv6/ip6_output.c:128 ip6_finish_output+0x35/0x200 net/ipv6/ip6_output.c:153 NF_HOOK_COND include/linux/netfilter.h:290 [inline] ip6_output+0x1db/0x520 net/ipv6/ip6_output.c:176 dst_output include/net/dst.h:441 [inline] ip6_local_out+0xaf/0x1a0 net/ipv6/output_core.c:179 ip6tunnel_xmit include/net/ip6_tunnel.h:160 [inline] udp_tunnel6_xmit_skb+0x6a6/0xba0 net/ipv6/ip6_udp_tunnel.c:109 send6+0x51a/0xd10 drivers/net/wireguard/socket.c:152 wg_socket_send_skb_to_peer drivers/net/wireguard/socket.c:177 [inline] wg_socket_send_buffer_to_peer+0x1f9/0x340 drivers/net/wireguard/socket.c:199 wg_packet_send_handshake_initiation+0x212/0x340 drivers/net/wireguard/send.c:40 wg_packet_handshake_send_worker+0x18/0x30 drivers/net/wireguard/send.c:51 process_one_work+0x98d/0x1630 kernel/workqueue.c:2275 worker_thread+0x64c/0x1120 kernel/workqueue.c:2421 kthread+0x3b1/0x4a0 kernel/kthread.c:292 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296 ================================================================================