]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
ARM: renesas: Rename RMOBILE_CPU_TYPE_* to RENESAS_CPU_TYPE_*
authorMarek Vasut <marek.vasut+renesas@mailbox.org>
Tue, 27 Feb 2024 16:05:47 +0000 (17:05 +0100)
committerTom Rini <trini@konsulko.com>
Sat, 2 Mar 2024 19:29:36 +0000 (14:29 -0500)
Rename RMOBILE_CPU_TYPE_* to RENESAS_CPU_TYPE_* because all
the chips are made by Renesas, while only a subset of them is
from the R-Mobile line.

Use the following command to perform the rename:

"
$ git grep -l '\<RMOBILE_CPU_TYPE_[A-Z0-9]\+\>' | \
  xargs -I {} sed -i 's@\<RMOBILE\(_CPU_TYPE_[A-Z0-9]\+\)\>@RENESAS\1@g' {}
"

Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Reviewed-by: Paul Barker <paul.barker.ct@bp.renesas.com>
arch/arm/mach-rmobile/cpu_info-rzg2l.c
arch/arm/mach-rmobile/cpu_info.c
arch/arm/mach-rmobile/include/mach/rmobile.h
board/renesas/salvator-x/salvator-x.c
board/renesas/ulcb/ulcb.c
drivers/mmc/renesas-sdhi.c
drivers/net/ravb.c
drivers/spi/renesas_rpc_spi.c

index ce7cc2a28db2a185b9c100cf23af80cafd2dc386..a1683a26e356490bab7694c8d6c5b51a805095db 100644 (file)
@@ -21,7 +21,7 @@ struct tfa_info {
 };
 
 static const struct tfa_info tfa_info[] = {
-       { "renesas,r9a07g044l2", "R9A07G044L", RMOBILE_CPU_TYPE_R9A07G044L },
+       { "renesas,r9a07g044l2", "R9A07G044L", RENESAS_CPU_TYPE_R9A07G044L },
 };
 
 static const struct tfa_info invalid_tfa_info = { NULL, "(invalid)", 0 };
index 35cfef2e1ab0e69d3d850ff27e061a0935f388a1..9c5ea4e6cd53adfe3f6415f7fc9dd3f5f1fcebc9 100644 (file)
@@ -62,22 +62,22 @@ static const struct {
        u16 cpu_type;
        u8 cpu_name[10];
 } rmobile_cpuinfo[] = {
-       { RMOBILE_CPU_TYPE_R8A7790, "R8A7790" },
-       { RMOBILE_CPU_TYPE_R8A7791, "R8A7791" },
-       { RMOBILE_CPU_TYPE_R8A7792, "R8A7792" },
-       { RMOBILE_CPU_TYPE_R8A7793, "R8A7793" },
-       { RMOBILE_CPU_TYPE_R8A7794, "R8A7794" },
-       { RMOBILE_CPU_TYPE_R8A7795, "R8A7795" },
-       { RMOBILE_CPU_TYPE_R8A7796, "R8A7796" },
-       { RMOBILE_CPU_TYPE_R8A77965, "R8A77965" },
-       { RMOBILE_CPU_TYPE_R8A77970, "R8A77970" },
-       { RMOBILE_CPU_TYPE_R8A77980, "R8A77980" },
-       { RMOBILE_CPU_TYPE_R8A77990, "R8A77990" },
-       { RMOBILE_CPU_TYPE_R8A77995, "R8A77995" },
-       { RMOBILE_CPU_TYPE_R8A779A0, "R8A779A0" },
-       { RMOBILE_CPU_TYPE_R8A779F0, "R8A779F0" },
-       { RMOBILE_CPU_TYPE_R8A779G0, "R8A779G0" },
-       { RMOBILE_CPU_TYPE_R8A779H0, "R8A779H0" },
+       { RENESAS_CPU_TYPE_R8A7790, "R8A7790" },
+       { RENESAS_CPU_TYPE_R8A7791, "R8A7791" },
+       { RENESAS_CPU_TYPE_R8A7792, "R8A7792" },
+       { RENESAS_CPU_TYPE_R8A7793, "R8A7793" },
+       { RENESAS_CPU_TYPE_R8A7794, "R8A7794" },
+       { RENESAS_CPU_TYPE_R8A7795, "R8A7795" },
+       { RENESAS_CPU_TYPE_R8A7796, "R8A7796" },
+       { RENESAS_CPU_TYPE_R8A77965, "R8A77965" },
+       { RENESAS_CPU_TYPE_R8A77970, "R8A77970" },
+       { RENESAS_CPU_TYPE_R8A77980, "R8A77980" },
+       { RENESAS_CPU_TYPE_R8A77990, "R8A77990" },
+       { RENESAS_CPU_TYPE_R8A77995, "R8A77995" },
+       { RENESAS_CPU_TYPE_R8A779A0, "R8A779A0" },
+       { RENESAS_CPU_TYPE_R8A779F0, "R8A779F0" },
+       { RENESAS_CPU_TYPE_R8A779G0, "R8A779G0" },
+       { RENESAS_CPU_TYPE_R8A779H0, "R8A779H0" },
        { 0x0, "CPU" },
 };
 
