summaryrefslogtreecommitdiff
path: root/drivers/ddr
diff options
context:
space:
mode:
authorMarek Vasut <marex@denx.de>2015-07-17 01:05:36 +0200
committerMarek Vasut <marex@denx.de>2015-08-08 14:14:14 +0200
commit84e0b0cf2b8589b1d22adcc324d91c9b004602a1 (patch)
tree30ad769dedeaef42e23dcf8be3dba1c39b94d6d8 /drivers/ddr
parent880e46f2d33c382a1acb449e277cf4f535b5c62a (diff)
ddr: altera: Init my_param and my_gbl
Init both structures with zeroes and zap all those zeroing shenanigans further down in the sdram_calibration_full(). Signed-off-by: Marek Vasut <marex@denx.de>
Diffstat (limited to 'drivers/ddr')
-rw-r--r--drivers/ddr/altera/sequencer.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/drivers/ddr/altera/sequencer.c b/drivers/ddr/altera/sequencer.c
index aceb6a06e1..2aa93c1ec9 100644
--- a/drivers/ddr/altera/sequencer.c
+++ b/drivers/ddr/altera/sequencer.c
@@ -3660,13 +3660,13 @@ int sdram_calibration_full(void)
struct param_type my_param;
struct gbl_type my_gbl;
uint32_t pass;
- uint32_t i;
+
+ memset(&my_param, 0, sizeof(my_param));
+ memset(&my_gbl, 0, sizeof(my_gbl));
param = &my_param;
gbl = &my_gbl;
- /* Initialize the debug mode flags */
- gbl->phy_debug_mode_flags = 0;
/* Set the calibration enabled by default */
gbl->phy_debug_mode_flags |= PHY_DEBUG_ENABLE_CAL_RPT;
/*
@@ -3686,13 +3686,6 @@ int sdram_calibration_full(void)
initialize_tracking();
- /* USER Enable all ranks, groups */
- for (i = 0; i < RW_MGR_MEM_NUMBER_OF_RANKS; i++)
- param->skip_ranks[i] = 0;
- for (i = 0; i < NUM_SHADOW_REGS; ++i)
- param->skip_shadow_regs[i] = 0;
- param->skip_groups = 0;
-
printf("%s: Preparing to start memory calibration\n", __FILE__);
debug("%s:%d\n", __func__, __LINE__);