From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by befuddled.reisers.ca (Postfix, from userid 65534) id AF5F01F08A7; Sat, 28 Jan 2017 12:49:09 -0500 (EST) Received: from mail-qk0-x229.google.com (mail-qk0-x229.google.com [IPv6:2607:f8b0:400d:c09::229]) by befuddled.reisers.ca (Postfix) with ESMTPS id D6F3B1F089A for ; Sat, 28 Jan 2017 12:49:07 -0500 (EST) Received: by mail-qk0-x229.google.com with SMTP id u25so92725040qki.2 for ; Sat, 28 Jan 2017 09:49:07 -0800 (PST) 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=pZMi20vw+mBVhoDoRaxJ5txVYCMKS1e7wJi1149JqCs=; b=FFf65p4ua8NpAkdsTbL7rzv3jyIL3vrCoW9Jk+t2DkmeEvmRVAkhaU2pVXMmSAyaqN eHml6B/lljomWkhTj1BRhF+o1LefNBbWtWZn5SIEz8b97zNuGw3gEGy2y6zaMlLzYo6N JstdScD+3s70gHAOIahH76IYyn7f9v3V86xuy6tir74dts4cSkme6oaT3W+t4HwQJYal XeHKdU+AyTWwaiJwsnnum1lCinYN+ueBAWyEFHQkoj1uIm7hxGGGVxOnEDiIHnqmOxd/ 001vv3wa2NeM2JwwgJBuEaXNqb6YLXMxFzAoGldI8qL+ItC+2nHDhdB/Otj+GDNe17g+ PySA== 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=pZMi20vw+mBVhoDoRaxJ5txVYCMKS1e7wJi1149JqCs=; b=ABFqmzGprLKavZwPcn2VPgEc0WQ7ZIL/uMYOucw8HTR7z/rOh/2HKvh2HMG3r7eNu7 YpQuvK9co7BCmAztyfyH80eFllc1FWgzEAi1KhLctmwbsII5RsqfBayVmJcEH4SSpVuo vdgrXbpDkviMqSxHOP9F3bMQ4wcl9fkfgBKe1Wvp9GqSgt4yBthMTidlsiiycGgZdi4x KDtv51oyEcc1o51yrfSeyMug1XcBFgQEH46oQjvF4PMXqNkHLRoTpqNBKqyeZoBCihyt cnq4G34M0xpdi4pHPviWvwpGcCT4bb99YPrlgUMefZQGmFMYU7OtC1ABaWpkrQne2IDO lnNQ== X-Gm-Message-State: AIkVDXIFduwTjYEGP4LnT2Rl5Roi7StTR2qbbatMjibCUEFMcGX9JlBfgSnzKpQn65FpzsdiMaRlAh3GGQ7LFg== X-Received: by 10.55.15.231 with SMTP id 100mr13872673qkp.244.1485625741780; Sat, 28 Jan 2017 09:49:01 -0800 (PST) MIME-Version: 1.0 Received: by 10.200.44.8 with HTTP; Sat, 28 Jan 2017 09:49:01 -0800 (PST) In-Reply-To: <20170126083312.GB25343@var.home> References: <20161220010836.GN2895@var.home> <20170124083045.GN2695@var.home> <20170126001801.GQ3119@var.home> <20170126083312.GB25343@var.home> From: Okash Khawaja Date: Sat, 28 Jan 2017 17:49:01 +0000 Message-ID: Subject: Re: Line discipline To: Samuel Thibault Cc: "Speakup is a screen review system for Linux." Content-Type: text/plain; charset=UTF-8 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 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: Sat, 28 Jan 2017 17:49:09 -0000 Hi, On Thu, Jan 26, 2017 at 8:33 AM, Samuel Thibault wrote: > Okash Khawaja, on Thu 26 Jan 2017 08:24:29 +0000, wrote: >> >> +static void speakup_ldisc_close(struct tty_struct *tty) >> >> +{ >> >> + pr_warn("speakup_test_close()\n"); >> > >> > Does it get called at speakup_dummy removal time? >> >> No > > Ok. I guess what we are missing is some part of the rest of > tty_release(). We notably seem to be lacking tty_ldisc_release(tty); > between tty_unlock and tty_flush_works. Added tty_ldisc_release() which resolved the problem. Also added tty_ldisc_flush() before tty_ldisc_release(). Wouldn't it be safer to add those functions before tty_unlock()? The only output I get from speakup_dummy is: Speakup RATE 8 PITCH 8 VOL 8 TONE 8 Dummy found That's same before and after this ldisc change. I looked around for tty release code, specifically tty_release() in drivers/tty/tty_io.c. Not sure if there's something else missing here. The modules seem to load and unload (multiple times) okay. Kernel log doesn't show anything odd. I'll still do some more tests and make the changes you suggested above before sharing the patch. > > Samuel Thanks, Okash