diff options
| -rw-r--r-- | drivers/edac/amd64_edac.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/edac/amd64_edac.c b/drivers/edac/amd64_edac.c index 81dca957fce0..54acd3a7acdc 100644 --- a/drivers/edac/amd64_edac.c +++ b/drivers/edac/amd64_edac.c | |||
| @@ -3326,8 +3326,14 @@ static int init_one_instance(unsigned int nid) | |||
| 3326 | * Always allocate two channels since we can have setups with DIMMs on | 3326 | * Always allocate two channels since we can have setups with DIMMs on |
| 3327 | * only one channel. Also, this simplifies handling later for the price | 3327 | * only one channel. Also, this simplifies handling later for the price |
| 3328 | * of a couple of KBs tops. | 3328 | * of a couple of KBs tops. |
| 3329 | * | ||
| 3330 | * On Fam17h+, the number of controllers may be greater than two. So set | ||
| 3331 | * the size equal to the maximum number of UMCs. | ||
| 3329 | */ | 3332 | */ |
| 3330 | layers[1].size = 2; | 3333 | if (pvt->fam >= 0x17) |
| 3334 | layers[1].size = num_umcs; | ||
| 3335 | else | ||
| 3336 | layers[1].size = 2; | ||
| 3331 | layers[1].is_virt_csrow = false; | 3337 | layers[1].is_virt_csrow = false; |
| 3332 | 3338 | ||
| 3333 | mci = edac_mc_alloc(nid, ARRAY_SIZE(layers), layers, 0); | 3339 | mci = edac_mc_alloc(nid, ARRAY_SIZE(layers), layers, 0); |
