ARM: Rockchip: Update Radxa Rock board
Signed-off-by: Andrey Panov <rockford@yandex.ru> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
parent
a0790f9875
commit
290161a2f0
|
@ -16,8 +16,9 @@
|
|||
#include <io.h>
|
||||
#include <i2c/i2c.h>
|
||||
#include <i2c/i2c-gpio.h>
|
||||
#include <mach/rockchip-pll.h>
|
||||
#include <mach/rockchip-regs.h>
|
||||
#include <mfd/act8846.h>
|
||||
#include <asm/armlinux.h>
|
||||
|
||||
static struct i2c_board_info radxa_rock_i2c_devices[] = {
|
||||
{
|
||||
|
@ -43,20 +44,6 @@ static void radxa_rock_pmic_init(void)
|
|||
act8846_set_bits(pmic, ACT8846_LDO9_CTRL, BIT(7), BIT(7));
|
||||
}
|
||||
|
||||
static int setup_plls(void)
|
||||
{
|
||||
if (!of_machine_is_compatible("radxa,rock"))
|
||||
return 0;
|
||||
|
||||
/* Codec PLL frequency: 594 MHz */
|
||||
rk3188_pll_set_parameters(RK3188_CPLL, 2, 198, 4);
|
||||
/* General PLL frequency: 300 MHz */
|
||||
rk3188_pll_set_parameters(RK3188_GPLL, 1, 50, 4);
|
||||
|
||||
return 0;
|
||||
}
|
||||
coredevice_initcall(setup_plls);
|
||||
|
||||
static int devices_init(void)
|
||||
{
|
||||
if (!of_machine_is_compatible("radxa,rock"))
|
||||
|
@ -68,20 +55,12 @@ static int devices_init(void)
|
|||
|
||||
radxa_rock_pmic_init();
|
||||
|
||||
/* Set mac_pll divisor to 6 (50MHz output) */
|
||||
writel((5 << 8) | (0x1f << 24), 0x20000098);
|
||||
armlinux_set_architecture(3066);
|
||||
|
||||
/* Map SRAM to address 0, kernel relies on this */
|
||||
writel((RK_SOC_CON0_REMAP << 16) | RK_SOC_CON0_REMAP,
|
||||
RK_GRF_BASE + RK_GRF_SOC_CON0);
|
||||
|
||||
return 0;
|
||||
}
|
||||
device_initcall(devices_init);
|
||||
|
||||
static int hostname_init(void)
|
||||
{
|
||||
if (!of_machine_is_compatible("radxa,rock"))
|
||||
return 0;
|
||||
|
||||
barebox_set_hostname("radxa-rock");
|
||||
|
||||
return 0;
|
||||
}
|
||||
postcore_initcall(hostname_init);
|
||||
|
|
|
@ -0,0 +1,9 @@
|
|||
#!/bin/sh
|
||||
|
||||
mount /dev/mshc1.0
|
||||
|
||||
oftree -f
|
||||
oftree -l /mnt/mshc1.0/rk3188-radxarock.dtb
|
||||
|
||||
global.bootm.image=/mnt/mshc1.0/zImage
|
||||
global.linux.bootargs.dyn.root="root=/dev/mmcblk0p2 rootwait"
|
|
@ -0,0 +1,8 @@
|
|||
#!/bin/sh
|
||||
|
||||
mount /dev/mshc1.0
|
||||
|
||||
oftree -f
|
||||
|
||||
global.bootm.image=/mnt/mshc1.0/zImage-old
|
||||
global.linux.bootargs.dyn.root="root=/dev/mmcblk0p2 rootwait"
|
|
@ -0,0 +1,7 @@
|
|||
#!/bin/sh
|
||||
|
||||
if [ -n "$nv.boot.default" ]; then
|
||||
exit
|
||||
fi
|
||||
|
||||
global.boot.default=mshc1
|
|
@ -0,0 +1 @@
|
|||
radxa-rock
|
Loading…
Reference in New Issue