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 X-Spam-Level: X-Spam-Status: No, score=-15.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 394BFC432BE for ; Fri, 27 Aug 2021 20:57:53 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 4315C60EE4 for ; Fri, 27 Aug 2021 20:57:52 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 4315C60EE4 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 5510A832B3; Fri, 27 Aug 2021 22:57:44 +0200 (CEST) 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="IFgiEl47"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 24C0C83212; Fri, 27 Aug 2021 22:57:37 +0200 (CEST) Received: from mail-io1-xd2f.google.com (mail-io1-xd2f.google.com [IPv6:2607:f8b0:4864:20::d2f]) (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 B6A42832AD for ; Fri, 27 Aug 2021 22:57:33 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=aford173@gmail.com Received: by mail-io1-xd2f.google.com with SMTP id b7so10226726iob.4 for ; Fri, 27 Aug 2021 13:57:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=6H9B+nPtS5P/KuzsndfRqWWrCtAdfXX7QujqkPq6ymY=; b=IFgiEl4763Fgy5i+kvOT1EOV7xBMspNFrTNkylWNSKaHNo6Do5DphwoOiD6zTymxlZ ZZZXJyyN4wwXXh/NcjUiygq9IK+dUobFSPqXm1cHS17670tipaS2SyQfc5GQC0HriDs7 AibSC/BLDkJL8LVSUSRDUDDoQJVuw5+M5I+YoG4Yk9YGrINvKhZfsFrdRK5VhPtp1yCt JkTgf1NRxLXgQOxtFXC5UKYhVp2nPvxOiUQEAjjLorE39TfogkoTBC4kldb4VN1lXONm F/giuApib25LPHVd2rvJ6f2pmhPGfXUJ+ng3uyY6VTrN9T/oP2RK3RO/nu2Sw/EWlEpY iYBQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=6H9B+nPtS5P/KuzsndfRqWWrCtAdfXX7QujqkPq6ymY=; b=LA+K8HmrLeIkTd3ckOBL8b9Fd0TvbYkdmU4zWD1/vElvig19euseiYlEYUKB63LX8a HbFodA9UheYFPMMfPDQ3RRTWh9vYBHzVksWBTTfmyOLL9FKhv5zt8yVPdNGegK12E97k 351n2XSkwB9Orab6HGUEGd+zdWHBjfXG1napSrq0jt7anwn7hmG6ohSRwbG6m0CCc054 r0M4n41E1TWKkm8jy9FCoKF4VLDbKveKnj8Nv0kTL2WMK0UYvcvxEAAe954Rjt4xHt+q Ff84ntgd0JhlkyC0xqMCWDZX7uSDRnF3TyXsGj8ARFB9tgyILelFbqN053o062szHEIl BPlA== X-Gm-Message-State: AOAM532TysD35GWpllI95vtbabmMW3LxGvUgQ+r8nCy3Iq53sh/5GItd LgXA9DujxYPl3xWT6on69kPL5jk+fKEwOw== X-Google-Smtp-Source: ABdhPJyVGx7GDSUNubztV/0SF0tsdvUxsast8f7iOjv0EDS/Wqpb80TGpkM0nNLV+2/q7jDLT3Q9DQ== X-Received: by 2002:a5d:990f:: with SMTP id x15mr8960345iol.200.1630097851662; Fri, 27 Aug 2021 13:57:31 -0700 (PDT) Received: from aford-IdeaCentre-A730.lan (c-73-37-219-234.hsd1.mn.comcast.net. [73.37.219.234]) by smtp.gmail.com with ESMTPSA id u10sm4238203ilg.15.2021.08.27.13.57.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 27 Aug 2021 13:57:31 -0700 (PDT) From: Adam Ford To: u-boot@lists.denx.de Cc: marek.vasut+renesas@gmail.com, biju.das.jz@bp.renesas.com, Adam Ford Subject: [PATCH 2/2] arm: rmobile: Remove duplicate code from beacon-rzg2m and hihope-rzg2 Date: Fri, 27 Aug 2021 15:57:18 -0500 Message-Id: <20210827205718.536008-2-aford173@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210827205718.536008-1-aford173@gmail.com> References: <20210827205718.536008-1-aford173@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.2 at phobos.denx.de X-Virus-Status: Clean With reset_cpu() now existing in common code, there is no need to have this exist in each board. Signed-off-by: Adam Ford diff --git a/board/beacon/beacon-rzg2m/beacon-rzg2m.c b/board/beacon/beacon-rzg2m/beacon-rzg2m.c index c12ff77fb2..f5146594b5 100644 --- a/board/beacon/beacon-rzg2m/beacon-rzg2m.c +++ b/board/beacon/beacon-rzg2m/beacon-rzg2m.c @@ -27,12 +27,3 @@ int board_init(void) return 0; } - -#define RST_BASE 0xE6160000 -#define RST_CA57RESCNT (RST_BASE + 0x40) -#define RST_CODE 0xA5A5000F - -void reset_cpu(void) -{ - writel(RST_CODE, RST_CA57RESCNT); -} diff --git a/board/hoperun/hihope-rzg2/hihope-rzg2.c b/board/hoperun/hihope-rzg2/hihope-rzg2.c index c1db387b27..59e124c829 100644 --- a/board/hoperun/hihope-rzg2/hihope-rzg2.c +++ b/board/hoperun/hihope-rzg2/hihope-rzg2.c @@ -16,12 +16,6 @@ #include #include -#define RST_BASE 0xE6160000 -#define RST_CA57RESCNT (RST_BASE + 0x40) -#define RST_CA53RESCNT (RST_BASE + 0x44) -#define RST_CA57_CODE 0xA5A5000F -#define RST_CA53_CODE 0x5A5A000F - DECLARE_GLOBAL_DATA_PTR; #define HSUSB_MSTP704 BIT(4) /* HSUSB */ @@ -65,19 +59,6 @@ int board_init(void) return 0; } -void reset_cpu(void) -{ - unsigned long midr, cputype; - - asm volatile("mrs %0, midr_el1" : "=r" (midr)); - cputype = (midr >> 4) & 0xfff; - - if (cputype == 0xd03) - writel(RST_CA53_CODE, RST_CA53RESCNT); - else - writel(RST_CA57_CODE, RST_CA57RESCNT); -} - #if defined(CONFIG_MULTI_DTB_FIT) /* If the firmware passed a device tree, use it for board identification. */ extern u64 rcar_atf_boot_args[]; -- 2.25.1