@@ -121,7 +121,7 @@ int print_cpuinfo(void)
 {
        int i = rmobile_cpuinfo_idx();
 
-       if (rmobile_cpuinfo[i].cpu_type == RMOBILE_CPU_TYPE_R8A7796 &&
+       if (rmobile_cpuinfo[i].cpu_type == RENESAS_CPU_TYPE_R8A7796 &&
            renesas_get_cpu_rev_integer() == 1 &&
            renesas_get_cpu_rev_fraction() == 1) {
                printf("CPU:   Renesas Electronics %s rev 1.1/1.2\n", get_cpu_name(i));
index d41b737d6b155bc962834837afc02fa37675fb94..67c480048deca539b3f5b6fd94d9a61e4ca346fa 100644 (file)
 #endif /* CONFIG_ARCH_RMOBILE */
 
 /* PRR CPU IDs */
-#define RMOBILE_CPU_TYPE_R8A7740       0x40
-#define RMOBILE_CPU_TYPE_R8A7790       0x45
-#define RMOBILE_CPU_TYPE_R8A7791       0x47
-#define RMOBILE_CPU_TYPE_R8A7792       0x4A
-#define RMOBILE_CPU_TYPE_R8A7793       0x4B
-#define RMOBILE_CPU_TYPE_R8A7794       0x4C
-#define RMOBILE_CPU_TYPE_R8A7795       0x4F
-#define RMOBILE_CPU_TYPE_R8A7796       0x52
-#define RMOBILE_CPU_TYPE_R8A77965      0x55
-#define RMOBILE_CPU_TYPE_R8A77970      0x54
-#define RMOBILE_CPU_TYPE_R8A77980      0x56
-#define RMOBILE_CPU_TYPE_R8A77990      0x57
-#define RMOBILE_CPU_TYPE_R8A77995      0x58
-#define RMOBILE_CPU_TYPE_R8A779A0      0x59
-#define RMOBILE_CPU_TYPE_R8A779F0      0x5A
-#define RMOBILE_CPU_TYPE_R8A779G0      0x5C
-#define RMOBILE_CPU_TYPE_R8A779H0      0x5D
-#define RMOBILE_CPU_TYPE_R9A07G044L    0x9A070440
+#define RENESAS_CPU_TYPE_R8A7740       0x40
+#define RENESAS_CPU_TYPE_R8A7790       0x45
+#define RENESAS_CPU_TYPE_R8A7791       0x47
+#define RENESAS_CPU_TYPE_R8A7792       0x4A
+#define RENESAS_CPU_TYPE_R8A7793       0x4B
+#define RENESAS_CPU_TYPE_R8A7794       0x4C
+#define RENESAS_CPU_TYPE_R8A7795       0x4F
+#define RENESAS_CPU_TYPE_R8A7796       0x52
+#define RENESAS_CPU_TYPE_R8A77965      0x55
+#define RENESAS_CPU_TYPE_R8A77970      0x54
+#define RENESAS_CPU_TYPE_R8A77980      0x56
+#define RENESAS_CPU_TYPE_R8A77990      0x57
+#define RENESAS_CPU_TYPE_R8A77995      0x58
+#define RENESAS_CPU_TYPE_R8A779A0      0x59
+#define RENESAS_CPU_TYPE_R8A779F0      0x5A
+#define RENESAS_CPU_TYPE_R8A779G0      0x5C
+#define RENESAS_CPU_TYPE_R8A779H0      0x5D
+#define RENESAS_CPU_TYPE_R9A07G044L    0x9A070440
 
 #ifndef __ASSEMBLY__
 #include <asm/types.h>
index 01571625e71df3386d6dff6b250e0048e3819af2..ca05285a09b20ce6f3a9915580598fbb0537627b 100644 (file)
@@ -78,15 +78,15 @@ int board_fit_config_name_match(const char *name)
        /* PRR driver is not available yet */
        u32 cpu_type = renesas_get_cpu_type();
 
-       if ((cpu_type == RMOBILE_CPU_TYPE_R8A7795) &&
+       if ((cpu_type == RENESAS_CPU_TYPE_R8A7795) &&
            !strcmp(name, "r8a77950-salvator-x-u-boot"))
                return 0;
 
-       if ((cpu_type == RMOBILE_CPU_TYPE_R8A7796) &&
+       if ((cpu_type == RENESAS_CPU_TYPE_R8A7796) &&
            !strcmp(name, "r8a77960-salvator-x-u-boot"))
                return 0;
 
-       if ((cpu_type == RMOBILE_CPU_TYPE_R8A77965) &&
+       if ((cpu_type == RENESAS_CPU_TYPE_R8A77965) &&
            !strcmp(name, "r8a77965-salvator-x-u-boot"))
                return 0;
 
index 5d7ebbd922fa0fc05da704a0c626f50e756bd162..6addf2bc8b4d5178007a07483a5f5f41217507a2 100644 (file)
@@ -69,15 +69,15 @@ int board_fit_config_name_match(const char *name)
        /* PRR driver is not available yet */
        u32 cpu_type = renesas_get_cpu_type();
 
-       if ((cpu_type == RMOBILE_CPU_TYPE_R8A7795) &&
+       if ((cpu_type == RENESAS_CPU_TYPE_R8A7795) &&
            !strcmp(name, "r8a77950-ulcb-u-boot"))
                return 0;
 
-       if ((cpu_type == RMOBILE_CPU_TYPE_R8A7796) &&
+       if ((cpu_type == RENESAS_CPU_TYPE_R8A7796) &&
            !strcmp(name, "r8a77960-ulcb-u-boot"))
                return 0;
 
-       if ((cpu_type == RMOBILE_CPU_TYPE_R8A77965) &&
+       if ((cpu_type == RENESAS_CPU_TYPE_R8A77965) &&
            !strcmp(name, "r8a77965-ulcb-u-boot"))
                return 0;
 
index 03e360ec1a2e640172c3f6d14f93acdbb980d972..82237ef3dbdd00eabd24e9ede30c616c9599824c 100644 (file)
@@ -885,28 +885,28 @@ static void renesas_sdhi_filter_caps(struct udevice *dev)
        struct tmio_sd_plat *plat = dev_get_plat(dev);
 
        /* HS400 is not supported on H3 ES1.x, M3W ES1.[012], V3M, V3H ES1.x, D3 */
-       if (((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A7795) &&
+       if (((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A7795) &&
            (renesas_get_cpu_rev_integer() <= 1)) ||
-           ((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A7796) &&
+           ((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A7796) &&
            (renesas_get_cpu_rev_integer() == 1) &&
            (renesas_get_cpu_rev_fraction() <= 2)) ||
-           (renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A77970) ||
-           ((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A77980) &&
+           (renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A77970) ||
+           ((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A77980) &&
            (renesas_get_cpu_rev_integer() <= 1)) ||
-           (renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A77995))
+           (renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A77995))
                plat->cfg.host_caps &= ~MMC_MODE_HS400;
 
        /* H3 ES2.0, ES3.0 and M3W ES1.2 and M3N bad taps */
-       if (((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A7795) &&
+       if (((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A7795) &&
            (renesas_get_cpu_rev_integer() >= 2)) ||
-           ((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A7796) &&
+           ((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A7796) &&
            (renesas_get_cpu_rev_integer() == 1) &&
            (renesas_get_cpu_rev_fraction() == 2)) ||
-           (renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A77965))
+           (renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A77965))
                priv->hs400_bad_tap = BIT(2) | BIT(3) | BIT(6) | BIT(7);
 
        /* M3W ES1.x for x>2 can use HS400 with manual adjustment and taps */
-       if ((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A7796) &&
+       if ((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A7796) &&
            (renesas_get_cpu_rev_integer() == 1) &&
            (renesas_get_cpu_rev_fraction() > 2)) {
                priv->adjust_hs400_enable = true;
@@ -917,12 +917,12 @@ static void renesas_sdhi_filter_caps(struct udevice *dev)
        }
 
        /* M3W+ bad taps */
-       if ((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A7796) &&
+       if ((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A7796) &&
            (renesas_get_cpu_rev_integer() == 3))
                priv->hs400_bad_tap = BIT(1) | BIT(3) | BIT(5) | BIT(7);
 
        /* M3N can use HS400 with manual adjustment */
-       if (renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A77965) {
+       if (renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A77965) {
                priv->adjust_hs400_enable = true;
                priv->adjust_hs400_offset = 3;
                priv->adjust_hs400_calib_table =
@@ -930,7 +930,7 @@ static void renesas_sdhi_filter_caps(struct udevice *dev)
        }
 
        /* E3 can use HS400 with manual adjustment */
-       if (renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A77990) {
+       if (renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A77990) {
                priv->adjust_hs400_enable = true;
                priv->adjust_hs400_offset = 3;
                priv->adjust_hs400_calib_table =
@@ -938,9 +938,9 @@ static void renesas_sdhi_filter_caps(struct udevice *dev)
        }
 
        /* H3 ES1.x, ES2.0 and M3W ES1.[0123] uses 4 tuning taps */
-       if (((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A7795) &&
+       if (((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A7795) &&
            (renesas_get_cpu_rev_integer() <= 2)) ||
-           ((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A7796) &&
+           ((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A7796) &&
            (renesas_get_cpu_rev_integer() == 1) &&
            (renesas_get_cpu_rev_fraction() <= 3)))
                priv->nrtaps = 4;
@@ -948,9 +948,9 @@ static void renesas_sdhi_filter_caps(struct udevice *dev)
                priv->nrtaps = 8;
 #endif
        /* H3 ES1.x and M3W ES1.0 uses bit 17 for DTRAEND */
-       if (((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A7795) &&
+       if (((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A7795) &&
            (renesas_get_cpu_rev_integer() <= 1)) ||
-           ((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A7796) &&
+           ((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A7796) &&
            (renesas_get_cpu_rev_integer() == 1) &&
            (renesas_get_cpu_rev_fraction() == 0)))
                priv->read_poll_flag = TMIO_SD_DMA_INFO1_END_RD;
@@ -958,7 +958,7 @@ static void renesas_sdhi_filter_caps(struct udevice *dev)
                priv->read_poll_flag = TMIO_SD_DMA_INFO1_END_RD2;
 
        /* V3M handles SD0H differently than other Gen3 SoCs */
-       if (renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A77970)
+       if (renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A77970)
                priv->needs_clkh_fallback = true;
        else
                priv->needs_clkh_fallback = false;
index 733f08ad4eaec3e48efa59f7d25baa9cbe371af7..4764bca7082473bea5bcc466446cb86efd051e2a 100644 (file)
@@ -392,8 +392,8 @@ static int ravb_dmac_init(struct udevice *dev)
        writel(0x00222210, eth->iobase + RAVB_REG_TGC);
 
        /* Delay CLK: 2ns (not applicable on R-Car E3/D3) */
-       if ((renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A77990) ||
-           (renesas_get_cpu_type() == RMOBILE_CPU_TYPE_R8A77995))
+       if ((renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A77990) ||
+           (renesas_get_cpu_type() == RENESAS_CPU_TYPE_R8A77995))
                return 0;
 
        if (!dev_read_u32(dev, "rx-internal-delay-ps", &delay)) {
index 165c0a1351ace8c048e81900ac956bbc6602e59e..8aff22386458d85a7a88b074a84e7938a6fe6066 100644 (file)
@@ -212,11 +212,11 @@ static u32 rpc_spi_get_strobe_delay(void)
         *       7: On other R-Car Gen3
         *      15: On R-Car Gen4
         */
-       if (cpu_type == RMOBILE_CPU_TYPE_R8A7796 && renesas_get_cpu_rev_integer() == 1)
+       if (cpu_type == RENESAS_CPU_TYPE_R8A7796 && renesas_get_cpu_rev_integer() == 1)
                return RPC_PHYCNT_STRTIM(6);
-       else if (cpu_type == RMOBILE_CPU_TYPE_R8A779F0 ||
-                cpu_type == RMOBILE_CPU_TYPE_R8A779G0 ||
-                cpu_type == RMOBILE_CPU_TYPE_R8A779H0)
+       else if (cpu_type == RENESAS_CPU_TYPE_R8A779F0 ||
+                cpu_type == RENESAS_CPU_TYPE_R8A779G0 ||
+                cpu_type == RENESAS_CPU_TYPE_R8A779H0)
                return RPC_PHYCNT_STRTIM2(15);
        else
 #endif