android_kernel_xiaomi_sm8350/drivers
Roland Dreier 9ead190bfd IB/uverbs: Don't serialize with ib_uverbs_idr_mutex
Currently, all userspace verbs operations that call into the kernel
are serialized by ib_uverbs_idr_mutex.  This can be a scalability
issue for some workloads, especially for devices driven by the ipath
driver, which needs to call into the kernel even for datapath
operations.

Fix this by adding reference counts to the userspace objects, and then
converting ib_uverbs_idr_mutex into a spinlock that only protects the
idrs long enough to take a reference on the object being looked up.
Because remove operations may fail, we have to do a slightly funky
two-step deletion, which is described in the comments at the top of
uverbs_cmd.c.

This also still leaves ib_uverbs_idr_lock as a single lock that is
possibly subject to contention.  However, the lock hold time will only
be a single idr operation, so multiple threads should still be able to
make progress, even if ib_uverbs_idr_lock is being ping-ponged.

Surprisingly, these changes even shrink the object code:

add/remove: 23/5 grow/shrink: 4/21 up/down: 633/-693 (-60)

Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-06-17 20:44:49 -07:00
..
acorn
acpi [PATCH] powernow-k8 crash workaround 2006-06-10 11:02:05 -07:00
amba
atm
base [PATCH] revert "swsusp add check for suspension of X controlled devices" 2006-05-31 16:27:11 -07:00
block
bluetooth
cdrom [PATCH] fix cdrom open 2006-06-17 10:44:26 -07:00
char [PATCH] Fix for the PPTP hangs that have been reported 2006-06-11 20:40:39 -07:00
connector
cpufreq
crypto
dio
edac
eisa
fc4
firmware
hwmon
i2c [PATCH] scx200_acb: fix section mismatch warning 2006-05-26 11:55:46 -07:00
ide [PATCH] sgiioc4: use mmio ops instead of port io 2006-05-31 16:27:11 -07:00
ieee1394 [PATCH] sbp2: fix check of return value of hpsb_allocate_and_register_addrspace() 2006-06-05 12:29:16 -07:00
infiniband IB/uverbs: Don't serialize with ib_uverbs_idr_mutex 2006-06-17 20:44:49 -07:00
input Input: psmouse - DMI updates for lifebook protocol 2006-05-29 23:31:12 -04:00
isdn [PATCH] Overrun in isdn_tty.c 2006-05-21 12:59:18 -07:00
leds
macintosh
mca
md [PATCH] md: Fix badness in sysfs_notify caused by md_new_event 2006-05-31 16:27:11 -07:00
media [PATCH] V4L/DVB (4045): Fixes recursive dependency for I2C 2006-05-24 18:48:28 -07:00
message Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6 2006-06-10 11:03:51 -07:00
mfd
misc
mmc [MMC] Prevent au1xmmc.c breakage on non-Au1200 Alchemy 2006-06-04 17:40:58 +01:00
mtd
net [PATCH] sky2: netconsole suspend/resume interaction 2006-06-17 10:52:12 -07:00
nubus
oprofile
parisc
parport
pci [PATCH] PCI: reverse pci config space restore order 2006-06-11 14:02:27 -07:00
pcmcia [PATCH] pcmcia: missing pcmcia_get_socket() result check 2006-06-02 00:56:17 +02:00
pnp
rapidio
rtc [PATCH] m48t86: ia64 build fix 2006-06-05 12:29:17 -07:00
s390 [PATCH] s390: cio non-unique path group ids 2006-06-05 12:29:16 -07:00
sbus
scsi [PATCH] sata_mv: grab host lock inside eng_timeout 2006-06-11 23:03:18 -04:00
serial [PATCH] ppc32 CPM_UART: various fixes for pq2 uart users 2006-05-26 22:38:56 +10:00
sh
sn
spi [PATCH] s3c24xx: fix spi driver with CONFIG_PM 2006-05-26 11:55:46 -07:00
tc
telephony
usb [ARM] 3547/1: PXA-OHCI: Allow platforms to specify a power budget 2006-06-08 22:44:07 +01:00
video [PATCH] fbcon: fix limited scroll in SCROLL_PAN_REDRAW mode 2006-06-08 15:12:21 -07:00
w1
zorro
Kconfig
Makefile