Skip to contentSkip to conversation

sb_edac: Fix typo computing number of banks

PATCH Applied Tony Luck 3 participants 3 messages Dec 2, 2014

Subsystems (2)
lore
Share & tools
lore

Tony Luck

author maintainer
#0 lore raw

PATCH 1/1 sb_edac: Fix typo computing number of banks

Code will always think there are 16 banks because of a typo

Reported-by Misha

---

Not sure if Misha is shy, or just busy. But my attempt to get them to post their own patch didn't work

 drivers/edac/sb_edac.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/edac/sb_edac.c +1 -1
index 993e8b61c4b2..63aa6730e89e 100644
@@ -901,7 +901,7 @@ static int get_dimm_config(struct mem_ctl_info *mci)
 	else
 		edac_dbg(0, "Memory is unregistered\n");
 
-	if (mtype == MEM_DDR4 || MEM_RDDR4)
+	if (mtype == MEM_DDR4 || mtype == MEM_RDDR4)
 		banks = 16;
 	else
 		banks = 8;
Signature · 1 line
2.1.0
#1 lore raw
Quoted 17 lines · Tony Luck

Code will always think there are 16 banks because of a typo

Reported-by Misha

---

Not sure if Misha is shy, or just busy. But my attempt to get them to post their own patch didn't work

 drivers/edac/sb_edac.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/edac/sb_edac.c +0 -0
index 993e8b61c4b2..63aa6730e89e 100644

drivers/edac/sb_edac.c static int get_dimm_config(struct mem_ctl_info *mci) · line 907

Quoted 8 lines
drivers/edac/sb_edac.c +1 -1
@@ -901,7 +901,7 @@ static int get_dimm_config(struct mem_ctl_info *mci)
 	else
 		edac_dbg(0, "Memory is unregistered\n");
 
-	if (mtype == MEM_DDR4 || MEM_RDDR4)
+	if (mtype == MEM_DDR4 || mtype == MEM_RDDR4)
 		banks = 16;
 	else
 		banks = 8;

ACK

Signature · 1 line
Aristeu
#2 lore raw

Em Tue, 2 Dec 2014 13:17:58 -0500
Aristeu Rozanski <[email protected]> escreveu:

Quoted 5 lines · Tony Luck
Quoted 4 lines

Code will always think there are 16 banks because of a typo

Reported-by Misha

Applied, thanks!

Quoted 24 lines
Quoted 13 lines

---

Not sure if Misha is shy, or just busy. But my attempt to get them to post their own patch didn't work

 drivers/edac/sb_edac.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/edac/sb_edac.c +0 -0
index 993e8b61c4b2..63aa6730e89e 100644

drivers/edac/sb_edac.c static int get_dimm_config(struct mem_ctl_info *mci) · line 907

Quoted 8 lines
drivers/edac/sb_edac.c +1 -1
@@ -901,7 +901,7 @@ static int get_dimm_config(struct mem_ctl_info *mci)
 	else
 		edac_dbg(0, "Memory is unregistered\n");
 
-	if (mtype == MEM_DDR4 || MEM_RDDR4)
+	if (mtype == MEM_DDR4 || mtype == MEM_RDDR4)
 		banks = 16;
 	else
 		banks = 8;

ACK