Merge git://git.denx.de/u-boot-fsl-qoriq
authorTom Rini <trini@konsulko.com>
Tue, 18 Apr 2017 15:36:06 +0000 (11:36 -0400)
committerTom Rini <trini@konsulko.com>
Tue, 18 Apr 2017 15:36:06 +0000 (11:36 -0400)
1  2 
arch/arm/cpu/armv7/Makefile
arch/arm/dts/Makefile
drivers/crypto/fsl/jr.c
drivers/ddr/fsl/options.c

index 3a9913a86bc1afad1dfba049f7024a1e98b4c683,999ab47065aff984055d1526ba2f5a154b478cf9..5fac252c0e008a497f06627a3c40903bb7b0ecb1
@@@ -12,13 -12,12 +12,13 @@@ obj-y      += cache_v7.o cache_v7_asm.
  obj-y += cpu.o cp15.o
  obj-y += syslib.o
  
- ifneq ($(CONFIG_AM43XX)$(CONFIG_AM33XX)$(CONFIG_OMAP44XX)$(CONFIG_OMAP54XX)$(CONFIG_TEGRA)$(CONFIG_MX6)$(CONFIG_MX7)$(CONFIG_TI81XX)$(CONFIG_AT91FAMILY)$(CONFIG_ARCH_SUNXI)$(CONFIG_ARCH_SOCFPGA)$(CONFIG_ARCH_MX7ULP)$(CONFIG_LS102XA),)
+ ifneq ($(CONFIG_AM43XX)$(CONFIG_AM33XX)$(CONFIG_OMAP44XX)$(CONFIG_OMAP54XX)$(CONFIG_TEGRA)$(CONFIG_MX6)$(CONFIG_MX7)$(CONFIG_TI81XX)$(CONFIG_AT91FAMILY)$(CONFIG_ARCH_SUNXI)$(CONFIG_ARCH_SOCFPGA)$(CONFIG_ARCH_MX7ULP)$(CONFIG_ARCH_LS1021A),)
  ifneq ($(CONFIG_SKIP_LOWLEVEL_INIT),y)
  obj-y += lowlevel_init.o
  endif
  endif
  
 +obj-$(CONFIG_ARM_SMCCC)               += smccc-call.o
  obj-$(CONFIG_ARMV7_NONSEC)    += nonsec_virt.o virt-v7.o virt-dt.o
  obj-$(CONFIG_ARMV7_PSCI)      += psci.o psci-common.o
  
diff --combined arch/arm/dts/Makefile
index ce34e3eeff8a4dd33d974aa2e0368d4c2818ccca,0ee42818f6b9804d552d8793dfc1afc03c43c466..53fc936f02259ee5b695556e3d1494a6c8a1d1d5
@@@ -29,12 -29,12 +29,12 @@@ dtb-$(CONFIG_EXYNOS5) += exynos5250-arn
  dtb-$(CONFIG_EXYNOS7420) += exynos7420-espresso7420.dtb
  dtb-$(CONFIG_ARCH_ROCKCHIP) += \
        rk3036-sdk.dtb \
 +      rk3188-radxarock.dtb \
        rk3288-evb.dtb \
        rk3288-fennec.dtb \
        rk3288-firefly.dtb \
        rk3288-miqi.dtb \
        rk3288-popmetal.dtb \
 -      rk3188-radxarock.dtb \
        rk3288-rock2-square.dtb \
        rk3288-tinker.dtb \
        rk3288-veyron-jerry.dtb \
@@@ -166,7 -166,7 +166,7 @@@ dtb-$(CONFIG_TARGET_AM57XX_EVM) += am57
        am571x-idk.dtb
  dtb-$(CONFIG_TARGET_STV0991) += stv0991.dtb
  
- dtb-$(CONFIG_LS102XA) += ls1021a-qds-duart.dtb \
+ dtb-$(CONFIG_ARCH_LS1021A) += ls1021a-qds-duart.dtb \
        ls1021a-qds-lpuart.dtb \
        ls1021a-twr-duart.dtb ls1021a-twr-lpuart.dtb \
        ls1021a-iot-duart.dtb
