From nobody Wed Jun 26 20:54:45 2024 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4W8Yq9651zz5QD9y; Wed, 26 Jun 2024 20:54:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4W8Yq92Wgkz4Lt9; Wed, 26 Jun 2024 20:54:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1719435285; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mCJYGvgpG0gVzPfOsh1fw0zYDy9MeuTNppJ+4clJaoE=; b=I4BGndnXAyt373gvHS9L0r4Xqrfr+IHhIzvtrvAIsQp3Mzz9GE8pR2REyU2eAk5LqLmObl 0iAV8RZZEURvfRYnHO9KyiWOvRcJwDv/s+j25aFzHTJahU9yNQ9NTABGEnQbAna/fDXN7Q P4DvexUmJBVSDbY8DmxCTybLD2ZLfyEawNLm9OXTanwVdkNRGZoFbpXJb8Ob3FPZA7nmJu L0sj6R6BfLbWPRq6uyvjVYY8lnFRmkVi0ygWVDkkhBWWEMQfBprcpwd12SoQYPcs8q8ju7 5FDamv2uB1IpJyiHh6Txu8tE1bvqFgabDQN2llhJ6mVxiIdcsv8FOFgqxF19gA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1719435285; a=rsa-sha256; cv=none; b=sPYFVicKwkPfBX+DEZSUTxiegFH9PqKRiBvs/WAF+so+PKzaXU/5BliYnFXtB/XaxY9w+Z +cJslDKDhzZvz84Tv1how3nq0N7zXmLGlGPnhmZkVM5k0uoKYCTg19LUcSoGP8Q9LXt0ds etYUozscYqh9LCCXbeMVODWmJ9IiNawghmaem8zKCwKAayvZ/VxKbSGUEN1W7x109lfIPF 53++lqx1bbLdloajPzCrTo/HEjzZapFIO6NTsoOcHfxYWAknJGx6MYRRQ/S6fvZxghcvpJ n5H9K0p6e8N7OMBEc/4KttWEYqCjOj2ftumyehgojoBWqcWx2YWi8OcJ+nwV5g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1719435285; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mCJYGvgpG0gVzPfOsh1fw0zYDy9MeuTNppJ+4clJaoE=; b=lVi3lNEQLbMd/2FTQFetHvUNoBVQ3pjc6aJgc0OAGbTFaxMXOHGYhdUEgmWqCzCyuLrlvi J8caBi48XRLuncp7DHFPvcnn7oXI0it2yNbmN7JABMIaWbtEQ+tb7En1AAd3O5zoMib4ID WG7E3Zm0DdKANohY9sYFxtewzVSdHKkbdc/las4hVUDWArNV8YOvP5cNZ49vRUuqZIbJ8V psJBlfFMZqxBB358211xhZn7C1qp9utmVAUSgJjrJNHqwLg9/V2sX2gonH+Cu2kzv/vp34 o2RKiobCpQg9/CRsoqYFtHGXKTCVKKlDjoBoP1sjYxUJn7vvaF6FOPW4B1orOw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4W8Yq925cDz10w6; Wed, 26 Jun 2024 20:54:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 45QKsjYL092573; Wed, 26 Jun 2024 20:54:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 45QKsjGB092570; Wed, 26 Jun 2024 20:54:45 GMT (envelope-from git) Date: Wed, 26 Jun 2024 20:54:45 GMT Message-Id: <202406262054.45QKsjGB092570@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: 889f74af66b8 - main - LinuxKPI: Add linux/nodemask.h List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 889f74af66b82e4401fb69ed8af6b9b4f48ce53b Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=889f74af66b82e4401fb69ed8af6b9b4f48ce53b commit 889f74af66b82e4401fb69ed8af6b9b4f48ce53b Author: Vladimir Kondratyev AuthorDate: 2024-06-26 20:49:52 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-06-26 20:49:52 +0000 LinuxKPI: Add linux/nodemask.h and dummy num_possible_nodes() implementation. We do not fully support NUMA in LinuxKPI yet. Sponsored by: Serenity CyberSecurity, LLC MFC after: 1 week Reviewed by: manu, bz Differential Revision: https://reviews.freebsd.org/D45613 --- .../linuxkpi/common/include/linux/nodemask.h | 40 ++++++++++++++++++++++ sys/compat/linuxkpi/common/include/linux/sched.h | 1 + 2 files changed, 41 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/nodemask.h b/sys/compat/linuxkpi/common/include/linux/nodemask.h new file mode 100644 index 000000000000..e61573bbc19f --- /dev/null +++ b/sys/compat/linuxkpi/common/include/linux/nodemask.h @@ -0,0 +1,40 @@ +/*- + * SPDX-License-Identifier: BSD-2-Clause + * + * Copyright (c) 2023 Serenity Cyber Security, LLC. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#ifndef _LINUXKPI_LINUX_NODEMASK_H_ +#define _LINUXKPI_LINUX_NODEMASK_H_ + +#include /* pr_debug */ + +static inline int +num_possible_nodes(void) +{ + pr_debug("%s: TODO\n", __func__); + return (1); +} + +#endif /* _LINUXKPI_LINUX_NODEMASK_H_ */ diff --git a/sys/compat/linuxkpi/common/include/linux/sched.h b/sys/compat/linuxkpi/common/include/linux/sched.h index 8cb6b12100d5..80354493f955 100644 --- a/sys/compat/linuxkpi/common/include/linux/sched.h +++ b/sys/compat/linuxkpi/common/include/linux/sched.h @@ -42,6 +42,7 @@ #include #include #include +#include #include #include #include