linux/drivers
Andrey Konovalov 46850ae936 UPSTREAM: vfio/type1: untag user pointers in vaddr_get_pfn
(Upstream commit 6cf5354c1c).

This patch is a part of a series that extends kernel ABI to allow to pass
tagged user pointers (with the top byte set to something else other than
0x00) as syscall arguments.

vaddr_get_pfn() uses provided user pointers for vma lookups, which can
only by done with untagged pointers.

Untag user pointers in this function.

Link: http://lkml.kernel.org/r/87422b4d72116a975896f2b19b00f38acbd28f33.1563904656.git.andreyknvl@google.com
Signed-off-by: Andrey Konovalov <andreyknvl@google.com>
Reviewed-by: Eric Auger <eric.auger@redhat.com>
Reviewed-by: Vincenzo Frascino <vincenzo.frascino@arm.com>
Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Cc: Dave Hansen <dave.hansen@intel.com>
Cc: Will Deacon <will@kernel.org>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: Felix Kuehling <Felix.Kuehling@amd.com>
Cc: Jens Wiklander <jens.wiklander@linaro.org>
Cc: Khalid Aziz <khalid.aziz@oracle.com>
Cc: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Cc: Mike Rapoport <rppt@linux.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Andrey Konovalov <andreyknvl@google.com>
Bug: 135692346
Change-Id: Ic4a7b673658538f7fcc5a5b76e77e574417214c7
2019-10-07 15:27:41 -04:00
..
accessibility
acpi ACPI / PCI: fix acpi_pci_irq_enable() memory leak 2019-10-05 13:09:53 +02:00
amba
android This is the 4.19.64 stable release 2019-08-04 09:37:11 +02:00
ata libata/ahci: Drop PCS quirk for Denverton and beyond 2019-10-05 13:09:52 +02:00
atm Kconfig: Fix the reference to the IDT77105 Phy driver in the description of ATM_NICSTAR_USE_IDT77105 2019-09-21 07:16:57 +02:00
auxdisplay auxdisplay: panel: need to delete scan_timer when misc_register fails in panel_attach 2019-09-06 10:21:56 +02:00
base This is the 4.19.78 stable release 2019-10-07 19:17:35 +02:00
bcma
block This is the 4.19.78 stable release 2019-10-07 19:17:35 +02:00
bluetooth Bluetooth: btrtl: Additional Realtek 8822CE Bluetooth devices 2019-10-01 08:26:12 +02:00
bus bus: ti-sysc: Simplify cleanup upon failures in sysc_probe() 2019-09-21 07:16:51 +02:00
cdrom cdrom: Fix race condition in cdrom_sysctl_register 2019-04-05 22:33:10 +02:00
char This is the 4.19.78 stable release 2019-10-07 19:17:35 +02:00
clk clk: sprd: add missing kfree 2019-10-07 18:57:03 +02:00
clocksource clocksource/drivers/exynos_mct: Increase priority over ARM arch timer 2019-07-26 09:14:12 +02:00
connector connector: fix unsafe usage of ->real_parent 2019-03-19 13:12:38 +01:00
cpufreq This is the 4.19.67 stable release 2019-08-16 11:27:10 +02:00
cpuidle BACKPORT: sched: loadavg: consolidate LOAD_INT, LOAD_FRAC, CALC_LOAD 2019-03-21 16:25:26 -07:00
crypto crypto: hisilicon - Fix double free in sec_free_hw_sgl() 2019-10-07 18:57:16 +02:00
dax mm/huge_memory: fix vmf_insert_pfn_{pmd, pud}() crash, handle unaligned addresses 2019-05-22 07:37:40 +02:00
dca
devfreq PM / devfreq: passive: fix compiler warning 2019-10-05 13:09:59 +02:00
dio
dma dmaengine: ti: edma: Do not reset reserved paRAM slots 2019-10-05 13:09:54 +02:00
dma-buf This is the 4.19.78 stable release 2019-10-07 19:17:35 +02:00
edac EDAC/amd64: Decode syndrome before translating address 2019-10-05 13:09:48 +02:00
eisa
energy_model
extcon extcon: arizona: Disable mic detect if running when driver is removed 2019-05-31 06:46:23 -07:00
firewire
firmware This is the 4.19.77 stable release 2019-10-06 11:27:45 +02:00
fmc
fpga fpga: altera-ps-spi: Fix getting of optional confd gpio 2019-09-21 07:16:53 +02:00
fsi fsi: scom: Don't abort operations for minor errors 2019-09-06 10:22:19 +02:00
gnss
gpio This is the 4.19.74 stable release 2019-09-19 09:18:49 +02:00
gpu UPSTREAM: drm/radeon: untag user pointers in radeon_gem_userptr_ioctl 2019-10-07 15:27:41 -04:00
hid HID: apple: Fix stuck function keys when using FN 2019-10-07 18:57:12 +02:00
hsi
hv Drivers: hv: kvp: Fix the recent regression caused by incorrect clean-up 2019-09-16 08:21:54 +02:00
hwmon hwmon: (acpi_power_meter) Change log level for 'unsafe software power cap' 2019-10-05 13:09:54 +02:00
hwspinlock
hwtracing intel_th: pci: Add Tiger Lake support 2019-09-06 10:22:18 +02:00
i2c i2c-cht-wc: Fix lockdep warning 2019-10-07 18:57:08 +02:00
ide
idle x86/cpu: Sanitize FAM6_ATOM naming 2019-05-14 19:17:53 +02:00
iio This is the 4.19.74 stable release 2019-09-19 09:18:49 +02:00
infiniband This is the 4.19.77 stable release 2019-10-06 11:27:45 +02:00
input Input: elan_i2c - remove Lenovo Legion Y7000 PnpID 2019-09-21 07:16:41 +02:00
iommu iommu/amd: Override wrong IVRS IOAPIC on Raven Ridge systems 2019-10-05 13:09:59 +02:00
ipack
irqchip irqchip/gic-v3-its: Fix LPI release for Multi-MSI devices 2019-10-01 08:26:08 +02:00
isdn mISDN: enforce CAP_NET_RAW for raw sockets 2019-10-05 13:09:31 +02:00
leds led: triggers: Fix a memory leak bug 2019-10-05 13:09:45 +02:00
lightnvm lightnvm: pblk: fix freeing of merged pages 2019-07-26 09:14:09 +02:00
macintosh
mailbox mbox: qcom: add APCS child device for QCS404 2019-10-07 18:57:02 +02:00
mcb
md This is the 4.19.77 stable release 2019-10-06 11:27:45 +02:00
media UPSTREAM: media/v4l2-core: untag user pointers in videobuf_dma_contig_user_get 2019-10-07 15:27:41 -04:00
memory memory: tegra: Fix integer overflow on tick value calculation 2019-05-25 18:23:32 +02:00
memstick memstick: Fix error cleanup path of memstick_init 2019-07-31 07:26:59 +02:00
message
mfd mfd: intel-lpss: Remove D3cold delay 2019-10-07 18:57:08 +02:00
misc This is the 4.19.70 stable release 2019-09-06 12:08:42 +02:00
mmc This is the 4.19.77 stable release 2019-10-06 11:27:45 +02:00
mtd mtd: cfi_cmdset_0002: Use chip_good() to retry in do_write_oneword() 2019-10-01 08:26:02 +02:00
mux
net This is the 4.19.78 stable release 2019-10-07 19:17:35 +02:00
nfc st_nci_hci_connectivity_event_received: null check the allocation 2019-08-29 08:28:31 +02:00
ntb
nubus
nvdimm libnvdimm/bus: Fix wait_nvdimm_bus_probe_idle() ABBA deadlock 2019-08-09 17:52:28 +02:00
nvme nvme-multipath: fix ana log nsid lookup when nsid is not found 2019-10-05 13:09:52 +02:00
nvmem nvmem: Use the same permissions for eeprom as for nvmem 2019-09-19 09:09:41 +02:00
of This is the 4.19.49 stable release 2019-06-09 09:27:18 +02:00
opp
oprofile
parisc parisc: Disable HP HSC-PCI Cards to prevent kernel crash 2019-10-05 13:10:04 +02:00
parport parport: Fix mem leak in parport_register_dev_model 2019-06-25 11:35:55 +08:00
pci PCI: exynos: Propagate errors for optional PHYs 2019-10-07 18:57:13 +02:00
pcmcia
perf drivers/perf: arm_pmu: Fix failure path in PM notifier 2019-08-06 19:06:55 +02:00
phy phy: renesas: rcar-gen3-usb2: Disable clearing VBUS in over-current 2019-09-21 07:16:42 +02:00
pinctrl pinctrl: meson-gxbb: Fix wrong pinning definition for uart_c 2019-10-07 18:57:00 +02:00
platform platform/x86: intel_pmc_core: Do not ioremap RAM 2019-10-05 13:09:55 +02:00
pnp
power power: supply: sysfs: ratelimit property read error message 2019-10-01 08:26:07 +02:00
powercap x86/cpu: Sanitize FAM6_ATOM naming 2019-05-14 19:17:53 +02:00
pps drivers/pps/pps.c: clear offset flags in PPS_SETPARAMS ioctl 2019-08-04 09:30:56 +02:00
ps3
ptp
pwm Revert "pwm: Set class for exported channels in sysfs" 2019-08-25 10:47:46 +02:00
rapidio drivers/rapidio/devices/rio_mport_cdev.c: NUL terminate some strings 2019-08-06 19:06:52 +02:00
ras RAS/CEC: Fix pfn insertion 2019-07-26 09:14:05 +02:00
regulator regulator: Defer init completion for a while after late_initcall 2019-10-05 13:10:07 +02:00
remoteproc remoteproc: qcom: q6v5-mss: add SCM probe dependency 2019-09-16 08:21:48 +02:00
reset reset: meson-audio-arb: Fix missing .owner setting of reset_controller_dev 2019-05-08 07:21:47 +02:00
rpmsg
rtc rtc: pcf85363/pcf85263: fix regmap error in set_time 2019-10-07 18:57:12 +02:00
s390 virtio/s390: fix race on airq_areas[] 2019-09-16 08:22:23 +02:00
sbus
scsi scsi: core: Reduce memory required for SCSI logging 2019-10-07 18:57:04 +02:00
sfi
sh
siox
slimbus slimbus: fix a potential NULL pointer dereference in of_qcom_slim_ngd_register 2019-05-31 06:46:14 -07:00
sn
soc soc: bcm: brcmstb: biuctrl: Register writes require a barrier 2019-07-14 08:11:03 +02:00
soundwire soundwire: fix regmap dependencies and align with other serial links 2019-10-07 18:57:27 +02:00
spi This is the 4.19.73 stable release 2019-09-16 09:35:02 +02:00
spmi
ssb ssb: Fix possible NULL pointer dereference in ssb_host_pcmcia_exit 2019-05-31 06:46:04 -07:00
staging media: imx: mipi csi-2: Don't fail if initial state times-out 2019-10-05 13:09:43 +02:00
target scsi: target/iblock: Fix overrun in WRITE SAME emulation 2019-09-16 08:22:17 +02:00
tc
tee UPSTREAM: tee/shm: untag user pointers in tee_shm_register 2019-10-07 15:27:41 -04:00
thermal This is the 4.19.51 stable release 2019-06-15 16:12:59 +02:00
thunderbolt thunderbolt: property: Fix a NULL pointer dereference 2019-05-31 06:46:31 -07:00
tty tty/serial: atmel: reschedule TX after RX was started 2019-09-21 07:16:45 +02:00
uio
usb ANDROID: usb: gadget: Fix dependency for f_accessory 2019-10-01 13:58:10 +00:00
uwb
vfio UPSTREAM: vfio/type1: untag user pointers in vaddr_get_pfn 2019-10-07 15:27:41 -04:00
vhost vhost: make sure log_num < in_num 2019-09-16 08:22:25 +02:00
video video: ssd1307fb: Start page range at page_offset 2019-10-07 18:56:30 +02:00
virt drivers/virt/fsl_hypervisor.c: prevent integer overflow in ioctl 2019-05-16 19:41:31 +02:00
virtio virtio_pci: fix a NULL pointer reference in vp_del_vqs 2019-05-10 17:54:08 +02:00
visorbus
vlynq
vme
w1 w1: fix the resume command API 2019-05-31 06:46:14 -07:00
watchdog watchdog: bcm2835_wdt: Fix module autoload 2019-09-06 10:22:02 +02:00
xen xen/pciback: remove set but not used variable 'old_state' 2019-08-25 10:47:52 +02:00
zorro
Kconfig
Makefile