[Stgt-devel] [PATCH] iscsi no zero data buffer
Pete Wyckoff
pw
Mon Jul 30 19:31:10 CEST 2007
Avoid zeroing out all the bytes of every incoming and outgoing data
buffer. This has a measurable performance impact.
Signed-off-by: Pete Wyckoff <pw at osc.edu>
---
usr/iscsi/iscsid.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/usr/iscsi/iscsid.c b/usr/iscsi/iscsid.c
index 8fd9099..ae840ad 100644
--- a/usr/iscsi/iscsid.c
+++ b/usr/iscsi/iscsid.c
@@ -966,9 +966,10 @@ iscsi_alloc_task(struct iscsi_connection *conn, int ext_len)
struct iscsi_hdr *req = (struct iscsi_hdr *) &conn->req.bhs;
struct iscsi_task *task;
- task = zalloc(sizeof(*task) + ext_len);
+ task = malloc(sizeof(*task) + ext_len);
if (!task)
return NULL;
+ memset(task, 0, sizeof(*task));
memcpy(&task->req, req, sizeof(*req));
task->conn = conn;
--
1.5.2.4
More information about the stgt
mailing list