On Tue, Oct 19, 2021 at 02:39:17PM +0200, Jan Beulich wrote:
> On 19.10.2021 12:40, Bertrand Marquis wrote:
> > --- a/xen/drivers/vpci/vpci.c
> > +++ b/xen/drivers/vpci/vpci.c
> > @@ -54,7 +54,7 @@ void vpci_remove_device(struct pci_dev *pdev)
> >      pdev->vpci = NULL;
> >  }
> >  
> > -int __hwdom_init vpci_add_handlers(struct pci_dev *pdev)
> > +int vpci_add_handlers(struct pci_dev *pdev)
> 
> A fundamental requirement when altering section attributes is to
> also check that all referenced entities are appropriately placed.
> Afaict this is not the case for __start_vpci_array[], and you'll
> need to also adjust linker scripts to deal with that.

Indeed, we need to just keep the CONFIG_LATE_HWDOM placement in
.rodata.

> Further
> you'd have to check that all functions referenced by that array
> aren't __hwdom_init. In taking an example (init_msi()) I'm
> actually surprised to find it's not marked __hwdom_init. So
> maybe all is fine as far as these are concerned.

My bad, I've forgot to mark the initializers used by
REGISTER_VPCI_INIT as __hwdom_init. I think there's no need for a
change there.

Thanks, Roger.

Reply via email to