From patchwork Sun Jun 23 06:26:20 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mike Rapoport X-Patchwork-Id: 13708512 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8D038C27C4F for ; Sun, 23 Jun 2024 06:28:49 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id DD4DD6B03B2; Sun, 23 Jun 2024 02:28:48 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id D5FAF6B057D; Sun, 23 Jun 2024 02:28:48 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id B61FC6B03B3; Sun, 23 Jun 2024 02:28:48 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id 93C7E6B03AE for ; Sun, 23 Jun 2024 02:28:48 -0400 (EDT) Received: from smtpin05.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 1767C4037C for ; Sun, 23 Jun 2024 06:28:48 +0000 (UTC) X-FDA: 82261175136.05.31EE221 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by imf06.hostedemail.com (Postfix) with ESMTP id 8BE33180007 for ; Sun, 23 Jun 2024 06:28:45 +0000 (UTC) Authentication-Results: imf06.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=qw9Tu3Fa; spf=pass (imf06.hostedemail.com: domain of rppt@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=rppt@kernel.org; dmarc=pass (policy=none) header.from=kernel.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1719124113; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding:in-reply-to: references:dkim-signature; bh=U00NkflM2uYmPTwtDeKua/L1etv6UwZPShpgiY/e/y8=; b=qE6WAvt7PKufiFG9LTbnccOJ4B8gpW0+5DXgTd2JR2dOMWKBVvbRz826clMIF8uW22Xv5g s6HBTzA7i37JCPdjWtCgeudPtVblFy0z/2JP9dOugOZISKxWRZhloW1L28efwzmQbmAptX zNB2m+l5yRWRmLCYHtXYnA+t9rCVuro= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1719124113; a=rsa-sha256; cv=none; b=6eYzBme2QfCiHAUnlajBgPZtjDmZS9qn+/3t6Qw31xYm2jJa/s3skhDZaw7DeTUvOaAGJd r48ak4SM150k6wKGKrOf/mzu0zfH57gN0EJPf1zLfejLIRplJdP8DxHyaZCsYP1mm6YqJD rIECNzB2VoZvt9m0dGRdh92/Y6uZyek= ARC-Authentication-Results: i=1; imf06.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=qw9Tu3Fa; spf=pass (imf06.hostedemail.com: domain of rppt@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=rppt@kernel.org; dmarc=pass (policy=none) header.from=kernel.org Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by dfw.source.kernel.org (Postfix) with ESMTP id 6C92061A88; Sun, 23 Jun 2024 06:28:44 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 55DAFC2BD10; Sun, 23 Jun 2024 06:28:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1719124124; bh=/szumQs4ZfZmpOw59Gy9dK6j0OCQ6BkDfNmmnoXGkso=; h=Date:From:To:Cc:Subject:From; b=qw9Tu3FaXDUjMlL6vrOMpeYK14O+mC1kSn1q+Enk7OOEqOy9fDcTf4XTXB8AdygZx dyrcejsfbSpJDkMWEtKViW9vTXAekICmms99os9mYGJ3MoTuUkz3SSkMVsHmktBMZw b0sWRg7pyFthmzee9uOVL9khVjJVOaw6egzPhoVWb6B+Vd3V7h5+RRz8wraurWwgeJ Qs+3HWJ+/apDAlCE+IV1m0RUmu9dZl/efze43OABSKCBqd9PjnYAhMajojrCZ7G6yS Zl85847Dax5/IDf+3tdvCxBaELtHJ9M7SH0yutlElFEv121O+Dq0k/rfO/6vIv6rxu f5mIofroEAkEQ== Date: Sun, 23 Jun 2024 09:26:20 +0300 From: Mike Rapoport To: Linus Torvalds Cc: Andrew Morton , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: [GIT PULL] memblock: fix fragility in checks for unset node ID Message-ID: MIME-Version: 1.0 Content-Disposition: inline X-Rspam-User: X-Rspamd-Server: rspam04 X-Rspamd-Queue-Id: 8BE33180007 X-Stat-Signature: 6comxw9hsjbzkimn4bapkcof1kyjkzxg X-HE-Tag: 1719124125-455665 X-HE-Meta: U2FsdGVkX1+W8DtilNbh7iDS7VTNFGEfa98S3p/8Oo68tx8c0uI/45nAhRowE3SOmgsvu7pAg4ngPp5u2/Fv+lAgGV5x/rNKo//pWrJaSQXZypyKP0W0CyWuWK/+Kw85JKnKf9C/xFRwngXY0TDGAcNoS9htmK6WKbpgcL/vTnlqbYCXIQwcLDwsmr+YGEWX+oDeEFJOLApJDZeaUpiHZEBH/MfqrjgtaaknMdQgpQec+TN3O2/RxCYtpVYQfO6BxbrIbFJdQ0fZBLlzP0ksZo2KbbLJlO3fIFKf6iTB+lSU1oa+ELacOizscgrS4Ksa+Sv9xT1K4Z9KXJ+s8l+2BLZXl/ZJpfW8ja9vqca5IbJ5o3dt4JGPvm3sYEMoJQdVQcDK4EPWKCAMWm80OvKuj2tElmdqQSTev6bp+gL7hvWgFmaurJ5XybQ4kkwWQW5lJ8rT9Rk+UJW5SLhDucuxa2X8HCh8xO2NJhBAlLKpNc6xiUTNprN2TytpXSjWndHx+mivwP9m8afQohpVNC78+T9EDPQNpDBydMbs9EX81fGrzj6W4MOltSqCa+TA3XmwfuVasa1oNWfGoIQi7DW2vQU4L9uSoosJNNUkWsQ4MqaN/gyJOeeeLP+eOKOHOJmWVyBv7FrHk443+IDWhYXF+sexiQbXBpgrqzarOm8ryM2QgsJp11jNsHgJlwFL2c10utomtV7ZhD77L7pHUMnYCKA5QGyxKUkgbeq8gNqsFQGXR01IOcpVg+VxxvazmZT6b6l6hdYQvvtjrohhvltVFZrZYiQId9KbH1Y4zInfW+lpbkjnDsL0p3g2Bf0r65NibsPk4tL0LxMGAS/u1kmj/h9dM910L5lxC6dkZC1ywzVYhoYXBHCNfZjjVITuayYaN+zi7ef/KfFG28iBrnTyyJkzQixxk9fYuOKpdK/gHEMjcLssQSoBO/zGXOiY/7ZF3XLEz2WTTSsucSrilZv oAEuQLEX CovXb1b7+ChGlxJSyxSKXy6OnKsZbkZAFHnn3ksNetCYD9C9r3CLO14SB3LuxX9y23cQXKp6gZO2dJbEz5h2CNyu/lKVTQovlhsmwytqtDS+k4JRCmRkY6MC0oQN9zmzRJ7cDxukAJ77zoSbwV97bCPWLeMN5PvS3K+GKg1QLpNy68s9WrzIIk3rpZQ7A4VMkfXkHZwr9VocjD533BBQdgFQIQ+V1VysmpLA1uuf3FnZRA6TdvpQtOvk3n0PMkqAJXbiR93N5Z3KvuH/RJSMYFDFDng== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Hi Linus, The following changes since commit 3ac36aa7307363b7247ccb6f6a804e11496b2b36: x86/mm/numa: Use NUMA_NO_NODE when calling memblock_set_node() (2024-06-06 22:20:39 +0300) are available in the Git repository at: https://git.kernel.org/pub/scm/linux/kernel/git/rppt/memblock tags/fixes-2024-06-23 for you to fetch changes up to 8043832e2a123fd9372007a29192f2f3ba328cd6: memblock: use numa_valid_node() helper to check for invalid node ID (2024-06-16 10:17:57 +0300) ---------------------------------------------------------------- memblock: fix fragility in checks for unset node ID Use numa_valid_node() function to verify that nid is a valid node ID instead of inconsistent comparisons with either NUMA_NO_NODE or MAX_NUMNODES. ---------------------------------------------------------------- Mike Rapoport (IBM) (1): memblock: use numa_valid_node() helper to check for invalid node ID include/linux/numa.h | 5 +++++ mm/memblock.c | 28 +++++++--------------------- 2 files changed, 12 insertions(+), 21 deletions(-)