Print this page
9042 multiples of tty streams modules cause weirdness
Reviewed by: Randy Fishel <randyf@sibernet.com>
Reviewed by: Carlos Neira <cneirabustos@gmail.com>
Approved by: Hans Rosenfeld <rosenfeld@grumpf.hope-2000.org>
NEX-16818 Add fksmbcl development tool
NEX-17264 SMB client test tp_smbutil_013 fails after NEX-14666
Reviewed by: Evan Layton <evan.layton@nexenta.com>
Reviewed by: Matt Barden <matt.barden@nexenta.com>
and: (fix ref leaks)
NEX-4083 Upstream changes from illumos 5917 and 5995
Reviewed by: Matt Barden <matt.barden@nexenta.com>
Reviewed by: Kevin Crowe <kevin.crowe@nexenta.com>
Reviewed by: Yuri Pankov <yuri.pankov@nexenta.com>
re #13613 rb4516 Tunables needs volatile keyword

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/sys/stream.h
          +++ new/usr/src/uts/common/sys/stream.h
↓ open down ↓ 13 lines elided ↑ open up ↑
  14   14   * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15   15   * If applicable, add the following below this CDDL HEADER, with the
  16   16   * fields enclosed by brackets "[]" replaced with your own identifying
  17   17   * information: Portions Copyright [yyyy] [name of copyright owner]
  18   18   *
  19   19   * CDDL HEADER END
  20   20   */
  21   21  /*
  22   22   * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  23   23   * Use is subject to license terms.
       24 + * Copyright 2018 OmniOS Community Edition (OmniOSce) Association.
  24   25   */
       26 +/*
       27 + * Copyright 2013 Nexenta Systems, Inc.  All rights reserved.
       28 + */
  25   29  
  26   30  /*      Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
  27   31  /*        All Rights Reserved   */
  28   32  
  29   33  
  30   34  #ifndef _SYS_STREAM_H
  31   35  #define _SYS_STREAM_H
  32   36  
  33   37  /*
  34   38   * For source compatibility
  35   39   */
  36   40  #include <sys/isa_defs.h>
  37      -#ifdef _KERNEL
       41 +#if defined(_KERNEL) || defined(_FAKE_KERNEL)
  38   42  #include <sys/kmem.h>
  39   43  #include <sys/uio.h>
  40   44  #endif
  41   45  #include <sys/poll.h>
  42   46  #include <sys/strmdep.h>
  43   47  #include <sys/cred.h>
  44   48  #include <sys/t_lock.h>
  45   49  #include <sys/model.h>
  46   50  
  47   51  #ifdef  __cplusplus
↓ open down ↓ 134 lines elided ↑ open up ↑
 182  186  #define QSYNCSTR        0x00100000      /* Q supports Synchronous STREAMS */
 183  187  #define QISDRV          0x00200000      /* the Queue is attached to a driver */
 184  188  /*      UNUSED          0x00400000         was QHOT                     */
 185  189  /*      UNUSED          0x00800000         was QNEXTHOT                 */
 186  190  /*      UNUSED          0x01000000         was _QNEXTLESS               */
 187  191  #define _QINSERTING     0x04000000      /* Private, module is being inserted */
 188  192  #define _QREMOVING      0x08000000      /* Private, module is being removed */
 189  193  #define _QASSOCIATED    0x10000000      /* queue is associated with a device */
 190  194  #define _QDIRECT        0x20000000      /* Private; transport module uses */
 191  195                                          /* direct interface to/from sockfs */
      196 +#define _QSINGLE_INSTANCE       0x40000000      /* Private; module may only */
      197 +                                                /* be pushed once */
 192  198  
 193  199  /* queue sqflags (protected by SQLOCK). */
 194  200  #define Q_SQQUEUED      0x01            /* Queue is in the syncq list */
 195  201  #define Q_SQDRAINING    0x02            /* Servicing syncq msgs.        */
 196  202                                          /* This is also noted by the    */
 197  203                                          /* q_draining field, but this one is */
 198  204                                          /* protected by SQLOCK */
 199  205  
 200  206  /*
 201  207   * Structure that describes the separate information
↓ open down ↓ 415 lines elided ↑ open up ↑
 617  623  #define SO_TONSTOP      0x2000  /* do not stop on background writes to stream */
 618  624  #define SO_BAND         0x4000  /* water marks affect band */
 619  625  #define SO_DELIM        0x8000  /* messages are delimited */
 620  626  #define SO_NODELIM      0x010000        /* turn off delimiters */
 621  627  #define SO_STRHOLD      0x020000        /* No longer implemented */
 622  628  #define SO_ERROPT       0x040000        /* set error option */
 623  629  #define SO_COPYOPT      0x080000        /* copy option(s) present */
 624  630  #define SO_MAXBLK       0x100000        /* set maximum message block size */
 625  631  #define SO_TAIL         0x200000        /* set the extra allocated space */
 626  632  
 627      -#ifdef _KERNEL
      633 +#if defined(_KERNEL) || defined(_FAKE_KERNEL)
 628  634  /*
 629  635   * Structure for rw (read/write) procedure calls. A pointer
 630  636   * to a struiod_t is passed as a parameter to the rwnext() call.
 631  637   *
 632  638   * Note: DEF_IOV_MAX is defined and used as it is in "fs/vncalls.c"
 633  639   *       as there isn't a formal definition of IOV_MAX ???
 634  640   */
 635  641  #define DEF_IOV_MAX     16
 636  642  
 637  643  typedef struct struiod {
↓ open down ↓ 107 lines elided ↑ open up ↑
 745  751  /*
 746  752   * Align address on next lower word boundary.
 747  753   */
 748  754  #define straln(a)       (caddr_t)((intptr_t)(a) & -(sizeof (int)-1))
 749  755  
 750  756  /*
 751  757   * Find the max size of data block.
 752  758   */
 753  759  #define bpsize(bp) ((unsigned int)(bp->b_datap->db_lim - bp->b_datap->db_base))
 754  760  
 755      -#ifdef _KERNEL
      761 +#if defined(_KERNEL) || defined(_FAKE_KERNEL)
 756  762  
 757  763  /*
 758  764   * For two-byte M_ERROR messages: indication that a side does not have an error
 759  765   */
 760  766  #define NOERROR ((unsigned char)-1)
 761  767  
 762  768  /*
 763  769   * declarations of common routines
 764  770   */
 765  771  
↓ open down ↓ 66 lines elided ↑ open up ↑
 832  838  extern int struioget(queue_t *, mblk_t *, struiod_t *, int);
 833  839  extern int rwnext(queue_t *, struiod_t *);
 834  840  extern int infonext(queue_t *, infod_t *);
 835  841  extern int isuioq(queue_t *);
 836  842  extern void create_putlocks(queue_t *, int);
 837  843  extern int mp_cont_len(mblk_t *, int *);
 838  844  
 839  845  /*
 840  846   * shared or externally configured data structures
 841  847   */
 842      -extern int nstrpush;                    /* maximum number of pushes allowed */
      848 +extern volatile int nstrpush;           /* maximum number of pushes allowed */
 843  849  
 844  850  #endif /* _KERNEL */
 845  851  
 846  852  #ifdef  __cplusplus
 847  853  }
 848  854  #endif
 849  855  
 850  856  #endif  /* _SYS_STREAM_H */
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX