linux-stable/drivers/xen
Dan Carpenter a663874605 xen, cpu_hotplug: Prevent an out of bounds access
[ Upstream commit 201676095d ]

The "cpu" variable comes from the sscanf() so Smatch marks it as
untrusted data.  We can't pass a higher value than "nr_cpu_ids" to
cpu_possible() or it results in an out of bounds access.

Fixes: d68d82afd4 ("xen: implement CPU hotplugging")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Juergen Gross <jgross@suse.com>
Signed-off-by: Juergen Gross <jgross@suse.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-01-27 14:50:31 +01:00
..
events
xen-pciback xen/pciback: Check dev_data before using it 2019-12-05 09:20:26 +01:00
xenbus
xenfs
acpi.c
arm-device.c
balloon.c xen/balloon: fix ballooned page accounting without hotplug enabled 2020-01-09 10:18:58 +01:00
biomerge.c
cpu_hotplug.c xen, cpu_hotplug: Prevent an out of bounds access 2020-01-27 14:50:31 +01:00
dbgp.c
efi.c
evtchn.c
fallback.c
features.c
gntalloc.c
gntdev-common.h
gntdev-dmabuf.c
gntdev-dmabuf.h
gntdev.c
grant-table.c
Kconfig xen/gntdev: Use select for DMA_SHARED_BUFFER 2019-12-31 16:35:50 +01:00
Makefile
manage.c
mcelog.c
mem-reservation.c
pci.c
pcpu.c
platform-pci.c
preempt.c
privcmd-buf.c
privcmd.c
privcmd.h
pvcalls-back.c
pvcalls-front.c pvcalls-front: don't return error when the ring is full 2019-12-17 20:35:32 +01:00
pvcalls-front.h
swiotlb-xen.c
sys-hypervisor.c
time.c
tmem.c
xen-acpi-cpuhotplug.c
xen-acpi-memhotplug.c
xen-acpi-pad.c
xen-acpi-processor.c
xen-balloon.c
xen-scsiback.c
xen-selfballoon.c
xen-stub.c
xlate_mmu.c