Skip to content

Commit

Permalink
change pmu powerup timing
Browse files Browse the repository at this point in the history
  • Loading branch information
benn committed Jan 7, 2014
1 parent c75ea90 commit fb357b4
Showing 1 changed file with 26 additions and 13 deletions.
39 changes: 26 additions & 13 deletions board/sunxi/board.c
Expand Up @@ -96,7 +96,32 @@ void sunxi_board_init(void)
int power_failed = 0;
unsigned long ramsize;

printf("DRAM:");

#ifdef CONFIG_AXP209_POWER
power_failed |= axp209_init();

axp209_write(0xf4, 0x06);
axp209_write(0xf2, 0x04);
axp209_write(0xff, 0x01);
axp209_write(0x3, 0x00);
axp209_write(0x4, 0x00);

axp209_write(0xff, 0x00);
axp209_write(0xf4, 0x00);

power_failed |= axp209_set_dcdc2(1400);
#ifdef CONFIG_FAST_MBUS
power_failed |= axp209_set_dcdc3(1300);
#else
power_failed |= axp209_set_dcdc3(1250);
#endif
power_failed |= axp209_set_ldo2(3000);
power_failed |= axp209_set_ldo3(2800);
power_failed |= axp209_set_ldo4(2800);
#endif


printf("dram:");
ramsize = sunxi_dram_init();
if (!ramsize) {
printf(" ?");
Expand All @@ -117,18 +142,6 @@ void sunxi_board_init(void)
power_failed |= axp152_set_dcdc4(1250);
power_failed |= axp152_set_ldo2(3000);
#endif
#ifdef CONFIG_AXP209_POWER
power_failed |= axp209_init();
power_failed |= axp209_set_dcdc2(1400);
#ifdef CONFIG_FAST_MBUS
power_failed |= axp209_set_dcdc3(1300);
#else
power_failed |= axp209_set_dcdc3(1250);
#endif
power_failed |= axp209_set_ldo2(3000);
power_failed |= axp209_set_ldo3(2800);
power_failed |= axp209_set_ldo4(2800);
#endif

/*
* Only clock up the CPU to full speed if we are reasonably
Expand Down

0 comments on commit fb357b4

Please sign in to comment.