Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp2648148imj; Mon, 11 Feb 2019 06:26:37 -0800 (PST) X-Google-Smtp-Source: AHgI3IaHBq1dP3K4JqomzVqw7FGn2PRIV4gzIaHAGZEX3eNXmRM+DGMIM9TEvz73UGxxCQOe/GVx X-Received: by 2002:a17:902:f24:: with SMTP id 33mr37809519ply.65.1549895196978; Mon, 11 Feb 2019 06:26:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549895196; cv=none; d=google.com; s=arc-20160816; b=q1mXSBOi5vv7UEzpTStXXQJiivDV3zcFATzlaOh6ei+waq8xCKhMJSeEt2LdeBoFLr lfZE8OSUEkzeydH1PH31uZrBABjMPrnl9P2YP/Bnby7EvE9rW85wr6MZFOwOikiLwqvW Hct0WAjcYmbLTXWcZEQeekxuzgnzsEQQUr+AM1ihtiQs0HxNpvpvzwKAstlrOKStZrKz Yg8KkrscZDT8Y8WPbz4qBBz2xYwGGnn1iA4KfSGV4NHD+dia4oZW1yiOMTIK7WDV+iJf iG8HsIt9TVPoPKarHBPOBGxsfqRyP9b45r5AzOIW2u3ap0KuIR66WhALkxTkSqvFTyZc 7fmg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=9ZVYc3Vqut8u0oZ+zpxEYojlallYtPpAb+LOqazCg2Y=; b=jspZSwzSvvsPzIjwJUDP7VSJ8DYscCCSRqbTo2KEADWPAgufTonvAl0jzRfPLTmEVR FcCzKw2pYNlFi0d6PM2icyUu+JVTF7CkjbhzLiUSbCtw9sjCehq5KqD0ow6g93pEdwGL qrC7vfG++rOkRrNkLH+3gpWP81fkCH6pwCWZh4uZVcII9EoNOU08D7+OWCd7APTSdEPN glLyhAG8tjnlHvsxijOT6xA9I711FcUTrSBm+5CaVYqsfvnajNIsrNYErdDB69xaLg/o sZ3PRRyWi37rQTdJAh5a0ckN4AFohbwmjjTNhiv5dy57gczaBaUj9VVyw4MF90dsWx8H Rmgg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=2EPmrGTA; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q70si9884059pgq.526.2019.02.11.06.26.21; Mon, 11 Feb 2019 06:26:36 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=2EPmrGTA; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728649AbfBKOWC (ORCPT + 99 others); Mon, 11 Feb 2019 09:22:02 -0500 Received: from mail.kernel.org ([198.145.29.99]:54886 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728640AbfBKOWB (ORCPT ); Mon, 11 Feb 2019 09:22:01 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (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 CAF87222AA; Mon, 11 Feb 2019 14:21:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1549894920; bh=zIuc1jMKdyBKdq1GqTjdwZmBk/2ehjvBH9lJHQ1MKSc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=2EPmrGTAOJ0ZGfRrKSjVojvrwjCTAYHC7GaxMEPi5yFQ2gUH+ier21xByOqkELNMy DvbqnYnfBpeYrUS1fqiYYFdoZTSfS5CK4LaDHUc8DImdrJxKulkzKKh46Q9I886Xzo WMHpazQ4vWRtg/53EXP3LeQliousvqQIKbDwiwuo= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Lukas Wunner , Andy Duan , Fabio Estevam , =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= , Sasha Levin Subject: [PATCH 4.20 031/352] serial: fsl_lpuart: clear parity enable bit when disable parity Date: Mon, 11 Feb 2019 15:14:18 +0100 Message-Id: <20190211141848.321240609@linuxfoundation.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190211141846.543045703@linuxfoundation.org> References: <20190211141846.543045703@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.20-stable review patch. If anyone has any objections, please let me know. ------------------ [ Upstream commit 397bd9211fe014b347ca8f95a8f4e1017bac1aeb ] Current driver only enable parity enable bit and never clear it when user set the termios. The fix clear the parity enable bit when PARENB flag is not set in termios->c_cflag. Cc: Lukas Wunner Signed-off-by: Andy Duan Reviewed-by: Fabio Estevam Acked-by: Uwe Kleine-König Signed-off-by: Greg Kroah-Hartman Signed-off-by: Sasha Levin --- drivers/tty/serial/fsl_lpuart.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/tty/serial/fsl_lpuart.c b/drivers/tty/serial/fsl_lpuart.c index 00c220e4f43c..086642ea4b26 100644 --- a/drivers/tty/serial/fsl_lpuart.c +++ b/drivers/tty/serial/fsl_lpuart.c @@ -1479,6 +1479,8 @@ lpuart_set_termios(struct uart_port *port, struct ktermios *termios, else cr1 &= ~UARTCR1_PT; } + } else { + cr1 &= ~UARTCR1_PE; } /* ask the core to calculate the divisor */ @@ -1690,6 +1692,8 @@ lpuart32_set_termios(struct uart_port *port, struct ktermios *termios, else ctrl &= ~UARTCTRL_PT; } + } else { + ctrl &= ~UARTCTRL_PE; } /* ask the core to calculate the divisor */ -- 2.19.1