Patchwork [v1,1/5] EDAC, skx_edac: Fix function calling order in skx_exit()

login
register
mail settings
Submitter Qiuxu Zhuo
Date Oct. 19, 2018, 8:44 a.m.
Message ID <1539938681-24068-1-git-send-email-qiuxu.zhuo@intel.com>
Download mbox | patch
Permalink /patch/639843/
State New
Headers show

Comments

Qiuxu Zhuo - Oct. 19, 2018, 8:44 a.m.
The order of function calling in skx_exit() is not the reversed
order in skx_init(). Fix it by moving skx_remove() to the last.

Signed-off-by: Qiuxu Zhuo <qiuxu.zhuo@intel.com>
---
 drivers/edac/skx_edac.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch

diff --git a/drivers/edac/skx_edac.c b/drivers/edac/skx_edac.c
index dd209e0dd9ab..d264e933695c 100644
--- a/drivers/edac/skx_edac.c
+++ b/drivers/edac/skx_edac.c
@@ -1175,8 +1175,8 @@  static void __exit skx_exit(void)
 {
 	edac_dbg(2, "\n");
 	mce_unregister_decode_chain(&skx_mce_dec);
-	skx_remove();
 	teardown_skx_debug();
+	skx_remove();
 }
 
 module_init(skx_init);