[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 3/5] xen/x86: introduce self modifying code test



On Wed, Nov 29, 2023 at 06:58:38PM -0800, Stefano Stabellini wrote:
> On Tue, 28 Nov 2023, Roger Pau Monne wrote:
> > Introduce a helper to perform checks related to self modifying code, and 
> > start
> > by creating a simple test to check that alternatives have been applied.
> > 
> > Such test is hooked into the boot process and called just after alternatives
> > have been applied.  In case of failure a message is printed, and the 
> > hypervisor
> > is tainted as not having passed the tests, this does require introducing a 
> > new
> > taint bit (printed as 'A').
> > 
> > A new sysctl is also introduced to run the tests on demand.  While there 
> > are no
> > current users introduced here, further changes will introduce those, and 
> > it's
> > helpful to have the interface defined in the sysctl header from the start.
> > 
> > Signed-off-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
> > ---
> > Changes since v1:
> >  - Rework test and interface.
> > ---
> >  tools/include/xenctrl.h             |  2 +
> >  tools/libs/ctrl/xc_misc.c           | 14 ++++++
> >  xen/arch/x86/Makefile               |  1 +
> >  xen/arch/x86/include/asm/test-smc.h | 18 ++++++++
> >  xen/arch/x86/setup.c                |  3 ++
> >  xen/arch/x86/sysctl.c               |  7 +++
> >  xen/arch/x86/test-smc.c             | 68 +++++++++++++++++++++++++++++
> 
> If possible, could we name this differently?

Wikipedia also suggests 'smoc' as an alternative acronym for
self-modifying code, would test-smoc be OK?

Thanks, Roger.



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.