From mboxrd@z Thu Jan 1 00:00:00 1970 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 phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7F718C61DA4 for ; Sat, 18 Feb 2023 15:27:51 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 189B085A18; Sat, 18 Feb 2023 16:27:49 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="h5x4SRA3"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id C611C851EB; Sat, 18 Feb 2023 16:27:46 +0100 (CET) Received: from mail-wm1-x333.google.com (mail-wm1-x333.google.com [IPv6:2a00:1450:4864:20::333]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 2188F85A28 for ; Sat, 18 Feb 2023 16:27:42 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jbx6244@gmail.com Received: by mail-wm1-x333.google.com with SMTP id j27so700232wms.3 for ; Sat, 18 Feb 2023 07:27:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id:from:to :cc:subject:date:message-id:reply-to; bh=je2XLdGSVHF77e+XxaahJdU5PEwZYYwpNeuQDjboRB8=; b=h5x4SRA3h0HXBZWh6HV7MVLAKTCjdw0pHN5SfXDlRhFRJJK4ZE47HxmevL4baq/vFM Y7ebPQ1EdLvSSv2ccshyLPy8guEKUM6S396YkAZctO0/e+ZevyfpmyBHI1juNR6pfOM4 TzWL24G8EzANpoRnDTE8p+ztnYA23wM1xnX9nR8Dj9T2GyVm1rqTS77MZ7haMVNMVdHc jMwQB7W3hM9W4xqZMBylthAvznVOCx6uAylMSknA9ACYeMIdUS1KLY3LLfv5qYJZkVJn iEw+FeJOAdWecnPdHRLtYvI/RI9Blq5AxrYsr8tIB1vdz0mXXcYF3eRaTNoIQKcKl3OB 5aRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=je2XLdGSVHF77e+XxaahJdU5PEwZYYwpNeuQDjboRB8=; b=olL1QyYPJdmaL7XgLrZ5vYMSLsOo4JeSqRYSrkYuOSdXQgsRuxwjR8vx46WscV6b+Q Q6FLR2B3CV+LW47UTHbvuykoSYuQhsKYRAgdxX4yvWWdkmA7tQhHWqpidQ9HTZcp4Pjx GQbPwdYqcj746z8CSEjgYgc8kRpj3L7A6MFrATci324nB7mH357T6AY6yJPsPz2edLEd LKwT31qfC5oVIFSbeyUQYAG1M8600zx4VSctwm1elF6/4U4d/UJw0rsmnE0P9I2u9cOX Z54Iak6aBNBukOqyZtixuMd/svLQeEPENPNk/gOW6EMJjcSGEA/CksDiK6wYFaxy2vY4 xlRg== X-Gm-Message-State: AO0yUKViWmTQ+bpl0Jicngz0vE2ju85R+p0P1im1gq6qRnCPeQQZwcVt h6BveOjL3YDzWTWjEjQjlho= X-Google-Smtp-Source: AK7set9Q3ar/Ml3IyD6FvAeSYrZnw4dTuMONyzpP0JsU63hghQULng3I0No20xg6hoBwYEVsH5bDNg== X-Received: by 2002:a05:600c:4d94:b0:3e0:1a9:b1e0 with SMTP id v20-20020a05600c4d9400b003e001a9b1e0mr3234891wmp.25.1676734061542; Sat, 18 Feb 2023 07:27:41 -0800 (PST) Received: from [192.168.2.1] (81-204-249-205.fixed.kpn.net. [81.204.249.205]) by smtp.gmail.com with ESMTPSA id j1-20020a05600c410100b003dec22de1b1sm8335299wmi.10.2023.02.18.07.27.40 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 18 Feb 2023 07:27:41 -0800 (PST) Message-ID: <8696a7cf-ce5d-b1ea-ab65-2f0d9bf8b7ff@gmail.com> Date: Sat, 18 Feb 2023 16:27:40 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.6.0 From: Johan Jonker Subject: [PATCH v4 05/11] rockchip: timer: dw-apb-timer: convert dev_read_addr output to phys_addr_t To: dario.binacchi@amarulasolutions.com, michael@amarulasolutions.com, sjg@chromium.org Cc: philipp.tomsich@vrull.eu, kever.yang@rock-chips.com, u-boot@lists.denx.de, yifeng.zhao@rock-chips.com References: Content-Language: en-US In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 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" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean The fdt_addr_t and phys_addr_t size have been decoupled. A 32bit CPU can expect 64-bit data from the device tree parser, so convert dev_read_addr output to phys_addr_t in the dw-apb-timer.c file. Signed-off-by: Johan Jonker Reviewed-by: Kever Yang --- drivers/timer/dw-apb-timer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/timer/dw-apb-timer.c b/drivers/timer/dw-apb-timer.c index 10f0a9f6..f55a3c54 100644 --- a/drivers/timer/dw-apb-timer.c +++ b/drivers/timer/dw-apb-timer.c @@ -23,7 +23,7 @@ #define DW_APB_CTRL 0x8 struct dw_apb_timer_priv { - fdt_addr_t regs; + phys_addr_t regs; struct reset_ctl_bulk resets; }; @@ -92,7 +92,7 @@ static int dw_apb_timer_of_to_plat(struct udevice *dev) if (CONFIG_IS_ENABLED(OF_REAL)) { struct dw_apb_timer_priv *priv = dev_get_priv(dev); - priv->regs = dev_read_addr(dev); + priv->regs = (phys_addr_t)dev_read_addr(dev); } return 0; -- 2.20.1