From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 97F8CD37482 for ; Thu, 17 Oct 2024 12:23:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=upV9IxmbyLh24y5KvmoZk8IuzsVT/v4PISDDNTLkG6M=; b=qit5XC0/YWssS7OX3y0G5Co0mJ G5jiDZBRfd4++qQQAfEn/2+eV0NT0Sz8ZWDHeJdlG7mFAvu8H6hsbt/Y2YBXyOW97Bbp3AP5yPlwn NRPoHKpLRyL4fFFVs/lKIYoYAm7PMvHk48ukaAWoppPnTsgYxMeEbFwsuUZaJ20FWGj80miJCDoUV tXIf7+/XaMDM7yagn2Izv9kyO35f3JdmduaucB4d0K+tkBYkEhgahk7KKzUflBuWYmUVZNQsFFTtu OpI4gXB0ZbB8Y7jIy5opiVTo29ZSdtX4NlamhtY4ozM7TqdhQfIxQCZkQIsfne7BmMsTdcZLUQ2lF bIBme1fQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1t1PXW-0000000ElIF-0vpB; Thu, 17 Oct 2024 12:23:38 +0000 Received: from mail-ed1-x533.google.com ([2a00:1450:4864:20::533]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1t1PVQ-0000000EkwU-3Lub for linux-arm-kernel@lists.infradead.org; Thu, 17 Oct 2024 12:21:36 +0000 Received: by mail-ed1-x533.google.com with SMTP id 4fb4d7f45d1cf-5c9150f9ed4so1069862a12.0 for ; Thu, 17 Oct 2024 05:21:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=google; t=1729167686; x=1729772486; darn=lists.infradead.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=upV9IxmbyLh24y5KvmoZk8IuzsVT/v4PISDDNTLkG6M=; b=K15ABPtaME2T2SgFhHaUmSbfEHJ9QovtRQHtIN2sZt40oITlgiTnuNV3igx7XFa+Na d7YTw9pvq+1EKS88d9oXOG1cqg/hJi9cZAKkkIm74nuKNYCExf2mwPfOipHT9Exm0puG /Wf0zqQyXo5YyDLYq9Ue57ZWD61th7NBwWhCnFNo89844cb5N6FOysssuw7s6k7QSEYk ld88YBu+vc7APLii3m8wewCV0Rdf4RI3+meINRprN9tr5owGER74VvfrsKXf6GMrLeOE TCwqEG6KsuoOBZm/iZpGObC0d/6PVXdmwDxlNLXJ4VdNd9CBnBn8SLo1B8CfMdjSipYP FzJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729167686; x=1729772486; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=upV9IxmbyLh24y5KvmoZk8IuzsVT/v4PISDDNTLkG6M=; b=saHOyNnjW91+/osVFfwIQcnxI0sauiPbuD2lDe1++TkvCRQMs0l/X2HtYQkXi+csoL R352efSydM5z9WGSBX3AGRmY3reaCaJ8gCZU39KKWAqewAn+jCELdsn/BIU0qXsOX14u 1CMM651KpPNpAsTyMEwejrP9DXbxAihEHNO+MQs1QsmOdSk5SxxNDjJjBizIyCHMiI/4 59E1EbAlKZzFViJDFQ0fD7NUJcXvWD3LVTsesAhKWVHizlL86Oh+PMONxCNNOK2ow7TY h3sI628OCwm75kjMODnALiH2fqynbsUxaWZ6hmt1vjj4qM/Itd1cd4CXH5qH/oftykqD qyNg== X-Forwarded-Encrypted: i=1; AJvYcCUmRVSyy3dQRyaDQ69G3D8ZJoflOZxuMtYk0V4Wlo3KKkBWf46q27S58airmyvDFETiKOMR1toLNCs5ArQArGuI@lists.infradead.org X-Gm-Message-State: AOJu0YxlvESl3oD11NRrn3pIjHl7r0ub/RYdhTUcOFWd8Pc4QkbhaKHd ik1VG9PVmarIEN58TeY+HTYoI9esN5BEKm9FLPN3WHg7cs9kNqNbYloTU3EJILE= X-Google-Smtp-Source: AGHT+IGq5ucbFHU1tVBUcI+q8DDYTzRsfdUSa7DEcY8Ig4Lc722w45PjwM12vp8ybtkKQFy10/mN6g== X-Received: by 2002:a05:6402:13cd:b0:5c9:3fe:c7b9 with SMTP id 4fb4d7f45d1cf-5c994e6dfd2mr5839341a12.0.1729167686207; Thu, 17 Oct 2024 05:21:26 -0700 (PDT) Received: from localhost ([193.86.92.181]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5c98d5077e6sm2733482a12.48.2024.10.17.05.21.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 17 Oct 2024 05:21:25 -0700 (PDT) Date: Thu, 17 Oct 2024 14:21:25 +0200 From: Michal Hocko To: Ryan Roberts Cc: Shakeel Butt , Andrew Morton , Anshuman Khandual , Ard Biesheuvel , Catalin Marinas , David Hildenbrand , Greg Marsden , Ivan Ivanov , Johannes Weiner , Kalesh Singh , Marc Zyngier , Mark Rutland , Matthias Brugger , Miroslav Benes , Roman Gushchin , Will Deacon , cgroups@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [RFC PATCH v1 03/57] mm/memcontrol: Fix seq_buf size to save memory when PAGE_SIZE is large Message-ID: References: <20241014105514.3206191-1-ryan.roberts@arm.com> <20241014105912.3207374-1-ryan.roberts@arm.com> <20241014105912.3207374-3-ryan.roberts@arm.com> <315d4258-ea96-4008-8781-9205f41cec6c@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <315d4258-ea96-4008-8781-9205f41cec6c@arm.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241017_052128_884063_3F4B97DA X-CRM114-Status: GOOD ( 18.78 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue 15-10-24 11:55:26, Ryan Roberts wrote: > On 14/10/2024 20:59, Shakeel Butt wrote: > > On Mon, Oct 14, 2024 at 11:58:10AM GMT, Ryan Roberts wrote: > >> Previously the seq_buf used for accumulating the memory.stat output was > >> sized at PAGE_SIZE. But the amount of output is invariant to PAGE_SIZE; > >> If 4K is enough on a 4K page system, then it should also be enough on a > >> 64K page system, so we can save 60K om the static buffer used in > >> mem_cgroup_print_oom_meminfo(). Let's make it so. > >> > >> This also has the beneficial side effect of removing a place in the code > >> that assumed PAGE_SIZE is a compile-time constant. So this helps our > >> quest towards supporting boot-time page size selection. > >> > >> Signed-off-by: Ryan Roberts > > > > Acked-by: Shakeel Butt > > Thanks Shakeel and Johannes, for the acks. Given this patch is totally > independent, I'll plan to resubmit it on its own and hopefully we can get it in > independently of the rest of the series. Yes, this makes sense independent on the whole series. Acked-by: Michal Hocko Thanks! -- Michal Hocko SUSE Labs