Home | History | Annotate | Download | only in linux
      1 /****************************************************************************
      2  ****************************************************************************
      3  ***
      4  ***   This header was automatically generated from a Linux kernel header
      5  ***   of the same name, to make information necessary for userspace to
      6  ***   call into the kernel available to libc.  It contains only constants,
      7  ***   structures, and macros generated from the original header, and thus,
      8  ***   contains no copyrightable information.
      9  ***
     10  ***   To edit the content of this header, modify the corresponding
     11  ***   source file (e.g. under external/kernel-headers/original/) then
     12  ***   run bionic/libc/kernel/tools/update_all.py
     13  ***
     14  ***   Any manual change here will be lost the next time this script will
     15  ***   be run. You've been warned!
     16  ***
     17  ****************************************************************************
     18  ****************************************************************************/
     19 #ifndef _UAPI_SCC_H
     20 #define _UAPI_SCC_H
     21 #define PA0HZP 0x00
     22 #define EAGLE 0x01
     23 #define PC100 0x02
     24 #define PRIMUS 0x04
     25 #define DRSI 0x08
     26 #define BAYCOM 0x10
     27 enum SCC_ioctl_cmds {
     28   SIOCSCCRESERVED = SIOCDEVPRIVATE,
     29   SIOCSCCCFG,
     30   SIOCSCCINI,
     31   SIOCSCCCHANINI,
     32   SIOCSCCSMEM,
     33   SIOCSCCGKISS,
     34   SIOCSCCSKISS,
     35   SIOCSCCGSTAT,
     36   SIOCSCCCAL
     37 };
     38 enum L1_params {
     39   PARAM_DATA,
     40   PARAM_TXDELAY,
     41   PARAM_PERSIST,
     42   PARAM_SLOTTIME,
     43   PARAM_TXTAIL,
     44   PARAM_FULLDUP,
     45   PARAM_SOFTDCD,
     46   PARAM_MUTE,
     47   PARAM_DTR,
     48   PARAM_RTS,
     49   PARAM_SPEED,
     50   PARAM_ENDDELAY,
     51   PARAM_GROUP,
     52   PARAM_IDLE,
     53   PARAM_MIN,
     54   PARAM_MAXKEY,
     55   PARAM_WAIT,
     56   PARAM_MAXDEFER,
     57   PARAM_TX,
     58   PARAM_HWEVENT = 31,
     59   PARAM_RETURN = 255
     60 };
     61 enum FULLDUP_modes {
     62   KISS_DUPLEX_HALF,
     63   KISS_DUPLEX_FULL,
     64   KISS_DUPLEX_LINK,
     65   KISS_DUPLEX_OPTIMA
     66 };
     67 #define TIMER_OFF 65535U
     68 #define NO_SUCH_PARAM 65534U
     69 enum HWEVENT_opts {
     70   HWEV_DCD_ON,
     71   HWEV_DCD_OFF,
     72   HWEV_ALL_SENT
     73 };
     74 #define RXGROUP 0100
     75 #define TXGROUP 0200
     76 enum CLOCK_sources {
     77   CLK_DPLL,
     78   CLK_EXTERNAL,
     79   CLK_DIVIDER,
     80   CLK_BRG
     81 };
     82 enum TX_state {
     83   TXS_IDLE,
     84   TXS_BUSY,
     85   TXS_ACTIVE,
     86   TXS_NEWFRAME,
     87   TXS_IDLE2,
     88   TXS_WAIT,
     89   TXS_TIMEOUT
     90 };
     91 typedef unsigned long io_port;
     92 struct scc_stat {
     93   long rxints;
     94   long txints;
     95   long exints;
     96   long spints;
     97   long txframes;
     98   long rxframes;
     99   long rxerrs;
    100   long txerrs;
    101   unsigned int nospace;
    102   unsigned int rx_over;
    103   unsigned int tx_under;
    104   unsigned int tx_state;
    105   int tx_queued;
    106   unsigned int maxqueue;
    107   unsigned int bufsize;
    108 };
    109 struct scc_modem {
    110   long speed;
    111   char clocksrc;
    112   char nrz;
    113 };
    114 struct scc_kiss_cmd {
    115   int command;
    116   unsigned param;
    117 };
    118 struct scc_hw_config {
    119   io_port data_a;
    120   io_port ctrl_a;
    121   io_port data_b;
    122   io_port ctrl_b;
    123   io_port vector_latch;
    124   io_port special;
    125   int irq;
    126   long clock;
    127   char option;
    128   char brand;
    129   char escc;
    130 };
    131 struct scc_mem_config {
    132   unsigned int dummy;
    133   unsigned int bufsize;
    134 };
    135 struct scc_calibrate {
    136   unsigned int time;
    137   unsigned char pattern;
    138 };
    139 #endif
    140