Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp3891461pxb; Tue, 17 Nov 2020 06:19:17 -0800 (PST) X-Google-Smtp-Source: ABdhPJw4qb4OLC7aA8loHxVy4rwY8DU0GbytDEpRPs2306LoL5SJJ/Nt9ij2cnib/0AaWEklgn92 X-Received: by 2002:a17:906:aad7:: with SMTP id kt23mr1738024ejb.158.1605622757178; Tue, 17 Nov 2020 06:19:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605622757; cv=none; d=google.com; s=arc-20160816; b=RQgA13slUKz1ZCT677X8uNiIETQk/CCNMaTjp79D5eOcaqV0TReoQax3ZgDU2J3lqT c63q/TmW07m2cy4i3SlPCLDt2wBFUgTiUXHi0YG3W4vEHBUZTnKNgXpDzpTzgaRnB5mD PyS73ifIVuweV0pepFGynapFB8okba6nbLuKIyLZnkXMWfrS7IdZg4cp9ia1GjpESYmi KR5Y6/L6QYYCxY/8AVFKN8aPvfQoql/kFNGmCUA9JT9J10BssDegs7uZtOaLyhA2LB9/ YwSI8ep6Vmr5qjQZag3a9iGIYH2FEkOVOKV/a/KiA4CCACTBgeP4K/lT6ZV6113JIObF gbeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Gtd0OmjB7msJDc5Zm6MqUsPtZsXu49gSQ8uZtfx9khE=; b=R0AUTR5mKTrw1i1EX3EqtNVds51cJFr+FhVue5x3Tx4ds9WyKcSQLGJ4gWtNw3b+1O NrIN1po+bPdgZLH/eSdEP+GWuCiv7a0Pp2tt1izm24VC9pJ/TvxotFBUVGZt7bxmGpaj ZDEPxpQ8ov0HC8CYlTid074p2ZGuUX8KRfWx17Ou5H9ZAWMP9PHVoGw9XJfFhrCMzxfl 22OklqvJ73vlzNvrcO/gttyFs2l59WuHUhPai0uaDSgLqbtV50Jvov8+FH6HZl+4rLLn hW4iXiwolviU+8fnd9G26hHl2Gh8Ladi5fJSq0QGFAKOQWIbic7ydGMibNZs4RbSZstV d5Hw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=qEVMnZyG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g15si4064896ejc.324.2020.11.17.06.18.53; Tue, 17 Nov 2020 06:19:17 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=qEVMnZyG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732909AbgKQNkv (ORCPT + 99 others); Tue, 17 Nov 2020 08:40:51 -0500 Received: from mail.kernel.org ([198.145.29.99]:52780 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732894AbgKQNkq (ORCPT ); Tue, 17 Nov 2020 08:40:46 -0500 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 64CE62465E; Tue, 17 Nov 2020 13:40:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605620446; bh=hDm07hmMZqMdno+nmMKZ5DeVXRppk4ddKQGEXEM6S1M=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=qEVMnZyG0UhKaK79dC1xD03UqFNRfMB2gizs4nYF9PMLP+Xf7DpBGhvPGuKxOJz+G WqYNjsCxkTbiC4Xadt7zgOk1cLu5BSeuxKqiteGBYCyBbD39Rmm/8V14u0q1Jr383m tAKynDXzU1HaJoyRy2io5WcULshQyh7Jq36vJGew= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Kirk Reiser , Gregory Nowak , Samuel Thibault Subject: [PATCH 5.9 192/255] speakup: Fix var_id_t values and thus keymap Date: Tue, 17 Nov 2020 14:05:32 +0100 Message-Id: <20201117122148.272346908@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201117122138.925150709@linuxfoundation.org> References: <20201117122138.925150709@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Samuel Thibault commit d7012df3c9aecdcfb50f7a2ebad766952fd1410e upstream. commit d97a9d7aea04 ("staging/speakup: Add inflection synth parameter") introduced a new "inflection" speakup parameter next to "pitch", but the values of the var_id_t enum are actually used by the keymap tables so we must not renumber them. The effect was that notably the volume control shortcut (speakup-1 or 2) was actually changing the inflection. This moves the INFLECTION value at the end of the var_id_t enum to fix back the enum values. This also adds a warning about it. Fixes: d97a9d7aea04 ("staging/speakup: Add inflection synth parameter") Cc: stable@vger.kernel.org Reported-by: Kirk Reiser Reported-by: Gregory Nowak Tested-by: Gregory Nowak Signed-off-by: Samuel Thibault Link: https://lore.kernel.org/r/20201012160646.qmdo4eqtj24hpch4@function Signed-off-by: Greg Kroah-Hartman --- drivers/accessibility/speakup/spk_types.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) --- a/drivers/accessibility/speakup/spk_types.h +++ b/drivers/accessibility/speakup/spk_types.h @@ -32,6 +32,10 @@ enum { E_NEW_DEFAULT, }; +/* + * Note: add new members at the end, speakupmap.h depends on the values of the + * enum starting from SPELL_DELAY (see inc_dec_var) + */ enum var_id_t { VERSION = 0, SYNTH, SILENT, SYNTH_DIRECT, KEYMAP, CHARS, @@ -42,9 +46,9 @@ enum var_id_t { SAY_CONTROL, SAY_WORD_CTL, NO_INTERRUPT, KEY_ECHO, SPELL_DELAY, PUNC_LEVEL, READING_PUNC, ATTRIB_BLEEP, BLEEPS, - RATE, PITCH, INFLECTION, VOL, TONE, PUNCT, VOICE, FREQUENCY, LANG, + RATE, PITCH, VOL, TONE, PUNCT, VOICE, FREQUENCY, LANG, DIRECT, PAUSE, - CAPS_START, CAPS_STOP, CHARTAB, + CAPS_START, CAPS_STOP, CHARTAB, INFLECTION, MAXVARS };