]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
ddr: altera: Replace ad-hoc constant with macro
authorMarek Vasut <marex@denx.de>
Mon, 4 Apr 2016 14:07:11 +0000 (16:07 +0200)
committerMarek Vasut <marex@denx.de>
Wed, 20 Apr 2016 09:28:43 +0000 (11:28 +0200)
The bit 22 is in fact DQS tracking enable bit (dqstrken) and there
is a macro for this bit already, so use it.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
Cc: Chin Liang See <clsee@altera.com>
drivers/ddr/altera/sequencer.c

index 79c265faa21a30d8a17292da93851b87300f0b5d..34b1aa79fb86098cedc556e63db3c696ad1a159d 100644 (file)
@@ -3486,7 +3486,7 @@ static int run_mem_calibrate(void)
        writel(PHY_MGR_CAL_RESET, &phy_mgr_cfg->cal_status);
 
        /* Stop tracking manager. */
-       clrbits_le32(&sdr_ctrl->ctrl_cfg, 1 << 22);
+       clrbits_le32(&sdr_ctrl->ctrl_cfg, SDR_CTRLGRP_CTRLCFG_DQSTRKEN_MASK);
 
        phy_mgr_initialize();
        rw_mgr_mem_initialize();
@@ -3507,7 +3507,7 @@ static int run_mem_calibrate(void)
        writel(0x2, &phy_mgr_cfg->mux_sel);
 
        /* Start tracking manager. */
-       setbits_le32(&sdr_ctrl->ctrl_cfg, 1 << 22);
+       setbits_le32(&sdr_ctrl->ctrl_cfg, SDR_CTRLGRP_CTRLCFG_DQSTRKEN_MASK);
 
        return pass;
 }