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
nexedi
linux
Commits
bb81a216
Commit
bb81a216
authored
Aug 27, 2010
by
Mauro Carvalho Chehab
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
i7300_edac: Detect if the device is on single mode
Signed-off-by:
Mauro Carvalho Chehab
<
mchehab@redhat.com
>
parent
d7de2bdb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
8 deletions
+17
-8
drivers/edac/i7300_edac.c
drivers/edac/i7300_edac.c
+17
-8
No files found.
drivers/edac/i7300_edac.c
View file @
bb81a216
...
...
@@ -92,12 +92,13 @@
/* OFFSETS for Function 1 */
#define MC_SETTINGS 0x40
#define IS_MIRRORED(mc) ((mc) & (1 << 16))
#define IS_ECC_ENABLED(mc) ((mc) & (1 << 5))
#define IS_RETRY_ENABLED(mc) ((mc) & (1 << 31))
#define IS_SCRBALGO_ENHANCED(mc) ((mc) & (1 << 8))
#define IS_MIRRORED(mc) ((mc) & (1 << 16))
#define IS_ECC_ENABLED(mc) ((mc) & (1 << 5))
#define IS_RETRY_ENABLED(mc) ((mc) & (1 << 31))
#define IS_SCRBALGO_ENHANCED(mc) ((mc) & (1 << 8))
#define MC_SETTINGS_A 0x58
#define IS_SINGLE_MODE(mca) ((mca) & (1 << 14))
#define TOLM 0x6C
#define REDMEMB 0x7C
...
...
@@ -237,9 +238,11 @@ struct i7300_pvt {
u16
tolm
;
/* top of low memory */
u64
ambase
;
/* AMB BAR */
u32
mc_settings
;
u16
mir
[
MAX_MIR
];
u32
mc_settings
;
/* Report several settings */
u32
mc_settings_a
;
u16
mir
[
MAX_MIR
];
/* Memory Interleave Reg*/
u16
mtr
[
MAX_SLOTS
][
MAX_BRANCHES
];
/* Memory Technlogy Reg */
u16
ambpresent
[
MAX_CHANNELS
];
/* AMB present regs */
...
...
@@ -653,9 +656,15 @@ static int i7300_get_mc_regs(struct mem_ctl_info *mci)
/* Get memory controller settings */
pci_read_config_dword
(
pvt
->
pci_dev_16_1_fsb_addr_map
,
MC_SETTINGS
,
&
pvt
->
mc_settings
);
pci_read_config_dword
(
pvt
->
pci_dev_16_1_fsb_addr_map
,
MC_SETTINGS_A
,
&
pvt
->
mc_settings_a
);
debugf0
(
"Memory controller operating on %s mode
\n
"
,
if
(
IS_SINGLE_MODE
(
pvt
->
mc_settings_a
))
debugf0
(
"Memory controller operating on single mode
\n
"
);
else
debugf0
(
"Memory controller operating on %s mode
\n
"
,
IS_MIRRORED
(
pvt
->
mc_settings
)
?
"mirrored"
:
"non-mirrored"
);
debugf0
(
"Error detection is %s
\n
"
,
IS_ECC_ENABLED
(
pvt
->
mc_settings
)
?
"enabled"
:
"disabled"
);
debugf0
(
"Retry is %s
\n
"
,
...
...
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