X-Git-Url: https://git.librecmc.org/?p=oweals%2Fu-boot.git;a=blobdiff_plain;f=arch%2Farm%2Finclude%2Fasm%2Fglobal_data.h;h=7c0905d240eb4fde666929ed2c5d5ee5f6e37894;hp=287a7bd5b19cb555abaa88b3c24dd3250afa35ff;hb=c27178ba3649f539c9f1890ea147f4c5415f63b5;hpb=e8f80a5a58c9b506453cc0780687e8ed457d30a6 diff --git a/arch/arm/include/asm/global_data.h b/arch/arm/include/asm/global_data.h index 287a7bd5b1..7c0905d240 100644 --- a/arch/arm/include/asm/global_data.h +++ b/arch/arm/include/asm/global_data.h @@ -9,10 +9,14 @@ /* Architecture-specific global data */ struct arch_global_data { -#if defined(CONFIG_FSL_ESDHC) +#if defined(CONFIG_FSL_ESDHC) || defined(CONFIG_FSL_ESDHC_IMX) u32 sdhc_clk; #endif +#if defined(CONFIG_FSL_ESDHC) + u32 sdhc_per_clk; +#endif + #if defined(CONFIG_U_QE) u32 qe_clk; u32 brg_clk; @@ -35,7 +39,7 @@ struct arch_global_data { unsigned int tbl; unsigned long lastinc; unsigned long long timer_reset_value; -#if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF)) +#if !(CONFIG_IS_ENABLED(SYS_ICACHE_OFF) && CONFIG_IS_ENABLED(SYS_DCACHE_OFF)) unsigned long tlb_addr; unsigned long tlb_size; #if defined(CONFIG_ARM64) @@ -74,6 +78,10 @@ struct arch_global_data { #if defined(CONFIG_FSL_LSCH3) && defined(CONFIG_SYS_FSL_HAS_DP_DDR) unsigned long mem2_clk; #endif + +#ifdef CONFIG_ARCH_IMX8 + struct udevice *scu_dev; +#endif }; #include @@ -109,4 +117,13 @@ static inline gd_t *get_gd(void) #endif #endif +static inline void set_gd(volatile gd_t *gd_ptr) +{ +#ifdef CONFIG_ARM64 + __asm__ volatile("ldr x18, %0\n" : : "m"(gd_ptr)); +#else + __asm__ volatile("ldr r9, %0\n" : : "m"(gd_ptr)); +#endif +} + #endif /* __ASM_GBL_DATA_H */