[patch 7/7] staging: speakup: migrate apollo, ltlk, audptr, decext, dectlk and spkout

Samuel Thibault samuel.thibault at ens-lyon.org
Sun Apr 9 17:46:16 EDT 2017


Okash Khawaja, on lun. 03 avril 2017 21:21:30 +0100, wrote:
> This patch simply uses the changes introduced in previous patches and migrates
> apollo, ltlk, audptr, decext, spkout and dectlk. Migrations are straightforward
> function pointer updates.
> 
> Signed-off by: Okash Khawaja <okash.khawaja at gmail.com>

Reviewed-by: Samuel Thibault <samuel.thibault at ens-lyon.org>

So that migrates the last drivers which we can (i.e. non-internal
synthesizers), right?  Congrats :)

> Index: linux-staging/drivers/staging/speakup/speakup_apollo.c
> ===================================================================
> --- linux-staging.orig/drivers/staging/speakup/speakup_apollo.c
> +++ linux-staging/drivers/staging/speakup/speakup_apollo.c
> @@ -22,9 +22,9 @@
>  #include <linux/sched.h>
>  #include <linux/timer.h>
>  #include <linux/kthread.h>
> +#include <linux/serial_reg.h>	/* for UART_MCR* constants */
>  
>  #include "spk_priv.h"
> -#include "serialio.h"
>  #include "speakup.h"
>  
>  #define DRV_VERSION "2.21"
> @@ -108,10 +108,10 @@
>  	.startup = SYNTH_START,
>  	.checkval = SYNTH_CHECK,
>  	.vars = vars,
> -	.io_ops = &spk_serial_io_ops,
> -	.probe = spk_serial_synth_probe,
> -	.release = spk_serial_release,
> -	.synth_immediate = spk_serial_synth_immediate,
> +	.io_ops = &spk_ttyio_ops,
> +	.probe = spk_ttyio_synth_probe,
> +	.release = spk_ttyio_release,
> +	.synth_immediate = spk_ttyio_synth_immediate,
>  	.catch_up = do_catch_up,
>  	.flush = spk_synth_flush,
>  	.is_alive = spk_synth_is_alive_restart,
> Index: linux-staging/drivers/staging/speakup/speakup_ltlk.c
> ===================================================================
> --- linux-staging.orig/drivers/staging/speakup/speakup_ltlk.c
> +++ linux-staging/drivers/staging/speakup/speakup_ltlk.c
> @@ -20,7 +20,6 @@
>   */
>  #include "speakup.h"
>  #include "spk_priv.h"
> -#include "serialio.h"
>  #include "speakup_dtlk.h" /* local header file for LiteTalk values */
>  
>  #define DRV_VERSION "2.11"
> @@ -112,10 +111,10 @@
>  	.startup = SYNTH_START,
>  	.checkval = SYNTH_CHECK,
>  	.vars = vars,
> -	.io_ops = &spk_serial_io_ops,
> +	.io_ops = &spk_ttyio_ops,
>  	.probe = synth_probe,
> -	.release = spk_serial_release,
> -	.synth_immediate = spk_serial_synth_immediate,
> +	.release = spk_ttyio_release,
> +	.synth_immediate = spk_ttyio_synth_immediate,
>  	.catch_up = spk_do_catch_up,
>  	.flush = spk_synth_flush,
>  	.is_alive = spk_synth_is_alive_restart,
> @@ -165,7 +164,7 @@
>  {
>  	int failed = 0;
>  
> -	failed = spk_serial_synth_probe(synth);
> +	failed = spk_ttyio_synth_probe(synth);
>  	if (failed == 0)
>  		synth_interrogate(synth);
>  	synth->alive = !failed;
> Index: linux-staging/drivers/staging/speakup/speakup_audptr.c
> ===================================================================
> --- linux-staging.orig/drivers/staging/speakup/speakup_audptr.c
> +++ linux-staging/drivers/staging/speakup/speakup_audptr.c
> @@ -20,7 +20,6 @@
>   */
>  #include "spk_priv.h"
>  #include "speakup.h"
> -#include "serialio.h"
>  
>  #define DRV_VERSION "2.11"
>  #define SYNTH_CLEAR 0x18 /* flush synth buffer */
> @@ -104,10 +103,10 @@
>  	.startup = SYNTH_START,
>  	.checkval = SYNTH_CHECK,
>  	.vars = vars,
> -	.io_ops = &spk_serial_io_ops,
> +	.io_ops = &spk_ttyio_ops,
>  	.probe = synth_probe,
> -	.release = spk_serial_release,
> -	.synth_immediate = spk_serial_synth_immediate,
> +	.release = spk_ttyio_release,
> +	.synth_immediate = spk_ttyio_synth_immediate,
>  	.catch_up = spk_do_catch_up,
>  	.flush = synth_flush,
>  	.is_alive = spk_synth_is_alive_restart,
> @@ -154,7 +153,7 @@
>  {
>  	int failed;
>  
> -	failed = spk_serial_synth_probe(synth);
> +	failed = spk_ttyio_synth_probe(synth);
>  	if (failed == 0)
>  		synth_version(synth);
>  	synth->alive = !failed;
> Index: linux-staging/drivers/staging/speakup/speakup_decext.c
> ===================================================================
> --- linux-staging.orig/drivers/staging/speakup/speakup_decext.c
> +++ linux-staging/drivers/staging/speakup/speakup_decext.c
> @@ -24,12 +24,12 @@
>  #include <linux/kthread.h>
>  
>  #include "spk_priv.h"
> -#include "serialio.h"
>  #include "speakup.h"
>  
>  #define DRV_VERSION "2.14"
>  #define SYNTH_CLEAR 0x03
>  #define PROCSPEECH 0x0b
> +
>  static volatile unsigned char last_char;
>  
>  static void read_buff_add(u_char ch)
> @@ -123,10 +123,10 @@
>  	.startup = SYNTH_START,
>  	.checkval = SYNTH_CHECK,
>  	.vars = vars,
> -	.io_ops = &spk_serial_io_ops,
> -	.probe = spk_serial_synth_probe,
> -	.release = spk_serial_release,
> -	.synth_immediate = spk_serial_synth_immediate,
> +	.io_ops = &spk_ttyio_ops,
> +	.probe = spk_ttyio_synth_probe,
> +	.release = spk_ttyio_release,
> +	.synth_immediate = spk_ttyio_synth_immediate,
>  	.catch_up = do_catch_up,
>  	.flush = synth_flush,
>  	.is_alive = spk_synth_is_alive_restart,
> Index: linux-staging/drivers/staging/speakup/speakup_spkout.c
> ===================================================================
> --- linux-staging.orig/drivers/staging/speakup/speakup_spkout.c
> +++ linux-staging/drivers/staging/speakup/speakup_spkout.c
> @@ -20,7 +20,6 @@
>   */
>  #include "spk_priv.h"
>  #include "speakup.h"
> -#include "serialio.h"
>  
>  #define DRV_VERSION "2.11"
>  #define SYNTH_CLEAR 0x18
> @@ -103,10 +102,10 @@
>  	.startup = SYNTH_START,
>  	.checkval = SYNTH_CHECK,
>  	.vars = vars,
> -	.io_ops = &spk_serial_io_ops,
> -	.probe = spk_serial_synth_probe,
> -	.release = spk_serial_release,
> -	.synth_immediate = spk_serial_synth_immediate,
> +	.io_ops = &spk_ttyio_ops,
> +	.probe = spk_ttyio_synth_probe,
> +	.release = spk_ttyio_release,
> +	.synth_immediate = spk_ttyio_synth_immediate,
>  	.catch_up = spk_do_catch_up,
>  	.flush = synth_flush,
>  	.is_alive = spk_synth_is_alive_restart,
> Index: linux-staging/drivers/staging/speakup/speakup_dectlk.c
> ===================================================================
> --- linux-staging.orig/drivers/staging/speakup/speakup_dectlk.c
> +++ linux-staging/drivers/staging/speakup/speakup_dectlk.c
> @@ -27,7 +27,6 @@
>  #include <linux/kthread.h>
>  #include "speakup.h"
>  #include "spk_priv.h"
> -#include "serialio.h"
>  
>  #define DRV_VERSION "2.20"
>  #define SYNTH_CLEAR 0x03
> @@ -130,10 +129,10 @@
>  	.vars = vars,
>  	.default_pitch = ap_defaults,
>  	.default_vol = g5_defaults,
> -	.io_ops = &spk_serial_io_ops,
> -	.probe = spk_serial_synth_probe,
> -	.release = spk_serial_release,
> -	.synth_immediate = spk_serial_synth_immediate,
> +	.io_ops = &spk_ttyio_ops,
> +	.probe = spk_ttyio_synth_probe,
> +	.release = spk_ttyio_release,
> +	.synth_immediate = spk_ttyio_synth_immediate,
>  	.catch_up = do_catch_up,
>  	.flush = synth_flush,
>  	.is_alive = spk_synth_is_alive_restart,
> 

-- 
Samuel
<i> ben oui ce serait idiot, mais osb
  -+- m'en fous de faire un truc débile ! -+-


More information about the Speakup mailing list