Skip to content

[CIQ 6.12] Rebase to v6.12.23 #215

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 13 commits into from
Apr 17, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions .github/workflows/build-check_aarch64-64k-debug.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: aarch64-64k-debug CI
on:
pull_request:
branches:
- '**'
- '!mainline'

jobs:
kernel-build-job:
runs-on:
labels: kernel-build-arm64
container:
image: rockylinux:9
env:
ROCKY_ENV: rocky9
ports:
- 80
options: --cpus 8
steps:
- name: Install tools and Libraries
run: |
dnf groupinstall 'Development Tools' -y
dnf install --enablerepo=crb bc dwarves kernel-devel openssl-devel elfutils-libelf-devel -y
- name: Checkout code
uses: actions/checkout@v4
with:
ref: "${{ github.event.pull_request.head.sha }}"
fetch-depth: 0
- name: Build the Kernel
run: |
git config --global --add safe.directory /__w/kernel-src-tree/kernel-src-tree
cp ciq/configs/kernel-aarch64-64k-debug.config .config
make olddefconfig
make -j$(nproc)
34 changes: 34 additions & 0 deletions .github/workflows/build-check_aarch64-64k.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: aarch64-64k CI
on:
pull_request:
branches:
- '**'
- '!mainline'

jobs:
kernel-build-job:
runs-on:
labels: kernel-build-arm64
container:
image: rockylinux:9
env:
ROCKY_ENV: rocky9
ports:
- 80
options: --cpus 8
steps:
- name: Install tools and Libraries
run: |
dnf groupinstall 'Development Tools' -y
dnf install --enablerepo=crb bc dwarves kernel-devel openssl-devel elfutils-libelf-devel -y
- name: Checkout code
uses: actions/checkout@v4
with:
ref: "${{ github.event.pull_request.head.sha }}"
fetch-depth: 0
- name: Build the Kernel
run: |
git config --global --add safe.directory /__w/kernel-src-tree/kernel-src-tree
cp ciq/configs/kernel-aarch64-64k.config .config
make olddefconfig
make -j$(nproc)
34 changes: 34 additions & 0 deletions .github/workflows/build-check_aarch64-debug.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: aarch64-debug CI
on:
pull_request:
branches:
- '**'
- '!mainline'

jobs:
kernel-build-job:
runs-on:
labels: kernel-build-arm64
container:
image: rockylinux:9
env:
ROCKY_ENV: rocky9
ports:
- 80
options: --cpus 8
steps:
- name: Install tools and Libraries
run: |
dnf groupinstall 'Development Tools' -y
dnf install --enablerepo=crb bc dwarves kernel-devel openssl-devel elfutils-libelf-devel -y
- name: Checkout code
uses: actions/checkout@v4
with:
ref: "${{ github.event.pull_request.head.sha }}"
fetch-depth: 0
- name: Build the Kernel
run: |
git config --global --add safe.directory /__w/kernel-src-tree/kernel-src-tree
cp ciq/configs/kernel-aarch64-debug.config .config
make olddefconfig
make -j$(nproc)
34 changes: 34 additions & 0 deletions .github/workflows/build-check_aarch64.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: aarch64 CI
on:
pull_request:
branches:
- '**'
- '!mainline'

jobs:
kernel-build-job:
runs-on:
labels: kernel-build-arm64
container:
image: rockylinux:9
env:
ROCKY_ENV: rocky9
ports:
- 80
options: --cpus 8
steps:
- name: Install tools and Libraries
run: |
dnf groupinstall 'Development Tools' -y
dnf install --enablerepo=crb bc dwarves kernel-devel openssl-devel elfutils-libelf-devel -y
- name: Checkout code
uses: actions/checkout@v4
with:
ref: "${{ github.event.pull_request.head.sha }}"
fetch-depth: 0
- name: Build the Kernel
run: |
git config --global --add safe.directory /__w/kernel-src-tree/kernel-src-tree
cp ciq/configs/kernel-aarch64.config .config
make olddefconfig
make -j$(nproc)
34 changes: 34 additions & 0 deletions .github/workflows/build-check_x86_64-debug.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: x86_64-debug CI
on:
pull_request:
branches:
- '**'
- '!mainline'

jobs:
kernel-build-job:
runs-on:
labels: kernel-build
container:
image: rockylinux:9
env:
ROCKY_ENV: rocky9
ports:
- 80
options: --cpus 8
steps:
- name: Install tools and Libraries
run: |
dnf groupinstall 'Development Tools' -y
dnf install --enablerepo=crb bc dwarves kernel-devel openssl-devel elfutils-libelf-devel -y
- name: Checkout code
uses: actions/checkout@v4
with:
ref: "${{ github.event.pull_request.head.sha }}"
fetch-depth: 0
- name: Build the Kernel
run: |
git config --global --add safe.directory /__w/kernel-src-tree/kernel-src-tree
cp ciq/configs/kernel-x86_64-debug.config .config
make olddefconfig
make -j$(nproc)
34 changes: 34 additions & 0 deletions .github/workflows/build-check_x86_64.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: x86_64 CI
on:
pull_request:
branches:
- '**'
- '!mainline'

