Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758400Ab1FKAOK (ORCPT ); Fri, 10 Jun 2011 20:14:10 -0400 Received: from mga09.intel.com ([134.134.136.24]:54406 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758302Ab1FKAOH convert rfc822-to-8bit (ORCPT ); Fri, 10 Jun 2011 20:14:07 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.65,350,1304319600"; d="scan'208";a="12217581" From: Andi Kleen To: Tony Luck Cc: Hidetoshi Seto , Ingo Molnar , Borislav Petkov , linux-kernel@vger.kernel.org, "Huang\, Ying" , Avi Kivity Subject: Re: [PATCH 05/10] MCE: Mask out address mask bits below address granuality References: <4df13c362729376e2@agluck-desktop.sc.intel.com> <4DF1D0B1.1020302@jp.fujitsu.com> Date: Fri, 10 Jun 2011 17:12:55 -0700 In-Reply-To: (Tony Luck's message of "Fri, 10 Jun 2011 12:06:45 -0700") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1387 Lines: 33 Tony Luck writes: > 2011/6/10 Hidetoshi Seto : >> Why do you have to mask it out in kernel, why not in user/logger? >> >> One possible story is: >>  "... the brand-new Xeon XXXX has new MCx_***_VALID bit in **** >>  register, if it is set the lower bits of MCx_ADDR indicates >>  ****, otherwise the bits are undefined ..." >> >> So I think that kernel should convey the raw value from hardware to >> userland.  Even if it contains some noise on it, user can determine >> whether it is useful or not.  And more, since this is an error record, >> there will be no second chance to retrieve the data afterward. > > This is a good point - we should log the original untouched bits someplace. These bits are undefined. It doesn't make sense to log undefined bits. They can contain random values. Showing random values just confuses people. How would the user even know it's undefined? They normally don't read the specs. Really programs have to handle that for the user. And there the only sane way is to just mask them off. -Andi -- ak@linux.intel.com -- Speaking for myself only -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/