};
};
};
- ion: ion{
+ ion{
compatible = "rockchip,ion";
#address-cells = <1>;
#size-cells = <0>;
pa_enable_time = <1000>;
};
+ ion {
+ compatible = "rockchip,ion";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ rockchip,ion-heap@1 { /* CMA HEAP */
+ compatible = "rockchip,ion-reserve";
+ reg = <1>;
+ memory-reservation = <0x00000000 0x04000000>; /* 64MB */
+ };
+ rockchip,ion-heap@3 { /* SYSTEM HEAP */
+ reg = <3>;
+ };
+ };
};
&fb {
// pinctrl-0 = <&spdif_tx>;
};
- ion: ion {
+ ion {
compatible = "rockchip,ion";
#address-cells = <1>;
#size-cells = <0>;
#include <linux/kernel.h>
#include <linux/of_address.h>
#include <linux/of_platform.h>
+#include <linux/of_fdt.h>
#include <asm/hardware/cache-l2x0.h>
#include <linux/rockchip/common.h>
#include "cpu_axi.h"
long (*ddr_round_rate)(uint32_t nMHz) = NULL;
void (*ddr_set_auto_self_refresh)(bool en) = NULL;
+extern int __init rockchip_ion_find_reserve_mem(unsigned long node,
+ const char *uname, int depth, void *data);
+void __init rockchip_ion_reserve(void)
+{
+ printk("%s\n", __func__);
+ of_scan_flat_dt(rockchip_ion_find_reserve_mem, NULL);
+}
+
#include <linux/kernel.h>
#include <linux/of_address.h>
#include <linux/of_platform.h>
-#include <linux/of_fdt.h>
#include <linux/rockchip/dvfs.h>
#include <linux/rockchip/common.h>
#include <linux/rockchip/cpu.h>
of_dvfs_init();
}
-extern int __init rockchip_ion_find_reserve_mem(unsigned long node,
- const char *uname, int depth, void *data);
static void __init rk3188_reserve(void)
{
- printk("%s\n", __func__);
- of_scan_flat_dt(rockchip_ion_find_reserve_mem, NULL);
+ /* reserve memory for ION */
+ rockchip_ion_reserve();
}
static const char * const rk3188_dt_compat[] __initconst = {
of_dvfs_init();
}
+static void __init rk3288_reserve(void)
+{
+ /* reserve memory for ION */
+ rockchip_ion_reserve();
+}
+
static const char * const rk3288_dt_compat[] __initconst = {
"rockchip,rk3288",
NULL,
.init_time = rk3288_dt_init_timer,
.dt_compat = rk3288_dt_compat,
.init_late = rockchip_suspend_init,
+ .reserve = rk3288_reserve,
.restart = rk3288_restart,
MACHINE_END
extern void __init rockchip_boot_mode_init(u32 flag, u32 mode);
extern void rockchip_restart_get_boot_mode(const char *cmd, u32 *flag, u32 *mode);
extern void __init rockchip_suspend_init(void);
+extern void __init rockchip_ion_reserve(void);
#endif