From: Haozhong Zhang Subject: Re: [PATCH 3/4] x86/mce: Translate passed-in GPA to host machine address Date: Wed, 16 Sep 2015 08:38:01 +0800 Message-ID: <20150916003801.GD26047@hzzhang-OptiPlex-9020.sh.intel.com> References: <1442305780-12790-1-git-send-email-haozhong.zhang@intel.com> <1442305780-12790-4-git-send-email-haozhong.zhang@intel.com> <55F8383202000078000A2EE1@prv-mh.provo.novell.com> <20150915134242.GA2747@hzzhang-OptiPlex-9020.sh.intel.com> <55F82223.8010305@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <55F82223.8010305@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Andrew Cooper Cc: Wei Liu , Ian Campbell , Stefano Stabellini , Liu Jinsong , Christoph Egger , Ian Jackson , xen-devel@lists.xen.org, Jan Beulich , Keir Fraser List-Id: xen-devel@lists.xenproject.org On Tue, Sep 15, 2015 at 02:50:27PM +0100, Andrew Cooper wrote: > On 15/09/15 14:42, Haozhong Zhang wrote: > > > >>> + mfn = mfn_x(get_gfn(d, gpfn, &t)); > >>> + > >>> + if (mfn == INVALID_MFN) { > >>> + put_domain(d); > >>> + return x86_mcerr("do_mca inject: illegal MSR value", > >>> + -EINVAL); > >> This message should be better distinguishable from the one further > >> down (or else it's pretty pointless) - perhaps you mean GPFN instead > >> of MSR? > >> > > Yes, I'll change it to "do_mca_inject: illegal GPFN". > > Please always always always write useful error messages. "illegal GPFN" > is useless without also stating which value is believed to be invalid. > > Furthermore, per the clarification in c/s e758ed1, "gfn" is the correct > term to use here. > I'll update error messages in this patch to include more detailed information. > ~Andrew > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xen.org > http://lists.xen.org/xen-devel