From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julien Grall Subject: Re: [PATCH 2/2 v2] xen: arm: Set all bits in mfn_to_xen_entry() Date: Fri, 21 Aug 2015 16:45:33 -0700 Message-ID: <55D7B81D.5080502@citrix.com> References: <1440113595-6961-1-git-send-email-chris.brand@broadcom.com> <1440113595-6961-3-git-send-email-chris.brand@broadcom.com> <55D729F8.30803@citrix.com> <4EE5B48738DDED408878C97C8E050A8B1D7F40D2@SJEXCHMB05.corp.ad.broadcom.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <4EE5B48738DDED408878C97C8E050A8B1D7F40D2@SJEXCHMB05.corp.ad.broadcom.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: "Chris (Christopher) Brand" , Andrew Cooper , "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org On 21/08/2015 12:47, Chris (Christopher) Brand wrote: > Hi Andrew, > >> On 21/08/15 00:33, Chris Brand wrote: >>> Ensure that every bit has a specific value. >>> >>> Reported-by: Julien Grall >>> Signed-off-by: Chris Brand >>> --- >>> v2 adds comments on pxn and avail. >> >> This is no functional change, if the compiler is conforming to the C spec. >> >> The spec guarantees that structure initialisation like this causes unspecified >> names to gain their default value. As these are integer bitfields, the default >> value is 0. >> >> What compiler is in use? It would appear that it is buggy, or at least has >> buggy scalar replacement optimisations. > > That's right. I'd forgotten about that. This was actually suggested by Julien in > a review of another patch I sent. I haven't seen any problems this fixes. I still think those patches are valid in order to know which value are set by default and what does it mean. Regards, -- Julien Grall