Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932750AbeAHVpp (ORCPT + 1 other); Mon, 8 Jan 2018 16:45:45 -0500 Received: from smtp50.i.mail.ru ([94.100.177.110]:49652 "EHLO smtp50.i.mail.ru" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752168AbeAHVpo (ORCPT ); Mon, 8 Jan 2018 16:45:44 -0500 Date: Tue, 9 Jan 2018 00:45:30 +0300 From: Mikhail Zaytsev To: Johan Hovold Cc: Oliver Neukum , Greg Kroah-Hartman , linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org Subject: Re: [PATCH v2 1/2] USB: serial: ark3116: Remove unused TIOCSSERIAL ioctl case. Message-ID: <20180109004507.0b7ac1a2@debian> In-Reply-To: <20180108152858.GH11344@localhost> References: <20180106200809.41cdd723@debian> <20180106201402.03d2ac88@debian> <1515407612.29712.1.camel@suse.com> <20180108152858.GH11344@localhost> X-Mailer: Claws Mail 3.14.1 (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Authentication-Results: smtp50.i.mail.ru; auth=pass smtp.auth=flashed@mail.ru smtp.mailfrom=flashed@mail.ru X-7FA49CB5: 0D63561A33F958A54EEB60FEC234656F44A2CA877C2D78180646075F00B0E1E5725E5C173C3A84C3E219FEC04DD79C21B4F6D134972FDF61F3CCD8A865B74A75C4224003CC836476C0CAF46E325F83A50BF2EBBBDD9D6B0F2AF38021CC9F462D574AF45C6390F7469DAA53EE0834AAEE X-Mailru-Sender: 159DE679A9C6F657CB201B8725788872660F17B30572B38EF767F76C9C5057D86B4C15F81911EFCF35240BD9E37F4C362F445727719BCECB540ECE9B597817E15BECAF0817D12387B4A721A3011E896F X-Mras: OK Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: On Mon, 8 Jan 2018 16:28:58 +0100 Johan Hovold wrote: > On Mon, Jan 08, 2018 at 11:33:32AM +0100, Oliver Neukum wrote: > > Am Samstag, den 06.01.2018, 20:14 +0300 schrieb Mikhail Zaytsev: > > > The patch removes unused TIOCSSERIAL ioctl case and adds the default block > > > to the switch. This will make the ioctl return -ENOTTY to user space (e.g. > > > setserial), because TIOCSSERIAL really isn't supported for these devices > > > currently. > > > > Hi, > > > > this will break software that is now running on these devices, > > won't it? Do you know why those devices basically ignore the > > ioctl? > > Yeah, that was my initial reactions as well, but then again, any sane > user space cannot rely on these ioctl being implemented for all tty > devices. > > I did some digging now and these (dummy) ioctl implementations where > added by commit 2f430b4bbae7 ("USB: ark3116: Add TIOCGSERIAL and > TIOCSSERIAL ioctl calls.") back in 2006. This in turn appears to have > been triggered by a change in a user space tool, wvdial, which started > erroring out if either was missing. > > I found a couple of bug reports about that through google, and looking > at the wvstreams (library) code now, it looks like the issue has indeed > been resolved by handling errors more gracefully (e.g. just logging > them). > > So I'm willing to give this a try, and if anyone complains later we add > back (or implement) TIOCSSERIAL. > Thanks Johan. I looked the commit 2f430b4bbae7. Author just did a cut'n'paste from other USB serial drivers. I think that it would be better remove the TIOCGSERIAL implementation too. Mikhail