From owner-svn-src-all@freebsd.org Mon Oct 5 10:44:37 2015 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 625059B1956; Mon, 5 Oct 2015 10:44:37 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.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 5456CFB1; Mon, 5 Oct 2015 10:44:37 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.70]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id t95AibF3072884; Mon, 5 Oct 2015 10:44:37 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id t95AiaOZ072881; Mon, 5 Oct 2015 10:44:36 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201510051044.t95AiaOZ072881@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Mon, 5 Oct 2015 10:44:36 +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: r288778 - stable/10/sys/cam/ctl 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.20 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: Mon, 05 Oct 2015 10:44:37 -0000 Author: mav Date: Mon Oct 5 10:44:36 2015 New Revision: 288778 URL: https://svnweb.freebsd.org/changeset/base/288778 Log: MFC r287993: Split two command flags with different meaning. This is only a cosmetical change. Modified: stable/10/sys/cam/ctl/ctl.c stable/10/sys/cam/ctl/ctl_cmd_table.c stable/10/sys/cam/ctl/ctl_private.h Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/cam/ctl/ctl.c ============================================================================== --- stable/10/sys/cam/ctl/ctl.c Mon Oct 5 10:43:45 2015 (r288777) +++ stable/10/sys/cam/ctl/ctl.c Mon Oct 5 10:44:36 2015 (r288778) @@ -11176,7 +11176,7 @@ ctl_scsiio_precheck(struct ctl_softc *so * it on the rtr queue. */ if (lun == NULL) { - if (entry->flags & CTL_CMD_FLAG_OK_ON_ALL_LUNS) { + if (entry->flags & CTL_CMD_FLAG_OK_ON_NO_LUN) { ctsio->io_hdr.flags |= CTL_FLAG_IS_WAS_ON_RTR; ctl_enqueue_rtr((union ctl_io *)ctsio); return (retval); @@ -11394,13 +11394,11 @@ ctl_cmd_applicable(uint8_t lun_type, con switch (lun_type) { case T_PROCESSOR: - if (((entry->flags & CTL_CMD_FLAG_OK_ON_PROC) == 0) && - ((entry->flags & CTL_CMD_FLAG_OK_ON_ALL_LUNS) == 0)) + if ((entry->flags & CTL_CMD_FLAG_OK_ON_PROC) == 0) return (0); break; case T_DIRECT: - if (((entry->flags & CTL_CMD_FLAG_OK_ON_SLUN) == 0) && - ((entry->flags & CTL_CMD_FLAG_OK_ON_ALL_LUNS) == 0)) + if ((entry->flags & CTL_CMD_FLAG_OK_ON_SLUN) == 0) return (0); break; default: Modified: stable/10/sys/cam/ctl/ctl_cmd_table.c ============================================================================== --- stable/10/sys/cam/ctl/ctl_cmd_table.c Mon Oct 5 10:43:45 2015 (r288777) +++ stable/10/sys/cam/ctl/ctl_cmd_table.c Mon Oct 5 10:44:36 2015 (r288778) @@ -546,7 +546,8 @@ const struct ctl_cmd_entry ctl_cmd_table /* 03 REQUEST SENSE */ {ctl_request_sense, CTL_SERIDX_RQ_SNS, CTL_FLAG_DATA_IN | - CTL_CMD_FLAG_OK_ON_ALL_LUNS | + CTL_CMD_FLAG_OK_ON_NO_LUN | + CTL_CMD_FLAG_OK_ON_BOTH | CTL_CMD_FLAG_ALLOW_ON_RESV | CTL_CMD_FLAG_NO_SENSE | CTL_CMD_FLAG_OK_ON_STOPPED | @@ -607,7 +608,8 @@ const struct ctl_cmd_entry ctl_cmd_table {NULL, CTL_SERIDX_INVLD, CTL_CMD_FLAG_NONE, CTL_LUN_PAT_NONE}, /* 12 INQUIRY */ -{ctl_inquiry, CTL_SERIDX_INQ, CTL_CMD_FLAG_OK_ON_ALL_LUNS | +{ctl_inquiry, CTL_SERIDX_INQ, CTL_CMD_FLAG_OK_ON_NO_LUN | + CTL_CMD_FLAG_OK_ON_BOTH | CTL_CMD_FLAG_ALLOW_ON_RESV | CTL_CMD_FLAG_NO_SENSE | CTL_CMD_FLAG_OK_ON_STOPPED | @@ -1172,7 +1174,8 @@ const struct ctl_cmd_entry ctl_cmd_table {NULL, CTL_SERIDX_INVLD, CTL_CMD_FLAG_NONE, CTL_LUN_PAT_NONE}, /* A0 REPORT LUNS */ -{ctl_report_luns, CTL_SERIDX_INQ, CTL_CMD_FLAG_OK_ON_ALL_LUNS | +{ctl_report_luns, CTL_SERIDX_INQ, CTL_CMD_FLAG_OK_ON_NO_LUN | + CTL_CMD_FLAG_OK_ON_BOTH | CTL_CMD_FLAG_ALLOW_ON_RESV | CTL_CMD_FLAG_NO_SENSE | CTL_CMD_FLAG_OK_ON_STOPPED | Modified: stable/10/sys/cam/ctl/ctl_private.h ============================================================================== --- stable/10/sys/cam/ctl/ctl_private.h Mon Oct 5 10:43:45 2015 (r288777) +++ stable/10/sys/cam/ctl/ctl_private.h Mon Oct 5 10:44:36 2015 (r288778) @@ -91,14 +91,14 @@ typedef enum { * WARNING: Keep the bottom nibble here free, we OR in the data direction * flags for each command. * - * Note: "OK_ON_ALL_LUNS" == we don't have to have a lun configured + * Note: "OK_ON_NO_LUN" == we don't have to have a lun configured * "OK_ON_BOTH" == we have to have a lun configured * "SA5" == command has 5-bit service action at byte 1 */ typedef enum { CTL_CMD_FLAG_NONE = 0x0000, CTL_CMD_FLAG_NO_SENSE = 0x0010, - CTL_CMD_FLAG_OK_ON_ALL_LUNS = 0x0020, + CTL_CMD_FLAG_OK_ON_NO_LUN = 0x0020, CTL_CMD_FLAG_ALLOW_ON_RESV = 0x0040, CTL_CMD_FLAG_ALLOW_ON_PR_WRESV = 0x0080, CTL_CMD_FLAG_OK_ON_PROC = 0x0100, @@ -109,7 +109,8 @@ typedef enum { CTL_CMD_FLAG_OK_ON_STANDBY = 0x1000, CTL_CMD_FLAG_OK_ON_UNAVAIL = 0x2000, CTL_CMD_FLAG_ALLOW_ON_PR_RESV = 0x4000, - CTL_CMD_FLAG_SA5 = 0x8000 + CTL_CMD_FLAG_SA5 = 0x8000, + CTL_CMD_FLAG_RUN_HERE = 0x10000 } ctl_cmd_flags; typedef enum {