From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6FBA5423E98 for ; Thu, 16 Jul 2026 13:24:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784208297; cv=none; b=RJeMnWOiu5kGxD4fb0MRZw1ola7+Sa7JMtcV93WCzqBSb2JIwkMtPVvv4zeQD33qtRYsMwRyuY7wY4mZCVSxG5Q2F7V2ftlA1zIIQb8JJBH6daHOh/5V61wCMsc7fJgMKubwEyJVuQbx2D2DIDGxHCrGWbJH9rzp/FEH6Q3CC7M= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784208297; c=relaxed/simple; bh=3IH0RAvQ3JwWxYH6LR4fyt3PeP+71z6kPqzGWEMyoX8=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=bcMHlG+6gUs9KiYupH0bpuRdZuRylKcHpJsstU60lbtegGAENh1it43JfLg2mJK4SZknqraXgVKb+MCoQPilYCSMb5FF1e8BIu9YjQ4YinnoT43nhY95P7GH0Le+c0cRsNRfmfZqRs3XkP7Gluvue9RjvJ79udVDc5qYs43ww9k= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=VjcQz7HV; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="VjcQz7HV" Received: by smtp.kernel.org (Postfix) with ESMTPSA id BF3191F000E9; Thu, 16 Jul 2026 13:24:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1784208296; bh=a91UqFOrJkNtKkfZIBS7Wu0Dr1ZR+NGPxSwxh4ZZj9w=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=VjcQz7HVRDr2rTsmFnvhua47DsM5+SJx6W9ZZ9NdzxwyOo8IIUTPezCEnhhaqEgiz SL5xHr3Y71AMfFgGCupo0Mlq6OIdJiR5d+acbKQoTd0c7nxQMKKfEt/W5x+eh510zI Yy0BsLlCNcCztJ9NMOOftnqjtpK2DXXebW9kaS1fMvGnIfRfIPwn5hldoCVuiUX1Wc z5FQUC+skSeKdsxqfU6bYe/ApHrdR0HrA7nm8sv7Im6s0AX+uI5dYQPHct2ZtFHKFz QkExgSNyk/I5ZZoFi+E7kqS4W/uMaV91g/E/q2LMv5qNu4Fmg6cWSkXcoQB2XXci5x sGfNTE6Oe1JfQ== Date: Thu, 16 Jul 2026 14:24:42 +0100 From: "Lorenzo Stoakes (ARM)" To: deepakroag Cc: Andrew Morton , David Hildenbrand , "Liam R. Howlett" , Vlastimil Babka , Mike Rapoport , Suren Baghdasaryan , Michal Hocko , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 1/3] feat: scale vmpressure window with machine size Message-ID: References: <20260716115734.80909-1-gaikwad.dcg@gmail.com> <20260716115734.80909-2-gaikwad.dcg@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20260716115734.80909-2-gaikwad.dcg@gmail.com> NAK. I'm not sure what you're doing here but this looks suspiciously like you're taking somebody else's (previously rejected) work and putting your name to it? And you're sending a v2 without having sent a v1? What? You're also getting basic process wrong here. We don't prefix with 'feat'. You only cc'd key people on 1/3 patches. There doesn't appear to be a cover letter. You are sending random vmalloc changes along with this too? On Thu, Jul 16, 2026 at 05:27:30PM +0530, deepakroag wrote: > Replace the fixed 512-page vmpressure window with a boot-time value > derived from total memory and CPU count, clamped between 128 and 2048 pages. So you're just making stuff up here? Clamp between 128 and 2048 because why not I guess? And no mention about the rest of the logic? > > Signed-off-by: deepakroag > --- There was already a patch for this in [0] which looks suspiciously close to what you're doing here (modulo clamping without using a clamp macro), unacknowledged. I hope you understand plagiarism is completely unacceptable? In any case it was rejected then for various reasons, you re-sending the same idea without crediting that changes nothing. Cheers, Lorenzo [0]:https://lore.kernel.org/all/20260227221555.29969-1-mcq@disroot.org/ > mm/vmpressure.c | 24 ++++++++++++++++++++++-- > 1 file changed, 22 insertions(+), 2 deletions(-) > > diff --git a/mm/vmpressure.c b/mm/vmpressure.c > index f053554e5..8925d4ad3 100644 > --- a/mm/vmpressure.c > +++ b/mm/vmpressure.c > @@ -33,9 +33,29 @@ > * SWAP_CLUSTER_MAX, it makes sense to use it for the window size as well. > * > * TODO: Make the window size depend on machine size, as we do for vmstat > - * thresholds. Currently we set it to 512 pages (2MB for 4KB pages). > + * thresholds. Scales with CPU count and total memory at boot. > */ > -static const unsigned long vmpressure_win = SWAP_CLUSTER_MAX * 16; > +static unsigned long vmpressure_win; > + > +static unsigned long __init vmpressure_window_size(void) > +{ > + unsigned long win; > + int mem; > + > + mem = totalram_pages() >> (27 - PAGE_SHIFT); > + win = SWAP_CLUSTER_MAX * (unsigned long)fls(num_online_cpus()) * > + (1 + fls(mem)); > + win = max(win, SWAP_CLUSTER_MAX * 4UL); > + win = min(win, SWAP_CLUSTER_MAX * 64UL); > + return win; > +} > + > +static int __init vmpressure_win_init(void) > +{ > + vmpressure_win = vmpressure_window_size(); > + return 0; > +} > +core_initcall(vmpressure_win_init); > > /* > * These thresholds are used when we account memory pressure through > -- > Deepak Rao Gaikwad >