[PATCH] Staging: speakup: Add comment for spinlock definition

Samuel Thibault samuel.thibault at ens-lyon.org
Thu Sep 28 19:23:09 EDT 2017


Hello,

Keerthi Reddy, on jeu. 28 sept. 2017 20:06:02 +0530, wrote:
> Its good practice to comment the usage of spinlock variable.

Yes, but

> @@ -246,7 +246,7 @@ static u_long last_spk_jiffy;
>  
>  struct st_spk_t *speakup_console[MAX_NR_CONSOLES];
>  
> -DEFINE_MUTEX(spk_mutex);
> +DEFINE_MUTEX(spk_mutex); /* Spinlock for synth_release() */

This is far from properly describing its role :)

See the use in all other files, this mutex is meant to lock the whole
speakup screen reader.

Samuel


More information about the Speakup mailing list