mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-21 16:33:24 +00:00
Make if_tdx_enabled macro x86-specific
This commit is contained in:
committed by
Tate, Hongliang Tian
parent
dd67a9a175
commit
e4aa261c48
@ -76,11 +76,13 @@ unsafe fn init() {
|
||||
unsafe {
|
||||
mm::frame::allocator::init_early_allocator();
|
||||
}
|
||||
|
||||
if_tdx_enabled!({
|
||||
#[cfg(target_arch = "x86_64")]
|
||||
arch::if_tdx_enabled!({
|
||||
} else {
|
||||
arch::serial::init();
|
||||
});
|
||||
#[cfg(not(target_arch = "x86_64"))]
|
||||
arch::serial::init();
|
||||
|
||||
logger::init();
|
||||
|
||||
@ -107,7 +109,8 @@ unsafe fn init() {
|
||||
|
||||
unsafe { arch::late_init_on_bsp() };
|
||||
|
||||
if_tdx_enabled!({
|
||||
#[cfg(target_arch = "x86_64")]
|
||||
arch::if_tdx_enabled!({
|
||||
arch::serial::init();
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user