From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Jan Beulich" Subject: Re: [V10 PATCH 10/23] PVH xen: domain create, context switch related code changes Date: Thu, 08 Aug 2013 10:08:23 +0100 Message-ID: <52037C2702000078000EA312@nat28.tlf.novell.com> References: <1374631171-15224-1-git-send-email-mukesh.rathor@oracle.com> <1374631171-15224-11-git-send-email-mukesh.rathor@oracle.com> <20130807184006.14862c33@mantra.us.oracle.com> <520364F702000078000EA213@nat28.tlf.novell.com> <52035EBE.9010905@eu.citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <52035EBE.9010905@eu.citrix.com> Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: George Dunlap Cc: "keir.xen@gmail.com" , "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org >>> On 08.08.13 at 11:02, George Dunlap wrote: > Overall I think checking before calling would make the code easier to > understand. All the functions which call this have is_foo_domain() > sprinkled all over anyway, and so it's easier for someone reading the > code to understand immediately that HVM and PVH guests don't need their > gdt destroyed. But my main point was that if we check inside the > function, we should avoid checking outside the function for consistency. And I fully agree with that (here as well as in the various cases where such redundancy already exists in the code). Jan