Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
0f959e19
Commit
0f959e19
authored
Jun 22, 2020
by
Borislav Petkov
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'edac-ghes' into edac-for-next
parents
17ed808a
e370f886
Changes
2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
200 additions
and
152 deletions
+200
-152
drivers/edac/ghes_edac.c
drivers/edac/ghes_edac.c
+193
-130
include/linux/edac.h
include/linux/edac.h
+7
-22
No files found.
drivers/edac/ghes_edac.c
View file @
0f959e19
This diff is collapsed.
Click to expand it.
include/linux/edac.h
View file @
0f959e19
...
@@ -594,27 +594,6 @@ struct mem_ctl_info {
...
@@ -594,27 +594,6 @@ struct mem_ctl_info {
? (mci)->dimms[(dimm)->idx + 1] \
? (mci)->dimms[(dimm)->idx + 1] \
: NULL)
: NULL)
/**
* edac_get_dimm_by_index - Get DIMM info at @index from a memory
* controller
*
* @mci: MC descriptor struct mem_ctl_info
* @index: index in the memory controller's DIMM array
*
* Returns a struct dimm_info * or NULL on failure.
*/
static
inline
struct
dimm_info
*
edac_get_dimm_by_index
(
struct
mem_ctl_info
*
mci
,
int
index
)
{
if
(
index
<
0
||
index
>=
mci
->
tot_dimms
)
return
NULL
;
if
(
WARN_ON_ONCE
(
mci
->
dimms
[
index
]
->
idx
!=
index
))
return
NULL
;
return
mci
->
dimms
[
index
];
}
/**
/**
* edac_get_dimm - Get DIMM info from a memory controller given by
* edac_get_dimm - Get DIMM info from a memory controller given by
* [layer0,layer1,layer2] position
* [layer0,layer1,layer2] position
...
@@ -650,6 +629,12 @@ static inline struct dimm_info *edac_get_dimm(struct mem_ctl_info *mci,
...
@@ -650,6 +629,12 @@ static inline struct dimm_info *edac_get_dimm(struct mem_ctl_info *mci,
if
(
mci
->
n_layers
>
2
)
if
(
mci
->
n_layers
>
2
)
index
=
index
*
mci
->
layers
[
2
].
size
+
layer2
;
index
=
index
*
mci
->
layers
[
2
].
size
+
layer2
;
return
edac_get_dimm_by_index
(
mci
,
index
);
if
(
index
<
0
||
index
>=
mci
->
tot_dimms
)
return
NULL
;
if
(
WARN_ON_ONCE
(
mci
->
dimms
[
index
]
->
idx
!=
index
))
return
NULL
;
return
mci
->
dimms
[
index
];
}
}
#endif
/* _LINUX_EDAC_H_ */
#endif
/* _LINUX_EDAC_H_ */
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment