Commit bc57117856cf1e581135810b37d3b75f9d1749f5

Authored by Borislav Petkov
1 parent 9975a5f22a

amd64_edac: Correct scrub rate setting

Exit early when setting scrub rate on unknown/unsupported families.

Cc: <stable@kernel.org> # 32.x 33.x 34.x
Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
Acked-by: Doug Thompson <dougthompson@xmission.com>

Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff

drivers/edac/amd64_edac.c
... ... @@ -178,7 +178,7 @@
178 178  
179 179 default:
180 180 amd64_printk(KERN_ERR, "Unsupported family!\n");
181   - break;
  181 + return -EINVAL;
182 182 }
183 183 return amd64_search_set_scrub_rate(pvt->misc_f3_ctl, *bandwidth,
184 184 min_scrubrate);