|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v4 5/6] xen/x86: add PHYSDEVOP_msi_set_enable
On Thu, Feb 28, 2019 at 03:58:37AM -0700, Jan Beulich wrote:
> >>> On 27.02.19 at 16:05, <marmarek@xxxxxxxxxxxxxxxxxxxxxx> wrote:
> > On Wed, Feb 27, 2019 at 04:41:37AM -0700, Jan Beulich wrote:
> >> >>> On 07.02.19 at 01:07, <marmarek@xxxxxxxxxxxxxxxxxxxxxx> wrote:
> >> > +int msi_msix_set_enable(struct pci_dev *pdev, int mode, int enable)
> >> > +{
> >> > + int ret;
> >> > +
> >> > + ret = xsm_msi_set_enable(XSM_DM_PRIV, pdev->domain,
> >> > + (pdev->seg << 16) | (pdev->bus << 8) |
> >> > pdev->devfn,
> >> > + mode, enable);
> >> > + if ( ret )
> >> > + return ret;
> >> > +
> >> > + switch ( mode )
> >> > + {
> >> > + case PHYSDEVOP_MSI_SET_ENABLE_MSI:
> >> > + msi_set_enable(pdev, enable);
> >> > + break;
> >> > +
> >> > + case PHYSDEVOP_MSI_SET_ENABLE_MSIX:
> >> > + msix_set_enable(pdev, enable);
> >> > + break;
> >> > + }
> >>
> >> What about a call to pci_intx()?
> >
> > Should pci_intx(dev, !enable) be called in all those cases?
>
> Well, that depends whether Dom0 is involved, which is where the
> operation would normally be done. But since this is about bypassing
> pciback, I think it may be needed.
Shouldn't that be done by device model itself? Or even on command from
the target domain? Automatically toggling INTx when manipulating MSI(-X)
seems wrong.
--
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
Attachment:
signature.asc _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |