Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp10562930rwd; Thu, 22 Jun 2023 01:27:42 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5vDwazieVWkvNgag0OSOC0dgj/rZJ9LytLnhlVgQ54sXhJ3FiBqnMI+jNrGrno2V/LumzN X-Received: by 2002:a05:6a20:3d27:b0:121:5c4b:45bc with SMTP id y39-20020a056a203d2700b001215c4b45bcmr15360892pzi.58.1687422462212; Thu, 22 Jun 2023 01:27:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687422462; cv=none; d=google.com; s=arc-20160816; b=t/OrVlNkTWd4sXPeBngXOeRfoik3a0gcU2ZoHwKUEDqaKod0ejpHgCKZWFz/jcCYl6 F9evjzbainpA1BQyi4eEYLMqI6O7JNyLQ0nWeMfbZCAxoOMZV2lVrtZlpt3YKIWgstNw qQYgSi8qipcXfsOXqqpAcBXRfbiUCyffu/bICPP0WmrUr1fWL0RQ30JuxCArAftigrve bvQgBSJLiFbFa9Xam06I3j2+qSXpSWCcTdyXwqJjMUg58xF7DRTBpmZYKPz9SbN1R5so 1R4ftxBi0Pg1bJs+DqotXXtszoOzEQndV+A/mqqkRT9cD4TLlgnOPhtyTQ8kx9cv5poR 7n9A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=w53NcBmn/IPVgjrXh3hKsvtsk7tDad26SsdH585QToY=; b=JuLDszLBCz/y2DNqNv/wpRSxb8dbwPsUA4K8YJNBl/2O6pLGhL0T0e6ylhND5v1kE2 xLSzHrdDmV5X2h/6kM4Rkj67Edvz2KTeJw4NtBtxVRFYnCmHdpl3OfB/CBqeEg/RkrIK o4PyKHxmWL5KbZvjVIXlrYGBrjiJq0NF13H+25oyQsKMuZuqqVZA6WPzzcxfluAhSczz AglPqBNxEj2GkmCs2p2YB2uRF/FiNMU4rLLm+8e0UeGO05sDNTmgg6ymLIbB8HHEFUnp +zkpZ9xSz3mNOtTWS4mgY+nr5df7yg0OmO/0Gms9xq24zUuCuChFYyQ7+lNI7GenULF6 8JMA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=XwhMjboY; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i67-20020a639d46000000b0054fdce77666si5872273pgd.630.2023.06.22.01.27.30; Thu, 22 Jun 2023 01:27:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-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=@linux.dev header.s=key1 header.b=XwhMjboY; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230185AbjFVI0X (ORCPT + 99 others); Thu, 22 Jun 2023 04:26:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43540 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230190AbjFVI0S (ORCPT ); Thu, 22 Jun 2023 04:26:18 -0400 Received: from out-63.mta0.migadu.com (out-63.mta0.migadu.com [91.218.175.63]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6EE0B1FE3 for ; Thu, 22 Jun 2023 01:26:13 -0700 (PDT) X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1687422370; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=w53NcBmn/IPVgjrXh3hKsvtsk7tDad26SsdH585QToY=; b=XwhMjboYkO1IjigA7jJUMcuvrlsYL6AEdKhP6EAdQek7nGl7SCwZP+s1KaXaDd0EbpkijC WzHmsAAL7fH0Q68pqE9kbEs/wm6WDN8VuTFUTe+F4YIjoGCH/bDYiJlTs6zAXz5aY/DcIU qOKI3csGnCUAw3UqbPNbuNVS2tXOJrg= From: Qi Zheng To: akpm@linux-foundation.org, david@fromorbit.com, tkhai@ya.ru, vbabka@suse.cz, roman.gushchin@linux.dev, djwong@kernel.org, brauner@kernel.org, paulmck@kernel.org, tytso@mit.edu Cc: airlied@gmail.com, daniel@ffwll.ch, robdclark@gmail.com, quic_abhinavk@quicinc.com, dmitry.baryshkov@linaro.org, sean@poorly.run, marijn.suijten@somainline.org, robh@kernel.org, tomeu.vizoso@collabora.com, steven.price@arm.com, alyssa.rosenzweig@collabora.com, agk@redhat.com, snitzer@kernel.org, song@kernel.org, colyli@suse.de, kent.overstreet@gmail.com, namit@vmware.com, gregkh@linuxfoundation.org, mst@redhat.com, david@redhat.com, jasowang@redhat.com, xuanzhuo@linux.alibaba.com, viro@zeniv.linux.org.uk, adilger.kernel@dilger.ca, jack@suse.com, chuck.lever@oracle.com, neilb@suse.de, kolga@netapp.com, minchan@kernel.org, senozhatsky@chromium.org, clm@fb.com, josef@toxicpanda.com, dsterba@suse.com, christian.koenig@amd.com, ray.huang@amd.com, linux-kernel@vger.kernel.org, linux-mm@kvack.org, intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, freedreno@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, Qi Zheng Subject: [PATCH 01/29] mm: shrinker: add shrinker::private_data field Date: Thu, 22 Jun 2023 08:24:26 +0000 Message-Id: <20230622082454.4090236-2-qi.zheng@linux.dev> In-Reply-To: <20230622082454.4090236-1-qi.zheng@linux.dev> References: <20230622082454.4090236-1-qi.zheng@linux.dev> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE 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-nfs@vger.kernel.org From: Qi Zheng 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 --- 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 -- 2.30.2