Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933002AbdHYN5X (ORCPT ); Fri, 25 Aug 2017 09:57:23 -0400 Received: from userp1040.oracle.com ([156.151.31.81]:27662 "EHLO userp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932988AbdHYN5V (ORCPT ); Fri, 25 Aug 2017 09:57:21 -0400 Subject: Re: [patch 20/41] x86: Replace access to desc_struct:a/b fields To: Thomas Gleixner , LKML References: <20170825103103.287814238@linutronix.de> <20170825104414.553007376@linutronix.de> Cc: Ingo Molnar , Peter Anvin , Peter Zijlstra , Andy Lutomirski , Borislav Petkov , Steven Rostedt , Juergen Gross From: Boris Ostrovsky Message-ID: Date: Fri, 25 Aug 2017 09:56:18 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <20170825104414.553007376@linutronix.de> Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: 7bit X-Source-IP: aserv0021.oracle.com [141.146.126.233] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 488 Lines: 17 > > Index: b/arch/x86/xen/enlighten_pv.c > =================================================================== > --- a/arch/x86/xen/enlighten_pv.c > +++ b/arch/x86/xen/enlighten_pv.c > @@ -494,7 +494,7 @@ static void __init xen_load_gdt_boot(con > static inline bool desc_equal(const struct desc_struct *d1, > const struct desc_struct *d2) > { > - return d1->a == d2->a && d1->b == d2->b; > + return memcmp(d1, d2, sizeof(*d1)); > } Shouldn't this be !memcmp() ? -boris