Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bc7accec authored by Mike Christie's avatar Mike Christie Committed by James Bottomley
Browse files

[SCSI] be2iscsi: fix gfp use in alloc_pdu



The pdu allication callout is called from a spin lock
and in the IO path so we cannot use GFP_KERNEL. This
has the driver use GFP_ATOMIC.

Signed-off-by: default avatarMike Christie <michaelc@cs.wisc.edu>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@suse.de>
parent df4da5cd
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -3785,7 +3785,7 @@ static int beiscsi_alloc_pdu(struct iscsi_task *task, uint8_t opcode)
	dma_addr_t paddr;
	dma_addr_t paddr;


	io_task->cmd_bhs = pci_pool_alloc(beiscsi_sess->bhs_pool,
	io_task->cmd_bhs = pci_pool_alloc(beiscsi_sess->bhs_pool,
					  GFP_KERNEL, &paddr);
					  GFP_ATOMIC, &paddr);
	if (!io_task->cmd_bhs)
	if (!io_task->cmd_bhs)
		return -ENOMEM;
		return -ENOMEM;
	io_task->bhs_pa.u.a64.address = paddr;
	io_task->bhs_pa.u.a64.address = paddr;