From 55404fd88827b96a7aa551176a808edab7348154 Mon Sep 17 00:00:00 2001 From: Mateusz Jablonski Date: Tue, 16 Jul 2024 15:20:04 +0000 Subject: [PATCH] refactor: move linux kernel headers to separate folders per source Signed-off-by: Mateusz Jablonski --- cmake/find_drm.cmake | 10 +++++----- third_party/uapi/README.md | 15 +++------------ third_party/uapi/dg1/.version | 1 + third_party/uapi/drm-uapi-helper/.version | 2 ++ .../{i915/prelim => drm-uapi-helper}/i915_drm.h | 0 .../prelim => drm-uapi-helper}/i915_drm_prelim.h | 0 .../uapi/{iaf => drm-uapi-helper}/iaf_netlink.h | 0 third_party/uapi/{ => upstream}/.version | 0 third_party/uapi/{ => upstream}/drm/drm.h | 0 third_party/uapi/{ => upstream}/drm/drm_fourcc.h | 0 third_party/uapi/{ => upstream}/drm/drm_mode.h | 0 third_party/uapi/{ => upstream}/i915/i915_drm.h | 0 third_party/uapi/{ => upstream}/xe/xe_drm.h | 0 13 files changed, 11 insertions(+), 17 deletions(-) create mode 100644 third_party/uapi/dg1/.version create mode 100644 third_party/uapi/drm-uapi-helper/.version rename third_party/uapi/{i915/prelim => drm-uapi-helper}/i915_drm.h (100%) rename third_party/uapi/{i915/prelim => drm-uapi-helper}/i915_drm_prelim.h (100%) rename third_party/uapi/{iaf => drm-uapi-helper}/iaf_netlink.h (100%) rename third_party/uapi/{ => upstream}/.version (100%) rename third_party/uapi/{ => upstream}/drm/drm.h (100%) rename third_party/uapi/{ => upstream}/drm/drm_fourcc.h (100%) rename third_party/uapi/{ => upstream}/drm/drm_mode.h (100%) rename third_party/uapi/{ => upstream}/i915/i915_drm.h (100%) rename third_party/uapi/{ => upstream}/xe/xe_drm.h (100%) diff --git a/cmake/find_drm.cmake b/cmake/find_drm.cmake index 8d385b70ae..1c9e267709 100644 --- a/cmake/find_drm.cmake +++ b/cmake/find_drm.cmake @@ -5,31 +5,31 @@ # if(NOT DEFINED NEO_DRM_HEADERS_DIR OR NEO_DRM_HEADERS_DIR STREQUAL "") - get_filename_component(NEO_DRM_HEADERS_DIR "${NEO_SOURCE_DIR}/third_party/uapi/drm" ABSOLUTE) + get_filename_component(NEO_DRM_HEADERS_DIR "${NEO_SOURCE_DIR}/third_party/uapi/upstream/drm" ABSOLUTE) endif() message(STATUS "drm includes dir: ${NEO_DRM_HEADERS_DIR}") if(NOT DEFINED NEO_I915_HEADERS_DIR OR NEO_I915_HEADERS_DIR STREQUAL "") - get_filename_component(NEO_I915_HEADERS_DIR "${NEO_SOURCE_DIR}/third_party/uapi/i915" ABSOLUTE) + get_filename_component(NEO_I915_HEADERS_DIR "${NEO_SOURCE_DIR}/third_party/uapi/upstream/i915" ABSOLUTE) endif() message(STATUS "i915 includes dir: ${NEO_I915_HEADERS_DIR}") if(NOT DEFINED NEO_I915_PRELIM_HEADERS_DIR OR NEO_I915_PRELIM_HEADERS_DIR STREQUAL "") - get_filename_component(NEO_I915_PRELIM_HEADERS_DIR "${NEO_SOURCE_DIR}/third_party${BRANCH_DIR_SUFFIX}uapi/i915/prelim" ABSOLUTE) + get_filename_component(NEO_I915_PRELIM_HEADERS_DIR "${NEO_SOURCE_DIR}/third_party/drm-uapi-helper" ABSOLUTE) endif() message(STATUS "i915 prelim includes dir: ${NEO_I915_PRELIM_HEADERS_DIR}") if(NOT DEFINED NEO_XE_HEADERS_DIR OR NEO_XE_HEADERS_DIR STREQUAL "") - get_filename_component(NEO_XE_HEADERS_DIR "${NEO_SOURCE_DIR}/third_party${BRANCH_DIR_SUFFIX}uapi/xe" ABSOLUTE) + get_filename_component(NEO_XE_HEADERS_DIR "${NEO_SOURCE_DIR}/third_party/uapi/upstream/xe" ABSOLUTE) endif() message(STATUS "xe includes dir: ${NEO_XE_HEADERS_DIR}") if(NOT DEFINED NEO_IAF_HEADERS_DIR OR NEO_IAF_HEADERS_DIR STREQUAL "") - get_filename_component(NEO_IAF_HEADERS_DIR "${NEO_SOURCE_DIR}/third_party/uapi/iaf" ABSOLUTE) + get_filename_component(NEO_IAF_HEADERS_DIR "${NEO_SOURCE_DIR}/third_party/uapi/drm-uapi-helper" ABSOLUTE) endif() message(STATUS "iaf includes dir: ${NEO_IAF_HEADERS_DIR}") diff --git a/third_party/uapi/README.md b/third_party/uapi/README.md index 2d600632b2..d1aa2a76d9 100644 --- a/third_party/uapi/README.md +++ b/third_party/uapi/README.md @@ -9,16 +9,7 @@ SPDX-License-Identifier: MIT Source locations of Linux kernel interface headers: -1. https://repositories.intel.com/graphics/kernel-api/index.html - - dg1/i915_drm.h -2. https://git.kernel.org/stable/h/v6.9.9 - - drm/drm.h - - drm/drm_mode.h - - drm/drm_fourcc.h - - i915/i915.h - - xe/xe_drm.h -3. https://github.com/intel-gpu/drm-uapi-helper/releases/tag/v2.0-rc24 - - i915/prelim/i915.h - - i915/prelim/i915_prelim.h - - iaf/iaf_netlink.h +1. dg1: https://repositories.intel.com/graphics/kernel-api/index.html +2. drm-uapi-helper: https://github.com/intel-gpu/drm-uapi-helper +3. upstream: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git diff --git a/third_party/uapi/dg1/.version b/third_party/uapi/dg1/.version new file mode 100644 index 0000000000..37f040ed33 --- /dev/null +++ b/third_party/uapi/dg1/.version @@ -0,0 +1 @@ +source: https://repositories.intel.com/graphics/kernel-api/index.html diff --git a/third_party/uapi/drm-uapi-helper/.version b/third_party/uapi/drm-uapi-helper/.version new file mode 100644 index 0000000000..10d2403440 --- /dev/null +++ b/third_party/uapi/drm-uapi-helper/.version @@ -0,0 +1,2 @@ +git_revision: v2.0-rc24 +git_url: https://github.com/intel-gpu/drm-uapi-helper diff --git a/third_party/uapi/i915/prelim/i915_drm.h b/third_party/uapi/drm-uapi-helper/i915_drm.h similarity index 100% rename from third_party/uapi/i915/prelim/i915_drm.h rename to third_party/uapi/drm-uapi-helper/i915_drm.h diff --git a/third_party/uapi/i915/prelim/i915_drm_prelim.h b/third_party/uapi/drm-uapi-helper/i915_drm_prelim.h similarity index 100% rename from third_party/uapi/i915/prelim/i915_drm_prelim.h rename to third_party/uapi/drm-uapi-helper/i915_drm_prelim.h diff --git a/third_party/uapi/iaf/iaf_netlink.h b/third_party/uapi/drm-uapi-helper/iaf_netlink.h similarity index 100% rename from third_party/uapi/iaf/iaf_netlink.h rename to third_party/uapi/drm-uapi-helper/iaf_netlink.h diff --git a/third_party/uapi/.version b/third_party/uapi/upstream/.version similarity index 100% rename from third_party/uapi/.version rename to third_party/uapi/upstream/.version diff --git a/third_party/uapi/drm/drm.h b/third_party/uapi/upstream/drm/drm.h similarity index 100% rename from third_party/uapi/drm/drm.h rename to third_party/uapi/upstream/drm/drm.h diff --git a/third_party/uapi/drm/drm_fourcc.h b/third_party/uapi/upstream/drm/drm_fourcc.h similarity index 100% rename from third_party/uapi/drm/drm_fourcc.h rename to third_party/uapi/upstream/drm/drm_fourcc.h diff --git a/third_party/uapi/drm/drm_mode.h b/third_party/uapi/upstream/drm/drm_mode.h similarity index 100% rename from third_party/uapi/drm/drm_mode.h rename to third_party/uapi/upstream/drm/drm_mode.h diff --git a/third_party/uapi/i915/i915_drm.h b/third_party/uapi/upstream/i915/i915_drm.h similarity index 100% rename from third_party/uapi/i915/i915_drm.h rename to third_party/uapi/upstream/i915/i915_drm.h diff --git a/third_party/uapi/xe/xe_drm.h b/third_party/uapi/upstream/xe/xe_drm.h similarity index 100% rename from third_party/uapi/xe/xe_drm.h rename to third_party/uapi/upstream/xe/xe_drm.h