diff --combined drivers/crypto/fsl/jr.c
index c33777fc7dd04edd7ef069882f4ab399767d4aea,f4f6c16df7cd08a57488d48bcca42ad00a1a484b..986eabfb088ce2de383380dcfc885cb86b9debe6
@@@ -47,7 -47,8 +47,7 @@@ static inline void start_jr0(uint8_t se
                 * VIRT_EN_INCL = 1 & VIRT_EN_POR = 0 & SEC_SCFGR_VIRT_EN = 1
                 */
                if ((ctpr_ms & SEC_CTPR_MS_VIRT_EN_POR) ||
 -                  (!(ctpr_ms & SEC_CTPR_MS_VIRT_EN_POR) &&
 -                                      (scfgr & SEC_SCFGR_VIRT_EN)))
 +                  (scfgr & SEC_SCFGR_VIRT_EN))
                        sec_out32(&sec->jrstartr, CONFIG_JRSTARTR_JR0);
        } else {
                /* VIRT_EN_INCL = 0 && VIRT_EN_POR_VALUE = 1 */
@@@ -341,7 -342,9 +341,9 @@@ static void desc_done(uint32_t status, 
  {
        struct result *x = arg;
        x->status = status;
+ #ifndef CONFIG_SPL_BUILD
        caam_jr_strstatus(status);
+ #endif
        x->done = 1;
  }
  
@@@ -435,7 -438,11 +437,11 @@@ static inline int sec_reset_idx(uint8_
  
        return 0;
  }
+ int sec_reset(void)
+ {
+       return sec_reset_idx(0);
+ }
+ #ifndef CONFIG_SPL_BUILD
  static int instantiate_rng(uint8_t sec_idx)
  {
        struct result op;
        return ret;
  }
  
- int sec_reset(void)
- {
-       return sec_reset_idx(0);
- }
  static u8 get_rng_vid(uint8_t sec_idx)
  {
        ccsr_sec_t *sec = (void *)SEC_ADDR(sec_idx);
@@@ -560,7 -562,7 +561,7 @@@ static int rng_init(uint8_t sec_idx
  
        return ret;
  }
+ #endif
  int sec_init_idx(uint8_t sec_idx)
  {
        ccsr_sec_t *sec = (void *)SEC_ADDR(sec_idx);
         * For AXI Read - Cacheable, Read allocate
         * Only For LS2080a, to solve CAAM coherency issues
         */
- #ifdef CONFIG_LS2080A
+ #ifdef CONFIG_ARCH_LS2080A
        mcr = (mcr & ~MCFGR_AWCACHE_MASK) | (0xb << MCFGR_AWCACHE_SHIFT);
        mcr = (mcr & ~MCFGR_ARCACHE_MASK) | (0x6 << MCFGR_ARCACHE_SHIFT);
  #else
  
        pamu_enable();
  #endif
+ #ifndef CONFIG_SPL_BUILD
        if (get_rng_vid(sec_idx) >= 4) {
                if (rng_init(sec_idx) < 0) {
                        printf("SEC%u: RNG instantiation failed\n", sec_idx);
                }
                printf("SEC%u: RNG instantiated\n", sec_idx);
        }
+ #endif
        return ret;
  }
  
index cee97fe23233d313cedc06b64d4d1349e0c2efe1,1b81a7a2500f74957ab4ecb0315803857bb957ba..b45a8797e449c0a675c415626360fe9bc43bcd75
@@@ -33,7 -33,7 +33,7 @@@ struct dynamic_odt 
  /* Quad rank is not verified yet due availability.
   * Replacing 20 OHM with 34 OHM since DDR4 doesn't have 20 OHM option
   */
- static const struct dynamic_odt single_Q[4] = {
+ static __maybe_unused const struct dynamic_odt single_Q[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_CS_AND_OTHER_DIMM,
@@@ -60,7 -60,7 +60,7 @@@
        }
  };
  
- static const struct dynamic_odt single_D[4] = {
+ static __maybe_unused const struct dynamic_odt single_D[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_ALL,
@@@ -77,7 -77,7 +77,7 @@@
        {0, 0, 0, 0}
  };
  
- static const struct dynamic_odt single_S[4] = {
+ static __maybe_unused const struct dynamic_odt single_S[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_ALL,
@@@ -89,7 -89,7 +89,7 @@@
        {0, 0, 0, 0},
  };
  
- static const struct dynamic_odt dual_DD[4] = {
+ static __maybe_unused const struct dynamic_odt dual_DD[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_SAME_DIMM,
        }
  };
  
- static const struct dynamic_odt dual_DS[4] = {
+ static __maybe_unused const struct dynamic_odt dual_DS[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_SAME_DIMM,
        },
        {0, 0, 0, 0}
  };
- static const struct dynamic_odt dual_SD[4] = {
+ static __maybe_unused const struct dynamic_odt dual_SD[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_OTHER_DIMM,
                FSL_DDR_ODT_ALL,
        }
  };
  
- static const struct dynamic_odt dual_SS[4] = {
+ static __maybe_unused const struct dynamic_odt dual_SS[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_OTHER_DIMM,
                FSL_DDR_ODT_ALL,
        {0, 0, 0, 0}
  };
  
- static const struct dynamic_odt dual_D0[4] = {
+ static __maybe_unused const struct dynamic_odt dual_D0[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_SAME_DIMM,
        {0, 0, 0, 0}
  };
  
- static const struct dynamic_odt dual_0D[4] = {
+ static __maybe_unused const struct dynamic_odt dual_0D[4] = {
        {0, 0, 0, 0},
        {0, 0, 0, 0},
        {       /* cs2 */
        }
  };
  
- static const struct dynamic_odt dual_S0[4] = {
+ static __maybe_unused const struct dynamic_odt dual_S0[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_CS,
  
  };
  
- static const struct dynamic_odt dual_0S[4] = {
+ static __maybe_unused const struct dynamic_odt dual_0S[4] = {
        {0, 0, 0, 0},
        {0, 0, 0, 0},
        {       /* cs2 */
  
  };
  
- static const struct dynamic_odt odt_unknown[4] = {
+ static __maybe_unused const struct dynamic_odt odt_unknown[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_CS,
        }
  };
  #elif defined(CONFIG_SYS_FSL_DDR3)
- static const struct dynamic_odt single_Q[4] = {
+ static __maybe_unused const struct dynamic_odt single_Q[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_CS_AND_OTHER_DIMM,
        }
  };
  
- static const struct dynamic_odt single_D[4] = {
+ static __maybe_unused const struct dynamic_odt single_D[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_ALL,
        {0, 0, 0, 0}
  };
  
- static const struct dynamic_odt single_S[4] = {
+ static __maybe_unused const struct dynamic_odt single_S[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_ALL,
        {0, 0, 0, 0},
  };
  
- static const struct dynamic_odt dual_DD[4] = {
+ static __maybe_unused const struct dynamic_odt dual_DD[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_SAME_DIMM,
        }
  };
  
- static const struct dynamic_odt dual_DS[4] = {
+ static __maybe_unused const struct dynamic_odt dual_DS[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_SAME_DIMM,
        },
        {0, 0, 0, 0}
  };
- static const struct dynamic_odt dual_SD[4] = {
+ static __maybe_unused const struct dynamic_odt dual_SD[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_OTHER_DIMM,
                FSL_DDR_ODT_ALL,
        }
  };
  
- static const struct dynamic_odt dual_SS[4] = {
+ static __maybe_unused const struct dynamic_odt dual_SS[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_OTHER_DIMM,
                FSL_DDR_ODT_ALL,
        {0, 0, 0, 0}
  };
  
- static const struct dynamic_odt dual_D0[4] = {
+ static __maybe_unused const struct dynamic_odt dual_D0[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_SAME_DIMM,
        {0, 0, 0, 0}
  };
  
- static const struct dynamic_odt dual_0D[4] = {
+ static __maybe_unused const struct dynamic_odt dual_0D[4] = {
        {0, 0, 0, 0},
        {0, 0, 0, 0},
        {       /* cs2 */
        }
  };
  
- static const struct dynamic_odt dual_S0[4] = {
+ static __maybe_unused const struct dynamic_odt dual_S0[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_CS,
  
  };
  
- static const struct dynamic_odt dual_0S[4] = {
+ static __maybe_unused const struct dynamic_odt dual_0S[4] = {
        {0, 0, 0, 0},
        {0, 0, 0, 0},
        {       /* cs2 */
  
  };
  
- static const struct dynamic_odt odt_unknown[4] = {
+ static __maybe_unused const struct dynamic_odt odt_unknown[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_CS,
        }
  };
  #else /* CONFIG_SYS_FSL_DDR3 */
- static const struct dynamic_odt single_Q[4] = {
+ static __maybe_unused const struct dynamic_odt single_Q[4] = {
        {0, 0, 0, 0},
        {0, 0, 0, 0},
        {0, 0, 0, 0},
        {0, 0, 0, 0}
  };
  
- static const struct dynamic_odt single_D[4] = {
+ static __maybe_unused const struct dynamic_odt single_D[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_ALL,
        {0, 0, 0, 0}
  };
  
- static const struct dynamic_odt single_S[4] = {
+ static __maybe_unused const struct dynamic_odt single_S[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_ALL,
        {0, 0, 0, 0},
  };
  
- static const struct dynamic_odt dual_DD[4] = {
+ static __maybe_unused const struct dynamic_odt dual_DD[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_OTHER_DIMM,
                FSL_DDR_ODT_OTHER_DIMM,
        }
  };
  
- static const struct dynamic_odt dual_DS[4] = {
+ static __maybe_unused const struct dynamic_odt dual_DS[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_OTHER_DIMM,
                FSL_DDR_ODT_OTHER_DIMM,
        {0, 0, 0, 0}
  };
  
- static const struct dynamic_odt dual_SD[4] = {
+ static __maybe_unused const struct dynamic_odt dual_SD[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_OTHER_DIMM,
                FSL_DDR_ODT_OTHER_DIMM,
        }
  };
  
- static const struct dynamic_odt dual_SS[4] = {
+ static __maybe_unused const struct dynamic_odt dual_SS[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_OTHER_DIMM,
                FSL_DDR_ODT_OTHER_DIMM,
        {0, 0, 0, 0}
  };
  
- static const struct dynamic_odt dual_D0[4] = {
+ static __maybe_unused const struct dynamic_odt dual_D0[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_ALL,
        {0, 0, 0, 0}
  };
  
- static const struct dynamic_odt dual_0D[4] = {
+ static __maybe_unused const struct dynamic_odt dual_0D[4] = {
        {0, 0, 0, 0},
        {0, 0, 0, 0},
        {       /* cs2 */
        }
  };
  
- static const struct dynamic_odt dual_S0[4] = {
+ static __maybe_unused const struct dynamic_odt dual_S0[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_CS,
  
  };
  
- static const struct dynamic_odt dual_0S[4] = {
+ static __maybe_unused const struct dynamic_odt dual_0S[4] = {
        {0, 0, 0, 0},
        {0, 0, 0, 0},
        {       /* cs2 */
  
  };
  
- static const struct dynamic_odt odt_unknown[4] = {
+ static __maybe_unused const struct dynamic_odt odt_unknown[4] = {
        {       /* cs0 */
                FSL_DDR_ODT_NEVER,
                FSL_DDR_ODT_CS,
@@@ -916,7 -916,7 +916,7 @@@ unsigned int populate_memctl_options(co
                if ((pdimm[0].data_width >= 64) && \
                        (pdimm[0].data_width <= 72))
                        popts->data_bus_width = 0;
 -              else if ((pdimm[0].data_width >= 32) || \
 +              else if ((pdimm[0].data_width >= 32) && \
                        (pdimm[0].data_width <= 40))
                        popts->data_bus_width = 1;
                else {