From patchwork Wed Jun 22 16:57:02 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Matthew Leach X-Patchwork-Id: 9193331 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 730A16075C for ; Wed, 22 Jun 2016 17:00:51 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6013B28409 for ; Wed, 22 Jun 2016 17:00:51 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 536E028415; Wed, 22 Jun 2016 17:00:51 +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=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id E532728409 for ; Wed, 22 Jun 2016 17:00:50 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.85_2 #1 (Red Hat Linux)) id 1bFlV1-0002Qm-H4; Wed, 22 Jun 2016 16:59:35 +0000 Received: from mx0.mattleach.net ([176.58.118.143]) by bombadil.infradead.org with esmtp (Exim 4.85_2 #1 (Red Hat Linux)) id 1bFlUt-0002Eg-DJ for linux-arm-kernel@lists.infradead.org; Wed, 22 Jun 2016 16:59:28 +0000 Received: by mx0.mattleach.net (Postfix, from userid 99) id C8D656222D; Wed, 22 Jun 2016 17:59:07 +0100 (BST) Received: from localhost.localdomain (host109-156-92-67.range109-156.btcentralplus.com [109.156.92.67]) by mx0.mattleach.net (Postfix) with ESMTPSA id B30076222E; Wed, 22 Jun 2016 17:58:40 +0100 (BST) From: Matthew Leach To: Krzysztof Kozlowski , Ben Dooks Subject: [PATCH v2 2/3] tty: serial: samsung: fixup accessors for endian Date: Wed, 22 Jun 2016 17:57:02 +0100 Message-Id: <20160622165703.7775-3-matthew@mattleach.net> X-Mailer: git-send-email 2.8.3 In-Reply-To: <20160622165703.7775-1-matthew@mattleach.net> References: <20160622165703.7775-1-matthew@mattleach.net> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160622_095927_694266_C4F663C2 X-CRM114-Status: UNSURE ( 8.95 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Matthew Leach , linux-samsung-soc@vger.kernel.org, Greg Kroah-Hartman , linux-kernel@vger.kernel.org, linux-serial@vger.kernel.org, Jiri Slaby , linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Fix the serial access code to deal with kernels built for big endian operation. Signed-off-by: Matthew Leach Acked-by: Ben Dooks Reviewed-by: Krzysztof Kozlowski --- CC: Greg Kroah-Hartman CC: Jiri Slaby CC: linux-serial@vger.kernel.org CC: linux-kernel@vger.kernel.org --- drivers/tty/serial/samsung.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/tty/serial/samsung.h b/drivers/tty/serial/samsung.h index fc5deaa..8f96b71 100644 --- a/drivers/tty/serial/samsung.h +++ b/drivers/tty/serial/samsung.h @@ -117,10 +117,10 @@ struct s3c24xx_uart_port { #define portaddrl(port, reg) \ ((unsigned long *)(unsigned long)((port)->membase + (reg))) -#define rd_regb(port, reg) (__raw_readb(portaddr(port, reg))) -#define rd_regl(port, reg) (__raw_readl(portaddr(port, reg))) +#define rd_regb(port, reg) (readb_relaxed(portaddr(port, reg))) +#define rd_regl(port, reg) (readl_relaxed(portaddr(port, reg))) -#define wr_regb(port, reg, val) __raw_writeb(val, portaddr(port, reg)) -#define wr_regl(port, reg, val) __raw_writel(val, portaddr(port, reg)) +#define wr_regb(port, reg, val) writeb_relaxed(val, portaddr(port, reg)) +#define wr_regl(port, reg, val) writel_relaxed(val, portaddr(port, reg)) #endif