iscsi.c (265500) | iscsi.c (265501) |
---|---|
1/*- 2 * Copyright (c) 2012 The FreeBSD Foundation 3 * All rights reserved. 4 * 5 * This software was developed by Edward Tomasz Napierala under sponsorship 6 * from the FreeBSD Foundation. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 12 unchanged lines hidden (view full) --- 21 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 * SUCH DAMAGE. 28 * | 1/*- 2 * Copyright (c) 2012 The FreeBSD Foundation 3 * All rights reserved. 4 * 5 * This software was developed by Edward Tomasz Napierala under sponsorship 6 * from the FreeBSD Foundation. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 12 unchanged lines hidden (view full) --- 21 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 * SUCH DAMAGE. 28 * |
29 * $FreeBSD: stable/10/sys/dev/iscsi/iscsi.c 265500 2014-05-07 06:44:19Z trasz $ | 29 * $FreeBSD: stable/10/sys/dev/iscsi/iscsi.c 265501 2014-05-07 06:46:59Z trasz $ |
30 */ 31 32#include <sys/param.h> 33#include <sys/condvar.h> 34#include <sys/conf.h> 35#include <sys/eventhandler.h> 36#include <sys/file.h> 37#include <sys/kernel.h> --- 31 unchanged lines hidden (view full) --- 69 * XXX: This is global so the iscsi_unload() can access it. 70 * Think about how to do this properly. 71 */ 72static struct iscsi_softc *sc; 73 74SYSCTL_NODE(_kern, OID_AUTO, iscsi, CTLFLAG_RD, 0, "iSCSI initiator"); 75static int debug = 1; 76TUNABLE_INT("kern.iscsi.debug", &debug); | 30 */ 31 32#include <sys/param.h> 33#include <sys/condvar.h> 34#include <sys/conf.h> 35#include <sys/eventhandler.h> 36#include <sys/file.h> 37#include <sys/kernel.h> --- 31 unchanged lines hidden (view full) --- 69 * XXX: This is global so the iscsi_unload() can access it. 70 * Think about how to do this properly. 71 */ 72static struct iscsi_softc *sc; 73 74SYSCTL_NODE(_kern, OID_AUTO, iscsi, CTLFLAG_RD, 0, "iSCSI initiator"); 75static int debug = 1; 76TUNABLE_INT("kern.iscsi.debug", &debug); |
77SYSCTL_INT(_kern_iscsi, OID_AUTO, debug, CTLFLAG_RW, | 77SYSCTL_INT(_kern_iscsi, OID_AUTO, debug, CTLFLAG_RWTUN, |
78 &debug, 2, "Enable debug messages"); 79static int ping_timeout = 5; 80TUNABLE_INT("kern.iscsi.ping_timeout", &ping_timeout); | 78 &debug, 2, "Enable debug messages"); 79static int ping_timeout = 5; 80TUNABLE_INT("kern.iscsi.ping_timeout", &ping_timeout); |
81SYSCTL_INT(_kern_iscsi, OID_AUTO, ping_timeout, CTLFLAG_RW, &ping_timeout, | 81SYSCTL_INT(_kern_iscsi, OID_AUTO, ping_timeout, CTLFLAG_RWTUN, &ping_timeout, |
82 5, "Timeout for ping (NOP-Out) requests, in seconds"); 83static int iscsid_timeout = 60; 84TUNABLE_INT("kern.iscsi.iscsid_timeout", &iscsid_timeout); | 82 5, "Timeout for ping (NOP-Out) requests, in seconds"); 83static int iscsid_timeout = 60; 84TUNABLE_INT("kern.iscsi.iscsid_timeout", &iscsid_timeout); |
85SYSCTL_INT(_kern_iscsi, OID_AUTO, iscsid_timeout, CTLFLAG_RW, &iscsid_timeout, | 85SYSCTL_INT(_kern_iscsi, OID_AUTO, iscsid_timeout, CTLFLAG_RWTUN, &iscsid_timeout, |
86 60, "Time to wait for iscsid(8) to handle reconnection, in seconds"); 87static int login_timeout = 60; 88TUNABLE_INT("kern.iscsi.login_timeout", &login_timeout); | 86 60, "Time to wait for iscsid(8) to handle reconnection, in seconds"); 87static int login_timeout = 60; 88TUNABLE_INT("kern.iscsi.login_timeout", &login_timeout); |
89SYSCTL_INT(_kern_iscsi, OID_AUTO, login_timeout, CTLFLAG_RW, &login_timeout, | 89SYSCTL_INT(_kern_iscsi, OID_AUTO, login_timeout, CTLFLAG_RWTUN, &login_timeout, |
90 60, "Time to wait for iscsid(8) to finish Login Phase, in seconds"); 91static int maxtags = 255; 92TUNABLE_INT("kern.iscsi.maxtags", &maxtags); | 90 60, "Time to wait for iscsid(8) to finish Login Phase, in seconds"); 91static int maxtags = 255; 92TUNABLE_INT("kern.iscsi.maxtags", &maxtags); |
93SYSCTL_INT(_kern_iscsi, OID_AUTO, maxtags, CTLFLAG_RW, &maxtags, | 93SYSCTL_INT(_kern_iscsi, OID_AUTO, maxtags, CTLFLAG_RWTUN, &maxtags, |
94 255, "Max number of IO requests queued"); 95 96static MALLOC_DEFINE(M_ISCSI, "iSCSI", "iSCSI initiator"); 97static uma_zone_t iscsi_outstanding_zone; 98 99#define CONN_SESSION(X) ((struct iscsi_session *)X->ic_prv0) 100#define PDU_SESSION(X) (CONN_SESSION(X->ip_conn)) 101 --- 2107 unchanged lines hidden --- | 94 255, "Max number of IO requests queued"); 95 96static MALLOC_DEFINE(M_ISCSI, "iSCSI", "iSCSI initiator"); 97static uma_zone_t iscsi_outstanding_zone; 98 99#define CONN_SESSION(X) ((struct iscsi_session *)X->ic_prv0) 100#define PDU_SESSION(X) (CONN_SESSION(X->ip_conn)) 101 --- 2107 unchanged lines hidden --- |