aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBorislav Petkov <bp@suse.de>2017-01-23 13:35:13 -0500
committerIngo Molnar <mingo@kernel.org>2017-01-24 03:14:56 -0500
commitcff4c0391a692cf9b89932c62a7f879fb3637148 (patch)
treeefbc40ecc6f8fab7010df49ae910f1c1aec8990e
parent0bceab677dcef409f6281d922461057721d547b3 (diff)
x86/ras: Get rid of mce_process_work()
Make mce_gen_pool_process() the workqueue function directly and save us an indirection. Signed-off-by: Borislav Petkov <bp@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Tony Luck <tony.luck@intel.com> Cc: Yazen Ghannam <Yazen.Ghannam@amd.com> Cc: linux-edac <linux-edac@vger.kernel.org> Link: http://lkml.kernel.org/r/20170123183514.13356-9-bp@alien8.de Signed-off-by: Ingo Molnar <mingo@kernel.org>
-rw-r--r--arch/x86/kernel/cpu/mcheck/mce-genpool.c2
-rw-r--r--arch/x86/kernel/cpu/mcheck/mce-internal.h2
-rw-r--r--arch/x86/kernel/cpu/mcheck/mce.c12
3 files changed, 3 insertions, 13 deletions
diff --git a/arch/x86/kernel/cpu/mcheck/mce-genpool.c b/arch/x86/kernel/cpu/mcheck/mce-genpool.c
index 93d824ec3120..1e5a50c11d3c 100644
--- a/arch/x86/kernel/cpu/mcheck/mce-genpool.c
+++ b/arch/x86/kernel/cpu/mcheck/mce-genpool.c
@@ -72,7 +72,7 @@ struct llist_node *mce_gen_pool_prepare_records(void)
72 return new_head.first; 72 return new_head.first;
73} 73}
74 74
75void mce_gen_pool_process(void) 75void mce_gen_pool_process(struct work_struct *__unused)
76{ 76{
77 struct llist_node *head; 77 struct llist_node *head;
78 struct mce_evt_llist *node, *tmp; 78 struct mce_evt_llist *node, *tmp;
diff --git a/arch/x86/kernel/cpu/mcheck/mce-internal.h b/arch/x86/kernel/cpu/mcheck/mce-internal.h
index cd74a3f00aea..903043e6a62b 100644
--- a/arch/x86/kernel/cpu/mcheck/mce-internal.h
+++ b/arch/x86/kernel/cpu/mcheck/mce-internal.h
@@ -31,7 +31,7 @@ struct mce_evt_llist {
31 struct mce mce; 31 struct mce mce;
32}; 32};
33 33
34void mce_gen_pool_process(void); 34void mce_gen_pool_process(struct work_struct *__unused);
35bool mce_gen_pool_empty(void); 35bool mce_gen_pool_empty(void);
36int mce_gen_pool_add(struct mce *mce); 36int mce_gen_pool_add(struct mce *mce);
37int mce_gen_pool_init(void); 37int mce_gen_pool_init(void);
diff --git a/arch/x86/kernel/cpu/mcheck/mce.c b/arch/x86/kernel/cpu/mcheck/mce.c
index ca15a7e1f97d..0fef5406f0eb 100644
--- a/arch/x86/kernel/cpu/mcheck/mce.c
+++ b/arch/x86/kernel/cpu/mcheck/mce.c
@@ -1316,16 +1316,6 @@ int memory_failure(unsigned long pfn, int vector, int flags)
1316#endif 1316#endif
1317 1317
1318/* 1318/*
1319 * Action optional processing happens here (picking up
1320 * from the list of faulting pages that do_machine_check()
1321 * placed into the genpool).
1322 */
1323static void mce_process_work(struct work_struct *dummy)
1324{
1325 mce_gen_pool_process();
1326}
1327
1328/*
1329 * Periodic polling timer for "silent" machine check errors. If the 1319 * Periodic polling timer for "silent" machine check errors. If the
1330 * poller finds an MCE, poll 2x faster. When the poller finds no more 1320 * poller finds an MCE, poll 2x faster. When the poller finds no more
1331 * errors, poll 2x slower (up to check_interval seconds). 1321 * errors, poll 2x slower (up to check_interval seconds).
@@ -2165,7 +2155,7 @@ int __init mcheck_init(void)
2165 mce_register_decode_chain(&mce_default_nb); 2155 mce_register_decode_chain(&mce_default_nb);
2166 mcheck_vendor_init_severity(); 2156 mcheck_vendor_init_severity();
2167 2157
2168 INIT_WORK(&mce_work, mce_process_work); 2158 INIT_WORK(&mce_work, mce_gen_pool_process);
2169 init_irq_work(&mce_irq_work, mce_irq_work_cb); 2159 init_irq_work(&mce_irq_work, mce_irq_work_cb);
2170 2160
2171 return 0; 2161 return 0;