Messages in this thread | | | Date | Wed, 29 Feb 2012 15:00:35 -0300 | From | Mauro Carvalho Chehab <> | Subject | Re: [PATCH 1/3] mce: Add a msg string to the MCE tracepoint |
| |
Em 29-02-2012 14:20, Luck, Tony escreveu: >> IMHO, before removing those fields, it would be better to first implement >> what is there at the mcelog userspace parser for the Intel machines into >> kernelspace (or to look into its source code), and check what registers >> aren't used by either AMD 64 MCE decoder or by the Intel MCE decoder. >> >> Tony, >> >> Is there anyone at Intel working on porting it to kernelspace? > > The mcelog code just looks at model specific fields in MCi_STATUS > and MCi_MISC. We could move it to the kernel - but I don't see > much value in doing so.
I see a few reasons:
- it would be consistent with what's being done at AMD. So, all x86 arch will report errors at the same way;
- userspace won't need to run an extra daemon/tool to decode the errors;
- fatal errors won't be lost (well, in fact, you have there already a parser for fatal errors. Not sure if all possible fatal errors are covered here, nor what else is needed, as you have already there part of mcelog decoder);
- a single place to maintain, when new cpu families are added;
- it makes easier to centralize the hardware error information, as there's no need to enrich the error on userspace.
> In this case all the information we need > is carried in status/misc - so as long as we keep all of those > bits (and the cpu family/model) we can safely decode/analyze later.
Hmm... the mcelog tool opens the /proc/cpuinfo:
$ grep cpuinfo * mcelog.c: f = fopen("/proc/cpuinfo","r"); mcelog.c: Eprintf("warning: Cannot parse /proc/cpuinfo\n"); mcelog.c: Eprintf("warning: Cannot open /proc/cpuinfo\n"); tsc.c: asprintf(&fn, "/sys/devices/system/cpu/cpu%d/cpufreq/cpuinfo_max_freq", cpu); tsc.c: /* /sys exists, but no cpufreq -- use value from cpuinfo */
That probably means that the needed cpu family/model info is not (or may not) be stored at the MCE structure.
> > -Tony
| |