From patchwork Thu Jun 16 20:04:35 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Janusz Krzysztofik X-Patchwork-Id: 9181523 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 73D9560776 for ; Thu, 16 Jun 2016 20:05:23 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6792028375 for ; Thu, 16 Jun 2016 20:05:23 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5BD5D2837F; Thu, 16 Jun 2016 20:05:23 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.8 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, HK_RANDOM_FROM, RCVD_IN_DNSWL_NONE, T_DKIM_INVALID autolearn=no version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 83A8028375 for ; Thu, 16 Jun 2016 20:05:21 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id E7465266D64; Thu, 16 Jun 2016 22:05:19 +0200 (CEST) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 30373266BEA; Thu, 16 Jun 2016 22:05:12 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 73F85266CE8; Thu, 16 Jun 2016 22:05:10 +0200 (CEST) Received: from mail-lf0-f66.google.com (mail-lf0-f66.google.com [209.85.215.66]) by alsa0.perex.cz (Postfix) with ESMTP id 62EC72669F9 for ; Thu, 16 Jun 2016 22:05:03 +0200 (CEST) Received: by mail-lf0-f66.google.com with SMTP id l184so6530876lfl.1 for ; Thu, 16 Jun 2016 13:05:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=GoHHffQRi3DnhxfqwVeLH7IOBpE+EZVuR2pcyGesGfA=; b=WoNpARmok8QbMjZDPNBqtEdzcuqwewjdbfGcy7p3rhwDdEL8T6VpGWKoppbJHTmh3f OuF5104Q0nv8fIMhCM57kFTALKrC0jV0NrYV4ba2/jpm+hqAU3xTks4tm3swpggmeZ8F 66yDwkZbec7nH7wjaXsoxv6CWtH7gNNj49AaRbnXx3+uEa/6C2GCAhlgxiSDAiK/C783 MAXYoMW+mKsfvb7qrKRP6G+SQdor/1Y1EyDK8EOuw+bzx56Q/Y/qWiU/4wSiicT3YYgI PrCM1pjp33xOBr9BLKsq0StAh0u6Utmss0w87Oikq2qvC+oCIpal8fwwHfYsiO3E/Va6 kGXg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=GoHHffQRi3DnhxfqwVeLH7IOBpE+EZVuR2pcyGesGfA=; b=lk+ZEJs6BOApie/gRU5MbsjFgr0k+mhWeB5nJjDXTFxfAmdcr0/HL+zS4gPeDks3UW uaCLNeJEBJ9EkeRC67axLDiKPxnm2pqzj1a2Mc8OV9U8qDT0whLIFsziFV/Q7meVPi4M 8/wVRQnWs8kDmgEmr3O20vojvT13efJwnTVxzlabE8G3l8BSJxBmMhTuafh+e+4BNiMW oWxauZDrC9ygy4/2sliE7PKjTRtWGK5yaq3ZYH7jajAutarWbpzx5J2NAzDmY/RTjg/y WMQvTsaM9OGyDtnWcpCdwEWIjBTA/4aFruGvgXS+4rtDf1aNtE9Kx8E9l6YR26Xt6MDw s0Cg== X-Gm-Message-State: ALyK8tJXD5bjnODB53+UYrBhRa+P38DYRwPs5/rawpfYW8eUaG5YpVsRZDqqN6J6sS5mYA== X-Received: by 10.25.15.159 with SMTP id 31mr1889834lfp.123.1466107502864; Thu, 16 Jun 2016 13:05:02 -0700 (PDT) Received: from z50.lan (93-181-165-181.internetia.net.pl. [93.181.165.181]) by smtp.gmail.com with ESMTPSA id t10sm4101294lfd.18.2016.06.16.13.05.01 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 16 Jun 2016 13:05:02 -0700 (PDT) From: Janusz Krzysztofik To: Mark Brown , Liam Girdwood Date: Thu, 16 Jun 2016 22:04:35 +0200 Message-Id: <1466107475-9747-1-git-send-email-jmkrzyszt@gmail.com> X-Mailer: git-send-email 2.7.3 Cc: linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org, Janusz Krzysztofik , Takashi Iwai Subject: [alsa-devel] [PATCH] snd: soc: cx20442 codec: set tty->receiver_room in v253_open X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP Commit 79901317ce80 ("n_tty: Don't flush buffer when closing ldisc"), introduced in v3.10, revealed a bug in the cx20442 codec driver which has never been setting tty->receive_room on line discipline open as it should from the beginning. Fix it. Created and tested on Amstrad Delta against Linux-4.7-rc3 Signed-off-by: Janusz Krzysztofik --- sound/soc/codecs/cx20442.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sound/soc/codecs/cx20442.c b/sound/soc/codecs/cx20442.c index d6f4abb..fb3885f 100644 --- a/sound/soc/codecs/cx20442.c +++ b/sound/soc/codecs/cx20442.c @@ -226,6 +226,7 @@ static int v253_open(struct tty_struct *tty) if (!tty->disc_data) return -ENODEV; + tty->receive_room = 16; if (tty->ops->write(tty, v253_init, len) != len) { ret = -EIO; goto err;