Skip to content

Commit 431311e

Browse files
coreos-sources: Update the cross-compilation patch to upstream
This commits also retabs the ebuilds Signed-off-by: Sayan Chowdhury <sayan.chowdhury2012@gmail.com>
1 parent 228b083 commit 431311e

3 files changed

Lines changed: 56 additions & 46 deletions

File tree

sdk_container/src/third_party/coreos-overlay/sys-kernel/coreos-sources/coreos-sources-6.18.45.ebuild

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,11 @@ detect_version
1717
DESCRIPTION="Full sources for the CoreOS Linux kernel"
1818
HOMEPAGE="http://www.kernel.org"
1919
if [[ "${PV%%_rc*}" != "${PV}" ]]; then
20-
SRC_URI="https://git.kernel.org/torvalds/p/v${KV%-coreos}/v${OKV} -> patch-${KV%-coreos}.patch ${KERNEL_BASE_URI}/linux-${OKV}.tar.xz"
21-
PATCH_DIR="${FILESDIR}/${KV_MAJOR}.${KV_PATCH}"
20+
SRC_URI="https://git.kernel.org/torvalds/p/v${KV%-coreos}/v${OKV} -> patch-${KV%-coreos}.patch ${KERNEL_BASE_URI}/linux-${OKV}.tar.xz"
21+
PATCH_DIR="${FILESDIR}/${KV_MAJOR}.${KV_PATCH}"
2222
else
23-
SRC_URI="${KERNEL_URI}"
24-
PATCH_DIR="${FILESDIR}/${KV_MAJOR}.${KV_MINOR}"
23+
SRC_URI="${KERNEL_URI}"
24+
PATCH_DIR="${FILESDIR}/${KV_MAJOR}.${KV_MINOR}"
2525
fi
2626

2727
# make modules_prepare depends on pahole
@@ -35,11 +35,11 @@ IUSE=""
3535
# patchlevel revision. We mustn't apply our patches first, it fails when the
3636
# local patches overlap with the upstream patch.
3737
UNIPATCH_LIST="
38-
${PATCH_DIR}/z0001-pahole-support-reproducible-builds.patch \
39-
${PATCH_DIR}/z0002-Revert-x86-boot-Remove-the-bugger-off-message.patch \
40-
${PATCH_DIR}/z0003-efi-Add-an-EFI_SECURE_BOOT-flag-to-indicate-secure-b.patch \
41-
${PATCH_DIR}/z0004-efi-Lock-down-the-kernel-if-booted-in-secure-boot-mo.patch \
42-
${PATCH_DIR}/z0005-mtd-phram-slram-Disable-when-the-kernel-is-locked-do.patch \
43-
${PATCH_DIR}/z0006-arm64-add-kernel-config-option-to-lock-down-when-in-.patch \
44-
${PATCH_DIR}/z0007-tools-hv-fix-cross-compilation-for-ARM64.patch \
38+
${PATCH_DIR}/z0001-pahole-support-reproducible-builds.patch \
39+
${PATCH_DIR}/z0002-Revert-x86-boot-Remove-the-bugger-off-message.patch \
40+
${PATCH_DIR}/z0003-efi-Add-an-EFI_SECURE_BOOT-flag-to-indicate-secure-b.patch \
41+
${PATCH_DIR}/z0004-efi-Lock-down-the-kernel-if-booted-in-secure-boot-mo.patch \
42+
${PATCH_DIR}/z0005-mtd-phram-slram-Disable-when-the-kernel-is-locked-do.patch \
43+
${PATCH_DIR}/z0006-arm64-add-kernel-config-option-to-lock-down-when-in-.patch \
44+
${PATCH_DIR}/z0007-tools-hv-fix-cross-compilation.patch \
4545
"

sdk_container/src/third_party/coreos-overlay/sys-kernel/coreos-sources/files/6.18/z0007-tools-hv-fix-cross-compilation-for-ARM64.patch

Lines changed: 0 additions & 35 deletions
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
From ca5ee0e918115fb5cf626d75461d9fca06e06caf Mon Sep 17 00:00:00 2001
2+
From: Aditya Garg <gargaditya@linux.microsoft.com>
3+
Date: Thu, 9 Apr 2026 03:32:18 -0700
4+
Subject: [PATCH] tools: hv: Fix cross-compilation
5+
6+
Use the native ARCH only in case it is not set, this will allow the
7+
cross-compilation where ARCH is explicitly set.
8+
9+
Additionally, simplify the ARCH check to build the fcopy daemon only
10+
for x86 and x86_64.
11+
12+
Fixes: 82b0945ce2c2 ("tools: hv: Add new fcopy application based on uio driver")
13+
Reported-by: Adrian Vladu <avladu@cloudbasesolutions.com>
14+
Closes: https://lore.kernel.org/linux-hyperv/PR3PR09MB54119DB2FD76977C62D8DD6AB04D2@PR3PR09MB5411.eurprd09.prod.outlook.com/
15+
Co-developed-by: Saurabh Sengar <ssengar@linux.microsoft.com>
16+
Signed-off-by: Saurabh Sengar <ssengar@linux.microsoft.com>
17+
Signed-off-by: Aditya Garg <gargaditya@linux.microsoft.com>
18+
Reviewed-by: Roman Kisel <romank@linux.microsoft.com>
19+
Signed-off-by: Wei Liu <wei.liu@kernel.org>
20+
---
21+
tools/hv/Makefile | 4 ++--
22+
1 file changed, 2 insertions(+), 2 deletions(-)
23+
24+
diff --git a/tools/hv/Makefile b/tools/hv/Makefile
25+
index 34ffcec264ab0f..016753f3dd7f61 100644
26+
--- a/tools/hv/Makefile
27+
+++ b/tools/hv/Makefile
28+
@@ -2,7 +2,7 @@
29+
# Makefile for Hyper-V tools
30+
include ../scripts/Makefile.include
31+
32+
-ARCH := $(shell uname -m 2>/dev/null)
33+
+ARCH ?= $(shell uname -m 2>/dev/null)
34+
sbindir ?= /usr/sbin
35+
libexecdir ?= /usr/libexec
36+
sharedstatedir ?= /var/lib
37+
@@ -20,7 +20,7 @@ override CFLAGS += -O2 -Wall -g -D_GNU_SOURCE -I$(OUTPUT)include
38+
override CFLAGS += -Wno-address-of-packed-member
39+
40+
ALL_TARGETS := hv_kvp_daemon hv_vss_daemon
41+
-ifneq ($(ARCH), aarch64)
42+
+ifneq ($(filter x86_64 x86,$(ARCH)),)
43+
ALL_TARGETS += hv_fcopy_uio_daemon
44+
endif
45+
ALL_PROGRAMS := $(patsubst %,$(OUTPUT)%,$(ALL_TARGETS))

0 commit comments

Comments
 (0)