Skip to content
Commit 7403bd14 authored by Jia-Ju Bai's avatar Jia-Ju Bai Committed by Lorenzo Pieralisi
Browse files

PCI: hv: Replace GFP_ATOMIC with GFP_KERNEL in new_pcichild_device()



new_pcichild_device() is not called in atomic context.

The call chain ending up at new_pcichild_device() is:
[1] new_pcichild_device() <- pci_devices_present_work()
pci_devices_present_work() is only set in INIT_WORK().

Despite never getting called from atomic context,
new_pcichild_device() calls kzalloc with GFP_ATOMIC,
which waits busily for allocation.

GFP_ATOMIC is not necessary and can be replaced with GFP_KERNEL
to avoid busy waiting.

Signed-off-by: default avatarJia-Ju Bai <baijiaju1990@gmail.com>
[lorenzo.pieralisi@arm.com: reworked commit log]
Signed-off-by: default avatarLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Reviewed-by: default avatarMichael Kelley <mikelley@microsoft.com>
parent ce397d21
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment