From patchwork Tue Jul 16 08:49:04 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiko Schocher X-Patchwork-Id: 1132529 X-Patchwork-Delegate: marek.vasut@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=denx.de Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 45nvHL1FcDz9sN4 for ; Tue, 16 Jul 2019 18:50:22 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id BB9D5C21E2C; Tue, 16 Jul 2019 08:50:03 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 613ECC21E2C; Tue, 16 Jul 2019 08:50:01 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id F3D05C21E53; Tue, 16 Jul 2019 08:49:51 +0000 (UTC) Received: from mail-out.m-online.net (mail-out.m-online.net [212.18.0.10]) by lists.denx.de (Postfix) with ESMTPS id A97ACC21D4A for ; Tue, 16 Jul 2019 08:49:47 +0000 (UTC) Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 45nvGg3mg3z1rY5f for ; Tue, 16 Jul 2019 10:49:47 +0200 (CEST) Received: from localhost (dynscan1.mnet-online.de [192.168.6.70]) by mail.m-online.net (Postfix) with ESMTP id 45nvGg3ckBz1qwLN for ; Tue, 16 Jul 2019 10:49:47 +0200 (CEST) X-Virus-Scanned: amavisd-new at mnet-online.de Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.70]) (amavisd-new, port 10024) with ESMTP id wqZ-sSg9z_0c for ; Tue, 16 Jul 2019 10:49:46 +0200 (CEST) X-Auth-Info: xGgyzVTcSTCLma2Zdz+IqKuJemfRg+x+XsszCIPcjgU= Received: from mail-internal.denx.de (p578adb1c.dip0.t-ipconnect.de [87.138.219.28]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.mnet-online.de (Postfix) with ESMTPSA for ; Tue, 16 Jul 2019 10:49:46 +0200 (CEST) Received: from pollux.denx.de (pollux [192.168.1.1]) by mail-internal.denx.de (Postfix) with ESMTP id BBE7D1854D6; Tue, 16 Jul 2019 10:49:10 +0200 (CEST) Received: by pollux.denx.de (Postfix, from userid 515) id B8B6B1A00A1; Tue, 16 Jul 2019 10:49:10 +0200 (CEST) From: Heiko Schocher To: U-Boot Mailing List Date: Tue, 16 Jul 2019 10:49:04 +0200 Message-Id: <20190716084907.1568340-3-hs@denx.de> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190716084907.1568340-1-hs@denx.de> References: <20190716084907.1568340-1-hs@denx.de> MIME-Version: 1.0 Cc: Marek Vasut , Sven Schwermer Subject: [U-Boot] [PATCH v1 2/5] usb, ohci: fix ohci swap register access X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" commit 57faca19a82f ("drivers: USB: OHCI: allow compilation for 64-bit targets") broke ohci support for the mpc85xx based socrates board, as it removed volatile keyword from ohci_readl/writel. Fix this so usb works again on socrates board. Signed-off-by: Heiko Schocher --- drivers/usb/host/ohci.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/host/ohci.h b/drivers/usb/host/ohci.h index f9f02cb09c..9b264bd92a 100644 --- a/drivers/usb/host/ohci.h +++ b/drivers/usb/host/ohci.h @@ -14,8 +14,8 @@ #include #ifdef CONFIG_SYS_OHCI_SWAP_REG_ACCESS -# define ohci_readl(a) __swap_32(readl(a)) -# define ohci_writel(v, a) writel(__swap_32(v), a) +# define ohci_readl(a) __swap_32(in_be32((u32 *)a)) +# define ohci_writel(a, b) out_be32((u32 *)b, __swap_32(a)) #else # define ohci_readl(a) readl(a) # define ohci_writel(v, a) writel(v, a)