Fix the return value so that standard errno return values can be used.
Signed-off-by: Marek Vasut <marex@denx.de>
#ifndef __ASSEMBLY__
unsigned long sdram_calculate_size(void);
-unsigned sdram_mmr_init_full(unsigned int sdr_phy_reg);
+int sdram_mmr_init_full(unsigned int sdr_phy_reg);
int sdram_calibration_full(void);
extern int sdram_calibration(void);
* SPDX-License-Identifier: GPL-2.0+
*/
#include <common.h>
+#include <errno.h>
#include <div64.h>
#include <watchdog.h>
#include <asm/arch/fpga_manager.h>
*
* Initialize the SDRAM MMR.
*/
-unsigned sdram_mmr_init_full(unsigned int sdr_phy_reg)
+int sdram_mmr_init_full(unsigned int sdr_phy_reg)
{
unsigned long status = 0;
struct socfpga_sdram_config *cfg = &sdram_config;