From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 B42A92BFC7B for ; Sat, 20 Dec 2025 02:42:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1766198527; cv=none; b=eX3hkK+ZkUTF1pJA3x6TxKUqkbbxFH1pdqMA3VaotZHX5zN8rPFP7ha6K1oLJ/4vZiPvcAu19uWzWIKBAGSq1kXYSe/UTM00xiyqNGiekLKN1hH/R72UUyKm9YMzcAgIyMmNQR+BWftWumQ+GAPh0mNXEeghFRz3kSCBOLYgQuc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1766198527; c=relaxed/simple; bh=mndMqX0S/14QL0u5YDFIVifJ026qwf4PHYrKtqB/M+M=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=UaN2TBWBEgq+yex5DzuYqIhDE4IO4y7JvHQchrnd8++ugb4BPUpR0LHSkmpm8YYZJ04Ls1y9kHxA/wGR8V1xECfuFE3zZlKjvRrZSrwp5s1zD4Eboc2+9HVlrHSaX6qS6UAtg7hkgLy4wx5TlTMtga9w7XqKuTd0H0kh7uinknY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=sAVdGaiY; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="sAVdGaiY" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 08355C4CEF1; Sat, 20 Dec 2025 02:42:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1766198527; bh=mndMqX0S/14QL0u5YDFIVifJ026qwf4PHYrKtqB/M+M=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=sAVdGaiYIqmFPMb237e+e2rLHhbk6C1T5tXs8tS0am3d4NjFmk0P8DtOT0G0S0KRY EYkC1Ccnl9LvqnT+geDFMUbhN+aRUFQGqMOzYqRkTYRUUaB4gI5xH1EKhAgAHdVNlS uIIR55jIq5OBdHuGHZsuxo+cgAvA5lXRI4wOVktQO0qf8TaroYo+hJnn54KXsqtKUt sS89hDW6xOf5pUvUg79dFM+vQtsUN+AF3H7cs2GQUykNVvDIsPJDwwgK1B4zH+uFSY q3dJ6G9C/Y36sNbVIdtq5kE5oU85vlZJXFUNPAJkSEAsghLTZrTzoK9mhuVcvRvPX4 yMI4yJFye4rIw== From: SeongJae Park To: Joshua Hahn Cc: SeongJae Park , Andrew Morton , Daniel Palmer , Guenter Roeck , Brendan Jackman , Johannes Weiner , Michal Hocko , Suren Baghdasaryan , Vlastimil Babka , Zi Yan , linux-kernel@vger.kernel.org, linux-mm@kvack.org, kernel-team@meta.com Subject: Re: [PATCH v2] mm/page_alloc: Report 1 as zone_batchsize for !CONFIG_MMU Date: Fri, 19 Dec 2025 18:41:58 -0800 Message-ID: <20251220024158.43433-1-sj@kernel.org> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20251218083200.2435789-1-joshua.hahnjy@gmail.com> References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit On Thu, 18 Dec 2025 00:31:59 -0800 Joshua Hahn wrote: > Commit 2783088ef24e ("mm/page_alloc: prevent reporting pcp->batch = 0") > moved the error handling (0-handling) of zone_batchsize from its > callers to inside the function. However, the commit left out the error > handling for the NOMMU case, leading to deadlocks on NOMMU systems. > > For NOMMU systems, return 1 instead of 0 for zone_batchsize, which restores > the previous deadlock-free behavior. > > There is no functional difference expected with this patch before commit > 2783088ef24e, other than the pr_debug in zone_pcp_init now printing out > 1 instead of 0 for zones in NOMMU systems. Not only is this a pr_debug, > the difference is purely semantic anyways. > > Fixes: 2783088ef24e ("mm/page_alloc: prevent reporting pcp->batch = 0") > Reported-by: Daniel Palmer > Closes: https://lore.kernel.org/linux-mm/CAFr9PX=_HaM3_xPtTiBn5Gw5-0xcRpawpJ02NStfdr0khF2k7g@mail.gmail.com/ > Reported-by: Guenter Roeck > Closes: https://lore.kernel.org/all/42143500-c380-41fe-815c-696c17241506@roeck-us.net/ > Signed-off-by: Joshua Hahn Acked-by: SeongJae Park Thanks, SJ [...]