0001
0002
0003
0004
0005
0006
0007 #ifndef _UAPI_PARPORT_H_
0008 #define _UAPI_PARPORT_H_
0009
0010
0011
0012
0013 #define PARPORT_MAX 16
0014
0015
0016 #define PARPORT_IRQ_NONE -1
0017 #define PARPORT_DMA_NONE -1
0018 #define PARPORT_IRQ_AUTO -2
0019 #define PARPORT_DMA_AUTO -2
0020 #define PARPORT_DMA_NOFIFO -3
0021 #define PARPORT_DISABLE -2
0022 #define PARPORT_IRQ_PROBEONLY -3
0023 #define PARPORT_IOHI_AUTO -1
0024
0025 #define PARPORT_CONTROL_STROBE 0x1
0026 #define PARPORT_CONTROL_AUTOFD 0x2
0027 #define PARPORT_CONTROL_INIT 0x4
0028 #define PARPORT_CONTROL_SELECT 0x8
0029
0030 #define PARPORT_STATUS_ERROR 0x8
0031 #define PARPORT_STATUS_SELECT 0x10
0032 #define PARPORT_STATUS_PAPEROUT 0x20
0033 #define PARPORT_STATUS_ACK 0x40
0034 #define PARPORT_STATUS_BUSY 0x80
0035
0036
0037 typedef enum {
0038 PARPORT_CLASS_LEGACY = 0,
0039 PARPORT_CLASS_PRINTER,
0040 PARPORT_CLASS_MODEM,
0041 PARPORT_CLASS_NET,
0042 PARPORT_CLASS_HDC,
0043 PARPORT_CLASS_PCMCIA,
0044 PARPORT_CLASS_MEDIA,
0045 PARPORT_CLASS_FDC,
0046 PARPORT_CLASS_PORTS,
0047 PARPORT_CLASS_SCANNER,
0048 PARPORT_CLASS_DIGCAM,
0049 PARPORT_CLASS_OTHER,
0050 PARPORT_CLASS_UNSPEC,
0051 PARPORT_CLASS_SCSIADAPTER
0052 } parport_device_class;
0053
0054
0055
0056 #define PARPORT_MODE_PCSPP (1<<0)
0057 #define PARPORT_MODE_TRISTATE (1<<1)
0058 #define PARPORT_MODE_EPP (1<<2)
0059 #define PARPORT_MODE_ECP (1<<3)
0060 #define PARPORT_MODE_COMPAT (1<<4)
0061 #define PARPORT_MODE_DMA (1<<5)
0062 #define PARPORT_MODE_SAFEININT (1<<6)
0063
0064
0065
0066
0067
0068 #define IEEE1284_MODE_NIBBLE 0
0069 #define IEEE1284_MODE_BYTE (1<<0)
0070 #define IEEE1284_MODE_COMPAT (1<<8)
0071 #define IEEE1284_MODE_BECP (1<<9)
0072 #define IEEE1284_MODE_ECP (1<<4)
0073 #define IEEE1284_MODE_ECPRLE (IEEE1284_MODE_ECP | (1<<5))
0074 #define IEEE1284_MODE_ECPSWE (1<<10)
0075 #define IEEE1284_MODE_EPP (1<<6)
0076 #define IEEE1284_MODE_EPPSL (1<<11)
0077 #define IEEE1284_MODE_EPPSWE (1<<12)
0078 #define IEEE1284_DEVICEID (1<<2)
0079 #define IEEE1284_EXT_LINK (1<<14)
0080
0081
0082
0083
0084
0085
0086
0087 #define IEEE1284_ADDR (1<<13)
0088 #define IEEE1284_DATA 0
0089
0090
0091 #define PARPORT_EPP_FAST (1<<0)
0092 #define PARPORT_W91284PIC (1<<1)
0093
0094
0095 #endif