From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by befuddled.reisers.ca (Postfix, from userid 65534) id AD9D41EFB26; Tue, 22 Aug 2017 02:53:12 -0400 (EDT) Received: from mail-oi0-x233.google.com (mail-oi0-x233.google.com [IPv6:2607:f8b0:4003:c06::233]) by befuddled.reisers.ca (Postfix) with ESMTPS id BB94E1EFAE7 for ; Tue, 22 Aug 2017 02:53:09 -0400 (EDT) Received: by mail-oi0-x233.google.com with SMTP id j144so49049996oib.1 for ; Mon, 21 Aug 2017 23:53:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=nmuGLpkRFLrTlCTicHEaQ1xfN/BjkiWtVSSn/5nW+s0=; b=Nm7S4OyWvFdi6djfBOc6Ni9aLIjI/thl523Ro+dKGzTkXb4lwh0LnLQbuuIo6jPcbK 5yFa/dmm4MKi3qhS3ZfMjMdUpd+ma8aYt4e5ivM5fuzWShisc9oDhbQPDjo9m4ZL6Ga+ 5hh7u1AeGqpQC30JZZr0IKCbpk10yfE3S0Gt555m96ruweI71jNgQp/9/iyGVYfOdiaZ EIAQnp0UihCWj6BxTBAI63kNozbp2dnMq1+XSHmKK5nPffmgc28908V0CRBVGMSUzU5G EcM6zWKX8l+6qQOlNC55M0n5s5fwe5zmiYVLbJwdvgO212gXh8iX8knBequolUHgMW7o JNIg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=nmuGLpkRFLrTlCTicHEaQ1xfN/BjkiWtVSSn/5nW+s0=; b=uc3nEecS4bygmR6T6Gk+QZ2kEMvSG6pXlxX99lNVwY2by8LAWSGghvt9BdAIjSYOma a+/2M//b/3QtzvhnnNkJQse752dc19DHk4MAX/XgUqBNIv9IZKSGoYepF0q2d6vDltn1 NQyAIu0P/+PLn0szoACroxJXm1s43RORYXJ7aEnt9l5gu8QNWU92T3r4EmmKOM05s4da UWt/JdiHUdg97Z438KrLZaMmJoOxGC+bu7RlprtgAF17LJrytuO9OdxKbEtl7hVS76ve bnsO92VkoBFi+6C31l1J6AbyKL/OVKGmd1ww+dS2uczqtZKDknossXh5jGMj6Iawcf3Y L4FQ== X-Gm-Message-State: AHYfb5iathzzvtna4K5VaaYlcjSn9VPJcXQSrhcHOO49euB7VO0rkdK0 9C0Bq6HtYiCaXPVMwijJ5pKQvSNTVw== X-Received: by 10.202.240.194 with SMTP id o185mr22540007oih.245.1503384784558; Mon, 21 Aug 2017 23:53:04 -0700 (PDT) MIME-Version: 1.0 Received: by 10.157.26.53 with HTTP; Mon, 21 Aug 2017 23:53:03 -0700 (PDT) Received: by 10.157.26.53 with HTTP; Mon, 21 Aug 2017 23:53:03 -0700 (PDT) In-Reply-To: References: <5411AE16-4310-4AB6-B868-72EBD677540B@gmail.com> <20170818231139.goeokriw7xsrhbm7@var.youpi.perso.aquilenet.fr> <20170820100347.GA1064@sanghar> <20170821144920.GG13793@rednote.net> <20170821160525.vtszuoewe73tpx3y@var.youpi.perso.aquilenet.fr> <20170821192432.GA411@sanghar> From: Okash Khawaja Date: Tue, 22 Aug 2017 07:53:03 +0100 Message-ID: Subject: Re: speakup-r empty line lockup To: John Covici Cc: Samuel Thibault , "Speakup is a screen review system for Linux." X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: speakup@linux-speakup.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Speakup is a screen review system for Linux." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Aug 2017 06:53:12 -0000 Thanks John. Appreciate it. I'll update here if I make progress. Cheers, Okash On 22 Aug 2017 12:36 am, "John Covici" wrote: > OK, tested the patch, no joy with this one either. Note that a couple > of thehunks sucedded with a bit of line difference, but that should > not be of significance. The procedure I used was to unpatch the > previous one and then put the new one in, same like I did with the > previous patch, unpatch old one and put in new one. > > On Mon, 21 Aug 2017 15:24:32 -0400, > Okash Khawaja wrote: > > > > [1 ] > > Hi, > > > > On Mon, Aug 21, 2017 at 12:23:46PM -0400, John Covici wrote: > > > He rewrote the whole part of the code, adding some new features as > > > well, so the bug mysteriously went away. > > > > I still think the root cause is correct, i.e. interrupt being triggered > > from its own interrupt handler context. The fix however was too broad. > > First one changed the behaviour in all cases. Second one from last night > > narrowed the change to just the interrupt context. > > > > If I had right serial synth, I would try the attached patch. This > > narrows the fix down even further, so that we avoid calling > > speakup_fake_down_arrow() only when we are in context of > > keyboard_notifier_call() which is always invoked in interrupt context, > > in response to a keyboard event. > > > > Thanks, > > Okash > > [2 speakup-r-fix ] > > --- > > drivers/staging/speakup/main.c | 15 ++++++++++++--- > > 1 file changed, 12 insertions(+), 3 deletions(-) > > > > --- a/drivers/staging/speakup/main.c > > +++ b/drivers/staging/speakup/main.c > > @@ -1376,6 +1376,8 @@ static void reset_highlight_buffers(stru > > > > static int read_all_key; > > > > +static volatile int in_keyboard_notifier = 0; > > + > > static void start_read_all_timer(struct vc_data *vc, int command); > > > > enum { > > @@ -1408,7 +1410,10 @@ static void read_all_doc(struct vc_data > > cursor_track = read_all_mode; > > spk_reset_index_count(0); > > if (get_sentence_buf(vc, 0) == -1) { > > - kbd_fakekey2(vc, RA_DOWN_ARROW); > > + del_timer(&cursor_timer); > > + if (!in_keyboard_notifier) > > + speakup_fake_down_arrow(); > > + start_read_all_timer(vc, RA_DOWN_ARROW); > > } else { > > say_sentence_num(0, 0); > > synth_insert_next_index(0); > > @@ -2212,8 +2217,10 @@ static int keyboard_notifier_call(struct > > int ret = NOTIFY_OK; > > static int keycode; /* to hold the current keycode */ > > > > + in_keyboard_notifier = 1; > > + > > if (vc->vc_mode == KD_GRAPHICS) > > - return ret; > > + goto out; > > > > /* > > * First, determine whether we are handling a fake keypress on > > @@ -2225,7 +2232,7 @@ static int keyboard_notifier_call(struct > > */ > > > > if (speakup_fake_key_pressed()) > > - return ret; > > + goto out; > > > > switch (code) { > > case KBD_KEYCODE: > > @@ -2266,6 +2273,8 @@ static int keyboard_notifier_call(struct > > break; > > } > > } > > +out: > > + in_keyboard_notifier = 0; > > return ret; > > } > > > > -- > Your life is like a penny. You're going to lose it. The question is: > How do > you spend it? > > John Covici > covici@ccs.covici.com >