Path: blob/master/drivers/accessibility/speakup/spk_priv.h
26282 views
/* SPDX-License-Identifier: GPL-2.0+ */1/* spk_priv.h2* 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#ifndef _SPEAKUP_PRIVATE_H11#define _SPEAKUP_PRIVATE_H1213#include <linux/printk.h>1415#include "spk_types.h"16#include "spk_priv_keyinfo.h"1718#define V_LAST_VAR { MAXVARS }19#define SPACE 0x2020#define SYNTH_CHECK 20030716 /* today's date ought to do for check value */21/* synth flags, for odd synths */22#define SF_DEC 1 /* to fiddle puncs in alpha strings so it doesn't spell */23#ifdef MODULE24#define SYNTH_START 125#else26#define SYNTH_START 027#endif2829#define KT_SPKUP 1530#define SPK_SYNTH_TIMEOUT 100000 /* in micro-seconds */31#define SYNTH_DEFAULT_DEV "ttyS0"32#define SYNTH_DEFAULT_SER 03334const struct old_serial_port *spk_serial_init(int index);35void spk_stop_serial_interrupt(void);36void spk_serial_release(struct spk_synth *synth);37void spk_ttyio_release(struct spk_synth *synth);38void spk_ttyio_register_ldisc(void);39void spk_ttyio_unregister_ldisc(void);4041void synth_buffer_skip_nonlatin1(void);42u16 synth_buffer_getc(void);43u16 synth_buffer_peek(void);44int synth_buffer_empty(void);45struct var_t *spk_get_var(enum var_id_t var_id);46ssize_t spk_var_show(struct kobject *kobj, struct kobj_attribute *attr,47char *buf);48ssize_t spk_var_store(struct kobject *kobj, struct kobj_attribute *attr,49const char *buf, size_t count);5051int spk_serial_synth_probe(struct spk_synth *synth);52int spk_ttyio_synth_probe(struct spk_synth *synth);53const char *spk_serial_synth_immediate(struct spk_synth *synth,54const char *buff);55const char *spk_ttyio_synth_immediate(struct spk_synth *synth,56const char *buff);57void spk_do_catch_up(struct spk_synth *synth);58void spk_do_catch_up_unicode(struct spk_synth *synth);59void spk_synth_flush(struct spk_synth *synth);60unsigned char spk_synth_get_index(struct spk_synth *synth);61int spk_synth_is_alive_nop(struct spk_synth *synth);62int spk_synth_is_alive_restart(struct spk_synth *synth);63__printf(1, 2)64void synth_printf(const char *buf, ...);65void synth_putwc(u16 wc);66void synth_putwc_s(u16 wc);67void synth_putws(const u16 *buf);68void synth_putws_s(const u16 *buf);69int synth_request_region(unsigned long start, unsigned long n);70int synth_release_region(unsigned long start, unsigned long n);71int synth_add(struct spk_synth *in_synth);72void synth_remove(struct spk_synth *in_synth);73struct spk_synth *synth_current(void);7475extern struct speakup_info_t speakup_info;7677extern struct var_t synth_time_vars[];7879extern struct spk_io_ops spk_serial_io_ops;80extern struct spk_io_ops spk_ttyio_ops;8182#endif838485