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

Commit 6470f2ba authored by Arne Redlich's avatar Arne Redlich Committed by James Bottomley
Browse files

[SCSI] trivial scsi_execute_async fix



In scsi_execute_async()'s error path, a struct scsi_io_context
allocated with kmem_cache_alloc() is kfree()'d. Obviously
kmem_cache_free() should be used instead.

Signed-off-by: default avatarArne Redlich <arne.redlich@xiranet.com>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@SteelEye.com>
parent fb4f66be
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -424,7 +424,7 @@ int scsi_execute_async(struct scsi_device *sdev, const unsigned char *cmd,
free_req:
free_req:
	blk_put_request(req);
	blk_put_request(req);
free_sense:
free_sense:
	kfree(sioc);
	kmem_cache_free(scsi_io_context_cache, sioc);
	return DRIVER_ERROR << 24;
	return DRIVER_ERROR << 24;
}
}
EXPORT_SYMBOL_GPL(scsi_execute_async);
EXPORT_SYMBOL_GPL(scsi_execute_async);