Newer
Older
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
* configuration node.
*
* returns:
* no returned results
*/
void fit_conf_print (const void *fit, int noffset, const char *p)
{
char *desc;
char *uname;
int ret;
/* Mandatory properties */
ret = fit_get_desc (fit, noffset, &desc);
printf ("%s Description: ", p);
if (ret)
printf ("unavailable\n");
else
printf ("%s\n", desc);
uname = (char *)fdt_getprop (fit, noffset, FIT_KERNEL_PROP, NULL);
printf ("%s Kernel: ", p);
if (uname == NULL)
printf ("unavailable\n");
else
printf ("%s\n", uname);
/* Optional properties */
uname = (char *)fdt_getprop (fit, noffset, FIT_RAMDISK_PROP, NULL);
if (uname)
printf ("%s Init Ramdisk: %s\n", p, uname);
uname = (char *)fdt_getprop (fit, noffset, FIT_FDT_PROP, NULL);
if (uname)
printf ("%s FDT: %s\n", p, uname);
}
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
/**
* fit_check_ramdisk - verify FIT format ramdisk subimage
* @fit_hdr: pointer to the FIT ramdisk header
* @rd_noffset: ramdisk subimage node offset within FIT image
* @arch: requested ramdisk image architecture type
* @verify: data CRC verification flag
*
* fit_check_ramdisk() verifies integrity of the ramdisk subimage and from
* specified FIT image.
*
* returns:
* 1, on success
* 0, on failure
*/
#ifndef USE_HOSTCC
static int fit_check_ramdisk (const void *fit, int rd_noffset, uint8_t arch, int verify)
{
fit_image_print (fit, rd_noffset, " ");
if (verify) {
puts (" Verifying Hash Integrity ... ");
if (!fit_image_check_hashes (fit, rd_noffset)) {
puts ("Bad Data Hash\n");
show_boot_progress (-125);
return 0;
}
puts ("OK\n");
}
show_boot_progress (126);
if (!fit_image_check_os (fit, rd_noffset, IH_OS_LINUX) ||
!fit_image_check_arch (fit, rd_noffset, arch) ||
!fit_image_check_type (fit, rd_noffset, IH_TYPE_RAMDISK)) {
printf ("No Linux %s Ramdisk Image\n",
genimg_get_arch_name(arch));
show_boot_progress (-126);
return 0;
}
show_boot_progress (127);
return 1;
}
#endif /* USE_HOSTCC */
#endif /* CONFIG_FIT */