All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH V2 1/3] sunxi: Use clrsetbits_le32 instead of multiple instruction
@ 2019-02-14 15:58 Michael Trimarchi
  2019-02-14 15:58 ` [U-Boot] [PATCH V2 2/3] sunxi: Don't change the rank in dram size detection in A33 Michael Trimarchi
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Michael Trimarchi @ 2019-02-14 15:58 UTC (permalink / raw)
  To: u-boot

Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
---

V1->V2: none

---
 arch/arm/mach-sunxi/dram_sun8i_a33.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/arch/arm/mach-sunxi/dram_sun8i_a33.c b/arch/arm/mach-sunxi/dram_sun8i_a33.c
index 1da2727f98..83212aaddf 100644
--- a/arch/arm/mach-sunxi/dram_sun8i_a33.c
+++ b/arch/arm/mach-sunxi/dram_sun8i_a33.c
@@ -148,12 +148,8 @@ static void auto_set_timing_para(struct dram_para *para)
 	reg_val = (tcksrx << 24) | (tcksre << 16) | (tckesr << 8) | (tcke << 0);
 	writel(reg_val, &mctl_ctl->dramtmg5);
 	/* Set two rank timing and exit self-refresh timing */
-	reg_val = readl(&mctl_ctl->dramtmg8);
-	reg_val &= ~(0xff << 8);
-	reg_val &= ~(0xff << 0);
-	reg_val |= (0x33 << 8);
-	reg_val |= (0x8 << 0);
-	writel(reg_val, &mctl_ctl->dramtmg8);
+	clrsetbits_le32(&mctl_ctl->dramtmg8, (0xff << 8) | (0xff << 0),
+			0x33 << 8 | (0x8 << 0));
 	/* Set phy interface time */
 	reg_val = (0x2 << 24) | (t_rdata_en << 16) | (0x1 << 8)
 			| (wr_latency << 0);
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2019-02-18  9:36 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-02-14 15:58 [U-Boot] [PATCH V2 1/3] sunxi: Use clrsetbits_le32 instead of multiple instruction Michael Trimarchi
2019-02-14 15:58 ` [U-Boot] [PATCH V2 2/3] sunxi: Don't change the rank in dram size detection in A33 Michael Trimarchi
2019-02-14 15:58 ` [U-Boot] [PATCH V2 3/3] sunxi: Fix A33 memory initialization Michael Trimarchi
2019-02-14 16:36   ` Philipp Tomsich
2019-02-14 16:40     ` Michael Nazzareno Trimarchi
2019-02-14 21:24     ` André Przywara
2019-02-15 10:18       ` Philipp Tomsich
2019-02-15 11:31         ` Andre Przywara
2019-02-15 11:40           ` Philipp Tomsich
2019-02-15 16:01             ` Michael Nazzareno Trimarchi
2019-02-15 16:09               ` Andre Przywara
2019-02-18  9:36 ` [U-Boot] [PATCH V2 1/3] sunxi: Use clrsetbits_le32 instead of multiple instruction Jagan Teki

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.