From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753068AbbCLLDk (ORCPT ); Thu, 12 Mar 2015 07:03:40 -0400 Received: from mail-we0-f172.google.com ([74.125.82.172]:37109 "EHLO mail-we0-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750973AbbCLLDi (ORCPT ); Thu, 12 Mar 2015 07:03:38 -0400 Date: Thu, 12 Mar 2015 12:03:33 +0100 From: Ingo Molnar To: Toshi Kani Cc: akpm@linux-foundation.org, hpa@zytor.com, tglx@linutronix.de, mingo@redhat.com, arnd@arndb.de, linux-mm@kvack.org, x86@kernel.org, linux-kernel@vger.kernel.org, dave.hansen@intel.com, Elliott@hp.com, pebolle@tiscali.nl Subject: Re: [PATCH 3/3] mtrr, mm, x86: Enhance MTRR checks for KVA huge page mapping Message-ID: <20150312110333.GA6898@gmail.com> References: <1426018997-12936-1-git-send-email-toshi.kani@hp.com> <1426018997-12936-4-git-send-email-toshi.kani@hp.com> <20150311070216.GD29788@gmail.com> <1426092728.17007.380.camel@misato.fc.hp.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1426092728.17007.380.camel@misato.fc.hp.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Toshi Kani wrote: > > Did it perhaps want to be the other way around: > > > > if (mtrr_state.have_fixed && (start < 0x1000000)) { > > ... > > } else if (start < 0x100000) { > > ... > > > > or did it simply mess up the condition? > > I think it was just paranoid to test the same condition twice... Read the code again, it's _not_ the same condition ... Thanks, Ingo