[U-Boot] [PATCH v2 2/6] arm64: mvebu: Add bubt command for flash image burn

Stefan Roese sr at denx.de
Tue Dec 6 10:22:16 CET 2016


Hi Kosta,

On 06.12.2016 10:06, Kostya Porotchkin wrote:

<snip>

>>> +int is_mmc_active(void)
>>> +{
>>> +	return 1;
>>> +}
>>> +#else /* CONFIG_DM_MMC */
>>> +#define mmc_burn_image 0
>>> +#define mmc_read_file 0
>>> +#define is_mmc_active 0
>>> +#endif /* CONFIG_DM_MMC */
>>
>> Please use empty functions instead.
> [Konstantin Porotchkin]
> Do you mean defining it in this way?
> #define mmc_burn_image(a)	0
> Or like below?
> int mmc_burn_image(size_t image_size)
> {
> 	return -1;
> }

The latter please. Perhaps its also possible to return some
decent error code in this case (ENODEV?) so that the
calling code can handle this case even better or report
this clearer to the user.

Thanks,
Stefan


More information about the U-Boot mailing list