Release 4.14 arch/x86/kernel/cpu/mcheck/mce-internal.h
/* SPDX-License-Identifier: GPL-2.0 */
#ifndef __X86_MCE_INTERNAL_H__
#define __X86_MCE_INTERNAL_H__
#include <linux/device.h>
#include <asm/mce.h>
enum severity_level {
MCE_NO_SEVERITY,
MCE_DEFERRED_SEVERITY,
MCE_UCNA_SEVERITY = MCE_DEFERRED_SEVERITY,
MCE_KEEP_SEVERITY,
MCE_SOME_SEVERITY,
MCE_AO_SEVERITY,
MCE_UC_SEVERITY,
MCE_AR_SEVERITY,
MCE_PANIC_SEVERITY,
};
extern struct blocking_notifier_head x86_mce_decoder_chain;
#define ATTR_LEN 16
#define INITIAL_CHECK_INTERVAL 5 * 60
/* 5 minutes */
/* One object for each MCE bank, shared by all CPUs */
struct mce_bank {
u64 ctl; /* subevents to enable */
unsigned char init; /* initialise bank? */
struct device_attribute attr; /* device attribute */
char attrname[ATTR_LEN]; /* attribute name */
};
struct mce_evt_llist {
struct llist_node llnode;
struct mce mce;
};
void mce_gen_pool_process(struct work_struct *__unused);
bool mce_gen_pool_empty(void);
int mce_gen_pool_add(struct mce *mce);
int mce_gen_pool_init(void);
struct llist_node *mce_gen_pool_prepare_records(void);
extern int (*mce_severity)(struct mce *a, int tolerant, char **msg, bool is_excp);
struct dentry *mce_get_debugfs_dir(void);
extern struct mce_bank *mce_banks;
extern mce_banks_t mce_banks_ce_disabled;
#ifdef CONFIG_X86_MCE_INTEL
unsigned long cmci_intel_adjust_timer(unsigned long interval);
bool mce_intel_cmci_poll(void);
void mce_intel_hcpu_update(unsigned long cpu);
void cmci_disable_bank(int bank);
#else
# define cmci_intel_adjust_timer mce_adjust_timer_default
static inline bool mce_intel_cmci_poll(void) { return false; }
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Borislav Petkov | 6 | 50.00% | 1 | 50.00% |
Chen Gong | 6 | 50.00% | 1 | 50.00% |
Total | 12 | 100.00% | 2 | 100.00% |
static inline void mce_intel_hcpu_update(unsigned long cpu) { }
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Chen Gong | 9 | 90.00% | 1 | 50.00% |
Naveen N. Rao | 1 | 10.00% | 1 | 50.00% |
Total | 10 | 100.00% | 2 | 100.00% |
static inline void cmci_disable_bank(int bank) { }
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Naveen N. Rao | 8 | 88.89% | 1 | 50.00% |
Chen Gong | 1 | 11.11% | 1 | 50.00% |
Total | 9 | 100.00% | 2 | 100.00% |
#endif
void mce_timer_kick(unsigned long interval);
#ifdef CONFIG_ACPI_APEI
int apei_write_mce(struct mce *m);
ssize_t apei_read_mce(struct mce *m, u64 *record_id);
int apei_check_mce(void);
int apei_clear_mce(u64 record_id);
#else
static inline int apei_write_mce(struct mce *m)
{
return -EINVAL;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Huang Ying | 16 | 100.00% | 1 | 100.00% |
Total | 16 | 100.00% | 1 | 100.00% |
static inline ssize_t apei_read_mce(struct mce *m, u64 *record_id)
{
return 0;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Huang Ying | 19 | 100.00% | 1 | 100.00% |
Total | 19 | 100.00% | 1 | 100.00% |
static inline int apei_check_mce(void)
{
return 0;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Huang Ying | 12 | 100.00% | 1 | 100.00% |
Total | 12 | 100.00% | 1 | 100.00% |
static inline int apei_clear_mce(u64 record_id)
{
return -EINVAL;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Huang Ying | 14 | 100.00% | 1 | 100.00% |
Total | 14 | 100.00% | 1 | 100.00% |
#endif
void mce_inject_log(struct mce *m);
/*
* We consider records to be equivalent if bank+status+addr+misc all match.
* This is only used when the system is going down because of a fatal error
* to avoid cluttering the console log with essentially repeated information.
* In normal processing all errors seen are logged.
*/
static inline bool mce_cmp(struct mce *m1, struct mce *m2)
{
return m1->bank != m2->bank ||
m1->status != m2->status ||
m1->addr != m2->addr ||
m1->misc != m2->misc;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Tony Luck | 50 | 100.00% | 1 | 100.00% |
Total | 50 | 100.00% | 1 | 100.00% |
extern struct device_attribute dev_attr_trigger;
#ifdef CONFIG_X86_MCELOG_LEGACY
void mce_work_trigger(void);
void mce_register_injector_chain(struct notifier_block *nb);
void mce_unregister_injector_chain(struct notifier_block *nb);
#else
static inline void mce_work_trigger(void) { }
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Tony Luck | 8 | 100.00% | 1 | 100.00% |
Total | 8 | 100.00% | 1 | 100.00% |
static inline void mce_register_injector_chain(struct notifier_block *nb) { }
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Borislav Petkov | 11 | 100.00% | 1 | 100.00% |
Total | 11 | 100.00% | 1 | 100.00% |
static inline void mce_unregister_injector_chain(struct notifier_block *nb) { }
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Borislav Petkov | 11 | 100.00% | 1 | 100.00% |
Total | 11 | 100.00% | 1 | 100.00% |
#endif
extern struct mca_config mca_cfg;
#endif /* __X86_MCE_INTERNAL_H__ */
Overall Contributors
Person | Tokens | Prop | Commits | CommitProp |
Huang Ying | 111 | 22.75% | 2 | 10.00% |
Chen Gong | 98 | 20.08% | 2 | 10.00% |
Tony Luck | 85 | 17.42% | 2 | 10.00% |
Borislav Petkov | 81 | 16.60% | 5 | 25.00% |
Andi Kleen | 75 | 15.37% | 3 | 15.00% |
Naveen N. Rao | 20 | 4.10% | 1 | 5.00% |
Chen Yucong | 9 | 1.84% | 1 | 5.00% |
Aravind Gopalakrishnan | 4 | 0.82% | 1 | 5.00% |
Kay Sievers | 3 | 0.61% | 1 | 5.00% |
Greg Kroah-Hartman | 1 | 0.20% | 1 | 5.00% |
Vishal Verma | 1 | 0.20% | 1 | 5.00% |
Total | 488 | 100.00% | 20 | 100.00% |
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.