amd64_edac: add f10-and-later methods-p3
Quoted 55 lines · Mauro Carvalho Chehab
From: Mauro Carvalho Chehab <[email protected]>
Subject: Re: [PATCH 13/21]amd64_edac: add f10-and-later methods-p3
To: "Borislav Petkov" <[email protected]>
Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
Date: Monday, May 4, 2009, 5:36 PM
Borislav Petkov escreveu:Quoted 6 lines
From: Doug Thompson <[email protected]>
Signed-off-by Doug Thompson <[email protected]>Signed-off-by Borislav Petkov <[email protected]>---
drivers/edac/amd64_edac.c| 318+++++++++++++++++++++++++++++++++++++++++++++
Quoted 1 line
1 files changed, 318 insertions(+), 0deletions(-)
Review
Quoted 2 lines
(quoted diff) +0
-0
b/drivers/edac/amd64_edac.cdrivers/edac/amd64_edac.c static int
Quoted 4 lines
index fe2342c..84075c0 100644
drivers/edac/amd64_edac.c +0
-0@@ -2726,4 +2726,322 @@ static int
f10_lookup_addr_in_dct(u32 InputAddr, u32 NodeID, u32 ChannelSelect)Quoted 6 lines
drivers/edac/amd64_edac.c +0
-0return CSFound; }+/*
+ *f10_match_to_this_node
+ *
+ * For a given 'DramRange' value, check if'SystemAddr' fall within this value
Quoted 2 lines
+ */
+static int f10_match_to_this_node(structamd64_pvt*pvt, int DramRange,
Quoted 1 line
+
u64 SystemAddr,
Quoted 1 line
+
int
*node_id,Quoted 1 line
+
int
*channel_select)Quoted 3 lines
+{
+ int CSFound = -1;As in the previous patch, please use a standard error code, instead of -1.
Quoted 1 line
+static int f10_translate_sysaddr_to_CS(struct
amd64_pvt*pvt,Quoted 1 line
+
u64 SysAddr,
Quoted 1 line
+
int *node,
Quoted 1 line
+
int *chanSel)
Quoted 9 lines
Quoted 4 lines
+{
+ int DramRange;
+ int CSFound = -1;Same here.
Cheers,
Mauro
Code was reference code from AMD. Probably safe to convert to use -EINVAL yes
doug t