jobs:
kernel-build-job:
runs-on:
labels: kernel-build
container:
image: rockylinux:9
env:
ROCKY_ENV: rocky9
ports:
- 80
options: --cpus 8
steps:
- name: Install tools and Libraries
run: |
dnf groupinstall 'Development Tools' -y
dnf install --enablerepo=crb bc dwarves kernel-devel openssl-devel elfutils-libelf-devel -y
- name: Checkout code
uses: actions/checkout@v4
with:
ref: "${{ github.event.pull_request.head.sha }}"
fetch-depth: 0
- name: Build the Kernel
run: |
git config --global --add safe.directory /__w/kernel-src-tree/kernel-src-tree
cp ciq/configs/kernel-x86_64.config .config
make olddefconfig
make -j$(nproc)
40 changes: 22 additions & 18 deletions arch/x86/include/asm/irqflags.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,28 @@ static __always_inline void native_local_irq_restore(unsigned long flags)

#endif

#ifndef CONFIG_PARAVIRT
#ifndef __ASSEMBLY__
/*
* Used in the idle loop; sti takes one instruction cycle
* to complete:
*/
static __always_inline void arch_safe_halt(void)
{
native_safe_halt();
}

/*
* Used when interrupts are already enabled or to
* shutdown the processor:
*/
static __always_inline void halt(void)
{
native_halt();
}
#endif /* __ASSEMBLY__ */
#endif /* CONFIG_PARAVIRT */

#ifdef CONFIG_PARAVIRT_XXL
#include <asm/paravirt.h>
#else
Expand All @@ -97,24 +119,6 @@ static __always_inline void arch_local_irq_enable(void)
native_irq_enable();
}

/*
* Used in the idle loop; sti takes one instruction cycle
* to complete:
*/
static __always_inline void arch_safe_halt(void)
{
native_safe_halt();
}

/*
* Used when interrupts are already enabled or to
* shutdown the processor:
*/
static __always_inline void halt(void)
{
native_halt();
}

/*
* For spinlocks, etc:
*/
Expand Down
20 changes: 10 additions & 10 deletions arch/x86/include/asm/paravirt.h
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,16 @@ static inline void notify_page_enc_status_changed(unsigned long pfn,
PVOP_VCALL3(mmu.notify_page_enc_status_changed, pfn, npages, enc);
}

static __always_inline void arch_safe_halt(void)
{
PVOP_VCALL0(irq.safe_halt);
}

static inline void halt(void)
{
PVOP_VCALL0(irq.halt);
}

#ifdef CONFIG_PARAVIRT_XXL
static inline void load_sp0(unsigned long sp0)
{
Expand Down Expand Up @@ -170,16 +180,6 @@ static inline void __write_cr4(unsigned long x)
PVOP_VCALL1(cpu.write_cr4, x);
}

static __always_inline void arch_safe_halt(void)
{
PVOP_VCALL0(irq.safe_halt);
}

static inline void halt(void)
{
PVOP_VCALL0(irq.halt);
}

extern noinstr void pv_native_wbinvd(void);

static __always_inline void wbinvd(void)
Expand Down
3 changes: 1 addition & 2 deletions arch/x86/include/asm/paravirt_types.h
Original file line number Diff line number Diff line change
Expand Up @@ -122,10 +122,9 @@ struct pv_irq_ops {
struct paravirt_callee_save save_fl;
struct paravirt_callee_save irq_disable;
struct paravirt_callee_save irq_enable;

#endif
void (*safe_halt)(void);
void (*halt)(void);
#endif
} __no_randomize_layout;

struct pv_mmu_ops {
Expand Down
14 changes: 8 additions & 6 deletions arch/x86/kernel/paravirt.c
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,11 @@ int paravirt_disable_iospace(void)
return request_resource(&ioport_resource, &reserve_ioports);
}

static noinstr void pv_native_safe_halt(void)
{
native_safe_halt();
}

#ifdef CONFIG_PARAVIRT_XXL
static noinstr void pv_native_write_cr2(unsigned long val)
{
Expand All @@ -120,11 +125,6 @@ noinstr void pv_native_wbinvd(void)
{
native_wbinvd();
}

static noinstr void pv_native_safe_halt(void)
{
native_safe_halt();
}
#endif

struct pv_info pv_info = {
Expand Down Expand Up @@ -182,9 +182,11 @@ struct paravirt_patch_template pv_ops = {
.irq.save_fl = __PV_IS_CALLEE_SAVE(pv_native_save_fl),
.irq.irq_disable = __PV_IS_CALLEE_SAVE(pv_native_irq_disable),
.irq.irq_enable = __PV_IS_CALLEE_SAVE(pv_native_irq_enable),
#endif /* CONFIG_PARAVIRT_XXL */

/* Irq HLT ops. */
.irq.safe_halt = pv_native_safe_halt,
.irq.halt = native_halt,
#endif /* CONFIG_PARAVIRT_XXL */

/* Mmu ops. */
.mmu.flush_tlb_user = native_flush_tlb_local,
Expand Down
16 changes: 2 additions & 14 deletions arch/x86/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -904,6 +904,8 @@ void __init setup_arch(char **cmdline_p)
if (efi_enabled(EFI_BOOT))
efi_init();

efi_set_secure_boot(boot_params.secure_boot);

reserve_ibft_region();
x86_init.resources.dmi_setup();

Expand Down Expand Up @@ -1070,20 +1072,6 @@ void __init setup_arch(char **cmdline_p)
/* Allocate bigger log buffer */
setup_log_buf(1);

if (efi_enabled(EFI_BOOT)) {
switch (boot_params.secure_boot) {
case efi_secureboot_mode_disabled:
pr_info("Secure boot disabled\n");
break;
case efi_secureboot_mode_enabled:
pr_info("Secure boot enabled\n");
break;
default:
pr_info("Secure boot could not be determined\n");
break;
}
}

reserve_initrd();

acpi_table_upgrade();
Expand Down
Loading