summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authortangwenji <tang.wenji@zte.com.cn>2019-03-13 17:56:38 +0300
committerMartin K. Petersen <martin.petersen@oracle.com>2019-03-21 03:36:39 +0300
commit1ea9b4633cda461f09b4476ff612d32d78e81c92 (patch)
treefe610e6d8b9ace3930673145c7842ce617ff96c5 /drivers
parentee26724af6c71a9db786c5809395b4853edd4d54 (diff)
downloadlinux-1ea9b4633cda461f09b4476ff612d32d78e81c92.tar.xz
scsi: target: iscsi: Fix np_ip_proto and np_sock_type in iscsit_setup_np
In the switch, np_ip_proto and np_sock_type set different values according to np_network_transport, and then uniformly assign values, so the previous values are overwritten. Signed-off-by: tangwenji <tang.wenji@zte.com.cn> Reviewed-by: Mike Christie <mchristi@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/target/iscsi/iscsi_target_login.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/target/iscsi/iscsi_target_login.c b/drivers/target/iscsi/iscsi_target_login.c
index ae3209efd0e0..c526e665f022 100644
--- a/drivers/target/iscsi/iscsi_target_login.c
+++ b/drivers/target/iscsi/iscsi_target_login.c
@@ -883,9 +883,6 @@ int iscsit_setup_np(
return -EINVAL;
}
- np->np_ip_proto = IPPROTO_TCP;
- np->np_sock_type = SOCK_STREAM;
-
ret = sock_create(sockaddr->ss_family, np->np_sock_type,
np->np_ip_proto, &sock);
if (ret < 0) {