Commit 66bbe0ce authored by Mike Christie's avatar Mike Christie Committed by James Bottomley

[SCSI] iscsi_tcp: enable sg chaining

The previous patches converted iscsi_tcp to support sg chaining.
This patch sets the proper flags and sets sg_table size to
4096. This allows fs io to be capped at max_sectors, but passthrough
IO to be limited by some other part of the kernel.
Signed-off-by: default avatarMike Christie <michaelc@cs.wisc.edu>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@HansenPartnership.com>
parent 4cd49ea1
...@@ -1928,13 +1928,14 @@ static struct scsi_host_template iscsi_sht = { ...@@ -1928,13 +1928,14 @@ static struct scsi_host_template iscsi_sht = {
.queuecommand = iscsi_queuecommand, .queuecommand = iscsi_queuecommand,
.change_queue_depth = iscsi_change_queue_depth, .change_queue_depth = iscsi_change_queue_depth,
.can_queue = ISCSI_DEF_XMIT_CMDS_MAX - 1, .can_queue = ISCSI_DEF_XMIT_CMDS_MAX - 1,
.sg_tablesize = ISCSI_SG_TABLESIZE, .sg_tablesize = 4096,
.max_sectors = 0xFFFF, .max_sectors = 0xFFFF,
.cmd_per_lun = ISCSI_DEF_CMD_PER_LUN, .cmd_per_lun = ISCSI_DEF_CMD_PER_LUN,
.eh_abort_handler = iscsi_eh_abort, .eh_abort_handler = iscsi_eh_abort,
.eh_device_reset_handler= iscsi_eh_device_reset, .eh_device_reset_handler= iscsi_eh_device_reset,
.eh_host_reset_handler = iscsi_eh_host_reset, .eh_host_reset_handler = iscsi_eh_host_reset,
.use_clustering = DISABLE_CLUSTERING, .use_clustering = DISABLE_CLUSTERING,
.use_sg_chaining = ENABLE_SG_CHAINING,
.slave_configure = iscsi_tcp_slave_configure, .slave_configure = iscsi_tcp_slave_configure,
.proc_name = "iscsi_tcp", .proc_name = "iscsi_tcp",
.this_id = -1, .this_id = -1,
...@@ -1974,7 +1975,7 @@ static struct iscsi_transport iscsi_tcp_transport = { ...@@ -1974,7 +1975,7 @@ static struct iscsi_transport iscsi_tcp_transport = {
.host_template = &iscsi_sht, .host_template = &iscsi_sht,
.conndata_size = sizeof(struct iscsi_conn), .conndata_size = sizeof(struct iscsi_conn),
.max_conn = 1, .max_conn = 1,
.max_cmd_len = ISCSI_TCP_MAX_CMD_LEN, .max_cmd_len = 16,
/* session management */ /* session management */
.create_session = iscsi_tcp_session_create, .create_session = iscsi_tcp_session_create,
.destroy_session = iscsi_tcp_session_destroy, .destroy_session = iscsi_tcp_session_destroy,
......
...@@ -24,9 +24,6 @@ ...@@ -24,9 +24,6 @@
#include <scsi/libiscsi.h> #include <scsi/libiscsi.h>
#define ISCSI_SG_TABLESIZE SG_ALL
#define ISCSI_TCP_MAX_CMD_LEN 16
struct crypto_hash; struct crypto_hash;
struct socket; struct socket;
struct iscsi_tcp_conn; struct iscsi_tcp_conn;
......
Markdown is supported
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