diff options
author | Prarit Bhargava <[email protected]> | 2017-05-31 13:32:00 -0400 |
---|---|---|
committer | Dan Williams <[email protected]> | 2017-07-17 11:43:58 -0700 |
commit | 7e700d2c59e5853c9126642976b4f5768f64c9b3 (patch) | |
tree | 4aea083be87ca8ab1b2f474b64f77a8faac93401 /net/switchdev/switchdev.c | |
parent | 43fe51e11c194a6576634585f81ba33e104194a5 (diff) |
acpi/nfit: Fix memory corruption/Unregister mce decoder on failure
nfit_init() calls nfit_mce_register() on module load. When the module
load fails the nfit mce decoder is not unregistered. The module's
memory is freed leaving the decoder chain referencing junk. This will
cause panics as future registrations will reference the free'd memory.
Unregister the nfit mce decoder on module init failure.
[v2]: register and then unregister mce handler to avoid losing mce events
[v3]: also cleanup nfit workqueue
Fixes: 6839a6d96f4e ("nfit: do an ARS scrub on hitting a latent media error")
Cc: <[email protected]>
Cc: "Rafael J. Wysocki" <[email protected]>
Cc: Len Brown <[email protected]>
Cc: Vishal Verma <[email protected]>
Cc: "Lee, Chun-Yi" <[email protected]>
Cc: Linda Knippers <[email protected]>
Cc: [email protected]
Acked-by: Jeff Moyer <[email protected]>
Signed-off-by: Prarit Bhargava <[email protected]>
Reviewed-by: Vishal Verma <[email protected]>
Signed-off-by: Dan Williams <[email protected]>
Diffstat (limited to 'net/switchdev/switchdev.c')
0 files changed, 0 insertions, 0 deletions