linux/drivers
Thomas Zimmermann a780278472 drm/gem: Acquire reservation lock in drm_gem_{pin/unpin}()
Acquire the buffer object's reservation lock in drm_gem_pin() and
remove locking the drivers' GEM callbacks where necessary. Same for
unpin().

DRM drivers and memory managers modified by this patch will now have
correct dma-buf locking semantics: the caller is responsible for
holding the reservation lock when calling the pin or unpin callback.

DRM drivers and memory managers that are not modified will now be
protected against concurent invocation of their pin and unpin callbacks.

PRIME does not implement struct dma_buf_ops.pin, which requires
the caller to hold the reservation lock. It does implement struct
dma_buf_ops.attach, which requires to callee to acquire the
reservation lock. The PRIME code uses drm_gem_pin(), so locks
are now taken as specified. Same for unpin and detach.

The patch harmonizes GEM pin and unpin to have non-interruptible
reservation locking across all drivers, as is already the case for
vmap and vunmap. This affects gem-shmem, gem-vram, loongson, qxl and
radeon.

Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Zack Rusin <zack.rusin@broadcom.com>
Reviewed-by: Dmitry Osipenko <dmitry.osipenko@collabora.com>
Tested-by: Dmitry Osipenko <dmitry.osipenko@collabora.com> # virtio-gpu
Link: https://patchwork.freedesktop.org/patch/msgid/20240227113853.8464-10-tzimmermann@suse.de
2024-03-11 13:33:50 +01:00
..
accel Merge drm/drm-next into drm-misc-next 2024-02-26 14:20:50 +01:00
accessibility
acpi acpi/ghes: Remove CXL CPER notifications 2024-02-20 22:50:52 -08:00
amba
android binder: signal epoll threads of self-work 2024-01-31 14:08:28 -08:00
ata ata: libata-core: Do not call ata_dev_power_set_standby() twice 2024-02-21 19:09:17 +01:00
atm atm: idt77252: fix a memleak in open_card_ubr0 2024-02-03 12:46:13 +00:00
auxdisplay drm-next for 6.8: 2024-01-12 11:32:19 -08:00
base Driver core fixes for 6.8-rc5 2024-02-17 08:56:41 -08:00
bcma
block block-6.8-2024-02-10 2024-02-10 08:02:48 -08:00
bluetooth USB / Thunderbolt changes for 6.8-rc1 2024-01-18 11:43:55 -08:00
bus bus: imx-weim: fix valid range check 2024-02-06 14:10:47 +08:00
cache cache: ax45mp_cache: Align end size to cache boundary in ax45mp_dma_cache_wback() 2024-02-21 16:24:10 +00:00
cdrom
cdx cdx: Unlock on error path in rescan_store() 2024-01-04 17:01:14 +01:00
char char/agp: remove agp_bridge_data::type 2024-02-16 18:07:13 +01:00
clk clk: samsung: clk-gs101: comply with the new dt cmu_misc clock names 2024-01-22 11:40:12 +01:00
clocksource
comedi
connector connector/cn_proc: revert "connector: Fix proc_event_num_listeners count not cleared" 2024-02-13 11:15:44 +01:00
counter
cpufreq cpufreq/amd-pstate: Fix setting scaling max/min freq values 2024-01-22 20:35:58 +01:00
cpuidle
crypto crypto: virtio/akcipher - Fix stack overflow on memcpy 2024-02-09 12:55:53 +08:00
cxl cxl/acpi: Fix load failures due to single window creation failure 2024-02-20 22:58:05 -08:00
dax New code for 6.8: 2024-01-10 08:45:22 -08:00
dca
devfreq
dio
dma dmaengine: at_hdmac: add missing kernel-doc style description 2024-02-02 17:16:55 +01:00
dma-buf Merge drm/drm-next into drm-misc-next 2024-02-07 13:02:20 +01:00
dpll dpll: fix possible deadlock during netlink dump operation 2024-02-08 18:29:21 -08:00
edac Driver core changes for 6.8-rc1 2024-01-18 09:48:40 -08:00
eisa
extcon
firewire firewire: core: send bus reset promptly on gap count error 2024-02-07 08:20:02 +09:00
firmware firmware/sysfb: fix an error code in sysfb_init() 2024-02-27 09:21:06 +01:00
fpga Char/Misc and other Driver changes for 6.8-rc1 2024-01-17 16:47:17 -08:00
fsi
gnss TTY/Serial changes for 6.8-rc1 2024-01-18 11:37:24 -08:00
gpio gpiolib: Handle no pin_ranges in gpiochip_generic_config() 2024-02-20 12:49:14 +01:00
gpu drm/gem: Acquire reservation lock in drm_gem_{pin/unpin}() 2024-03-11 13:33:50 +01:00
greybus TTY/Serial changes for 6.8-rc1 2024-01-18 11:37:24 -08:00
hid HID: wacom: generic: Avoid reporting a serial of '0' to userspace 2024-02-13 11:40:23 +01:00
hsi
hte
hv
hwmon hwmon: (nct6775) Fix access to temperature configuration registers 2024-02-21 13:56:33 -08:00
hwspinlock
hwtracing
i2c i2c: imx: when being a target, mark the last read as processed 2024-02-23 23:39:35 +01:00
i3c i3c: master: cdns: Update maximum prescaler value for i2c clock 2024-01-08 00:51:36 +01:00
idle Power management updates for 6.8-rc1 2024-01-09 16:32:11 -08:00
iio iio: adc: ad4130: only set GPIO_CTRL if pin is unused 2024-02-10 16:52:39 +00:00
infiniband RDMA/srpt: fix function pointer cast warnings 2024-02-14 11:15:54 +02:00
input Input updates for v6.8-rc2 2024-02-02 12:52:44 -08:00
interconnect interconnect: qcom: x1e80100: Add missing ACV enable_mask 2024-02-04 23:36:06 +02:00
iommu IOMMU Fixes for Linux v6.8-rc5 2024-02-24 15:59:26 -08:00
ipack TTY/Serial changes for 6.8-rc1 2024-01-18 11:37:24 -08:00
irqchip irqchip/gic-v3-its: Do not assume vPE tables are preallocated 2024-02-21 21:11:20 +01:00
isdn
leds - New Drivers 2024-01-17 15:25:27 -08:00
macintosh macintosh/via-pmu-backlight: Include <linux/backlight.h> 2024-03-07 13:33:34 +01:00
mailbox mediatek: add CMDQ support for mt8188 2024-01-17 15:39:32 -08:00
mcb
md - Fix DM integrity and verity targets to not use excessive stack when 2024-02-24 09:55:29 -08:00
media Linux 6.8-rc6 2024-02-26 11:41:07 +01:00
memory IOMMU Updates for Linux v6.8 2024-01-18 15:16:57 -08:00
memstick
message
mfd TTY/Serial changes for 6.8-rc1 2024-01-18 11:37:24 -08:00
misc misc: open-dice: Fix spurious lockdep warning 2024-01-30 16:20:54 -08:00
mmc mmc: slot-gpio: Allow non-sleeping GPIO ro 2024-02-06 12:35:44 +01:00
most
mtd This pull request contains updates for UBI and UBIFS: 2024-01-17 10:27:13 -08:00
mux mux: mmio: use reg property when parent device is not a syscon 2024-01-04 17:01:14 +01:00
net net: phy: realtek: Fix rtl8211f_config_init() for RTL8211F(D)(I)-VD-CG PHY 2024-02-22 09:53:54 +01:00
nfc
ntb
nubus nubus: Make nubus_bus_type static and constant 2024-01-03 13:33:59 +01:00
nvdimm virtio: features, fixes 2024-01-18 16:44:03 -08:00
nvme nvmet: remove superfluous initialization 2024-02-13 15:42:44 -08:00
nvmem nvmem: include bit index in cell sysfs file name 2024-02-14 16:28:16 +01:00
of Devicetree fixes for v6.8: 2024-02-15 10:19:55 -08:00
opp OPP: Rename 'rate_clk_single' 2024-01-05 15:55:41 +05:30
parisc parisc/power: Fix power soft-off button emulation on qemu 2024-01-07 22:59:16 +01:00
parport
pci PCI/MSI: Prevent MSI hardware interrupt number truncation 2024-02-19 16:11:01 +01:00
pcmcia
peci
perf perf: CXL: fix CPMU filter value mask length 2024-02-20 12:04:07 +00:00
phy phy: ti: phy-omap-usb2: Fix NULL pointer dereference for SRP 2024-01-30 22:41:11 +05:30
pinctrl pinctrl: amd: Add IRQF_ONESHOT to the interrupt request 2024-01-31 10:06:07 +01:00
platform platform/x86: thinkpad_acpi: Only update profile if successfully converted 2024-02-20 14:35:36 +01:00
pmdomain pmdomain: mediatek: fix race conditions with genpd 2024-01-23 13:19:15 +01:00
pnp More ACPI updates for 6.8-rc1 2024-01-17 14:37:40 -08:00
power Revert "power: supply: qcom_battmgr: Register the power supplies after PDR is up" 2024-01-26 22:45:58 +01:00
powercap
pps
ps3
ptp Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2024-01-04 18:06:46 -08:00
pwm pwm: jz4740: Don't use dev_err_probe() in .request() 2024-01-12 18:25:05 +01:00
rapidio
ras
regulator regulator (max5970): Fix IRQ handler 2024-01-30 15:27:16 +00:00
remoteproc
reset SoC: driver updates for 6.8 2024-01-11 11:31:46 -08:00
rpmsg
rtc rtc: nuvoton: Compatible with NCT3015Y-R and NCT3018Y-R 2024-01-18 01:05:33 +01:00
s390 s390 fixes for 6.8-rc6 2024-02-23 09:54:13 -08:00
sbus
scsi scsi: jazz_esp: Only build if SCSI core is builtin 2024-02-15 15:34:47 -05:00
sh maple: make maple_bus_type static and const 2024-01-04 14:37:17 +01:00
siox
slimbus
soc RISC-V SoC driver fixes for v6.8-rc6 2024-02-23 13:53:54 +01:00
soundwire soundwire updates for 6.7 2024-01-18 17:08:31 -08:00
spi spi-mxs: Fix chipselect glitch 2024-02-13 15:48:22 +00:00
spmi
ssb
staging staging/fbtft: Include <linux/backlight.h> 2024-02-28 09:59:27 +01:00
target scsi: target: pscsi: Fix bio_put() for error case 2024-02-15 14:44:07 -05:00
tc
tee Another moderately busy cycle for documentation, including: 2024-01-11 19:46:52 -08:00
thermal thermal: intel: powerclamp: Remove dead code for target mwait value 2024-01-22 11:59:22 +01:00
thunderbolt thunderbolt: Fix setting the CNS bit in ROUTER_CS_5 2024-01-29 09:48:40 +02:00
tty serial: amba-pl011: Fix DMA transmission in RS485 mode 2024-02-19 09:43:37 +01:00
ufs scsi: ufs: Uninitialized variable in ufshcd_devfreq_target() 2024-02-15 14:46:13 -05:00
uio uio: Fix use-after-free in uio_open 2024-01-04 17:03:47 +01:00
usb USB fixes for 6.8-rc6 2024-02-25 10:41:57 -08:00
vdpa virtio: features, fixes 2024-01-18 16:44:03 -08:00
vfio VFIO updates for v6.8-rc1 2024-01-18 15:57:25 -08:00
vhost virtio: features, fixes 2024-01-18 16:44:03 -08:00
video fbdev/chipsfb: Include <linux/backlight.h> 2024-03-07 13:33:34 +01:00
virt Char/Misc and other Driver changes for 6.8-rc1 2024-01-17 16:47:17 -08:00
virtio virtio: features, fixes 2024-01-18 16:44:03 -08:00
w1
watchdog linux-watchdog 6.8-rc1 tag 2024-01-12 13:32:30 -08:00
xen xen/events: close evtchn after mapping cleanup 2024-02-13 10:12:47 +01:00
zorro
Kconfig
Makefile fbdev/intelfb: Remove driver 2024-01-12 12:38:37 +01:00