lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170825101615.045fd1c0@gandalf.local.home>
Date:   Fri, 25 Aug 2017 10:16:15 -0400
From:   Steven Rostedt <rostedt@...dmis.org>
To:     Thomas Gleixner <tglx@...utronix.de>
Cc:     Boris Ostrovsky <boris.ostrovsky@...cle.com>,
        LKML <linux-kernel@...r.kernel.org>,
        Ingo Molnar <mingo@...nel.org>, Peter Anvin <hpa@...or.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Andy Lutomirski <luto@...nel.org>,
        Borislav Petkov <bp@...en8.de>, Juergen Gross <jgross@...e.com>
Subject: Re: [patch 20/41] x86: Replace access to desc_struct:a/b fields

On Fri, 25 Aug 2017 16:02:02 +0200 (CEST)
Thomas Gleixner <tglx@...utronix.de> wrote:

> On Fri, 25 Aug 2017, Boris Ostrovsky wrote:
> 
> >   
> > >  
> > > 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() ?  
> 
> Bah yes.

This is why I'm one of those that like to add the "== 0" to it. Because
I always get this wrong :-p

-- Steve

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