ARM: 6077/1: ux500: add SOC Kconfig variables
[linux-2.6/linux-acpi-2.6/ibm-acpi-2.6.git] / include / linux / vt.h
blob778b7b2a47d4afc36e81c8516124acbc850e2f07
1 #ifndef _LINUX_VT_H
2 #define _LINUX_VT_H
5 /*
6 * These constants are also useful for user-level apps (e.g., VC
7 * resizing).
8 */
9 #define MIN_NR_CONSOLES 1 /* must be at least 1 */
10 #define MAX_NR_CONSOLES 63 /* serial lines start at 64 */
11 #define MAX_NR_USER_CONSOLES 63 /* must be root to allocate above this */
12 /* Note: the ioctl VT_GETSTATE does not work for
13 consoles 16 and higher (since it returns a short) */
15 /* 0x56 is 'V', to avoid collision with termios and kd */
17 #define VT_OPENQRY 0x5600 /* find available vt */
19 struct vt_mode {
20 char mode; /* vt mode */
21 char waitv; /* if set, hang on writes if not active */
22 short relsig; /* signal to raise on release req */
23 short acqsig; /* signal to raise on acquisition */
24 short frsig; /* unused (set to 0) */
26 #define VT_GETMODE 0x5601 /* get mode of active vt */
27 #define VT_SETMODE 0x5602 /* set mode of active vt */
28 #define VT_AUTO 0x00 /* auto vt switching */
29 #define VT_PROCESS 0x01 /* process controls switching */
30 #define VT_PROCESS_AUTO 0x02 /* process is notified of switching */
32 struct vt_stat {
33 unsigned short v_active; /* active vt */
34 unsigned short v_signal; /* signal to send */
35 unsigned short v_state; /* vt bitmask */
37 #define VT_GETSTATE 0x5603 /* get global vt state info */
38 #define VT_SENDSIG 0x5604 /* signal to send to bitmask of vts */
40 #define VT_RELDISP 0x5605 /* release display */
41 #define VT_ACKACQ 0x02 /* acknowledge switch */
43 #define VT_ACTIVATE 0x5606 /* make vt active */
44 #define VT_WAITACTIVE 0x5607 /* wait for vt active */
45 #define VT_DISALLOCATE 0x5608 /* free memory associated to vt */
47 struct vt_sizes {
48 unsigned short v_rows; /* number of rows */
49 unsigned short v_cols; /* number of columns */
50 unsigned short v_scrollsize; /* number of lines of scrollback */
52 #define VT_RESIZE 0x5609 /* set kernel's idea of screensize */
54 struct vt_consize {
55 unsigned short v_rows; /* number of rows */
56 unsigned short v_cols; /* number of columns */
57 unsigned short v_vlin; /* number of pixel rows on screen */
58 unsigned short v_clin; /* number of pixel rows per character */
59 unsigned short v_vcol; /* number of pixel columns on screen */
60 unsigned short v_ccol; /* number of pixel columns per character */
62 #define VT_RESIZEX 0x560A /* set kernel's idea of screensize + more */
63 #define VT_LOCKSWITCH 0x560B /* disallow vt switching */
64 #define VT_UNLOCKSWITCH 0x560C /* allow vt switching */
65 #define VT_GETHIFONTMASK 0x560D /* return hi font mask */
67 struct vt_event {
68 unsigned int event;
69 #define VT_EVENT_SWITCH 0x0001 /* Console switch */
70 #define VT_EVENT_BLANK 0x0002 /* Screen blank */
71 #define VT_EVENT_UNBLANK 0x0004 /* Screen unblank */
72 #define VT_EVENT_RESIZE 0x0008 /* Resize display */
73 #define VT_MAX_EVENT 0x000F
74 unsigned int oldev; /* Old console */
75 unsigned int newev; /* New console (if changing) */
76 unsigned int pad[4]; /* Padding for expansion */
79 #define VT_WAITEVENT 0x560E /* Wait for an event */
81 struct vt_setactivate {
82 unsigned int console;
83 struct vt_mode mode;
86 #define VT_SETACTIVATE 0x560F /* Activate and set the mode of a console */
88 #ifdef __KERNEL__
90 #ifdef CONFIG_VT_CONSOLE
92 extern int vt_kmsg_redirect(int new);
94 #else
96 static inline int vt_kmsg_redirect(int new)
98 return 0;
101 #endif
103 #endif /* __KERNEL__ */
105 #define vt_get_kmsg_redirect() vt_kmsg_redirect(-1)
107 #endif /* _LINUX_VT_H */