intel / ccc-linux-guest-hardening

Linux Security Hardening for Confidential Compute
https://intel.github.io/ccc-linux-guest-hardening-docs
MIT License
65 stars 13 forks source link

TDX kernel doesn't compile on Ubuntu 18.04 #15

Closed Wenzel closed 1 year ago

Wenzel commented 2 years ago

While testing the new deployment in the CI on ubuntu 18.04: https://github.com/Wenzel/ccc-linux-guest-hardening/runs/6811995302?check_suite_focus=true#step:6:170

TASK [guest : Build TDX guest kernel] ******************************************
fatal: [localhost]: FAILED! => changed=false 
  cmd: /usr/bin/make --jobs=2
  msg: |-
    arch/x86/kernel/tdx.c:491:13: warning: ‘tdx_msr_is_context_switched’ defined but not used [-Wunused-function]
     static bool tdx_msr_is_context_switched(unsigned int msr)
                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~
    In file included from ./include/linux/printk.h:7:0,
                     from ./include/linux/kernel.h:19,
                     from arch/x86/kernel/kafl-agent.c:7:
    ./include/linux/kern_levels.h:5:18: error: initializer element is not constant
     #define KERN_SOH "\001"  /* ASCII Start Of Header */
                      ^
    ./include/linux/kern_levels.h:12:22: note: in expansion of macro ‘KERN_SOH’
     #define KERN_WARNING KERN_SOH "4" /* warning conditions */
                          ^~~~~~~~
    arch/x86/kernel/kafl-agent.c:835:28: note: in expansion of macro ‘KERN_WARNING’
     static int vprintk_level = KERN_WARNING[1];
                                ^~~~~~~~~~~~
    make[4]: *** [arch/x86/kernel/kafl-agent.o] Error 1
    make[3]: *** [arch/x86/kernel] Error 2
    make[3]: *** Waiting for unfinished jobs....
    make[2]: *** [arch/x86] Error 2
    make[2]: *** Waiting for unfinished jobs....
williamcroberts commented 1 year ago

Why even bother with 18.04, its essentially EOL? It's update cycle ends April 2023 and goes into extended security patches only.

Wenzel commented 1 year ago

It's an old issue, and I agree with you here, no need to fix this.