Merge tag 'platform-drivers-x86-v5.18-1' of git://git.kernel.org/pub/scm/linux/kernel...
[linux-block.git] / include / linux / selection.h
CommitLineData
b2441318 1/* SPDX-License-Identifier: GPL-2.0 */
1da177e4
LT
2/*
3 * selection.h
4 *
5 * Interface between console.c, tty_io.c, vt.c, vc_screen.c and selection.c
6 */
7
8#ifndef _LINUX_SELECTION_H_
9#define _LINUX_SELECTION_H_
10
11#include <linux/tiocl.h>
12#include <linux/vt_buffer.h>
13
120c0b6d 14struct tty_struct;
dce05aa6 15struct vc_data;
1da177e4
LT
16
17extern void clear_selection(void);
496124e5
OK
18extern int set_selection_user(const struct tiocl_selection __user *sel,
19 struct tty_struct *tty);
20extern int set_selection_kernel(struct tiocl_selection *v,
21 struct tty_struct *tty);
1da177e4
LT
22extern int paste_selection(struct tty_struct *tty);
23extern int sel_loadlut(char __user *p);
24extern int mouse_reporting(void);
25extern void mouse_report(struct tty_struct * tty, int butt, int mrx, int mry);
dce05aa6
JS
26
27bool vc_is_sel(struct vc_data *vc);
1da177e4
LT
28
29extern int console_blanked;
30
8ede5cce 31extern const unsigned char color_table[];
91e74ca5
JS
32extern unsigned char default_red[];
33extern unsigned char default_grn[];
34extern unsigned char default_blu[];
1da177e4 35
d73568c4 36extern unsigned short *screen_pos(const struct vc_data *vc, int w_offset,
b8209f69 37 bool viewed);
d73568c4
JS
38extern u16 screen_glyph(const struct vc_data *vc, int offset);
39extern u32 screen_glyph_unicode(const struct vc_data *vc, int offset);
1da177e4 40extern void complement_pos(struct vc_data *vc, int offset);
b8209f69 41extern void invert_screen(struct vc_data *vc, int offset, int count, bool viewed);
1da177e4 42
a5c6bd80
JS
43extern void getconsxy(const struct vc_data *vc, unsigned char xy[static 2]);
44extern void putconsxy(struct vc_data *vc, unsigned char xy[static const 2]);
1da177e4 45
d73568c4 46extern u16 vcs_scr_readw(const struct vc_data *vc, const u16 *org);
1da177e4 47extern void vcs_scr_writew(struct vc_data *vc, u16 val, u16 *org);
432c9ed2 48extern void vcs_scr_updated(struct vc_data *vc);
1da177e4 49
d21b0be2 50extern int vc_uniscr_check(struct vc_data *vc);
d73568c4 51extern void vc_uniscr_copy_line(const struct vc_data *vc, void *dest,
b8209f69 52 bool viewed,
d21b0be2
NP
53 unsigned int row, unsigned int col,
54 unsigned int nr);
55
1da177e4 56#endif