Print this page
104 Bring back lx brand

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/sys/ptms.h
          +++ new/usr/src/uts/common/sys/ptms.h
↓ open down ↓ 118 lines elided ↑ open up ↑
 119  119  #ifdef DEBUG
 120  120  extern void ptms_log(char *, uint_t);
 121  121  extern void ptms_logp(char *, uintptr_t);
 122  122  #define DDBG(a, b) ptms_log(a, b)
 123  123  #define DDBGP(a, b) ptms_logp(a, b)
 124  124  #else
 125  125  #define DDBG(a, b)
 126  126  #define DDBGP(a, b)
 127  127  #endif
 128  128  
      129 +typedef struct __ptmptsopencb_arg *ptmptsopencb_arg_t;
      130 +typedef struct ptmptsopencb {
      131 +        boolean_t               (*ppocb_func)(ptmptsopencb_arg_t);
      132 +        ptmptsopencb_arg_t      ppocb_arg;
      133 +} ptmptsopencb_t;
      134 +
 129  135  #endif /* _KERNEL */
 130  136  
 131  137  typedef struct pt_own {
 132  138          uid_t   pto_ruid;
 133  139          gid_t   pto_rgid;
 134  140  } pt_own_t;
 135  141  
 136  142  /*
 137  143   * ioctl commands
 138  144   *
↓ open down ↓ 11 lines elided ↑ open up ↑
 150  156   *
 151  157   * PT_OWNER: Sets uid and gid for slave device.  It returns 0 on success.
 152  158   *
 153  159   */
 154  160  #define ISPTM           (('P'<<8)|1)    /* query for master */
 155  161  #define UNLKPT          (('P'<<8)|2)    /* unlock master/slave pair */
 156  162  #define PTSSTTY         (('P'<<8)|3)    /* set tty flag */
 157  163  #define ZONEPT          (('P'<<8)|4)    /* set zone of master/slave pair */
 158  164  #define OWNERPT         (('P'<<8)|5)    /* set owner/group for slave device */
 159  165  
      166 +#ifdef _KERNEL
      167 +/*
      168 + * kernel ioctl commands
      169 + *
      170 + * PTMPTSOPENCB: Returns a callback function pointer and opaque argument.
      171 + *            The return value of the callback function when it's invoked
      172 + *            with the opaque argument passed to it will indicate if the
      173 + *            pts slave device is currently open.
      174 + */
      175 +#define PTMPTSOPENCB    (('P'<<8)|6)    /* check if the slave is open */
      176 +
      177 +#endif /* _KERNEL */
      178 +
 160  179  #ifdef  __cplusplus
 161  180  }
 162  181  #endif
 163  182  
 164  183  #endif  /* _SYS_PTMS_H */
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX