From 99f453e9533f590fe40432b62c131625d7e91e46 Mon Sep 17 00:00:00 2001 From: Marek Vasut Date: Sat, 1 Aug 2015 22:25:29 +0200 Subject: [PATCH] ddr: altera: sdram: Clean up sdram_mmr_init_full() part 8 Fix the return value so that standard errno return values can be used. Signed-off-by: Marek Vasut --- arch/arm/mach-socfpga/include/mach/sdram.h | 2 +- drivers/ddr/altera/sdram.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-socfpga/include/mach/sdram.h b/arch/arm/mach-socfpga/include/mach/sdram.h index d57257df24..89240b8c06 100644 --- a/arch/arm/mach-socfpga/include/mach/sdram.h +++ b/arch/arm/mach-socfpga/include/mach/sdram.h @@ -9,7 +9,7 @@ #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); diff --git a/drivers/ddr/altera/sdram.c b/drivers/ddr/altera/sdram.c index 295747b3fa..68a9b60e79 100644 --- a/drivers/ddr/altera/sdram.c +++ b/drivers/ddr/altera/sdram.c @@ -4,6 +4,7 @@ * SPDX-License-Identifier: GPL-2.0+ */ #include +#include #include #include #include @@ -621,7 +622,7 @@ static void sdr_load_regs(struct socfpga_sdram_config *cfg) * * 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; -- 2.25.1