mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 19:51:31 -04:00
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: Jia-Ju Bai <[email protected]> [[email protected]: reworked commit log] Signed-off-by: Lorenzo Pieralisi <[email protected]> Reviewed-by: Michael Kelley <[email protected]>
This commit is contained in:
parent
ce397d215c
commit
7403bd14d7
1 changed files with 1 additions and 1 deletions
|
|
@ -1543,7 +1543,7 @@ static struct hv_pci_dev *new_pcichild_device(struct hv_pcibus_device *hbus,
|
|||
unsigned long flags;
|
||||
int ret;
|
||||
|
||||
hpdev = kzalloc(sizeof(*hpdev), GFP_ATOMIC);
|
||||
hpdev = kzalloc(sizeof(*hpdev), GFP_KERNEL);
|
||||
if (!hpdev)
|
||||
return NULL;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue