1 // SPDX-License-Identifier: GPL-2.0+
3 * K2L EVM : Board initialization
6 * Texas Instruments Incorporated, <www.ti.com>
11 #include <asm/arch/ddr3.h>
12 #include <asm/arch/hardware.h>
13 #include <asm/ti-common/keystone_net.h>
15 unsigned int get_external_clk(u32 clk)
17 unsigned int clk_freq;
43 static struct pll_init_data core_pll_config[NUM_SPDS] = {
44 [SPD800] = CORE_PLL_799,
45 [SPD1000] = CORE_PLL_1000,
46 [SPD1200] = CORE_PLL_1198,
50 0, 0, 1, 4, 23, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1
53 static struct pll_init_data tetris_pll_config[] = {
54 [SPD800] = TETRIS_PLL_799,
55 [SPD1000] = TETRIS_PLL_1000,
56 [SPD1200] = TETRIS_PLL_1198,
57 [SPD1350] = TETRIS_PLL_1352,
58 [SPD1400] = TETRIS_PLL_1401,
61 static struct pll_init_data pa_pll_config =
64 struct pll_init_data *get_pll_init_data(int pll)
67 struct pll_init_data *data;
71 speed = get_max_dev_speed(speeds);
72 data = &core_pll_config[speed];
75 speed = get_max_arm_speed(speeds);
76 data = &tetris_pll_config[speed];
79 data = &pa_pll_config;
88 #ifdef CONFIG_BOARD_EARLY_INIT_F
89 int board_early_init_f(void)
97 #if defined(CONFIG_MULTI_DTB_FIT)
98 int board_fit_config_name_match(const char *name)
100 if (!strcmp(name, "keystone-k2l-evm"))
107 #ifdef CONFIG_SPL_BUILD
108 void spl_init_keystone_plls(void)