Received: by 10.192.165.148 with SMTP id m20csp4862986imm; Tue, 24 Apr 2018 09:33:33 -0700 (PDT) X-Google-Smtp-Source: AIpwx494NDR/kZ7LzJisW20t6OGQuwFx3/gDp1S5d7TfmLGxSV2D9BOSeJrhzgEB+Z0paRb7ZV0E X-Received: by 2002:a17:902:be06:: with SMTP id r6-v6mr19832123pls.158.1524587613890; Tue, 24 Apr 2018 09:33:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524587613; cv=none; d=google.com; s=arc-20160816; b=PzznxBIL0vZfHqJJI1+wWzqNeKdfR2xGqclcxAfwxAA8Hm5pT/um/0AcikGtDsvJQR milOt0yLndDSTuNpiqEVRx5/lgWWP4NQ8CRsB7MLDy/Bonzb15rMPg4w5ZbyNoLgcSsC J0YLOke624pFF3n0QUy3Oo1LikkvXkOhKcfoss4T4e/ZbTWmDggADl11bCGqbuvV2Era 0kraMZi/pU2TiBU3YvOBZm19rmPVvh3r3ofdMvgSvHDPWccincQT8UfxITvGc/gJ7I9/ aqr+Hg/HK6XUcjIw7SgrksGbal79ovs0GEJpUOWZ6F/xf+L4mKmT9nGp1B/ZY3+fxk6C J27g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:cc:to:subject:from:references :in-reply-to:message-id:arc-authentication-results; bh=SQEgWaA/Nlx33BTbjTYk8Im/Vv2I6fXq88OxS6vFVHk=; b=LkOPY1kMqixwOTQ+nD2yhjWrFceYE5UwYbc/raqPBJhZYwrpdhZgAmm12lP52gXsmg 6jfMlgOleXDmBrVxrMxktndUGRn8l7GCaGKriitUdkWaHRZpQY24aUnbmqvBuumzAcxd 1mgOfDLuSdtFxRkaFR5Djqb3T3ItAKOhM+q++2xWxRlCzXzaBu39Cj/O8Vw6gK9iUfZv E0l+YlWUv4QfTdgVlpWY9CQFEP/DvdSEY/g7nMXJc/r+YAeNR6TRz09/r1+SV7ViEGR8 Av92nthaparwJrwMNILC7sccPjCCqdvEnfLgAmoI7J6qXMtnks+wF+J3cjih+bc5eSpn GHJA== ARC-Authentication-Results: i=1; mx.google.com; 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 i7-v6si13683205plt.95.2018.04.24.09.33.18; Tue, 24 Apr 2018 09:33:33 -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; 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 S1752583AbeDXQbq (ORCPT + 99 others); Tue, 24 Apr 2018 12:31:46 -0400 Received: from pegase1.c-s.fr ([93.17.236.30]:19330 "EHLO pegase1.c-s.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750908AbeDXQbc (ORCPT ); Tue, 24 Apr 2018 12:31:32 -0400 Received: from localhost (mailhub1-int [192.168.12.234]) by localhost (Postfix) with ESMTP id 40VpkB3GkBz9ttkg; Tue, 24 Apr 2018 18:31:30 +0200 (CEST) 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 5un9Wo1zu7kt; Tue, 24 Apr 2018 18:31:30 +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 40VpkB2ld2z9ttkc; Tue, 24 Apr 2018 18:31:30 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 6E8F28B911; Tue, 24 Apr 2018 18:31:31 +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 7nlOQRzelq4F; Tue, 24 Apr 2018 18:31:31 +0200 (CEST) Received: from po15720vm.idsi0.si.c-s.fr (po15451.idsi0.si.c-s.fr [172.25.231.2]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 657D08B902; Tue, 24 Apr 2018 18:31:30 +0200 (CEST) Received: by po15720vm.idsi0.si.c-s.fr (Postfix, from userid 0) id 5EC5E6C624; Tue, 24 Apr 2018 18:31:30 +0200 (CEST) Message-Id: <49a0a97eb70906937cc8b6a02699aa036a187a60.1524587425.git.christophe.leroy@c-s.fr> In-Reply-To: <02633d43f29e1ba01865cd334216dc8efb8b4b11.1524587425.git.christophe.leroy@c-s.fr> References: <02633d43f29e1ba01865cd334216dc8efb8b4b11.1524587425.git.christophe.leroy@c-s.fr> From: Christophe Leroy Subject: [PATCH 2/3] powerpc/nohash: remove _PAGE_BUSY To: Benjamin Herrenschmidt , Paul Mackerras , Michael Ellerman Cc: linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org Date: Tue, 24 Apr 2018 18:31:30 +0200 (CEST) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org _PAGE_BUSY is always 0, remove it Signed-off-by: Christophe Leroy --- arch/powerpc/include/asm/nohash/64/pgtable.h | 10 +++------- arch/powerpc/include/asm/nohash/pte-book3e.h | 5 ----- 2 files changed, 3 insertions(+), 12 deletions(-) diff --git a/arch/powerpc/include/asm/nohash/64/pgtable.h b/arch/powerpc/include/asm/nohash/64/pgtable.h index 251d74c9013e..e8de7cb4d3fb 100644 --- a/arch/powerpc/include/asm/nohash/64/pgtable.h +++ b/arch/powerpc/include/asm/nohash/64/pgtable.h @@ -186,14 +186,12 @@ static inline unsigned long pte_update(struct mm_struct *mm, __asm__ __volatile__( "1: ldarx %0,0,%3 # pte_update\n\ - andi. %1,%0,%6\n\ - bne- 1b \n\ andc %1,%0,%4 \n\ - or %1,%1,%7\n\ + or %1,%1,%6\n\ stdcx. %1,0,%3 \n\ bne- 1b" : "=&r" (old), "=&r" (tmp), "=m" (*ptep) - : "r" (ptep), "r" (clr), "m" (*ptep), "i" (_PAGE_BUSY), "r" (set) + : "r" (ptep), "r" (clr), "m" (*ptep), "r" (set) : "cc" ); #else unsigned long old = pte_val(*ptep); @@ -290,13 +288,11 @@ static inline void __ptep_set_access_flags(struct mm_struct *mm, __asm__ __volatile__( "1: ldarx %0,0,%4\n\ - andi. %1,%0,%6\n\ - bne- 1b \n\ or %0,%3,%0\n\ stdcx. %0,0,%4\n\ bne- 1b" :"=&r" (old), "=&r" (tmp), "=m" (*ptep) - :"r" (bits), "r" (ptep), "m" (*ptep), "i" (_PAGE_BUSY) + :"r" (bits), "r" (ptep), "m" (*ptep) :"cc"); #else unsigned long old = pte_val(*ptep); diff --git a/arch/powerpc/include/asm/nohash/pte-book3e.h b/arch/powerpc/include/asm/nohash/pte-book3e.h index 9ff51b4c0cac..12730b81cd98 100644 --- a/arch/powerpc/include/asm/nohash/pte-book3e.h +++ b/arch/powerpc/include/asm/nohash/pte-book3e.h @@ -57,13 +57,8 @@ #define _PAGE_USER (_PAGE_BAP_UR | _PAGE_BAP_SR) /* Can be read */ #define _PAGE_PRIVILEGED (_PAGE_BAP_SR) -#define _PAGE_BUSY 0 - #define _PAGE_SPECIAL _PAGE_SW0 -/* Flags to be preserved on PTE modifications */ -#define _PAGE_HPTEFLAGS _PAGE_BUSY - /* Base page size */ #ifdef CONFIG_PPC_64K_PAGES #define _PAGE_PSIZE _PAGE_PSIZE_64K -- 2.13.3