0001
0002
0003
0004
0005
0006
0007
0008
0009 #ifndef __LINUX_MEMORY_OF_REG_H
0010 #define __LINUX_MEMORY_OF_REG_H
0011
0012 #if defined(CONFIG_OF) && defined(CONFIG_DDR)
0013 const struct lpddr2_min_tck *of_get_min_tck(struct device_node *np,
0014 struct device *dev);
0015 const struct lpddr2_timings *of_get_ddr_timings(struct device_node *np_ddr,
0016 struct device *dev,
0017 u32 device_type, u32 *nr_frequencies);
0018 const struct lpddr3_min_tck *of_lpddr3_get_min_tck(struct device_node *np,
0019 struct device *dev);
0020 const struct lpddr3_timings *
0021 of_lpddr3_get_ddr_timings(struct device_node *np_ddr,
0022 struct device *dev, u32 device_type, u32 *nr_frequencies);
0023
0024 const struct lpddr2_info *of_lpddr2_get_info(struct device_node *np,
0025 struct device *dev);
0026 #else
0027 static inline const struct lpddr2_min_tck
0028 *of_get_min_tck(struct device_node *np, struct device *dev)
0029 {
0030 return NULL;
0031 }
0032
0033 static inline const struct lpddr2_timings
0034 *of_get_ddr_timings(struct device_node *np_ddr, struct device *dev,
0035 u32 device_type, u32 *nr_frequencies)
0036 {
0037 return NULL;
0038 }
0039
0040 static inline const struct lpddr3_min_tck
0041 *of_lpddr3_get_min_tck(struct device_node *np, struct device *dev)
0042 {
0043 return NULL;
0044 }
0045
0046 static inline const struct lpddr3_timings
0047 *of_lpddr3_get_ddr_timings(struct device_node *np_ddr,
0048 struct device *dev, u32 device_type, u32 *nr_frequencies)
0049 {
0050 return NULL;
0051 }
0052
0053 static inline const struct lpddr2_info
0054 *of_lpddr2_get_info(struct device_node *np, struct device *dev)
0055 {
0056 return NULL;
0057 }
0058 #endif
0059
0060 #endif