[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH v4 3/8] x86/domain: allocate d->{iomem,irq}_caps before arch-specific initialization
On Mon, Aug 04, 2025 at 12:20:11PM +0200, Jan Beulich wrote: > On 31.07.2025 21:21, dmkhn@xxxxxxxxx wrote: > > From: Denis Mukhin <dmukhin@xxxxxxxx> > > > > Move IRQ/IOMEM rangesets allocation before arch_domain_create(). > > > > That guarantees that arch-specific code could access those rangesets to > > register traps for emulation. > > > > It is necessary for those emulators registering trap handlers and ensuring > > that emulated IRQs are not shared with the physical IRQs. > > > > Move dom0_setup_permissions() call right after I/O rangesets are allocated. > > > > Move pvh_setup_mmcfg() inside dom0_setup_permissions() close to the place > > where MMCFG ranges are initialized. > > And this is just because you like doing so? I ask because first and foremost > I can't make the connection between this and the purpose of this patch. No, that is a bad leftover from the MMIO-based emulator. > > > --- a/xen/arch/x86/dom0_build.c > > +++ b/xen/arch/x86/dom0_build.c > > @@ -471,6 +471,24 @@ static void __init process_dom0_ioports_disable(struct > > domain *dom0) > > } > > } > > > > +static void __hwdom_init setup_mmcfg(struct domain *d) > > Why __hwdom_init when ... > > > @@ -480,6 +498,14 @@ int __init dom0_setup_permissions(struct domain *d) > > if ( pv_shim ) > > return 0; > > > > + /* > > + * MMCFG initialization must be performed before setting domain > > + * permissions, as the MCFG areas must not be part of the domain IOMEM > > + * accessible regions. > > + */ > > + if ( is_hvm_domain(d) ) > > + setup_mmcfg(d); > > ... the sole caller is __init? > > Jan
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |