From: Christoph Egger <Christoph.Egger@amd.com>
To: "Ke, Liping" <liping.ke@intel.com>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
Keir Fraser <keir.fraser@eu.citrix.com>,
"Jiang, Yunhong" <yunhong.jiang@intel.com>
Subject: Re: [patch 4/4]Enable CMCI (Corrected Machine Check Error Interrupt) for Intel CPUs
Date: Tue, 13 Jan 2009 12:21:22 +0100 [thread overview]
Message-ID: <200901131221.23669.Christoph.Egger@amd.com> (raw)
In-Reply-To: <E2263E4A5B2284449EEBD0AAB751098401C4F02B3C@PDSMSX501.ccr.corp.intel.com>
On Tuesday 13 January 2009 03:12:51 Ke, Liping wrote:
> Hi, Christoph
> Please see our comments below
>
> Christoph Egger wrote:
> > On Friday 19 December 2008 07:19:16 Ke, Liping wrote:
> >> Hi, all
> >>
> >> Patch 4 is the main patch for CMCI enabling in XEN. It adds the CMCI
> >> interrupt handler, new common CMCI/MCA init process,CMCI owner judge
> >> algorithm when bring_up CPUs, CPU on/offline and polling
> >> mechanisms, etc
> >>
> >> Thanks & Regards,
> >> Criping
> >
> > This patch changes the public API. There's no need to change
> > struct mcinfo_extended. The marshalling technique allows to use
> > this structure as often as needed. Please undo this change.
>
> Since Intel extended msrs' number is bigger than AMD, and we can't use
> pointer and allocate memory in mca handler, so we extended it from 5 -> 10.
> We think it should not impact any of your usage.
>
> Else, we can change boundary 5->0, use a globally allocated pointer
> instead. But it seems not that necessary. How do you think about?
When I defined the API, I already knew that 5 is not enough for Intel.
So I made struct mc_info large enough to keep multiple entities in any
combination. I expected from you to fill struct mcinfo_extended two or
three times into struct mc_info the same way as you do with
struct mcinfo_bank. There's no (additional) allocation needed.
From your description I just read, that you don't know this marshalling
technique.
> > struct mcinfo_global is also changed. Why can't mc_coreid not be
> > filled with the apicid ? Adding the apicid field breaks the alignment
> > causing troubles on 32bit-guest-on-64bit-hypervisor.
>
> We plan to extend the apic_id to 32 bit since 8 bit is not enough for new
> apic_id. Besides, for this problem, before sending the patch, we actually
> talked about it. Seems original structure is not 32/64 alligned. How about
> below changes?
>
> struct mcinfo_global {
> struct mcinfo_common common; 4 byte
>
> /* running domain at the time in error (most likely the impacted one)
> */ uint16_t mc_domid; 2 byte
> uint32_t mc_socketid; /* physical socket of the physical core */ 4 byte
> uint16_t mc_coreid; /* physical impacted core */ 2 byte
> uint8_t mc_apicid; ---change it to 4 byte
> uint16_t mc_core_threadid; /* core thread of physical core */ 2 byte
> uint16_t mc_vcpuid; /* virtual cpu scheduled for mc_domid */ 2 byte
> uint64_t mc_gstatus; /* global status */ 8 byte
> uint32_t mc_flags; 4 byte
> };
>
>
> Change to
> ------------------------>>>>>
>
> struct mcinfo_global {
> struct mcinfo_common common; 4 byte
>
> /* running domain at the time in error (most likely the impacted one)
> */ uint32_t mc_socketid; /* physical socket of the physical core */ 4 byte
> -----------------------------------------------------------------
> uint16_t mc_domid; 2 byte
> uint16_t mc_coreid; /* physical impacted core */ 2 byte
> uint32_t mc_apicid; ---change it to 4 byte
> -------------------------------------------------------------------
> uint16_t mc_core_threadid; /* core thread of physical core */ 2 byte
> uint16_t mc_vcpuid; /* virtual cpu scheduled for mc_domid */ 2 byte
> uint32_t mc_flags; 4 byte
> --------------------------------------------------------------------------
> uint64_t mc_gstatus; /* global status */ 8 byte
> };
Your proposed change fixes the alignment problem, but it doesn't answer my
question: Why is mc_apicid needed at all since the CPU core is already
identified by mc_coreid ?
Christoph
--
Advanced Micro Devices GmbH
Karl-Hammerschmidt-Str. 34
85609 Dornach b. München
Geschäftsführer: Jochen Polster, Thomas M. McCoy, Giuliano Meroni
Sitz: Dornach, Gemeinde Aschheim, Landkreis München
Registergericht München, HRB Nr. 43632
next prev parent reply other threads:[~2009-01-13 11:21 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-19 6:19 [patch 4/4]Enable CMCI (Corrected Machine Check Error Interrupt) for Intel CPUs Ke, Liping
2009-01-12 14:03 ` Christoph Egger
2009-01-13 2:12 ` Ke, Liping
2009-01-13 11:21 ` Christoph Egger [this message]
2009-01-13 16:48 ` Frank Van Der Linden
2009-01-13 17:11 ` Christoph Egger
2009-01-13 17:29 ` Frank van der Linden
2009-01-14 2:11 ` Jiang, Yunhong
2009-01-14 1:35 ` Ke, Liping
2009-01-14 2:58 ` Jiang, Yunhong
2009-01-14 4:13 ` Frank van der Linden
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200901131221.23669.Christoph.Egger@amd.com \
--to=christoph.egger@amd.com \
--cc=keir.fraser@eu.citrix.com \
--cc=liping.ke@intel.com \
--cc=xen-devel@lists.xensource.com \
--cc=yunhong.jiang@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.