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

login
register
mail settings
Submitter Qiuxu Zhuo
Date Nov. 16, 2018, 7:33 a.m.
Message ID <1542353616-13421-1-git-send-email-qiuxu.zhuo@intel.com>
Download mbox | patch
Permalink /patch/658309/
State New
Headers show

Comments

Qiuxu Zhuo - Nov. 16, 2018, 7:33 a.m.
The order of function calling in skx_exit() is not the reversed
order in skx_init(). Fix it by calling functions in skx_exit()
in a proper order.

Signed-off-by: Qiuxu Zhuo <qiuxu.zhuo@intel.com>
---
 drivers/edac/skx_edac.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
Borislav Petkov - Nov. 16, 2018, 10:23 a.m.
On Fri, Nov 16, 2018 at 03:33:36PM +0800, Qiuxu Zhuo wrote:
> The order of function calling in skx_exit() is not the reversed
> order in skx_init(). Fix it by calling functions in skx_exit()
> in a proper order.
> 
> Signed-off-by: Qiuxu Zhuo <qiuxu.zhuo@intel.com>
> ---
>  drivers/edac/skx_edac.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

All 4 applied, thanks.

Hint for the future: please teach your git to send the patches threaded,
i.e., the mail header should have:

In-Reply-To: <first mail's Message-ID>
References: <first mail's Message-ID>

Thx.
Qiuxu Zhuo - Nov. 16, 2018, 1:28 p.m.
Hi Boris,

> All 4 applied, thanks.

> 

> Hint for the future: please teach your git to send the patches threaded, i.e., the

> mail header should have:

> 

> In-Reply-To: <first mail's Message-ID>

> References: <first mail's Message-ID>


OK. 
Thanks for the hint :-)

- Qiuxu

Patch

diff --git a/drivers/edac/skx_edac.c b/drivers/edac/skx_edac.c
index a99ea61dad32..b23c8aaa5f2b 100644
--- a/drivers/edac/skx_edac.c
+++ b/drivers/edac/skx_edac.c
@@ -1339,11 +1339,11 @@  static void __exit skx_exit(void)
 {
 	edac_dbg(2, "\n");
 	mce_unregister_decode_chain(&skx_mce_dec);
-	skx_remove();
+	teardown_skx_debug();
 	if (nvdimm_count)
 		skx_adxl_put();
 	kfree(skx_msg);
-	teardown_skx_debug();
+	skx_remove();
 }
 
 module_init(skx_init);