]> www.infradead.org Git - users/willy/xarray.git/commit
ipc: Convert ipcs_idr to XArray
authorMatthew Wilcox (Oracle) <willy@infradead.org>
Sun, 4 Aug 2019 11:20:30 +0000 (07:20 -0400)
committerMatthew Wilcox (Oracle) <willy@infradead.org>
Fri, 9 Aug 2019 01:38:13 +0000 (21:38 -0400)
commit81c32a6ea73941fd0196c853afda49deb8b337d6
tree4cebb752001226307428d4bd5ad1b628c5b43aa3
parentb929407240fd22e08420cb0cb8f33664ba656129
ipc: Convert ipcs_idr to XArray

The XArray has better loops than the IDR has, removing the need to
open-code them.  We also don't need to call idr_destroy() any more.
Allocating the ID is a little tricky due to needing to get 'seq'
correct.  Open-code a variant of __xa_alloc() which lets us set the
ID and the seq before depositing the pointer in the array.

Signed-off-by: Matthew Wilcox <willy@infradead.org>
include/linux/ipc_namespace.h
include/linux/xarray.h
ipc/ipc_sysctl.c
ipc/msg.c
ipc/namespace.c
ipc/sem.c
ipc/shm.c
ipc/util.c
ipc/util.h
lib/xarray.c