summaryrefslogtreecommitdiffstats
path: root/virt
diff options
context:
space:
mode:
authorGuillaume Nault <gnault@redhat.com>2020-01-13 22:39:20 +0100
committerDavid S. Miller <davem@davemloft.net>2020-01-14 11:28:40 -0800
commit4905294162bda43bef65b411cf791005c7e15b28 (patch)
tree9af0ba1fed79d65b4c30438d9f274a6f2df35b39 /virt
parent621400366bdba122b37bfa5f5a64ebfd07919a4a (diff)
downloadlinux-4905294162bda43bef65b411cf791005c7e15b28.tar.gz
linux-4905294162bda43bef65b411cf791005c7e15b28.tar.bz2
linux-4905294162bda43bef65b411cf791005c7e15b28.zip
netns: Remove __peernet2id_alloc()
__peernet2id_alloc() was used for both plain lookups and for netns ID allocations (depending the value of '*alloc'). Let's separate lookups from allocations instead. That is, integrate the lookup code into __peernet2id() and make peernet2id_alloc() responsible for allocating new netns IDs when necessary. This makes it clear that __peernet2id() doesn't modify the idr and prepares the code for lockless lookups. Also, mark the 'net' argument of __peernet2id() as 'const', since we're modifying this line. Signed-off-by: Guillaume Nault <gnault@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'virt')
0 files changed, 0 insertions, 0 deletions