Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3840820pxj; Tue, 11 May 2021 13:06:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx8aSiq+QqoQnr4dfUKLN9gYraH4GcuxhLHpDSEZ/qu531BTgdk+Q1IJm39gV4gP1VrQj+g X-Received: by 2002:a05:6402:1052:: with SMTP id e18mr21327292edu.366.1620763614654; Tue, 11 May 2021 13:06:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620763614; cv=none; d=google.com; s=arc-20160816; b=sBHyJcqLyGZg4jiJrXlQJy2kpzbUPe0GXdarTA3Zxcvakozd3+bSVT98NQfBA5eIsZ z2Zb6Oh5n2i4a074NcrNv4lZrvT/pYO5C0j4fg+nXIlzTrUmXXV6PZicPTmsJJfRUjXu Q+PJciGfDNu1B03DpCWDRADKk4mWDvOwY1ggC5+X+lurQ7yeMnS+2sAkGNlUeHIaEVCs hqWDpSazwogUy9B0uSY179Cs3mzBhjvGDyRGGIb7chWePEJcLrBd0W4riJF8XINDHu/m g4Bbi21VeDRY+A/8L6onljAQkRVRDjHkeGRed+gY1qSin93KUO8zTkDcVu+jiS97uM+2 5xvA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=+rQ+/O26dzW1w2t4ljTQp+H/oyZCpkAzLKavXR6vwAE=; b=s/SndjBCFYfRDNw14MQ2FB5ElnTOXYpQgCyyjZg4fw2eTuZiTAxr7QnU0h5Q9xKIkd rOBxf2s5wGYAouXBUFlOW+yhuIi08WA0NkX7cJ+SKx3uRumaa6iUJVvwqfIDI/KCYfDR vtnD7HLoxC9yzx9D5QOxG2ZZhWb5x166bIIhbK5/5EQJBVT9RNAkl8gFhpMFHLjA43/N BVikdyWRYpCjgMMffVbNPYpsegxDWLHg2gNM0sMzrkk60T6UC/L6hXPtuVxW+flVWvU2 63Nj7MDiGX5VfYbXeHOrKiNo/ZpNV/LM/aCORu5NJe751TOm4UCj28g7Yo/KM3ebgSoU VUMA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@walle.cc header.s=mail2016061301 header.b="sIa6/0q2"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b7si17611686ejv.300.2021.05.11.13.06.30; Tue, 11 May 2021 13:06:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@walle.cc header.s=mail2016061301 header.b="sIa6/0q2"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230306AbhEKUDd (ORCPT + 99 others); Tue, 11 May 2021 16:03:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40154 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230130AbhEKUDN (ORCPT ); Tue, 11 May 2021 16:03:13 -0400 Received: from ssl.serverraum.org (ssl.serverraum.org [IPv6:2a01:4f8:151:8464::1:2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0966DC061574; Tue, 11 May 2021 13:02:06 -0700 (PDT) Received: from mwalle01.fritz.box (unknown [IPv6:2a02:810c:c200:2e91:fa59:71ff:fe9b:b851]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ssl.serverraum.org (Postfix) with ESMTPSA id 0778822270; Tue, 11 May 2021 22:02:04 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=walle.cc; s=mail2016061301; t=1620763324; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=+rQ+/O26dzW1w2t4ljTQp+H/oyZCpkAzLKavXR6vwAE=; b=sIa6/0q2Y+vJHJieHtCBz0wFVQ20yOjApp8POjbu9Efa1NMzdEWdEIp2c1fOQ+cAK7wQnI 2PL/LR835KPaHHpn2MofpKXs9mI1JOCAI4EnKQcv17/n7p0REj1JHLx7fTAA4cHdeb++GF /2iv8heO7f64/62S0YnhntJjICwb2Dg= From: Michael Walle To: linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , Jiri Slaby , Angelo Dureghello , Fugang Duan , Philippe Schenker , Michael Walle Subject: [PATCH 5/8] serial: fsl_lpuart: remove RTSCTS handling from get_mctrl() Date: Tue, 11 May 2021 22:01:45 +0200 Message-Id: <20210511200148.11934-6-michael@walle.cc> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20210511200148.11934-1-michael@walle.cc> References: <20210511200148.11934-1-michael@walle.cc> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The wrong code in set_mctrl() was already removed in commit 2b30efe2e88a ("tty: serial: lpuart: Remove unnecessary code from set_mctrl"), but the code in get_mctrl() wasn't removed. It will not return the state of the RTS or CTS line but whether automatic flow control is enabled, which is wrong for the get_mctrl(). Thus remove it. Fixes: 2b30efe2e88a ("tty: serial: lpuart: Remove unnecessary code from set_mctrl") Signed-off-by: Michael Walle --- drivers/tty/serial/fsl_lpuart.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/drivers/tty/serial/fsl_lpuart.c b/drivers/tty/serial/fsl_lpuart.c index 0a578ad31a19..74c04dba02d4 100644 --- a/drivers/tty/serial/fsl_lpuart.c +++ b/drivers/tty/serial/fsl_lpuart.c @@ -1418,17 +1418,7 @@ static unsigned int lpuart_get_mctrl(struct uart_port *port) static unsigned int lpuart32_get_mctrl(struct uart_port *port) { - unsigned int temp = 0; - unsigned long reg; - - reg = lpuart32_read(port, UARTMODIR); - if (reg & UARTMODIR_TXCTSE) - temp |= TIOCM_CTS; - - if (reg & UARTMODIR_RXRTSE) - temp |= TIOCM_RTS; - - return temp; + return 0; } static void lpuart_set_mctrl(struct uart_port *port, unsigned int mctrl) -- 2.20.1