From patchwork Wed Feb 16 00:18:03 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lino Sanfilippo X-Patchwork-Id: 12747755 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 57809C433EF for ; Wed, 16 Feb 2022 00:22:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=A58lq2uAz9QZGqfO8bFR4e99Woenm8msO4eaisNI+70=; b=eQPTEXpnMf2qyN tQ6yUeEWjmGjV7/HVU+ElwK6gIJAzIiVMVxphYE2LzJrtQjiQG6l3fDyJUdyefJLhymhwzWzzNyBw mnsRz1AyqF/huXL/dfR0OiVpKLmj/Dn3z06OITlUQCyW0M9y9qBLLkTDRLnrWkizzYjEK8X4g8Fwm YXuuh5VEhXoVgmjozNPL+skwiySSRSo3aPPoZnJGS+eQEacXXHVfHH4uleUnPp+7Wp+8Xz5ILdLx2 WvQwNnrSuAB+HPGWPajZKHQcbJXHIJg4hWgDwprbF6zTsPHPWh2yWXcUHi0vLZk4uBhH3NY3MuMj6 KlydufPiju62OC2B1WCQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nK848-0050tR-H4; Wed, 16 Feb 2022 00:21:05 +0000 Received: from mout.gmx.net ([212.227.15.18]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nK82B-00504F-3d for linux-arm-kernel@lists.infradead.org; Wed, 16 Feb 2022 00:19:04 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1644970727; bh=7qzWDUNopK0bho5I5nYj0J78qRs15cAksVO/Q8GWxsw=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date:In-Reply-To:References; b=eFU5XYTy+SpZQMBcsDZPHFLFN/heaRrGD12W2PBjm6CRz7xdnfZoP8qKfzPPfmuOc 3+6+eam14QnT0azUMnqf/WBAcu7kQiwsONOTFuW/SMqfsadjkX9ieNX/FDot6bU4kA OfiAarqevJrMmzFMdzFEyCjsspbIhflL4hq93ViQ= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from Venus.fritz.box ([149.172.237.68]) by mail.gmx.net (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1N6KYl-1oMKQo09Jx-016e1C; Wed, 16 Feb 2022 01:18:47 +0100 From: Lino Sanfilippo To: gregkh@linuxfoundation.org, jirislaby@kernel.org, u.kleine-koenig@pengutronix.de Subject: [PATCH 2 9/9] serial: atmel: remove redundant assignment in rs485_config Date: Wed, 16 Feb 2022 01:18:03 +0100 Message-Id: <20220216001803.637-10-LinoSanfilippo@gmx.de> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220216001803.637-1-LinoSanfilippo@gmx.de> References: <20220216001803.637-1-LinoSanfilippo@gmx.de> MIME-Version: 1.0 X-Provags-ID: V03:K1:zA2TdkclBElvUYZlMDu80hyoLmVC33BJetCeueVe0nw+noQF1V1 L/Ab3lZ4xwopWgLe/eddWpj7m2jLKl0mONq2uA12enhs6iQJxOtpVQrJETJo4TM51LKZ6c0 +Y+sXtpzeFP2FmWNq4E4DBv6OtQJnx4A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BpbCJugA5GMy1hUwNtAaW6axViMSoDL8/TzxtgqZvxLvif6yTKj0jhC2Q4jyTfrty/siL099k CjFptrr3RbHdWUyu1uOgXqDEabjS0WNKBHkjoqzVhI9EDsVw5kp9FKIVtUBhGcqSqIBStgeyg QCIQxHcXHriSmE= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220215_161903_484561_930C2BD7 X-CRM114-Status: GOOD ( 11.01 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arm-kernel@lists.infradead.org, alexandre.belloni@bootlin.com, mcoquelin.stm32@gmail.com, Lino Sanfilippo , richard.genoud@gmail.com, festevam@gmail.com, s.hauer@pengutronix.de, linux@armlinux.org.uk, alexandre.torgue@foss.st.com, ludovic.desroches@microchip.com, lukas@wunner.de, linux-imx@nxp.com, kernel@pengutronix.de, linux-serial@vger.kernel.org, shawnguo@kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-kernel@vger.kernel.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org In uart_set_rs485_config() the serial core already assigns the passed serial_rs485 struct to the uart port. So remove the assignment from the drivers rs485_config() function to avoid redundancy. Signed-off-by: Lino Sanfilippo Acked-by: Richard Genoud --- drivers/tty/serial/atmel_serial.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/tty/serial/atmel_serial.c b/drivers/tty/serial/atmel_serial.c index 2d09a89974a2..2ab589a3d86c 100644 --- a/drivers/tty/serial/atmel_serial.c +++ b/drivers/tty/serial/atmel_serial.c @@ -299,11 +299,9 @@ static int atmel_config_rs485(struct uart_port *port, /* Resetting serial mode to RS232 (0x0) */ mode &= ~ATMEL_US_USMODE; - port->rs485 = *rs485conf; - if (rs485conf->flags & SER_RS485_ENABLED) { dev_dbg(port->dev, "Setting UART to RS485\n"); - if (port->rs485.flags & SER_RS485_RX_DURING_TX) + if (rs485conf->flags & SER_RS485_RX_DURING_TX) atmel_port->tx_done_mask = ATMEL_US_TXRDY; else atmel_port->tx_done_mask = ATMEL_US_TXEMPTY;