~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/include/uapi/linux/ppdev.h

Version: ~ [ linux-6.11.5 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.58 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.114 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.169 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.228 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.284 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.322 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.9 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */
  2 /*
  3  * linux/include/linux/ppdev.h
  4  *
  5  * User-space parallel port device driver (header file).
  6  *
  7  * Copyright (C) 1998-9 Tim Waugh <tim@cyberelk.demon.co.uk>
  8  *
  9  * This program is free software; you can redistribute it and/or
 10  * modify it under the terms of the GNU General Public License
 11  * as published by the Free Software Foundation; either version
 12  * 2 of the License, or (at your option) any later version.
 13  *
 14  * Added PPGETTIME/PPSETTIME, Fred Barnes, 1999
 15  * Added PPGETMODES/PPGETMODE/PPGETPHASE, Fred Barnes <frmb2@ukc.ac.uk>, 03/01/2001
 16  */
 17 
 18 #ifndef _UAPI_LINUX_PPDEV_H
 19 #define _UAPI_LINUX_PPDEV_H
 20 
 21 #define PP_IOCTL        'p'
 22 
 23 /* Set mode for read/write (e.g. IEEE1284_MODE_EPP) */
 24 #define PPSETMODE       _IOW(PP_IOCTL, 0x80, int)
 25 
 26 /* Read status */
 27 #define PPRSTATUS       _IOR(PP_IOCTL, 0x81, unsigned char)
 28 #define PPWSTATUS       OBSOLETE__IOW(PP_IOCTL, 0x82, unsigned char)
 29 
 30 /* Read/write control */
 31 #define PPRCONTROL      _IOR(PP_IOCTL, 0x83, unsigned char)
 32 #define PPWCONTROL      _IOW(PP_IOCTL, 0x84, unsigned char)
 33 
 34 struct ppdev_frob_struct {
 35         unsigned char mask;
 36         unsigned char val;
 37 };
 38 #define PPFCONTROL      _IOW(PP_IOCTL, 0x8e, struct ppdev_frob_struct)
 39 
 40 /* Read/write data */
 41 #define PPRDATA         _IOR(PP_IOCTL, 0x85, unsigned char)
 42 #define PPWDATA         _IOW(PP_IOCTL, 0x86, unsigned char)
 43 
 44 /* Read/write econtrol (not used) */
 45 #define PPRECONTROL     OBSOLETE__IOR(PP_IOCTL, 0x87, unsigned char)
 46 #define PPWECONTROL     OBSOLETE__IOW(PP_IOCTL, 0x88, unsigned char)
 47 
 48 /* Read/write FIFO (not used) */
 49 #define PPRFIFO         OBSOLETE__IOR(PP_IOCTL, 0x89, unsigned char)
 50 #define PPWFIFO         OBSOLETE__IOW(PP_IOCTL, 0x8a, unsigned char)
 51 
 52 /* Claim the port to start using it */
 53 #define PPCLAIM         _IO(PP_IOCTL, 0x8b)
 54 
 55 /* Release the port when you aren't using it */
 56 #define PPRELEASE       _IO(PP_IOCTL, 0x8c)
 57 
 58 /* Yield the port (release it if another driver is waiting,
 59  * then reclaim) */
 60 #define PPYIELD         _IO(PP_IOCTL, 0x8d)
 61 
 62 /* Register device exclusively (must be before PPCLAIM). */
 63 #define PPEXCL          _IO(PP_IOCTL, 0x8f)
 64 
 65 /* Data line direction: non-zero for input mode. */
 66 #define PPDATADIR       _IOW(PP_IOCTL, 0x90, int)
 67 
 68 /* Negotiate a particular IEEE 1284 mode. */
 69 #define PPNEGOT         _IOW(PP_IOCTL, 0x91, int)
 70 
 71 /* Set control lines when an interrupt occurs. */
 72 #define PPWCTLONIRQ     _IOW(PP_IOCTL, 0x92, unsigned char)
 73 
 74 /* Clear (and return) interrupt count. */
 75 #define PPCLRIRQ        _IOR(PP_IOCTL, 0x93, int)
 76 
 77 /* Set the IEEE 1284 phase that we're in (e.g. IEEE1284_PH_FWD_IDLE) */
 78 #define PPSETPHASE      _IOW(PP_IOCTL, 0x94, int)
 79 
 80 /* Set and get port timeout (struct timeval's) */
 81 #define PPGETTIME       _IOR(PP_IOCTL, 0x95, struct timeval)
 82 #define PPSETTIME       _IOW(PP_IOCTL, 0x96, struct timeval)
 83 
 84 /* Get available modes (what the hardware can do) */
 85 #define PPGETMODES      _IOR(PP_IOCTL, 0x97, unsigned int)
 86 
 87 /* Get the current mode and phaze */
 88 #define PPGETMODE       _IOR(PP_IOCTL, 0x98, int)
 89 #define PPGETPHASE      _IOR(PP_IOCTL, 0x99, int)
 90 
 91 /* get/set flags */
 92 #define PPGETFLAGS      _IOR(PP_IOCTL, 0x9a, int)
 93 #define PPSETFLAGS      _IOW(PP_IOCTL, 0x9b, int)
 94 
 95 /* flags visible to the world */
 96 #define PP_FASTWRITE    (1<<2)
 97 #define PP_FASTREAD     (1<<3)
 98 #define PP_W91284PIC    (1<<4)
 99 
100 /* only masks user-visible flags */
101 #define PP_FLAGMASK     (PP_FASTWRITE | PP_FASTREAD | PP_W91284PIC)
102 
103 #endif /* _UAPI_LINUX_PPDEV_H */
104 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php