Skip to content

Commit

Permalink
x86/RAS: Rename smca_bank_names to smca_names
Browse files Browse the repository at this point in the history
Make it differ more from struct smca_bank_name for better readability.

Signed-off-by: Borislav Petkov <bp@suse.de>
Tested-by: Yazen Ghannam <yazen.ghannam@amd.com>
Link: http://lkml.kernel.org/r/20161103125556.15482-3-bp@alien8.de
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
  • Loading branch information
Borislav Petkov authored and Thomas Gleixner committed Nov 8, 2016
1 parent 1ce9cd7 commit a9a1c0e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion arch/x86/include/asm/mce.h
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ struct smca_bank_name {
const char *long_name; /* Long name for pretty-printing */
};

extern struct smca_bank_name smca_bank_names[N_SMCA_BANK_TYPES];
extern struct smca_bank_name smca_names[N_SMCA_BANK_TYPES];

#define HWID_MCATYPE(hwid, mcatype) ((hwid << 16) | mcatype)

Expand Down
6 changes: 3 additions & 3 deletions arch/x86/kernel/cpu/mcheck/mce_amd.c
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ static const char * const smca_umc_block_names[] = {
"misc_umc"
};

struct smca_bank_name smca_bank_names[] = {
struct smca_bank_name smca_names[] = {
[SMCA_LS] = { "load_store", "Load Store Unit" },
[SMCA_IF] = { "insn_fetch", "Instruction Fetch Unit" },
[SMCA_L2_CACHE] = { "l2_cache", "L2 Cache" },
Expand All @@ -84,7 +84,7 @@ struct smca_bank_name smca_bank_names[] = {
[SMCA_PSP] = { "psp", "Platform Security Processor" },
[SMCA_SMU] = { "smu", "System Management Unit" },
};
EXPORT_SYMBOL_GPL(smca_bank_names);
EXPORT_SYMBOL_GPL(smca_names);

static struct smca_hwid smca_hwid_mcatypes[] = {
/* { bank_type, hwid_mcatype, xec_bitmap } */
Expand Down Expand Up @@ -832,7 +832,7 @@ static const char *get_name(unsigned int bank, struct threshold_block *b)
}

snprintf(buf_mcatype, MAX_MCATYPE_NAME_LEN,
"%s_%x", smca_bank_names[bank_type].name,
"%s_%x", smca_names[bank_type].name,
smca_banks[bank].id);
return buf_mcatype;
}
Expand Down
2 changes: 1 addition & 1 deletion drivers/edac/mce_amd.c
Original file line number Diff line number Diff line change
Expand Up @@ -867,7 +867,7 @@ static void decode_smca_errors(struct mce *m)
return;

bank_type = hwid->bank_type;
ip_name = smca_bank_names[bank_type].long_name;
ip_name = smca_names[bank_type].long_name;

pr_emerg(HW_ERR "%s Extended Error Code: %d\n", ip_name, xec);

Expand Down

0 comments on commit a9a1c0e

Please sign in to comment.