------------[ cut here ]------------
UBSAN: array-index-out-of-bounds in net/ipv6/route.c:1095:9
index 255 is out of range for type 'const int[12]'
CPU: 0 UID: 0 PID: 9224 Comm: syz.6.953 Not tainted 6.15.0-rc3-syzkaller-00584-gcc17b4b9c332 #0 PREEMPT(full)
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/19/2025
Call Trace:
dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120
ubsan_epilogue+0xa/0x40 lib/ubsan.c:231
__ubsan_handle_out_of_bounds+0xe9/0xf0 lib/ubsan.c:453
ip6_rt_type_to_error net/ipv6/route.c:1095 [inline]
ip6_rt_init_dst_reject net/ipv6/route.c:1112 [inline]
ip6_rt_init_dst net/ipv6/route.c:1137 [inline]
ip6_rt_copy_init+0x8e7/0x970 net/ipv6/route.c:1175
ip6_rt_pcpu_alloc net/ipv6/route.c:1424 [inline]
rt6_make_pcpu_route net/ipv6/route.c:1467 [inline]
ip6_pol_route+0xbac/0x1180 net/ipv6/route.c:2302
pol_lookup_func include/net/ip6_fib.h:617 [inline]
fib6_rule_lookup+0x348/0x6f0 net/ipv6/fib6_rules.c:125
ip6_route_output_flags_noref net/ipv6/route.c:2674 [inline]
ip6_route_output_flags+0x364/0x5d0 net/ipv6/route.c:2686
ip6_route_output include/net/ip6_route.h:93 [inline]
ip6_dst_lookup_tail+0x1ae/0x1510 net/ipv6/ip6_output.c:1128
ip6_dst_lookup_flow+0x47/0xe0 net/ipv6/ip6_output.c:1259
udp_tunnel6_dst_lookup+0x231/0x3c0 net/ipv6/ip6_udp_tunnel.c:165
geneve6_xmit_skb drivers/net/geneve.c:957 [inline]
geneve_xmit+0xd2e/0x2b70 drivers/net/geneve.c:1043
__netdev_start_xmit include/linux/netdevice.h:5203 [inline]
netdev_start_xmit include/linux/netdevice.h:5212 [inline]
xmit_one net/core/dev.c:3828 [inline]
dev_hard_start_xmit+0x2d4/0x830 net/core/dev.c:3844
__dev_queue_xmit+0x1adf/0x3a70 net/core/dev.c:4681
dev_queue_xmit include/linux/netdevice.h:3349 [inline]
neigh_hh_output include/net/neighbour.h:523 [inline]
neigh_output include/net/neighbour.h:537 [inline]
ip6_finish_output2+0x11bc/0x16a0 net/ipv6/ip6_output.c:141
__ip6_finish_output net/ipv6/ip6_output.c:-1 [inline]
ip6_finish_output+0x234/0x7d0 net/ipv6/ip6_output.c:226
NF_HOOK include/linux/netfilter.h:314 [inline]
ndisc_send_skb+0xb47/0x1400 net/ipv6/ndisc.c:513
addrconf_rs_timer+0x369/0x670 net/ipv6/addrconf.c:4038
call_timer_fn+0x17b/0x5f0 kernel/time/timer.c:1789
expire_timers kernel/time/timer.c:1840 [inline]
__run_timers kernel/time/timer.c:2414 [inline]
__run_timer_base+0x61a/0x860 kernel/time/timer.c:2426
run_timer_base kernel/time/timer.c:2435 [inline]
run_timer_softirq+0xb7/0x180 kernel/time/timer.c:2445
handle_softirqs+0x283/0x870 kernel/softirq.c:579
__do_softirq kernel/softirq.c:613 [inline]
invoke_softirq kernel/softirq.c:453 [inline]
__irq_exit_rcu+0xca/0x1f0 kernel/softirq.c:680
irq_exit_rcu+0x9/0x30 kernel/softirq.c:696
instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1049 [inline]
sysvec_apic_timer_interrupt+0xa6/0xc0 arch/x86/kernel/apic/apic.c:1049
asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:702
RIP: 0010:lock_acquire+0x175/0x360 kernel/locking/lockdep.c:5870
Code: 00 00 00 00 9c 8f 44 24 30 f7 44 24 30 00 02 00 00 0f 85 cd 00 00 00 f7 44 24 08 00 02 00 00 74 01 fb 65 48 8b 05 1b b3 d7 10 <48> 3b 44 24 58 0f 85 f2 00 00 00 48 83 c4 60 5b 41 5c 41 5d 41 5e
RSP: 0018:ffffc90003987098 EFLAGS: 00000206
RAX: 544b2af0cc3f3c00 RBX: 0000000000000000 RCX: 544b2af0cc3f3c00
RDX: 0000000000000000 RSI: ffffffff8d938c17 RDI: ffffffff8bc1ca60
RBP: ffffffff817199f5 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: ffffffff817199f5 R12: 0000000000000002
R13: ffffffff8df3b860 R14: 0000000000000000 R15: 0000000000000246
rcu_lock_acquire include/linux/rcupdate.h:331 [inline]
rcu_read_lock include/linux/rcupdate.h:841 [inline]
class_rcu_constructor include/linux/rcupdate.h:1155 [inline]
unwind_next_frame+0xc2/0x2390 arch/x86/kernel/unwind_orc.c:479
arch_stack_walk+0x11c/0x150 arch/x86/kernel/stacktrace.c:25
stack_trace_save+0x9c/0xe0 kernel/stacktrace.c:122
save_stack+0xf7/0x1f0 mm/page_owner.c:156
__set_page_owner+0x8d/0x4a0 mm/page_owner.c:329
set_page_owner include/linux/page_owner.h:32 [inline]
post_alloc_hook+0x1d8/0x230 mm/page_alloc.c:1714
prep_new_page mm/page_alloc.c:1722 [inline]
get_page_from_freelist+0x21e0/0x22c0 mm/page_alloc.c:3684
__alloc_frozen_pages_noprof+0x181/0x370 mm/page_alloc.c:4966
alloc_pages_mpol+0x232/0x4a0 mm/mempolicy.c:2301
alloc_frozen_pages_noprof mm/mempolicy.c:2372 [inline]
alloc_pages_noprof+0xa9/0x190 mm/mempolicy.c:2392
get_free_pages_noprof+0xc/0x30 mm/page_alloc.c:5025
alloc_one_pg_vec_page net/packet/af_packet.c:4410 [inline]
alloc_pg_vec net/packet/af_packet.c:4440 [inline]
packet_set_ring+0x6bc/0x2380 net/packet/af_packet.c:4525
packet_setsockopt+0xc5a/0x12c0 net/packet/af_packet.c:3891
do_sock_setsockopt+0x257/0x3e0 net/socket.c:2296
__sys_setsockopt net/socket.c:2321 [inline]
__do_sys_setsockopt net/socket.c:2327 [inline]
__se_sys_setsockopt net/socket.c:2324 [inline]
__x64_sys_setsockopt+0x18b/0x220 net/socket.c:2324
do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
do_syscall_64+0xf6/0x210 arch/x86/entry/syscall_64.c:94
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f5caf78e969
Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f5cb05b8038 EFLAGS: 00000246 ORIG_RAX: 0000000000000036
RAX: ffffffffffffffda RBX: 00007f5caf9b6160 RCX: 00007f5caf78e969
RDX: 000000000000000d RSI: 0000000000000107 RDI: 0000000000000006
RBP: 00007f5caf810ab1 R08: 0000000000000010 R09: 0000000000000000
R10: 00002000000000c0 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 00007f5caf9b6160 R15: 00007ffcbfd04a48
---[ end trace ]---
----------------
Code disassembly (best guess):
0: 00 00 add %al,(%rax)
2: 00 00 add %al,(%rax)
4: 9c pushf
5: 8f 44 24 30 pop 0x30(%rsp)
9: f7 44 24 30 00 02 00 testl $0x200,0x30(%rsp)
10: 00
11: 0f 85 cd 00 00 00 jne 0xe4
17: f7 44 24 08 00 02 00 testl $0x200,0x8(%rsp)
1e: 00
1f: 74 01 je 0x22
21: fb sti
22: 65 48 8b 05 1b b3 d7 mov %gs:0x10d7b31b(%rip),%rax # 0x10d7b345
29: 10
* 2a: 48 3b 44 24 58 cmp 0x58(%rsp),%rax <-- trapping instruction
2f: 0f 85 f2 00 00 00 jne 0x127
35: 48 83 c4 60 add $0x60,%rsp
39: 5b pop %rbx
3a: 41 5c pop %r12
3c: 41 5d pop %r13
3e: 41 5e pop %r14