Skip to content

Impossible to build the kernel #2

@platyman

Description

@platyman

I'm working in a proxmox virtual environment. It is impossible to build the kernel (fragvisor linux) . When I build with a linux kernel other than 4.4 (on ubuntu 22.04), the make -j $(nproc) command ends with an error:

arch/x86/kernel/head64.c: In function 'x86_64_start_kernel':
include/linux/compiler.h:484:45: error: call to '__compiletime_assert_158' declared with attribute error: BUILD_BUG_ON failed: __fix_to_virt(__end_of_fixed_addresses) <= MODULES_END
  484 | _compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)

And when I build on an ubuntu16.04 with a 4.4 kernel the build finishes fine but I get two errors:

arch/x86/kvm/svm.c: In the 'pf_interception' function :
arch/x86/kvm/svm.c:1633:7 : error : too few arguments to function 'kvm_mmu_page_fault'
   r = kvm_mmu_page_fault(&svm->vcpu, fault_address, error_code,
       ^
In the file included from include/linux/kvm_host.h:35:0,
                 from arch/x86/kvm/svm.c:17 :
./arch/x86/include/asm/kvm_host.h:1114:5: note: declared here
 int kvm_mmu_page_fault(struct kvm_vcpu *vcpu, gva_t gva, u32 error_code,
     ^
  CC arch/x86/purgatoire/kexec-purgatoire.o
scripts/Makefile.build:269: recipe failed for target 'arch/x86/kvm/svm.o'.
make[2]: *** [arch/x86/kvm/svm.o] Error 1
scripts/Makefile.build:476: recipe for target 'arch/x86/kvm' failed
make[1] : *** [arch/x86/kvm] Error 2
make[1]: *** Waiting for unfinished jobs....

And

include/linux/compiler.h:484:38: error: call to ‘__compiletime_assert_158’ declared with attribute error: BUILD_BUG_ON failed: __fix_to_virt(__end_of_fixed_addresses) <= MODULES_END
  _compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
                                      ^
include/linux/compiler.h:467:4: note: in definition of macro ‘__compiletime_assert’
    prefix ## suffix();    \
    ^
include/linux/compiler.h:484:2: note: in expansion of macro ‘_compiletime_assert’
  _compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
  ^
include/linux/bug.h:50:37: note: in expansion of macro ‘compiletime_assert’
 #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
                                     ^
include/linux/bug.h:74:2: note: in expansion of macro ‘BUILD_BUG_ON_MSG’
  BUILD_BUG_ON_MSG(condition, "BUILD_BUG_ON failed: " #condition)
  ^
arch/x86/kernel/head64.c:158:2: note: in expansion of macro ‘BUILD_BUG_ON’
  BUILD_BUG_ON(__fix_to_virt(__end_of_fixed_addresses) <= MODULES_END);

The compilation finished, but when I run the “sudo make modules_install” command, I get the following error:

  INSTALL arch/x86/crypto/aes-x86_64.ko
cp: cannot stat 'arch/x86/crypto/aes-x86_64.ko': No such file or directory
At main.c:255:
- SSL error:02001002:system library:fopen:No such file or directory: bss_file.c:175
- SSL error:2006D080:BIO routines:BIO_new_file:no such file: bss_file.c:178
sign-file: /lib/modules/4.4.137+/kernel/arch/x86/crypto/aes-x86_64.ko: No such file or directory
scripts/Makefile.modinst:35: recipe for target 'arch/x86/crypto/aes-x86_64.ko' failed
make[1]: *** [arch/x86/crypto/aes-x86_64.ko] Error 1
Makefile:1157: recipe for target '_modinst_' failed
make: *** [_modinst_] Error 2

Would it be possible to know on which operating system the tool has been tested (if that's what's causing the problem) or how to resolve these errors (if the problem lies elsewhere). Thank you for your attention.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions