Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp3017864ybi; Mon, 17 Jun 2019 14:48:04 -0700 (PDT) X-Google-Smtp-Source: APXvYqzCESUhzX7oKkTTFYLDImYss35xDhibFQJFZSaCaHE/HwCnCUKYDUl/prv1nWGw1cQhTd2g X-Received: by 2002:a17:902:205:: with SMTP id 5mr102961089plc.165.1560808084021; Mon, 17 Jun 2019 14:48:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560808084; cv=none; d=google.com; s=arc-20160816; b=Mzdhyh1Y5pArELJH/lVjuno2Er1ay/ct3S2IPGNGHHO5hQ5DybWDVW+2QsQFhDn2ni qVzeNLD6TdET9bSzGgEL9M/cvEMVyAfuZMUtIqkTLy9N3IDHYctlwKpCAuP3cEV5Z7PI FZzfGo/QD+G4fYHhKxPgDZ3tVXJxUenhwIFyF4ViiMzWdIgUzdCf27t2SyRufiTzFVbt EyMRTSXNkh9AALvxVweUVVA5165BdE78Q0ToJNA9HChIzEhHP2ivw/+MulGa3GxFVIVK qIZemtyJqnsOdxYNYj4E6rCQIWxGLA8HQEgtqRwysfvWyX6VcP/nyWJ555Lu4tJjJnac ToFw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=ZZO4LfmpEKhCUXBijrOkaQcSAOYgGw2UTduyEJKqtUM=; b=C2mU5WuIJBLYWL8iIPxVD7jjzftR77b1scPvazOiwX+bwYYRKsN/vYr3kbDm3Eh0st wLAvHHho9aIrATvqyMythDCU+F9KPQDolRDawXkGA9ME/GiOHU6EeNkJDTE/vye4gvgA /5HOL8n1gvtaHsGNVv+yW+1W4jp2VoDMMdoNt5N4TmRBkRUgLVtcFXjOK/iMPPOVXnxs M09OS1Wx9bHAmTzamjia6EpJaAptf1RZHJnrITh0/pfBpTjfQYlzjLub87AKzmawDPXq x5OS9fnzJWUbhX8SpAO99w16GC+SnWzpS2tp+WWZR3RwOWfYtFRKlTxMy3LmB3+EVy2c W4/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@c-s.fr header.s=mail header.b=rFQ6wPYm; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c21si1966911pls.414.2019.06.17.14.47.48; Mon, 17 Jun 2019 14:48:04 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@c-s.fr header.s=mail header.b=rFQ6wPYm; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727850AbfFQVri (ORCPT + 99 others); Mon, 17 Jun 2019 17:47:38 -0400 Received: from pegase1.c-s.fr ([93.17.236.30]:65095 "EHLO pegase1.c-s.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726001AbfFQVri (ORCPT ); Mon, 17 Jun 2019 17:47:38 -0400 Received: from localhost (mailhub1-int [192.168.12.234]) by localhost (Postfix) with ESMTP id 45SPvX6TlFz9v2j5; Mon, 17 Jun 2019 23:47:36 +0200 (CEST) Authentication-Results: localhost; dkim=pass reason="1024-bit key; insecure key" header.d=c-s.fr header.i=@c-s.fr header.b=rFQ6wPYm; dkim-adsp=pass; dkim-atps=neutral X-Virus-Scanned: Debian amavisd-new at c-s.fr Received: from pegase1.c-s.fr ([192.168.12.234]) by localhost (pegase1.c-s.fr [192.168.12.234]) (amavisd-new, port 10024) with ESMTP id kfOc68UfSeIR; Mon, 17 Jun 2019 23:47:36 +0200 (CEST) Received: from messagerie.si.c-s.fr (messagerie.si.c-s.fr [192.168.25.192]) by pegase1.c-s.fr (Postfix) with ESMTP id 45SPvX5J6hz9v2j4; Mon, 17 Jun 2019 23:47:36 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=c-s.fr; s=mail; t=1560808056; bh=ZZO4LfmpEKhCUXBijrOkaQcSAOYgGw2UTduyEJKqtUM=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=rFQ6wPYmQaExzXDJpuiuwF99J40FOd3hnE2uSehyW28k5885nTWUowJdEwZb/P5d4 pbBu5Tjp/FYB046ADolt7U/U7qWYQYalbvkkoGof6+o3NdbtRi3HPYmJrOZ8UtiWPx 95HrQPIJjHuHmOlx0hiK/+SInH+u1YZMgtadrHos= Received: from localhost (localhost [127.0.0.1]) by messagerie.si.c-s.fr (Postfix) with ESMTP id EF6648B84D; Mon, 17 Jun 2019 23:47:36 +0200 (CEST) X-Virus-Scanned: amavisd-new at c-s.fr Received: from messagerie.si.c-s.fr ([127.0.0.1]) by localhost (messagerie.si.c-s.fr [127.0.0.1]) (amavisd-new, port 10023) with ESMTP id OwA-rgv9DTHK; Mon, 17 Jun 2019 23:47:36 +0200 (CEST) Received: from PO15451 (unknown [192.168.4.90]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 50FEF8B7FF; Mon, 17 Jun 2019 23:47:36 +0200 (CEST) Subject: Re: [PATCH] powerpc/mm/32s: fix condition that is always true To: Andreas Schwab Cc: Benjamin Herrenschmidt , Paul Mackerras , Michael Ellerman , j.neuschaefer@gmx.net, linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org References: <1e412310cc18ea654fb2ce4c935654d8d1069f27.1550775950.git.christophe.leroy@c-s.fr> <87muif52lv.fsf_-_@igel.home> From: Christophe Leroy Message-ID: <58297c81-430b-d615-fa11-55136ae924f5@c-s.fr> Date: Mon, 17 Jun 2019 23:47:35 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.1 MIME-Version: 1.0 In-Reply-To: <87muif52lv.fsf_-_@igel.home> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: fr Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Le 17/06/2019 à 23:22, Andreas Schwab a écrit : > Move a misplaced paren that makes the condition always true. > > Fixes: 63b2bc619565 ("powerpc/mm/32s: Use BATs for STRICT_KERNEL_RWX") > Signed-off-by: Andreas Schwab Reviewed-by: Christophe Leroy > --- > arch/powerpc/mm/pgtable_32.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arch/powerpc/mm/pgtable_32.c b/arch/powerpc/mm/pgtable_32.c > index d53188dee18f..35cb96cfc258 100644 > --- a/arch/powerpc/mm/pgtable_32.c > +++ b/arch/powerpc/mm/pgtable_32.c > @@ -360,7 +360,7 @@ void mark_initmem_nx(void) > unsigned long numpages = PFN_UP((unsigned long)_einittext) - > PFN_DOWN((unsigned long)_sinittext); > > - if (v_block_mapped((unsigned long)_stext) + 1) > + if (v_block_mapped((unsigned long)_stext + 1)) > mmu_mark_initmem_nx(); > else > change_page_attr(page, numpages, PAGE_KERNEL); >