Print this page
10532 Convert sesio(7I) to mandoc

Split Close
Expand all
Collapse all
          --- old/usr/src/man/man7i/sesio.7i.man.txt
          +++ new/usr/src/man/man7i/sesio.7i.man.txt
   1    1  SESIO(7I)                       Ioctl Requests                       SESIO(7I)
   2    2  
   3      -
   4      -
   5    3  NAME
   6      -       sesio - enclosure services device driver interface
        4 +     sesio - enclosure services device driver interface
   7    5  
   8    6  SYNOPSIS
   9      -       #include <sys/sesio.h>
        7 +     #include <sys/scsi/targets/sesio.h>
  10    8  
  11      -
  12    9  DESCRIPTION
  13      -       The  ses device driver provides the following ioctls as a means to
  14      -       access SCSI enclosure services devices.
       10 +     The ses device driver provides the following ioctls as a means to access
       11 +     SCSI enclosure services devices.
  15   12  
  16   13  IOCTLS
  17      -       The  ses driver supports the following ioctls:
       14 +     The ses driver supports the following ioctls:
  18   15  
  19      -       SES_IOCTL_GETSTATE
  20      -                             This ioctl obtains enclosure state in the
  21      -                             ses_ioctl structure.
       16 +     SES_IOCTL_GETSTATE  This ioctl obtains enclosure state in the ses_ioctl
       17 +                         structure.
  22   18  
       19 +     SES_IOCTL_SETSTATE  This ioctl is used to set parameters on the enclosure
       20 +                         services device.  The ses_ioctl structure is used to
       21 +                         pass information into the driver.
  23   22  
  24      -       SES_IOCTL_SETSTATE
  25      -                             This ioctl is used to set parameters on the
  26      -                             enclosure services device. The ses_ioctl
  27      -                             structure is used to pass information into the
  28      -                             driver.
       23 +EXAMPLES
       24 +     Example 1  Using the SES_IOCTL_GETSTATE ioctl
  29   25  
       26 +     The following example uses the SES_IOCTL_GETSTATE ioctl to recover 20
       27 +     bytes of page 4 from a previously opened device.
  30   28  
  31      -ERRORS
  32      -       EIO
  33      -                 The ses driver was unable to obtain data from the enclosure
  34      -                 services device or the  data transfer could not be completed.
       29 +       char   abuf[30];
       30 +       struct ses_ioctl *sesp;
       31 +       int    status;
  35   32  
       33 +       sesp = (ses_ioctl *)abuf;
       34 +       sesp->size = 20;
       35 +       sesp->page_code = 4;
       36 +       status = ioctl(fd, SES_IOCTL_GETSTATE, abuf);
  36   37  
  37      -       ENOTTY
  38      -                 The  ses driver does not support the requested ioctl
  39      -                 function.
       38 +ERRORS
       39 +     EIO     The ses driver was unable to obtain data from the enclosure
       40 +             services device or the  data transfer could not be completed.
  40   41  
       42 +     ENOTTY  The ses driver does not support the requested ioctl function.
  41   43  
  42      -       ENXIO
  43      -                 The enclosure services device does not exist.
       44 +     ENXIO   The enclosure services device does not exist.
  44   45  
       46 +     EFAULT  The user specified a bad data length.
  45   47  
  46      -       EFAULT
  47      -                 The user specified a bad data length.
  48      -
  49      -
  50   48  STRUCTURES
  51      -       The  ses_ioctl structure has the following fields:
       49 +     The ses_ioctl structure has the following fields:
  52   50  
  53      -         uint32_t;               /* Size of buffer that follows */
  54      -         uint8_t page_code:      /* Page to be read/written */
  55      -         uint8_t reserved[3];    /* Reserved; Set to 0 */
  56      -         unit8t  buffer[1];      /* Size arbitrary, user specifies */
       51 +       uint32_t page_size;      /* Size of buffer that follows */
       52 +       uint8_t  page_code:      /* Page to be read/written */
       53 +       uint8_t  reserved[3];    /* Reserved; Set to 0 */
  57   54  
       55 +ARCHITECTURE
       56 +     SPARC
  58   57  
  59      -EXAMPLES
  60      -       Example 1 Using the  SES_IOCTL_GETSTATE ioctl
  61      -
  62      -
  63      -       The following example uses the  SES_IOCTL_GETSTATE ioctl to recover 20
  64      -       bytes of page 4 from a previously opened device.
  65      -
  66      -
  67      -         char   abuf[30];
  68      -         struct ses_ioctl *sesp;
  69      -         int    status;
  70      -         sesp = (ses_ioctl *)abuf;
  71      -         sesp->size = 20;
  72      -         sesp->page_code = 4;
  73      -         status = ioctl(fd, SES_IOCTL_GETSTATE, abuf);
  74      -
  75      -
  76      -ATTRIBUTES
  77      -       See  attributes(5) for descriptions of the following attributes:
  78      -
  79      -
  80      -
  81      -
  82      -       +---------------+-----------------+
  83      -       |ATTRIBUTE TYPE | ATTRIBUTE VALUE |
  84      -       +---------------+-----------------+
  85      -       |Architecture   | SPARC           |
  86      -       +---------------+-----------------+
  87      -
  88   58  SEE ALSO
  89      -       ses(7D), ioctl(9E)
       59 +     ses(7D), ioctl(9E)
  90   60  
  91      -
  92      -
  93      -                                March 27, 1997                       SESIO(7I)
       61 +illumos                        October 23, 2017                        illumos
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX