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

Re: [Xen-devel] [PATCH v8] interrupts: allow guest to set/clear MSI-X mask bit

>>> On 04.09.13 at 20:07, Joby Poriyath <joby.poriyath@xxxxxxxxxx> wrote:
> Guest needs the ability to enable and disable MSI-X interrupts
> by setting the MSI-X control bit, for a passed-through device.
> Guest is allowed to write MSI-X mask bit only if Xen *thinks*
> that mask is clear (interrupts enabled). If the mask is set by
> Xen (interrupts disabled), writes to mask bit by the guest is
> ignored.
> Currently, a write to MSI-X mask bit by the guest is silently
> ignored.
> A likely scenario is where we have a 82599 SR-IOV nic passed
> through to a guest. From the guest if you do
>   ifconfig <ETH_DEV> down
>   ifconfig <ETH_DEV> up
> the interrupts remain masked. On VF reset, the mask bit is set
> by the controller. At this point, Xen is not aware that mask is set.
> However, interrupts are enabled by VF driver by clearing the mask
> bit by writing directly to BAR3 region containing the MSI-X table.
> From dom0, we can verify that
> interrupts are being masked using 'xl debug-keys M'.
> Initially, guest was allowed to modify MSI-X bit.
> Later this behaviour was changed.
> See changeset 74c213c506afcd74a8556dd092995fd4dc38b225.
> patch revision history
> ----------------------
> v1: Initial patch to allow guest writes to MSI-X control bit
> v2: retained the reserved bits while updating MSI-X control vector
>     (only 1 bit is defined)
> v3: Allow guest writes only when Xen view of MSI-X control bit is 0
> v4: Added a warning if Xen thinks MSI-X control bit is masked,
>     where in reality, it's not
> v5 & v6: Added const-correctness
> v7: Get msi_desc from the guest write 'address'
> v8: Added ASSERT and renamed m_desc to msi_desc

Looks good to me now - unless I hear otherwise from anyone I
would go and apply this as soon as the current backlog in the
staging tree cleared.


Xen-devel mailing list



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