From nobody Wed Jun 26 20:54:44 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 4W8Yq83n2sz5QD9t; Wed, 26 Jun 2024 20:54:44 +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 4W8Yq81cn5z4LWH; Wed, 26 Jun 2024 20:54:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1719435284; 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=ByrxV3i+rqcItGL0w3vbFO9nhK/dv9BZracTfFggzOM=; b=ix2QPZ0OyS6VyMFnmr9G0ygaxj17z2+quhtVLg3hpjFlRlhsBo0v12kGSocT5KPLcNmY9Q qPD5aU3vxENsb1Jt6QV9sBPiSC1un/esXzkmxD59nMjg5HQqXwGjgcTY6RO/31U+S6oS5w DPzmu53Y2ulWAlm6XqbOKspqB+3d1W8iwhi2BxRRkTbJqH0uD/0cZ84u11t/E85DTzoRJW 1p3nIs0NcyHO9pNWemVTrFOf9NDVX5YVbWFVy8YFSRUGkgnl3UCrSBdLlWNy+8yAZp9Et4 3td1RFaDEQemXKJbJhh77QPf3pxKvBgr17HOctTWD+1uEjohiqBVNUxjPyih7Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1719435284; a=rsa-sha256; cv=none; b=V0Vk73bkXa9EHrI2EUnENXxuc9Et3QjDU5Ec67PiipAlSsgDHka3pP5k/HD1nde2G1gsmD lxcxGNx+cfaeRW+JTCYiTxmI35b6qbz/xPKOGvpatpYDXR3fykvjzv3nKZ5eYLGwtKWPxL 7HC0kxsc5tUNoYxwb+aZ53P9mj4DrdVvXIjevsORRNIaMYOoCewBDBH2FMghY3Q9pAytE6 HV+hO0nlLK++dqNrl88HJzk2eOIDo0jAf/7B1BLTrnwqib4loPIwAuvWtItuAWpQnpzrcL x6GStz+Oz/dIFRhZsb0reGhVD7E744SoZMhT2rnoPFMGoKxxriLAIpEmILeG1g== 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=1719435284; 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=ByrxV3i+rqcItGL0w3vbFO9nhK/dv9BZracTfFggzOM=; b=Rsm3CPNDBm4K7fZQGaWpCqGlE3+RR0VjsJJYjLF4TUJKzdCEFGPjM/ZPABC+x4rxGtOSof eB0fjDDVvKk6VdxbLDmhsH1N0pXEsXsuFu0Lzw5s2Tg7h+65i8j0SoNlRbCTt1N1vRLZ7M q04ZGA9xyY1nwf4vhHqwFzarCIBtC4yQvAfe9czrCIkeX53kdOP4bU4o/yRxATdgHh9HH4 GfzJ/NUfXj0lJea4QoflR5TKR42mfasrFG41YEh6hZFCefrZcuCylToOWi0FX5zP8jgpFz DZtk4yN2UCIkQSMvMQ4qyS7ERTFZs7H5eJGEbWP+y4a5GiNNUfL73JEtLjeRpA== 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 4W8Yq816zXz10m0; Wed, 26 Jun 2024 20:54:44 +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 45QKsiGA092537; Wed, 26 Jun 2024 20:54:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 45QKsi2b092534; Wed, 26 Jun 2024 20:54:44 GMT (envelope-from git) Date: Wed, 26 Jun 2024 20:54:44 GMT Message-Id: <202406262054.45QKsi2b092534@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: 256eb8d53611 - main - LinuxKPI: Remove linux/sched.h include from linux/kernel.h header 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: 256eb8d5361143b7d436a195530e0eefe1450e6d Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=256eb8d5361143b7d436a195530e0eefe1450e6d commit 256eb8d5361143b7d436a195530e0eefe1450e6d Author: Vladimir Kondratyev AuthorDate: 2024-06-26 20:47:12 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-06-26 20:47:12 +0000 LinuxKPI: Remove linux/sched.h include from linux/kernel.h header This include prevents usage of any kernel.h helpers in sched.h and all of dependencies. Linux does not have it too. Fix building of kernel and drm-kmod after than. Sponsored by: Serenity CyberSecurity, LLC MFC after: 1 week Reviewed by: manu, bz Differential Revision: https://reviews.freebsd.org/D45692 --- sys/compat/linuxkpi/common/include/linux/gpf.h | 33 ++++++++++++++++++++++ sys/compat/linuxkpi/common/include/linux/idr.h | 1 + sys/compat/linuxkpi/common/include/linux/kernel.h | 1 - .../linuxkpi/common/include/linux/scatterlist.h | 3 ++ sys/compat/linuxkpi/common/src/linux_rcu.c | 1 + 5 files changed, 38 insertions(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/include/linux/gpf.h b/sys/compat/linuxkpi/common/include/linux/gpf.h new file mode 100644 index 000000000000..01e883a94728 --- /dev/null +++ b/sys/compat/linuxkpi/common/include/linux/gpf.h @@ -0,0 +1,33 @@ +/*- + * SPDX-License-Identifier: BSD-2-Clause + * + * Copyright (c) 2024 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_GPF_H_ +#define _LINUXKPI_LINUX_GPF_H_ + +#include + +#endif /* _LINUXKPI_LINUX_GPF_H_ */ diff --git a/sys/compat/linuxkpi/common/include/linux/idr.h b/sys/compat/linuxkpi/common/include/linux/idr.h index ca3f8171ff44..7f55b8e57c7e 100644 --- a/sys/compat/linuxkpi/common/include/linux/idr.h +++ b/sys/compat/linuxkpi/common/include/linux/idr.h @@ -34,6 +34,7 @@ #include #include +#include #include #define IDR_BITS 5 diff --git a/sys/compat/linuxkpi/common/include/linux/kernel.h b/sys/compat/linuxkpi/common/include/linux/kernel.h index fd5f42fbe36c..43938cdf73de 100644 --- a/sys/compat/linuxkpi/common/include/linux/kernel.h +++ b/sys/compat/linuxkpi/common/include/linux/kernel.h @@ -50,7 +50,6 @@ #include #include #include -#include #include #include #include diff --git a/sys/compat/linuxkpi/common/include/linux/scatterlist.h b/sys/compat/linuxkpi/common/include/linux/scatterlist.h index e462d5c649f1..51ced19e6b5b 100644 --- a/sys/compat/linuxkpi/common/include/linux/scatterlist.h +++ b/sys/compat/linuxkpi/common/include/linux/scatterlist.h @@ -32,8 +32,11 @@ #define _LINUXKPI_LINUX_SCATTERLIST_H_ #include +#include +#include #include +#include #include #include #include diff --git a/sys/compat/linuxkpi/common/src/linux_rcu.c b/sys/compat/linuxkpi/common/src/linux_rcu.c index 335708b6747f..4879c30164e3 100644 --- a/sys/compat/linuxkpi/common/src/linux_rcu.c +++ b/sys/compat/linuxkpi/common/src/linux_rcu.c @@ -41,6 +41,7 @@ #include #include +#include #include #include #include