xref: /csrg-svn/sys/vax/uba/qvioctl.h (revision 33098)
133097Sbostic /*
233097Sbostic  *	@(#)qvioctl.h	1.7 (ULTRIX) 6/11/85
333097Sbostic  *
433097Sbostic  * Ioctl definitions for the qvss.
533097Sbostic  *
6*33098Sbostic  *	@(#)qvioctl.h	1.2 (Berkeley) 12/22/87
733097Sbostic  *
833097Sbostic  */
933097Sbostic #ifdef KERNEL
1033097Sbostic #include "qevent.h"
1133097Sbostic #include "../h/ioctl.h"
1233097Sbostic #include "qvreg.h"
1333097Sbostic #else
1433097Sbostic #include <qevent.h>
1533097Sbostic #include <sys/ioctl.h>
1633097Sbostic #include <qvreg.h>
1733097Sbostic #endif
1833097Sbostic 
1933097Sbostic struct qv_kpcmd {
2033097Sbostic 	char nbytes;		/* number of bytes in parameter */
2133097Sbostic 	unsigned char cmd;	/* command to be sent, peripheral bit will */
2233097Sbostic 				/* be forced by driver */
2333097Sbostic 	unsigned char par[2];	/* bytes of parameters to be sent */
2433097Sbostic };
2533097Sbostic /*
2633097Sbostic  * qvss information block
2733097Sbostic  */
2833097Sbostic 
2933097Sbostic struct qv_info {
3033097Sbostic 	short	mswitches;		/* current value of mouse buttons */
3133097Sbostic 	vsCursor tablet;		/* current tablet position	*/
3233097Sbostic 	short	tswitches;		/* current tablet buttons NI!	*/
3333097Sbostic 	vsCursor cursor;		/* current cursor position	*/
3433097Sbostic 	short	row;			/* screen row			*/
3533097Sbostic 	short	col;			/* screen col			*/
3633097Sbostic 	short	max_row;		/* max character row		*/
3733097Sbostic 	short	max_col;		/* max character col		*/
3833097Sbostic 	short	max_x;			/* max x position		*/
3933097Sbostic 	short	max_y;			/* max y position		*/
4033097Sbostic 	short	max_cur_x;		/* max cursor y position 	*/
4133097Sbostic 	short	max_cur_y;		/* max cursor y position	*/
4233097Sbostic 	char	*bitmap;		/* bit map position		*/
4333097Sbostic 	short	*scanmap;		/* scanline map position	*/
4433097Sbostic 	short	*cursorbits;		/* cursor bit position		*/
4533097Sbostic 	struct	qvdevice *qvaddr;	/* virtual address of the csr	*/
4633097Sbostic 	vsEvent *ibuff;			/* pointer to event queue	*/
4733097Sbostic 	int 	iqsize;			/* may assume power of two 	*/
4833097Sbostic 	int 	ihead;			/* atomic write			*/
4933097Sbostic 	int 	itail;			/* atomic read			*/
5033097Sbostic 	vsCursor mouse;			/* atomic read/write		*/
5133097Sbostic 	vsBox	mbox;			/* atomic read/write		*/
5233097Sbostic 	short	mthreshold;		/* mouse motion parameter	*/
5333097Sbostic 	short	mscale;			/* mouse scale factor (if
5433097Sbostic 					   negative, then do square).	*/
5533097Sbostic };
5633097Sbostic typedef struct qv_info vsIoAddr;
5733097Sbostic 
58*33098Sbostic #define QIOCGINFO 	_IOR('q', 1, struct qv_info)	/* get the info	 */
59*33098Sbostic #define QIOCSMSTATE	_IOW('q', 2, vsCursor)		/* set mouse pos */
60*33098Sbostic #define QIOCINIT	_IO('q', 4)			/* init screen   */
61*33098Sbostic #define QIOCKPCMD	_IOW('q', 5, struct qv_kpcmd)	/* keybd. per. cmd */
62*33098Sbostic #define QIOCADDR	_IOR('q', 6, struct qv_info *)	/* get address */
6333097Sbostic 
64