diff options
author | Borislav Petkov <borislav.petkov@amd.com> | 2010-12-22 13:31:45 -0500 |
---|---|---|
committer | Borislav Petkov <borislav.petkov@amd.com> | 2011-03-17 09:46:15 -0400 |
commit | 78da121e1560805a0e6e11952de30b416accef62 (patch) | |
tree | 405a56f49280210c354355c7d977a490831e39df /drivers/edac/amd64_edac.h | |
parent | cb32850744b8b574966637ae98d55692717eced4 (diff) |
amd64_edac: Cleanup DCT Select Low/High code
Shorten macro names, remove family name from macros, fix macro
arguments, shorten debug strings.
No functionality change.
Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
Diffstat (limited to 'drivers/edac/amd64_edac.h')
-rw-r--r-- | drivers/edac/amd64_edac.h | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/drivers/edac/amd64_edac.h b/drivers/edac/amd64_edac.h index 7323f1b493ad..0244c612b3f2 100644 --- a/drivers/edac/amd64_edac.h +++ b/drivers/edac/amd64_edac.h | |||
@@ -227,19 +227,19 @@ | |||
227 | #define DCHR1 0x194 | 227 | #define DCHR1 0x194 |
228 | #define DDR3_MODE BIT(8) | 228 | #define DDR3_MODE BIT(8) |
229 | 229 | ||
230 | #define F10_DCTL_SEL_LOW 0x110 | 230 | #define DCT_SEL_LO 0x110 |
231 | #define dct_sel_baseaddr(pvt) ((pvt->dct_sel_low) & 0xFFFFF800) | 231 | #define dct_sel_baseaddr(pvt) ((pvt)->dct_sel_lo & 0xFFFFF800) |
232 | #define dct_sel_interleave_addr(pvt) (((pvt->dct_sel_low) >> 6) & 0x3) | 232 | #define dct_sel_interleave_addr(pvt) (((pvt)->dct_sel_lo >> 6) & 0x3) |
233 | #define dct_high_range_enabled(pvt) (pvt->dct_sel_low & BIT(0)) | 233 | #define dct_high_range_enabled(pvt) ((pvt)->dct_sel_lo & BIT(0)) |
234 | #define dct_interleave_enabled(pvt) (pvt->dct_sel_low & BIT(2)) | 234 | #define dct_interleave_enabled(pvt) ((pvt)->dct_sel_lo & BIT(2)) |
235 | 235 | ||
236 | #define dct_ganging_enabled(pvt) ((boot_cpu_data.x86 == 0x10) && ((pvt)->dct_sel_low & BIT(4))) | 236 | #define dct_ganging_enabled(pvt) ((boot_cpu_data.x86 == 0x10) && ((pvt)->dct_sel_lo & BIT(4))) |
237 | 237 | ||
238 | #define dct_data_intlv_enabled(pvt) (pvt->dct_sel_low & BIT(5)) | 238 | #define dct_data_intlv_enabled(pvt) ((pvt)->dct_sel_lo & BIT(5)) |
239 | #define dct_dram_enabled(pvt) (pvt->dct_sel_low & BIT(8)) | 239 | #define dct_dram_enabled(pvt) ((pvt)->dct_sel_lo & BIT(8)) |
240 | #define dct_memory_cleared(pvt) (pvt->dct_sel_low & BIT(10)) | 240 | #define dct_memory_cleared(pvt) ((pvt)->dct_sel_lo & BIT(10)) |
241 | 241 | ||
242 | #define F10_DCTL_SEL_HIGH 0x114 | 242 | #define DCT_SEL_HI 0x114 |
243 | 243 | ||
244 | /* | 244 | /* |
245 | * Function 3 - Misc Control | 245 | * Function 3 - Misc Control |
@@ -419,8 +419,8 @@ struct amd64_pvt { | |||
419 | u64 top_mem; /* top of memory below 4GB */ | 419 | u64 top_mem; /* top of memory below 4GB */ |
420 | u64 top_mem2; /* top of memory above 4GB */ | 420 | u64 top_mem2; /* top of memory above 4GB */ |
421 | 421 | ||
422 | u32 dct_sel_low; /* DRAM Controller Select Low Reg */ | 422 | u32 dct_sel_lo; /* DRAM Controller Select Low */ |
423 | u32 dct_sel_hi; /* DRAM Controller Select High Reg */ | 423 | u32 dct_sel_hi; /* DRAM Controller Select High */ |
424 | u32 online_spare; /* On-Line spare Reg */ | 424 | u32 online_spare; /* On-Line spare Reg */ |
425 | 425 | ||
426 | /* x4 or x8 syndromes in use */ | 426 | /* x4 or x8 syndromes in use */ |