Thread (12 messages) 12 messages, 3 authors, 2022-01-28

Re: [PATCH net] net: dev: Detect dev_hold() after netdev_wait_allrefs()

From: Eric Dumazet <edumazet@google.com>
Date: 2022-01-28 02:30:17
Also in: lkml

On Thu, Jan 27, 2022 at 6:27 PM Jann Horn [off-list ref] wrote:
I like that idea... but this_cpu_dec()/this_cpu_inc() use GS-relative
addressing, at least on X86-64, so NULL might make things worse, I
think? /proc/kallsyms on my machine starts with:

0000000000000000 A fixed_percpu_data
0000000000000000 A __per_cpu_start
0000000000001000 A cpu_debug_store
0000000000002000 A irq_stack_backing_store
0000000000006000 A cpu_tss_rw
000000000000b000 A gdt_page
000000000000c000 A exception_stacks
0000000000010000 A entry_stack_storage
0000000000011000 A espfix_waddr

So we'd probably need some different placeholder instead of NULL to
actually crash...
Orthogonal problem, maybe we should make sure the first page of
per-cpu data is un-mapped.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help