blob: 408235eb935b21d4fc1256b816e54b54a9c62109 [file] [log] [blame]
Chin Liang Seecb350602014-03-04 22:13:53 -06001/*
Marek Vasut372f70d2015-08-10 21:21:07 +02002 * Altera SoCFPGA Clock and PLL configuration
Chin Liang Seecb350602014-03-04 22:13:53 -06003 *
Marek Vasut372f70d2015-08-10 21:21:07 +02004 * SPDX-License-Identifier: BSD-3-Clause
Chin Liang Seecb350602014-03-04 22:13:53 -06005 */
6
Marek Vasut372f70d2015-08-10 21:21:07 +02007#ifndef __SOCFPGA_PLL_CONFIG_H__
8#define __SOCFPGA_PLL_CONFIG_H__
Chin Liang Seecb350602014-03-04 22:13:53 -06009
Marek Vasut372f70d2015-08-10 21:21:07 +020010#define CONFIG_HPS_DBCTRL_STAYOSC1 1
Chin Liang Seecb350602014-03-04 22:13:53 -060011
Marek Vasut372f70d2015-08-10 21:21:07 +020012#define CONFIG_HPS_MAINPLLGRP_VCO_DENOM 0
Dinh Nguyend28f4a72016-05-10 15:13:59 -050013#define CONFIG_HPS_MAINPLLGRP_VCO_NUMER 73
Marek Vasut372f70d2015-08-10 21:21:07 +020014#define CONFIG_HPS_MAINPLLGRP_MPUCLK_CNT 0
15#define CONFIG_HPS_MAINPLLGRP_MAINCLK_CNT 0
16#define CONFIG_HPS_MAINPLLGRP_DBGATCLK_CNT 0
Dinh Nguyend28f4a72016-05-10 15:13:59 -050017#define CONFIG_HPS_MAINPLLGRP_MAINQSPICLK_CNT 4
Marek Vasut372f70d2015-08-10 21:21:07 +020018#define CONFIG_HPS_MAINPLLGRP_MAINNANDSDMMCCLK_CNT 511
Dinh Nguyend28f4a72016-05-10 15:13:59 -050019#define CONFIG_HPS_MAINPLLGRP_CFGS2FUSER0CLK_CNT 14
Marek Vasut372f70d2015-08-10 21:21:07 +020020#define CONFIG_HPS_MAINPLLGRP_MAINDIV_L3MPCLK 1
21#define CONFIG_HPS_MAINPLLGRP_MAINDIV_L3SPCLK 1
22#define CONFIG_HPS_MAINPLLGRP_MAINDIV_L4MPCLK 1
23#define CONFIG_HPS_MAINPLLGRP_MAINDIV_L4SPCLK 1
24#define CONFIG_HPS_MAINPLLGRP_DBGDIV_DBGATCLK 0
25#define CONFIG_HPS_MAINPLLGRP_DBGDIV_DBGCLK 1
26#define CONFIG_HPS_MAINPLLGRP_TRACEDIV_TRACECLK 0
27#define CONFIG_HPS_MAINPLLGRP_L4SRC_L4MP 1
28#define CONFIG_HPS_MAINPLLGRP_L4SRC_L4SP 1
Chin Liang Seecb350602014-03-04 22:13:53 -060029
Dinh Nguyend28f4a72016-05-10 15:13:59 -050030#define CONFIG_HPS_PERPLLGRP_VCO_DENOM 0
31#define CONFIG_HPS_PERPLLGRP_VCO_NUMER 39
Marek Vasut372f70d2015-08-10 21:21:07 +020032#define CONFIG_HPS_PERPLLGRP_VCO_PSRC 0
Dinh Nguyend28f4a72016-05-10 15:13:59 -050033#define CONFIG_HPS_PERPLLGRP_EMAC0CLK_CNT 511
shengjiangwuc213f632015-12-22 15:22:02 +080034#define CONFIG_HPS_PERPLLGRP_EMAC1CLK_CNT 3
Marek Vasut372f70d2015-08-10 21:21:07 +020035#define CONFIG_HPS_PERPLLGRP_PERQSPICLK_CNT 511
36#define CONFIG_HPS_PERPLLGRP_PERNANDSDMMCCLK_CNT 4
37#define CONFIG_HPS_PERPLLGRP_PERBASECLK_CNT 4
38#define CONFIG_HPS_PERPLLGRP_S2FUSER1CLK_CNT 511
39#define CONFIG_HPS_PERPLLGRP_DIV_USBCLK 0
Dinh Nguyend28f4a72016-05-10 15:13:59 -050040#define CONFIG_HPS_PERPLLGRP_DIV_SPIMCLK 0
Marek Vasut372f70d2015-08-10 21:21:07 +020041#define CONFIG_HPS_PERPLLGRP_DIV_CAN0CLK 1
Dinh Nguyend28f4a72016-05-10 15:13:59 -050042#define CONFIG_HPS_PERPLLGRP_DIV_CAN1CLK 4
Marek Vasut372f70d2015-08-10 21:21:07 +020043#define CONFIG_HPS_PERPLLGRP_GPIODIV_GPIODBCLK 6249
44#define CONFIG_HPS_PERPLLGRP_SRC_SDMMC 2
45#define CONFIG_HPS_PERPLLGRP_SRC_NAND 2
46#define CONFIG_HPS_PERPLLGRP_SRC_QSPI 1
Chin Liang Seecb350602014-03-04 22:13:53 -060047
Dinh Nguyend28f4a72016-05-10 15:13:59 -050048#define CONFIG_HPS_SDRPLLGRP_VCO_DENOM 0
49#define CONFIG_HPS_SDRPLLGRP_VCO_NUMER 31
Marek Vasut372f70d2015-08-10 21:21:07 +020050#define CONFIG_HPS_SDRPLLGRP_VCO_SSRC 0
51#define CONFIG_HPS_SDRPLLGRP_DDRDQSCLK_CNT 1
52#define CONFIG_HPS_SDRPLLGRP_DDRDQSCLK_PHASE 0
53#define CONFIG_HPS_SDRPLLGRP_DDR2XDQSCLK_CNT 0
54#define CONFIG_HPS_SDRPLLGRP_DDR2XDQSCLK_PHASE 0
55#define CONFIG_HPS_SDRPLLGRP_DDRDQCLK_CNT 1
56#define CONFIG_HPS_SDRPLLGRP_DDRDQCLK_PHASE 4
57#define CONFIG_HPS_SDRPLLGRP_S2FUSER2CLK_CNT 5
58#define CONFIG_HPS_SDRPLLGRP_S2FUSER2CLK_PHASE 0
Chin Liang Seecb350602014-03-04 22:13:53 -060059
Marek Vasut372f70d2015-08-10 21:21:07 +020060#define CONFIG_HPS_CLK_OSC1_HZ 25000000
61#define CONFIG_HPS_CLK_OSC2_HZ 25000000
62#define CONFIG_HPS_CLK_F2S_SDR_REF_HZ 0
63#define CONFIG_HPS_CLK_F2S_PER_REF_HZ 0
Dinh Nguyend28f4a72016-05-10 15:13:59 -050064#define CONFIG_HPS_CLK_MAINVCO_HZ 1850000000
Marek Vasut372f70d2015-08-10 21:21:07 +020065#define CONFIG_HPS_CLK_PERVCO_HZ 1000000000
Dinh Nguyend28f4a72016-05-10 15:13:59 -050066#define CONFIG_HPS_CLK_SDRVCO_HZ 800000000
67#define CONFIG_HPS_CLK_EMAC0_HZ 1953125
Marek Vasut372f70d2015-08-10 21:21:07 +020068#define CONFIG_HPS_CLK_EMAC1_HZ 250000000
69#define CONFIG_HPS_CLK_USBCLK_HZ 200000000
70#define CONFIG_HPS_CLK_NAND_HZ 50000000
71#define CONFIG_HPS_CLK_SDMMC_HZ 200000000
Dinh Nguyend28f4a72016-05-10 15:13:59 -050072#define CONFIG_HPS_CLK_QSPI_HZ 370000000
Marek Vasut372f70d2015-08-10 21:21:07 +020073#define CONFIG_HPS_CLK_SPIM_HZ 200000000
74#define CONFIG_HPS_CLK_CAN0_HZ 100000000
Dinh Nguyend28f4a72016-05-10 15:13:59 -050075#define CONFIG_HPS_CLK_CAN1_HZ 12500000
Marek Vasut372f70d2015-08-10 21:21:07 +020076#define CONFIG_HPS_CLK_GPIODB_HZ 32000
77#define CONFIG_HPS_CLK_L4_MP_HZ 100000000
78#define CONFIG_HPS_CLK_L4_SP_HZ 100000000
Chin Liang Seecb350602014-03-04 22:13:53 -060079
Marek Vasut372f70d2015-08-10 21:21:07 +020080#define CONFIG_HPS_ALTERAGRP_MPUCLK 1
Dinh Nguyend28f4a72016-05-10 15:13:59 -050081#define CONFIG_HPS_ALTERAGRP_MAINCLK 4
82#define CONFIG_HPS_ALTERAGRP_DBGATCLK 4
Marek Vasut372f70d2015-08-10 21:21:07 +020083
Chin Liang Seecb350602014-03-04 22:13:53 -060084
Marek Vasut372f70d2015-08-10 21:21:07 +020085#endif /* __SOCFPGA_PLL_CONFIG_H__ */