diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/edac/amd64_edac.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/edac/amd64_edac.c b/drivers/edac/amd64_edac.c index 5a297a26211d..cc8e7c78a23c 100644 --- a/drivers/edac/amd64_edac.c +++ b/drivers/edac/amd64_edac.c | |||
@@ -170,8 +170,11 @@ static int __amd64_set_scrub_rate(struct pci_dev *ctl, u32 new_bw, u32 min_rate) | |||
170 | * memory controller and apply to register. Search for the first | 170 | * memory controller and apply to register. Search for the first |
171 | * bandwidth entry that is greater or equal than the setting requested | 171 | * bandwidth entry that is greater or equal than the setting requested |
172 | * and program that. If at last entry, turn off DRAM scrubbing. | 172 | * and program that. If at last entry, turn off DRAM scrubbing. |
173 | * | ||
174 | * If no suitable bandwidth is found, turn off DRAM scrubbing entirely | ||
175 | * by falling back to the last element in scrubrates[]. | ||
173 | */ | 176 | */ |
174 | for (i = 0; i < ARRAY_SIZE(scrubrates); i++) { | 177 | for (i = 0; i < ARRAY_SIZE(scrubrates) - 1; i++) { |
175 | /* | 178 | /* |
176 | * skip scrub rates which aren't recommended | 179 | * skip scrub rates which aren't recommended |
177 | * (see F10 BKDG, F3x58) | 180 | * (see F10 BKDG, F3x58) |
@@ -181,12 +184,6 @@ static int __amd64_set_scrub_rate(struct pci_dev *ctl, u32 new_bw, u32 min_rate) | |||
181 | 184 | ||
182 | if (scrubrates[i].bandwidth <= new_bw) | 185 | if (scrubrates[i].bandwidth <= new_bw) |
183 | break; | 186 | break; |
184 | |||
185 | /* | ||
186 | * if no suitable bandwidth found, turn off DRAM scrubbing | ||
187 | * entirely by falling back to the last element in the | ||
188 | * scrubrates array. | ||
189 | */ | ||
190 | } | 187 | } |
191 | 188 | ||
192 | scrubval = scrubrates[i].scrubval; | 189 | scrubval = scrubrates[i].scrubval; |