Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp20214409rwd; Wed, 28 Jun 2023 22:19:25 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5mnoWHN/0ifcq2E2XAWxlOwWVVkSrdAonWTxPS2QucCIPfooI53cy1/NbqvOTkueN2jx9a X-Received: by 2002:a05:6808:158e:b0:3a3:6e8e:5168 with SMTP id t14-20020a056808158e00b003a36e8e5168mr3097079oiw.39.1688015965126; Wed, 28 Jun 2023 22:19:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688015965; cv=none; d=google.com; s=arc-20160816; b=ilyZ/8tHU0m4cAflUbG/vo8QIqY9ILGTD2PbssCQX4oFsJLEbFoxYsuKt9vem+GvUM 6bf7AYFki6spfr3cohGY3YtGcisq2J3w68ASeetHQjW9XtOe9PT/NFFdryRiB+UKwRuw C1ojTSQX5gnMQKsLUxPx20B+IiRqd/6yXiDzZNDkyXA6uOETLRuQMUWgTux6t39erM+6 FDvLjtJS/yK/BXTdiUSpTrTsYXh8PMU/QJGIvSsZa7ovEw+x0IaQqf3HXYJ5ckifvUUY s8Gcm43WC8WvEGx1LlSFJdwszRR6Pqlc89dqbVLz/EFQhZbzJTtsV0y1qHwMWMPKDwve ADZg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:message-id:in-reply-to :subject:cc:to:from:date:dkim-signature; bh=zFm7aP76Kl3qxn7n2tNVkuwpkcso4qVmefkLtKFqRbs=; fh=IAySOyfq6o/a4xP344im1S6zwWfM5WsGwplRngjadrI=; b=WGTuBAtQEuVIHwxPLUgLivOlSewcNbar4invR9gLuETo3prYIYDj10CX/rAau48zU2 0vSXgfgJyJDIhz2iC/D+1/SKu1upYDBUSIgxzy77B+QxJTRLQRpCmrRMpMw8Sby7UYiq 06RR9iuImLLU1LVR3uerypLYYWNkD4bgsTV851yUV3NL0kopCfIchX28hmRh+SDjSxzU 5Ose37Y4UzhFVkVUSCoxvbg3ND5i/2Eb/aTe3mIHNn3IqKVSVhZQyqPqTkXAbWSjEWRb PhdamU0UPg2pzcUYArMxWMaqQxza3N9YsSVUkvHcV7LyE9d4k9eKK/3djzhQ+kGRMIby ZBWQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20221208 header.b=SH61IoWs; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s205-20020a632cd6000000b0055ae20ada77si6928393pgs.591.2023.06.28.22.18.48; Wed, 28 Jun 2023 22:19:25 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20221208 header.b=SH61IoWs; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231286AbjF2FIY (ORCPT + 99 others); Thu, 29 Jun 2023 01:08:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53756 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231363AbjF2FIW (ORCPT ); Thu, 29 Jun 2023 01:08:22 -0400 Received: from mail-yb1-xb32.google.com (mail-yb1-xb32.google.com [IPv6:2607:f8b0:4864:20::b32]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A9B832724 for ; Wed, 28 Jun 2023 22:08:20 -0700 (PDT) Received: by mail-yb1-xb32.google.com with SMTP id 3f1490d57ef6-bacf685150cso268407276.3 for ; Wed, 28 Jun 2023 22:08:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20221208; t=1688015300; x=1690607300; h=mime-version:references:message-id:in-reply-to:subject:cc:to:from :date:from:to:cc:subject:date:message-id:reply-to; bh=zFm7aP76Kl3qxn7n2tNVkuwpkcso4qVmefkLtKFqRbs=; b=SH61IoWshgo0/pKjl3ljDej2EI0+DSaPIoPH0EnGJIbXtfIIjKOXzIBV7zaurn/u2O NzEik2ic/sSNSVVbeZ/UgymQtK7K6oY5QRG/wzVH8poLJ32013nMh89etey0qcHiO54m 9VJ8ecSgnyFVz892TYk34hIsLIVdE3C863sWe4PpKLL17z0rdk//QH8zHLezplf5zecn CMt8pQ6lO/N91/4KfIatcw4X88/dCSpVTpYW/IpvL+vwGOTzzDciFmwrt9muCsAvhi7d WOqlfS0Kym0VC+rHJLQVRUIX2a29Zo7bJvGsOEaU1uowBUKaMzsYZ9yHhLs0KJAe7PQ3 Eu7w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1688015300; x=1690607300; h=mime-version:references:message-id:in-reply-to:subject:cc:to:from :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=zFm7aP76Kl3qxn7n2tNVkuwpkcso4qVmefkLtKFqRbs=; b=ApwFd/LvLJH37m45wDenAdeIKHnEUor8O9o0Q3DTynr/A6kDEahi8RNrmSr07G1zea ZLjdaNxAtxXAXzAkBKhTM0pDTeabNYAJthO625HH7GScdOouzATEGPhnK9qC/OXKk1D5 JWunzVUBsx0Q8PbRoiKTFgvswm59B1Nx4oJfonQQ9YRpRnVp3XosWv7msmqLSEpTkeOI R1y1lqo+qJa+mmJEtpI3D4bHGyh8qr3RjnlDzFg85NWmRbQ/76IthIwifpruwxZg3hGv c5a0EHus2xvc1WY3oHJvvhaw0grIksnFFGzFLQ6LxNdp0C8I4ZyQJiM6mwu7I75G9RfR 5MMw== X-Gm-Message-State: AC+VfDxXSb8XfgSJdEcs4uL83Ff2XkGKHWDZgjSG60+gxPEStUmQlzTD ZNVTf45wUdPnwUv+RpOv6peBDQ== X-Received: by 2002:a25:bc86:0:b0:c25:3076:ffdc with SMTP id e6-20020a25bc86000000b00c253076ffdcmr9008572ybk.1.1688015299744; Wed, 28 Jun 2023 22:08:19 -0700 (PDT) Received: from ripple.attlocal.net (172-10-233-147.lightspeed.sntcca.sbcglobal.net. [172.10.233.147]) by smtp.gmail.com with ESMTPSA id 66-20020a251545000000b00bcc0f2e4f05sm2365847ybv.59.2023.06.28.22.08.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Jun 2023 22:08:19 -0700 (PDT) Date: Wed, 28 Jun 2023 22:08:08 -0700 (PDT) From: Hugh Dickins X-X-Sender: hugh@ripple.attlocal.net To: Gerald Schaefer cc: Hugh Dickins , Andrew Morton , Vasily Gorbik , Mike Kravetz , Mike Rapoport , "Kirill A. Shutemov" , Matthew Wilcox , David Hildenbrand , Suren Baghdasaryan , Qi Zheng , Yang Shi , Mel Gorman , Peter Xu , Peter Zijlstra , Will Deacon , Yu Zhao , Alistair Popple , Ralph Campbell , Ira Weiny , Steven Price , SeongJae Park , Lorenzo Stoakes , Huang Ying , Naoya Horiguchi , Christophe Leroy , Zack Rusin , Jason Gunthorpe , Axel Rasmussen , Anshuman Khandual , Pasha Tatashin , Miaohe Lin , Minchan Kim , Christoph Hellwig , Song Liu , Thomas Hellstrom , Russell King , "David S. Miller" , Michael Ellerman , "Aneesh Kumar K.V" , Heiko Carstens , Christian Borntraeger , Claudio Imbrenda , Alexander Gordeev , Jann Horn , Vishal Moola , Vlastimil Babka , linux-arm-kernel@lists.infradead.org, sparclinux@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-s390@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH v2 07/12] s390: add pte_free_defer() for pgtables sharing page In-Reply-To: <20230628211624.531cdc58@thinkpad-T15> Message-ID: References: <54cb04f-3762-987f-8294-91dafd8ebfb0@google.com> <20230628211624.531cdc58@thinkpad-T15> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Spam-Status: No, score=-17.6 required=5.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, ENV_AND_HDR_SPF_MATCH,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE,USER_IN_DEF_DKIM_WL,USER_IN_DEF_SPF_WL autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 28 Jun 2023, Gerald Schaefer wrote: > > As discussed in the other thread, we would rather go with less complexity, > possibly switching to an approach w/o the list and fragment re-use in the > future. For now, as a first step in that direction, we can try with not > adding fragments back only for pte_free_defer(). Here is an adjusted > version of your patch, copying most of your pte_free_defer() logic and > also description, tested with LTP and all three of your patch series applied: Thanks, Gerald: I don't mind abandoning my 13/12 SLAB_TYPESAFE_BY_RCU patch (posted with fewer Cc's to the s390 list last week), and switching to your simpler who-cares-if-we-sometimes-don't-make-maximal-use-of-page patch. But I didn't get deep enough into it today to confirm it - and disappointed that you've found it necessary to play with pt_frag_refcount in addition to _refcount and HH bits. No real problem with that, but my instinct says it should be simpler. Tomorrow... Hugh