From owner-svn-src-all@FreeBSD.ORG Wed May 7 07:31:26 2014 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 33E8351B; Wed, 7 May 2014 07:31:26 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 06E15FAF; Wed, 7 May 2014 07:31:26 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s477VPcs018531; Wed, 7 May 2014 07:31:25 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s477VP4k018525; Wed, 7 May 2014 07:31:25 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201405070731.s477VP4k018525@svn.freebsd.org> From: Edward Tomasz Napierala Date: Wed, 7 May 2014 07:31:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r265508 - in stable/10/sys: cam/ctl dev/iscsi X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 May 2014 07:31:26 -0000 Author: trasz Date: Wed May 7 07:31:25 2014 New Revision: 265508 URL: http://svnweb.freebsd.org/changeset/base/265508 Log: MFC r264525: Add some stuff to make it easier to figure out for the system administrator whether the ICL_KERNEL_PROXY stuff got compiled in correctly. Sponsored by: The FreeBSD Foundation Modified: stable/10/sys/cam/ctl/ctl_frontend_iscsi.c stable/10/sys/cam/ctl/ctl_ioctl.h stable/10/sys/dev/iscsi/iscsi.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/cam/ctl/ctl_frontend_iscsi.c ============================================================================== --- stable/10/sys/cam/ctl/ctl_frontend_iscsi.c Wed May 7 07:29:39 2014 (r265507) +++ stable/10/sys/cam/ctl/ctl_frontend_iscsi.c Wed May 7 07:31:25 2014 (r265508) @@ -75,6 +75,10 @@ __FBSDID("$FreeBSD$"); #include #endif +#ifdef ICL_KERNEL_PROXY +FEATURE(cfiscsi_kernel_proxy, "iSCSI target built with ICL_KERNEL_PROXY"); +#endif + static MALLOC_DEFINE(M_CFISCSI, "cfiscsi", "Memory used for CTL iSCSI frontend"); static uma_zone_t cfiscsi_data_wait_zone; @@ -1960,7 +1964,18 @@ cfiscsi_ioctl(struct cdev *dev, case CTL_ISCSI_CLOSE: cfiscsi_ioctl_close(ci); break; -#endif /* ICL_KERNEL_PROXY */ +#else + case CTL_ISCSI_LISTEN: + case CTL_ISCSI_ACCEPT: + case CTL_ISCSI_SEND: + case CTL_ISCSI_RECEIVE: + case CTL_ISCSI_CLOSE: + ci->status = CTL_ISCSI_ERROR; + snprintf(ci->error_str, sizeof(ci->error_str), + "%s: CTL compiled without ICL_KERNEL_PROXY", + __func__); + break; +#endif /* !ICL_KERNEL_PROXY */ default: ci->status = CTL_ISCSI_ERROR; snprintf(ci->error_str, sizeof(ci->error_str), Modified: stable/10/sys/cam/ctl/ctl_ioctl.h ============================================================================== --- stable/10/sys/cam/ctl/ctl_ioctl.h Wed May 7 07:29:39 2014 (r265507) +++ stable/10/sys/cam/ctl/ctl_ioctl.h Wed May 7 07:31:25 2014 (r265508) @@ -617,7 +617,11 @@ typedef enum { CTL_ISCSI_LIST, CTL_ISCSI_LOGOUT, CTL_ISCSI_TERMINATE, -#ifdef ICL_KERNEL_PROXY +#if defined(ICL_KERNEL_PROXY) || 1 + /* + * We actually need those in all cases, but leave the ICL_KERNEL_PROXY, + * to remember to remove them along with rest of proxy code, eventually. + */ CTL_ISCSI_LISTEN, CTL_ISCSI_ACCEPT, CTL_ISCSI_SEND, Modified: stable/10/sys/dev/iscsi/iscsi.c ============================================================================== --- stable/10/sys/dev/iscsi/iscsi.c Wed May 7 07:29:39 2014 (r265507) +++ stable/10/sys/dev/iscsi/iscsi.c Wed May 7 07:31:25 2014 (r265508) @@ -65,6 +65,10 @@ #include #endif +#ifdef ICL_KERNEL_PROXY +FEATURE(iscsi_kernel_proxy, "iSCSI initiator built with ICL_KERNEL_PROXY"); +#endif + /* * XXX: This is global so the iscsi_unload() can access it. * Think about how to do this properly.