1 /* SPDX-License-Identifier: BSD-2-Clause */ 2 /* 3 * Copyright 2017 NXP 4 */ 5 6 #ifndef __IMX_MMDC_H 7 #define __IMX_MMDC_H 8 9 #define IMX_DDR_TYPE_DDR3 0 10 #define IMX_DDR_TYPE_LPDDR2 1 11 #define IMX_DDR_TYPE_LPDDR3 2 12 /* For i.MX6SLL */ 13 #define IMX_MMDC_DDR_TYPE_LPDDR3 3 14 15 /* i.MX6 */ 16 #define MMDC_MDMISC 0x18 17 #define MDMISC_DDR_TYPE_MASK GENMASK_32(4, 3) 18 #define MDMISC_DDR_TYPE_SHIFT 0x3 19 20 /* i.MX7 */ 21 #define DDRC_MSTR 0x0 22 #define MSTR_DDR3 BIT(0) 23 #define MSTR_LPDDR2 BIT(2) 24 #define MSTR_LPDDR3 BIT(3) 25 26 int imx_get_ddr_type(void); 27 28 #endif 29