On 26.06.2020 15:59, Ross Lagerwall wrote: > On 2020-06-26 13:24, Andrew Cooper wrote: >> @@ -56,18 +57,48 @@ int arch_livepatch_safety_check(void) >> return -EBUSY; >> } >> >> -int arch_livepatch_quiesce(void) >> +int noinline arch_livepatch_quiesce(void) >> { >> + /* If Shadow Stacks are in use, disable CR4.CET so we can modify >> CR0.WP. */ >> + if ( cpu_has_xen_shstk ) > > Should this be: > if ( IS_ENABLED(CONFIG_XEN_SHSTK) && cpu_has_xen_shstk ) > > to match arch_livepatch_revive?
While it may look a little asymmetric, I think it's preferable to is IS_ENABLED() only where really needed, i.e. here it guarding code that otherwise may not build. Jan