Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp11025456rwd; Thu, 22 Jun 2023 07:52:37 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5meZrYklQytlCOZ8udWP0IwQ3do0ShmLgYRzt0qenXYs8iB0/wOY2YBTTxKScgsi5vYagJ X-Received: by 2002:a17:90a:28a3:b0:255:c829:b638 with SMTP id f32-20020a17090a28a300b00255c829b638mr11880769pjd.9.1687445557144; Thu, 22 Jun 2023 07:52:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687445557; cv=none; d=google.com; s=arc-20160816; b=RuhR3KPHQu7YwVpArH9saSUW08tHJhkP/4V9PeYWjcBqIW2HRWs/kvlYv5TPFnCQeI sO2Qcra8JrjU9kJjYOKgYbYHojTY7pftuuHo8D3TFPa+v5dWJNNJVqTNzNQrY8Ju0Spw IqmuiHXBiIahTdGyeE7VuJoCj/OMO7pt9St5riqyXIlnwWTLWeXOmd4xEV3h5WFLemYL kmIB2m0qLfbFPWGaira9p38vKYyGp+wdpqv3qr5aHWcVSJTBJBpshRXbdhXeXHJsWOZs ueRt88ojhHgWuue1z5xFF4RN/37E4oGiBgkvVSIxsKLqyXvN1s/PBpEeJl7WwvUsK0eZ /eOQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature:dkim-signature; bh=+0hFI3xJ2OGZHWhdLSxnOFvnT5Y+IP+BBRNQel7RyVs=; b=mql7CzBIkFCDaFk2fAlk+M5cwVa4rRpzK2E/74L0IAVXuVfwAfPDO4kJHxrhExAYH4 A4TLWDW3SB/Y810SMKt6GplLFxyheKosSvq6XG6cfKP2JLG3Xrka/bRkTJd/VslmbKQD myU3g8J/l+FabO+BkjqnhSCEXJFf4K0M9molEw6NedACWuodzMT0Zp7/pVNtBXHMQH/G XuWdPKY2nePXTCDJ7rsNX6J5ELRnv+HeyBO3bCKJLJsBdYZODly31EFfNC1NkkqNxdg2 RCvq/7w855A47jWjEUyQYx5k1Ex43wDKJjiJCWHeAS8tJeTJRbJLbgWLlB4qsiRDZpKJ 7MXw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=YraQJudJ; dkim=neutral (no key) header.i=@suse.cz; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q24-20020a17090aa01800b0024753ec4dccsi1488106pjp.124.2023.06.22.07.52.11; Thu, 22 Jun 2023 07:52:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-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=@suse.cz header.s=susede2_rsa header.b=YraQJudJ; dkim=neutral (no key) header.i=@suse.cz; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231836AbjFVOsE (ORCPT + 99 others); Thu, 22 Jun 2023 10:48:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54454 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231787AbjFVOsC (ORCPT ); Thu, 22 Jun 2023 10:48:02 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 66410C2; Thu, 22 Jun 2023 07:48:00 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 22955229C0; Thu, 22 Jun 2023 14:47:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1687445279; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=+0hFI3xJ2OGZHWhdLSxnOFvnT5Y+IP+BBRNQel7RyVs=; b=YraQJudJxxlhLJeEEEMxIUpfKYnVAv60cpmpHUQTGUBUh8t+ZXVmLjxm9M+1UGDbzHnQsz y6MEklPR6hPtAV8L33jHrD9qnGqvcBlma7u4mxdi/4lNztRux4EuDbVLobNoZf1RBa/v9Z PHfZlgjn/oBKddDSwkaKW1hcpThgEsQ= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1687445279; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=+0hFI3xJ2OGZHWhdLSxnOFvnT5Y+IP+BBRNQel7RyVs=; b=6XBRPNh3BjOoRZ1UijrujZWnxKxTKGitdF/zIOBj8hh8OwgFWdOjIPj2xpz1ePgJ9tQjeA VaJVHD8gCvpB4lBA== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id BA77013905; Thu, 22 Jun 2023 14:47:58 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id awUvLB5flGSsIgAAMHmgww (envelope-from ); Thu, 22 Jun 2023 14:47:58 +0000 Message-ID: Date: Thu, 22 Jun 2023 16:47:58 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.12.0 Subject: Re: [PATCH 01/29] mm: shrinker: add shrinker::private_data field Content-Language: en-US To: Qi Zheng , akpm@linux-foundation.org, david@fromorbit.com, tkhai@ya.ru, roman.gushchin@linux.dev, djwong@kernel.org, brauner@kernel.org, paulmck@kernel.org, tytso@mit.edu Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-arm-msm@vger.kernel.org, dm-devel@redhat.com, linux-raid@vger.kernel.org, linux-bcache@vger.kernel.org, virtualization@lists.linux-foundation.org, linux-fsdevel@vger.kernel.org, linux-ext4@vger.kernel.org, linux-nfs@vger.kernel.org, linux-xfs@vger.kernel.org, linux-btrfs@vger.kernel.org References: <20230622085335.77010-1-zhengqi.arch@bytedance.com> <20230622085335.77010-2-zhengqi.arch@bytedance.com> From: Vlastimil Babka In-Reply-To: <20230622085335.77010-2-zhengqi.arch@bytedance.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham 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-ext4@vger.kernel.org On 6/22/23 10:53, Qi Zheng wrote: > To prepare for the dynamic allocation of shrinker instances > embedded in other structures, add a private_data field to > struct shrinker, so that we can use shrinker::private_data > to record and get the original embedded structure. > > Signed-off-by: Qi Zheng I would fold this to 02/29, less churn. > --- > include/linux/shrinker.h | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/include/linux/shrinker.h b/include/linux/shrinker.h > index 224293b2dd06..43e6fcabbf51 100644 > --- a/include/linux/shrinker.h > +++ b/include/linux/shrinker.h > @@ -70,6 +70,8 @@ struct shrinker { > int seeks; /* seeks to recreate an obj */ > unsigned flags; > > + void *private_data; > + > /* These are for internal use */ > struct list_head list; > #ifdef CONFIG_MEMCG