diff options
Diffstat (limited to 'board/sunxi/board.c')
-rw-r--r-- | board/sunxi/board.c | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/board/sunxi/board.c b/board/sunxi/board.c index 64ccbc7245..917f5b18f6 100644 --- a/board/sunxi/board.c +++ b/board/sunxi/board.c @@ -28,7 +28,7 @@ #endif #include <asm/gpio.h> #include <asm/io.h> -#include <crc.h> +#include <u-boot/crc.h> #include <environment.h> #include <linux/libfdt.h> #include <nand.h> @@ -637,13 +637,6 @@ void sunxi_board_init(void) power_failed |= axp_set_sw(IS_ENABLED(CONFIG_AXP_SW_ON)); #endif #endif - printf("DRAM:"); - gd->ram_size = sunxi_dram_init(); - printf(" %d MiB\n", (int)(gd->ram_size >> 20)); - if (!gd->ram_size) - hang(); - - sunxi_spl_store_dram_size(gd->ram_size); /* * Only clock up the CPU to full speed if we are reasonably @@ -652,7 +645,16 @@ void sunxi_board_init(void) if (!power_failed) clock_set_pll1(CONFIG_SYS_CLK_FREQ); else - printf("Failed to set core voltage! Can't set CPU frequency\n"); + printf("Error setting up the power controller.\n" + "CPU frequency not set.\n"); + + printf("DRAM:"); + gd->ram_size = sunxi_dram_init(); + printf(" %d MiB\n", (int)(gd->ram_size >> 20)); + if (!gd->ram_size) + hang(); + + sunxi_spl_store_dram_size(gd->ram_size); } #endif @@ -663,7 +665,7 @@ int g_dnl_board_usb_cable_connected(void) struct phy phy; int ret; - ret = uclass_get_device(UCLASS_USB_DEV_GENERIC, 0, &dev); + ret = uclass_get_device(UCLASS_USB_GADGET_GENERIC, 0, &dev); if (ret) { pr_err("%s: Cannot find USB device\n", __func__); return ret; |