]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/blame - drivers/staging/speakup/spk_priv.h
Merge tag 'powerpc-4.13-8' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc...
[mirror_ubuntu-artful-kernel.git] / drivers / staging / speakup / spk_priv.h
CommitLineData
c6e3fd22 1/* spk_priv.h
7ea8778e
CM
2 * review functions for the speakup screen review package.
3 * originally written by: Kirk Reiser and Andy Berdan.
4 *
5 * extensively modified by David Borowski.
6 *
7 * Copyright (C) 1998 Kirk Reiser.
8 * Copyright (C) 2003 David Borowski.
9
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
14 *
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
7ea8778e 19 */
c6e3fd22
WH
20#ifndef _SPEAKUP_PRIVATE_H
21#define _SPEAKUP_PRIVATE_H
22
23#include "spk_types.h"
24#include "spk_priv_keyinfo.h"
25
26#ifndef pr_warn
27#define pr_warn(fmt, arg...) printk(KERN_WARNING fmt, ##arg)
28#endif
29
30#define V_LAST_VAR { MAXVARS }
31#define SPACE 0x20
32#define SYNTH_CHECK 20030716 /* today's date ought to do for check value */
33/* synth flags, for odd synths */
34#define SF_DEC 1 /* to fiddle puncs in alpha strings so it doesn't spell */
35#ifdef MODULE
36#define SYNTH_START 1
37#else
38#define SYNTH_START 0
39#endif
40
41#define KT_SPKUP 15
6b9ad1c7 42#define SPK_SYNTH_TIMEOUT 100000 /* in micro-seconds */
a5525dc0
OK
43#define SYNTH_DEFAULT_DEV "ttyS0"
44#define SYNTH_DEFAULT_SER 0
c6e3fd22 45
13d932f7
KD
46const struct old_serial_port *spk_serial_init(int index);
47void spk_stop_serial_interrupt(void);
9176d156 48int spk_wait_for_xmitr(struct spk_synth *in_synth);
13d932f7 49void spk_serial_release(void);
1ab92da3 50void spk_ttyio_release(void);
9f8dced2
OK
51void spk_ttyio_register_ldisc(void);
52void spk_ttyio_unregister_ldisc(void);
c6e3fd22 53
89fc2ae8
ST
54void synth_buffer_skip_nonlatin1(void);
55u16 synth_buffer_getc(void);
56u16 synth_buffer_peek(void);
13d932f7
KD
57int synth_buffer_empty(void);
58struct var_t *spk_get_var(enum var_id_t var_id);
59ssize_t spk_var_show(struct kobject *kobj, struct kobj_attribute *attr,
60 char *buf);
61ssize_t spk_var_store(struct kobject *kobj, struct kobj_attribute *attr,
62 const char *buf, size_t count);
c6e3fd22 63
13d932f7 64int spk_serial_synth_probe(struct spk_synth *synth);
1ab92da3 65int spk_ttyio_synth_probe(struct spk_synth *synth);
98c1fda7 66const char *spk_serial_synth_immediate(struct spk_synth *synth, const char *buff);
1ab92da3 67const char *spk_ttyio_synth_immediate(struct spk_synth *synth, const char *buff);
13d932f7
KD
68void spk_do_catch_up(struct spk_synth *synth);
69void spk_synth_flush(struct spk_synth *synth);
ca693dcd 70unsigned char spk_synth_get_index(struct spk_synth *synth);
13d932f7
KD
71int spk_synth_is_alive_nop(struct spk_synth *synth);
72int spk_synth_is_alive_restart(struct spk_synth *synth);
ae8784fc 73__printf(1, 2)
13d932f7 74void synth_printf(const char *buf, ...);
89fc2ae8
ST
75void synth_putwc(u16 wc);
76void synth_putwc_s(u16 wc);
77void synth_putws(const u16 *buf);
78void synth_putws_s(const u16 *buf);
cb23ebdf
DR
79int synth_request_region(unsigned long start, unsigned long n);
80int synth_release_region(unsigned long start, unsigned long n);
13d932f7
KD
81int synth_add(struct spk_synth *in_synth);
82void synth_remove(struct spk_synth *in_synth);
c6e3fd22
WH
83
84extern struct speakup_info_t speakup_info;
85
86extern struct var_t synth_time_vars[];
87
1e441594 88extern struct spk_io_ops spk_serial_io_ops;
1ab92da3 89extern struct spk_io_ops spk_ttyio_ops;
1e441594 90
c6e3fd22 91#endif