Author: mav
Date: Mon Oct  5 10:46:24 2015
New Revision: 288781
URL: https://svnweb.freebsd.org/changeset/base/288781

Log:
  MFC r288020: Remove couple excess SGLIST I/O flags.
  
  Those flags duplicated respective (sg_entries > 0) values.

Modified:
  stable/10/sys/cam/ctl/ctl_backend_block.c
  stable/10/sys/cam/ctl/ctl_backend_ramdisk.c
  stable/10/sys/cam/ctl/ctl_frontend_ioctl.c
  stable/10/sys/cam/ctl/ctl_io.h
  stable/10/sys/cam/ctl/ctl_tpc_local.c
  stable/10/sys/cam/ctl/ctl_util.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/cam/ctl/ctl_backend_block.c
==============================================================================
--- stable/10/sys/cam/ctl/ctl_backend_block.c   Mon Oct  5 10:45:52 2015        
(r288780)
+++ stable/10/sys/cam/ctl/ctl_backend_block.c   Mon Oct  5 10:46:24 2015        
(r288781)
@@ -1652,7 +1652,7 @@ ctl_be_block_dispatch(struct ctl_be_bloc
        io->scsiio.kern_data_len = beio->io_len;
        io->scsiio.kern_data_resid = 0;
        io->scsiio.kern_sg_entries = beio->num_segs;
-       io->io_hdr.flags |= CTL_FLAG_ALLOCATED | CTL_FLAG_KDPTR_SGLIST;
+       io->io_hdr.flags |= CTL_FLAG_ALLOCATED;
 
        /*
         * For the read case, we need to read the data into our buffers and

Modified: stable/10/sys/cam/ctl/ctl_backend_ramdisk.c
==============================================================================
--- stable/10/sys/cam/ctl/ctl_backend_ramdisk.c Mon Oct  5 10:45:52 2015        
(r288780)
+++ stable/10/sys/cam/ctl/ctl_backend_ramdisk.c Mon Oct  5 10:46:24 2015        
(r288781)
@@ -321,7 +321,6 @@ ctl_backend_ramdisk_continue(union ctl_i
                        sg_entries[i].len = MIN(PAGE_SIZE, len - len_filled);
                        len_filled += sg_entries[i].len;
                }
-               io->io_hdr.flags |= CTL_FLAG_KDPTR_SGLIST;
        } else {
                sg_filled = 0;
                len_filled = len;

Modified: stable/10/sys/cam/ctl/ctl_frontend_ioctl.c
==============================================================================
--- stable/10/sys/cam/ctl/ctl_frontend_ioctl.c  Mon Oct  5 10:45:52 2015        
(r288780)
+++ stable/10/sys/cam/ctl/ctl_frontend_ioctl.c  Mon Oct  5 10:46:24 2015        
(r288781)
@@ -149,7 +149,7 @@ ctl_ioctl_do_datamove(struct ctl_scsiio 
         * To simplify things here, if we have a single buffer, stick it in
         * a S/G entry and just make it a single entry S/G list.
         */
-       if (ctsio->io_hdr.flags & CTL_FLAG_EDPTR_SGLIST) {
+       if (ctsio->ext_sg_entries > 0) {
                int len_seen;
 
                ext_sglen = ctsio->ext_sg_entries * sizeof(*ext_sglist);

Modified: stable/10/sys/cam/ctl/ctl_io.h
==============================================================================
--- stable/10/sys/cam/ctl/ctl_io.h      Mon Oct  5 10:45:52 2015        
(r288780)
+++ stable/10/sys/cam/ctl/ctl_io.h      Mon Oct  5 10:46:24 2015        
(r288781)
@@ -88,8 +88,6 @@ typedef enum {
        CTL_FLAG_DATA_OUT       = 0x00000002,   /* DATA OUT */
        CTL_FLAG_DATA_NONE      = 0x00000003,   /* no data */
        CTL_FLAG_DATA_MASK      = 0x00000003,
-       CTL_FLAG_KDPTR_SGLIST   = 0x00000008,   /* kern_data_ptr is S/G list*/
-       CTL_FLAG_EDPTR_SGLIST   = 0x00000010,   /* ext_data_ptr is S/G list */
        CTL_FLAG_DO_AUTOSENSE   = 0x00000020,   /* grab sense info */
        CTL_FLAG_USER_REQ       = 0x00000040,   /* request came from userland */
        CTL_FLAG_ALLOCATED      = 0x00000100,   /* data space allocated */

Modified: stable/10/sys/cam/ctl/ctl_tpc_local.c
==============================================================================
--- stable/10/sys/cam/ctl/ctl_tpc_local.c       Mon Oct  5 10:45:52 2015        
(r288780)
+++ stable/10/sys/cam/ctl/ctl_tpc_local.c       Mon Oct  5 10:46:24 2015        
(r288781)
@@ -162,7 +162,7 @@ tpcl_datamove(union ctl_io *io)
         * To simplify things here, if we have a single buffer, stick it in
         * a S/G entry and just make it a single entry S/G list.
         */
-       if (ctsio->io_hdr.flags & CTL_FLAG_EDPTR_SGLIST) {
+       if (ctsio->ext_sg_entries > 0) {
                int len_seen;
 
                ext_sglist = (struct ctl_sg_entry *)ctsio->ext_data_ptr;

Modified: stable/10/sys/cam/ctl/ctl_util.c
==============================================================================
--- stable/10/sys/cam/ctl/ctl_util.c    Mon Oct  5 10:45:52 2015        
(r288780)
+++ stable/10/sys/cam/ctl/ctl_util.c    Mon Oct  5 10:46:24 2015        
(r288781)
@@ -882,7 +882,7 @@ ctl_data_print(union ctl_io *io)
                return;
        if (io->io_hdr.flags & CTL_FLAG_BUS_ADDR)
                return;
-       if (io->io_hdr.flags & CTL_FLAG_EDPTR_SGLIST)   /* XXX: Implement */
+       if (io->scsiio.ext_sg_entries > 0)      /* XXX: Implement */
                return;
        ctl_scsi_path_string(io, path_str, sizeof(path_str));
        len = min(io->scsiio.kern_data_len, 4096);
_______________________________________________
svn-src-stable-10@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10
To unsubscribe, send any mail to "svn-src-stable-10-unsubscr...@freebsd.org"

Reply via email to