[u-boot] rk: adjust some debug information.

Change-Id: I2fb006d1bf8a5d701cae83a86e543e12fc814e38
Signed-off-by: Firefly <service@t-firefly.com>
(cherry picked from commit 1a307ccd792a178eb7a807fc5ee8456b000827ec)
This commit is contained in:
Firefly
2016-01-27 11:14:34 +08:00
committed by cjp
parent 3fb5335f4a
commit 46992ad0cd
12 changed files with 36 additions and 38 deletions

View File

@ -1,5 +1,5 @@
/*
* (C) Copyright 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* (C) Copyright 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
* Peter, Software Engineering, <superpeter.cai@gmail.com>.
*
* SPDX-License-Identifier: GPL-2.0+
@ -375,7 +375,7 @@ const disk_partition_t* get_disk_partition(const char *name)
{
int part_index = find_mtd_part(&gBootInfo.cmd_mtd, name);
if (part_index < 0) {
printf("failed to find part: '%s'\n", name);
debug("Failed to find part: '%s'\n", name);
return NULL;
}
return &gBootInfo.cmd_mtd.parts[part_index];

View File

@ -1,5 +1,5 @@
/*
* (C) Copyright 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* (C) Copyright 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
* Peter, Software Engineering, <superpeter.cai@gmail.com>.
*
* SPDX-License-Identifier: GPL-2.0+
@ -718,21 +718,23 @@ void rkimage_prepare_fdt(void)
#ifdef CONFIG_RESOURCE_PARTITION
resource_content content = rkimage_load_fdt(get_disk_partition(BOOT_NAME));
if (!content.load_addr) {
printf("failed to prepare fdt from boot!\n");
debug("Failed to prepare fdt from boot!\n");
} else {
printf("Load FDT from boot image.\n");
gd->fdt_blob = content.load_addr;
gd->fdt_size = content.content_size;
FBTDBG("prepare fdt from recovery:%p(%d)\n", gd->fdt_blob, gd->fdt_size);
return;
}
#ifdef CONFIG_OF_FROM_RESOURCE
content = rkimage_load_fdt(get_disk_partition(RESOURCE_NAME));
if (!content.load_addr) {
printf("failed to prepare fdt from resource!\n");
debug("Failed to prepare fdt from resource!\n");
} else {
printf("Load FDT from resource image.\n");
gd->fdt_blob = content.load_addr;
gd->fdt_size = content.content_size;
FBTDBG("prepare fdt from resource:%p(%d)\n", gd->fdt_blob, gd->fdt_size);
return;
}
#endif

View File

@ -1,5 +1,5 @@
/*
* (C) Copyright 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* (C) Copyright 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
* Peter, Software Engineering, <superpeter.cai@gmail.com>.
*
* SPDX-License-Identifier: GPL-2.0+

View File

@ -2,7 +2,7 @@
* (C) Copyright 2001
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
*
* (C) Copyright 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* (C) Copyright 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
*
* SPDX-License-Identifier: GPL-2.0+
*/
@ -285,8 +285,8 @@ bool show_resource_image(const char* image_path) {
memset(&image, 0, sizeof(image));
snprintf(image.path, sizeof(image.path), "%s", image_path);
if(ptn)
{
if (ptn) {
printf("Find logo from partition %s\n", LOGO_NAME);
#ifdef CONFIG_DIRECT_LOGO
bmp = lcd_get_buffer();
#else
@ -296,14 +296,11 @@ bool show_resource_image(const char* image_path) {
debug("bmp image at 0x%p, sign:%c%c\n", bmp, bmp->header.signature[0], bmp->header.signature[1]);
}
if(ptn && bmp && bmp->header.signature[0] == 'B' && bmp->header.signature[1] == 'M')
{
if (ptn && bmp && bmp->header.signature[0] == 'B' && bmp->header.signature[1] == 'M') {
debug("%s:show logo.bmp from logo partition\n", __func__);
lcd_display_bitmap_center((uint32_t)(unsigned long)bmp);
ret = true;
}
else
{
} else {
if (get_content(0, &image)) {
debug("%s:show logo from resource or boot partition\n", __func__);
int blocks = (image.content_size + BLOCK_SIZE - 1) / BLOCK_SIZE;

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* Copyright (C) 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
* zyw < zyw@rock-chips.com >
* yxj <yxj@rock-chips.com>
*
@ -220,7 +220,7 @@ static int act8846_parse_dt(const void* blob)
node = fdt_node_offset_by_compatible(blob,
g_i2c_node, COMPAT_ACTIVE_ACT8846);
if (node < 0) {
printf("can't find dts node for act8846\n");
debug("can't find dts node for act8846\n");
return -ENODEV;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* Copyright (C) 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
* zhangqing <zhangqing@rock-chips.com>
*
* SPDX-License-Identifier: GPL-2.0+
@ -189,7 +189,7 @@ static int act8931_parse_dt(const void* blob)
node = fdt_node_offset_by_compatible(blob,
g_i2c_node, COMPAT_ACTIVE_ACT8931);
if (node < 0) {
printf("can't find dts node for act8931\n");
debug("can't find dts node for act8931\n");
return -ENODEV;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* Copyright (C) 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
* yxj <yxj@rock-chips.com>
*
*/
@ -87,7 +87,7 @@ int ricoh619_parse_dt(const void* blob)
node = fdt_node_offset_by_compatible(blob, g_i2c_node,
COMPAT_RICOH_RICOH619);
if (node < 0) {
printf("can't find dts node for ricoh619\n");
debug("can't find dts node for ricoh619\n");
return -ENODEV;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* Copyright (C) 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
* zyw < zyw@rock-chips.com >
* andy <yxj@rock-chips.com>
*
@ -303,7 +303,7 @@ static int rk808_parse_dt(const void* blob)
node = fdt_node_offset_by_compatible(blob,
g_i2c_node, COMPAT_ROCKCHIP_RK808);
if (node < 0) {
printf("can't find dts node for rk808\n");
debug("can't find dts node for rk808\n");
return -ENODEV;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* Copyright (C) 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
* zhangqing < zhangqing@rock-chips.com >
* andy <yxj@rock-chips.com>
*
@ -243,24 +243,24 @@ static int rk818_parse_dt(const void* blob)
node = fdt_node_offset_by_compatible(blob,
g_i2c_node, COMPAT_ROCKCHIP_RK818);
if (node < 0) {
printf("can't find dts node for rk818\n");
debug("can't find dts node for rk818\n");
return -ENODEV;
}
if (!fdt_device_is_available(blob,node)) {
printf("device rk818 is disabled\n");
debug("device rk818 is disabled\n");
return -1;
}
ret = fdt_get_i2c_info(blob, node, &bus, &addr);
if (ret < 0) {
printf("pmic rk818 get fdt i2c failed\n");
debug("pmic rk818 get fdt i2c failed\n");
return ret;
}
ret = rk818_i2c_probe(bus, addr);
if (ret < 0) {
printf("pmic rk818 i2c probe failed\n");
debug("pmic rk818 i2c probe failed\n");
return ret;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* Copyright (C) 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
* zhangqing < zhangqing@rock-chips.com >
* andy <yxj@rock-chips.com>
*
@ -55,7 +55,7 @@ static int rt5025_parse_dt(const void* blob)
node = fdt_node_offset_by_compatible(blob,
g_i2c_node, COMPAT_ROCKCHIP_RT5025);
if (node < 0) {
printf("can't find dts node for rt5025\n");
debug("can't find dts node for rt5025\n");
return -ENODEV;
}
@ -72,7 +72,7 @@ static int rt5025_parse_dt(const void* blob)
nd = rt5025_i2c_probe(bus, addr);
if (nd < 0) {
printf("pmic rt5025 i2c probe failed\n");
debug("pmic rt5025 i2c probe failed\n");
return -1;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* Copyright (C) 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
* zhangqing < zhangqing@rock-chips.com >
*
* SPDX-License-Identifier: GPL-2.0+
@ -59,7 +59,7 @@ static int rt5036_parse_dt(const void* blob)
node = fdt_node_offset_by_compatible(blob,
g_i2c_node, COMPAT_ROCKCHIP_RT5036);
if (node < 0) {
printf("can't find dts node for rt5036\n");
debug("can't find dts node for rt5036\n");
return -ENODEV;
}
@ -76,7 +76,7 @@ static int rt5036_parse_dt(const void* blob)
nd = rt5036_i2c_probe(bus, addr);
if (nd < 0) {
printf("pmic rt5036 i2c probe failed\n");
debug("pmic rt5036 i2c probe failed\n");
return -1;
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2008-2015 Fuzhou Rockchip Electronics Co., Ltd
* Copyright (C) 2008-2016 Fuzhou Rockchip Electronics Co., Ltd
* zhangqing < zhangqing@rock-chips.com >
* andy <yxj@rock-chips.com>
*
@ -47,7 +47,7 @@ int regulator_register_check(int num_matches)
for (i = 0; i < MAX_DCDC_NUM; i++) {
if (strcmp(regulator_init_pwm_matches[num_matches].name, regulator_init_pmic_matches[i].name) == 0) {
printf("ERROR:regulator_register_check:this name %s is used,not init it.\n",
printf("DCDC %s has been used, pwm regulator not init it.\n",
regulator_init_pwm_matches[num_matches].name);
ret = -ENODEV;
return ret;
@ -76,7 +76,6 @@ static int pwm_regulator_set_voltage(int pwm_id, int num_matches,
ret = regulator_register_check(num_matches);
if (ret < 0) {
printf("ERROR:not support pwm set voltage\n");
return ret;
}