1
2
3
4
5
6
7
8
9#ifndef __LINUX_MEMORY_OF_REG_H
10#define __LINUX_MEMORY_OF_REG_H
11
12#if defined(CONFIG_OF) && defined(CONFIG_DDR)
13const struct lpddr2_min_tck *of_get_min_tck(struct device_node *np,
14 struct device *dev);
15const struct lpddr2_timings *of_get_ddr_timings(struct device_node *np_ddr,
16 struct device *dev,
17 u32 device_type, u32 *nr_frequencies);
18const struct lpddr3_min_tck *of_lpddr3_get_min_tck(struct device_node *np,
19 struct device *dev);
20const struct lpddr3_timings *
21of_lpddr3_get_ddr_timings(struct device_node *np_ddr,
22 struct device *dev, u32 device_type, u32 *nr_frequencies);
23#else
24static inline const struct lpddr2_min_tck
25 *of_get_min_tck(struct device_node *np, struct device *dev)
26{
27 return NULL;
28}
29
30static inline const struct lpddr2_timings
31 *of_get_ddr_timings(struct device_node *np_ddr, struct device *dev,
32 u32 device_type, u32 *nr_frequencies)
33{
34 return NULL;
35}
36
37static inline const struct lpddr3_min_tck
38 *of_lpddr3_get_min_tck(struct device_node *np, struct device *dev)
39{
40 return NULL;
41}
42
43static inline const struct lpddr3_timings
44 *of_lpddr3_get_ddr_timings(struct device_node *np_ddr,
45 struct device *dev, u32 device_type, u32 *nr_frequencies)
46{
47 return NULL;
48}
49#endif
50
51#endif
52