From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751811AbdJSCo3 (ORCPT ); Wed, 18 Oct 2017 22:44:29 -0400 Received: from mail-pf0-f194.google.com ([209.85.192.194]:50449 "EHLO mail-pf0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751592AbdJSCnb (ORCPT ); Wed, 18 Oct 2017 22:43:31 -0400 X-Google-Smtp-Source: ABhQp+QbE/SZmRVozdyktlAivr6lFnJVq2OulDGr3cMaeHfDv+iE/39WSoaOhUYhDmv81Ieden6j4w== Date: Thu, 19 Oct 2017 13:43:19 +1100 From: Balbir Singh To: jglisse@redhat.com Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrea Arcangeli , Andrew Morton , Joerg Roedel , Suravee Suthikulpanit , David Woodhouse , Alistair Popple , Michael Ellerman , Benjamin Herrenschmidt , Stephen Rothwell , Andrew Donnellan , iommu@lists.linux-foundation.org, linuxppc-dev@lists.ozlabs.org Subject: Re: [PATCH 0/2] Optimize mmu_notifier->invalidate_range callback Message-ID: <20171019134319.1b856091@MiWiFi-R3-srv> In-Reply-To: <20171017031003.7481-1-jglisse@redhat.com> References: <20171017031003.7481-1-jglisse@redhat.com> X-Mailer: Claws Mail 3.15.1-dirty (GTK+ 2.24.31; x86_64-redhat-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by nfs id v9J2iYFK005448 On Mon, 16 Oct 2017 23:10:01 -0400 jglisse@redhat.com wrote: > From: Jérôme Glisse > > (Andrew you already have v1 in your queue of patch 1, patch 2 is new, > i think you can drop it patch 1 v1 for v2, v2 is bit more conservative > and i fixed typos) > > All this only affect user of invalidate_range callback (at this time > CAPI arch/powerpc/platforms/powernv/npu-dma.c, IOMMU ATS/PASID in > drivers/iommu/amd_iommu_v2.c|intel-svm.c) > > This patchset remove useless double call to mmu_notifier->invalidate_range > callback wherever it is safe to do so. The first patch just remove useless > call As in an extra call? Where does that come from? > and add documentation explaining why it is safe to do so. The second > patch go further by introducing mmu_notifier_invalidate_range_only_end() > which skip callback to invalidate_range this can be done when clearing a > pte, pmd or pud with notification which call invalidate_range right after > clearing under the page table lock. > Balbir Singh. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pg0-f70.google.com (mail-pg0-f70.google.com [74.125.83.70]) by kanga.kvack.org (Postfix) with ESMTP id D9B636B0033 for ; Wed, 18 Oct 2017 22:43:32 -0400 (EDT) Received: by mail-pg0-f70.google.com with SMTP id y7so5521489pgb.16 for ; Wed, 18 Oct 2017 19:43:32 -0700 (PDT) Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id b13sor2518384pgu.71.2017.10.18.19.43.31 for (Google Transport Security); Wed, 18 Oct 2017 19:43:31 -0700 (PDT) Date: Thu, 19 Oct 2017 13:43:19 +1100 From: Balbir Singh Subject: Re: [PATCH 0/2] Optimize mmu_notifier->invalidate_range callback Message-ID: <20171019134319.1b856091@MiWiFi-R3-srv> In-Reply-To: <20171017031003.7481-1-jglisse@redhat.com> References: <20171017031003.7481-1-jglisse@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Sender: owner-linux-mm@kvack.org List-ID: To: jglisse@redhat.com Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrea Arcangeli , Andrew Morton , Joerg Roedel , Suravee Suthikulpanit , David Woodhouse , Alistair Popple , Michael Ellerman , Benjamin Herrenschmidt , Stephen Rothwell , Andrew Donnellan , iommu@lists.linux-foundation.org, linuxppc-dev@lists.ozlabs.org On Mon, 16 Oct 2017 23:10:01 -0400 jglisse@redhat.com wrote: > From: J=C3=A9r=C3=B4me Glisse >=20 > (Andrew you already have v1 in your queue of patch 1, patch 2 is new, > i think you can drop it patch 1 v1 for v2, v2 is bit more conservative > and i fixed typos) >=20 > All this only affect user of invalidate_range callback (at this time > CAPI arch/powerpc/platforms/powernv/npu-dma.c, IOMMU ATS/PASID in > drivers/iommu/amd_iommu_v2.c|intel-svm.c) >=20 > This patchset remove useless double call to mmu_notifier->invalidate_range > callback wherever it is safe to do so. The first patch just remove useless > call As in an extra call? Where does that come from? > and add documentation explaining why it is safe to do so. The second > patch go further by introducing mmu_notifier_invalidate_range_only_end() > which skip callback to invalidate_range this can be done when clearing a > pte, pmd or pud with notification which call invalidate_range right after > clearing under the page table lock. > Balbir Singh. -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf0-x244.google.com (mail-pf0-x244.google.com [IPv6:2607:f8b0:400e:c00::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 3yHYC92gCZzDqBd for ; Thu, 19 Oct 2017 13:43:33 +1100 (AEDT) Received: by mail-pf0-x244.google.com with SMTP id t188so5414711pfd.10 for ; Wed, 18 Oct 2017 19:43:33 -0700 (PDT) Date: Thu, 19 Oct 2017 13:43:19 +1100 From: Balbir Singh To: jglisse@redhat.com Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrea Arcangeli , Andrew Morton , Joerg Roedel , Suravee Suthikulpanit , David Woodhouse , Alistair Popple , Michael Ellerman , Benjamin Herrenschmidt , Stephen Rothwell , Andrew Donnellan , iommu@lists.linux-foundation.org, linuxppc-dev@lists.ozlabs.org Subject: Re: [PATCH 0/2] Optimize mmu_notifier->invalidate_range callback Message-ID: <20171019134319.1b856091@MiWiFi-R3-srv> In-Reply-To: <20171017031003.7481-1-jglisse@redhat.com> References: <20171017031003.7481-1-jglisse@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , On Mon, 16 Oct 2017 23:10:01 -0400 jglisse@redhat.com wrote: > From: J=C3=A9r=C3=B4me Glisse >=20 > (Andrew you already have v1 in your queue of patch 1, patch 2 is new, > i think you can drop it patch 1 v1 for v2, v2 is bit more conservative > and i fixed typos) >=20 > All this only affect user of invalidate_range callback (at this time > CAPI arch/powerpc/platforms/powernv/npu-dma.c, IOMMU ATS/PASID in > drivers/iommu/amd_iommu_v2.c|intel-svm.c) >=20 > This patchset remove useless double call to mmu_notifier->invalidate_range > callback wherever it is safe to do so. The first patch just remove useless > call As in an extra call? Where does that come from? > and add documentation explaining why it is safe to do so. The second > patch go further by introducing mmu_notifier_invalidate_range_only_end() > which skip callback to invalidate_range this can be done when clearing a > pte, pmd or pud with notification which call invalidate_range right after > clearing under the page table lock. > Balbir Singh.