public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
To: David Vrabel <david.vrabel@citrix.com>
Cc: Andrew Cooper <andrew.cooper3@citrix.com>,
	konrad@kernel.org, boris.ostrovsky@oracle.com,
	linux-kernel@vger.kernel.org, xen-devel@lists.xenproject.org
Subject: Re: [Xen-devel] [PATCH v3 1/7] xen-pciback: Document the various parameters and attributes in SysFS
Date: Wed, 9 Jul 2014 10:47:44 -0400	[thread overview]
Message-ID: <20140709144744.GC27881@laptop.dumpdata.com> (raw)
In-Reply-To: <53BD556F.10408@citrix.com>

On Wed, Jul 09, 2014 at 03:45:03PM +0100, David Vrabel wrote:
> On 09/07/14 15:25, Konrad Rzeszutek Wilk wrote:
> > On Wed, Jul 09, 2014 at 03:22:30PM +0100, Andrew Cooper wrote:
> >> On 09/07/14 15:13, Konrad Rzeszutek Wilk wrote:
> >>> On Wed, Jul 09, 2014 at 03:05:56PM +0100, Andrew Cooper wrote:
> >>>> On 09/07/14 14:59, Konrad Rzeszutek Wilk wrote:
> >>>>>>> +What:           /sys/bus/pci/drivers/pciback/irq_handler_state
> >>>>>>> +Date:           Oct 2011
> >>>>>>> +KernelVersion:  3.1
> >>>>>>> +Contact:        xen-devel@lists.xenproject.org
> >>>>>>> +Description:
> >>>>>>> +                An option to toggle Xen PCI back to acknowledge (or stop)
> >>>>>>> +                interrupts for the specific device regardless of whether the
> >>>>>>> +                device is shared, enabled, or on a level interrupt line.
> >>>>>>> +                Writing a string of DDDD:BB:DD.F will toggle the state.
> >>>>>>> +                This is Domain:Bus:Device.Function where domain is optional.
> >>>>>> I do not understand under what circumstances this should be used in.
> >>>>> So that dom0 does not disable the IRQ line as it would be getting the IRQs
> >>>>> for the guest as well (because the IRQ line is level and another guest
> >>>>> uses an PCI device that is using the same line).
> >>>> Why is this relevant?  Xen (and Xen alone) actually controls this aspect
> >>>> of interrupts.  Xen manages passing line level interrupts to any domain
> >>>> which might have a device hanging off a particular line, and has to wait
> >>>> until all domains have EOI'd the line until it can clear the interrupt
> >>>> at the IO-APIC.
> >>> Because Linux will think there is an IRQ storm as the event->IRQ points
> >>> to the default one. And then it will mask the event, which means dom0
> >>> will mask the PIRQ, and Xen will then also mask the IRQ.
> >>
> >> Xen will (and by this I mean 'should', and this was the behaviour last
> >> time I delved in there) only mask the IRQ if dom0 is the only consumer
> >> of these interrupts.
> >>
> >> For any PCIPassthrough, dom0 will get line interrupts for passed-through
> >> devices, but in this case pci-back should always handle the line
> >> interrupts so Linux doesn't block them as an IRQ storm.
> > 
> > And that is what it does - and this option provides the option to enable/disable
> > it the system admin wishes to do it.
> 
> I still don't understand why someone would want to flip the handler to
> a broken mode.

The intent was to allow you to flip to the 'enable' mode in case Linux
did not detect it correctly.
> 
> The original commit isn't very enlightening either.

Thoughts then on what this documentation patch should say to make it
clear of its intent?

> 
> David

  reply	other threads:[~2014-07-09 14:48 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-08 18:58 [PATCH] Xen PCIbackend support for slot and bus reset (v3) konrad
2014-07-08 18:58 ` [PATCH v3 1/7] xen-pciback: Document the various parameters and attributes in SysFS konrad
2014-07-08 18:18   ` [Xen-devel] " Andrew Cooper
2014-07-09 12:17   ` David Vrabel
2014-07-09 13:59     ` Konrad Rzeszutek Wilk
2014-07-09 14:05       ` Andrew Cooper
2014-07-09 14:13         ` Konrad Rzeszutek Wilk
2014-07-09 14:22           ` Andrew Cooper
2014-07-09 14:25             ` Konrad Rzeszutek Wilk
2014-07-09 14:45               ` David Vrabel
2014-07-09 14:47                 ` Konrad Rzeszutek Wilk [this message]
2014-07-09 14:57                   ` David Vrabel
2014-07-09 15:11                     ` Konrad Rzeszutek Wilk
2014-07-08 18:58 ` [PATCH v3 2/7] xen/pciback: Don't deadlock when unbinding konrad
2014-07-09 12:21   ` David Vrabel
2014-07-09 14:01     ` Konrad Rzeszutek Wilk
2014-07-08 18:58 ` [PATCH v3 3/7] xen/pciback: Move the FLR code to a function konrad
2014-07-08 18:58 ` [PATCH v3 4/7] xen/pciback: Implement PCI reset slot or bus with 'do_flr' SysFS attribute konrad
2014-07-08 18:02   ` David Vrabel
2014-07-08 18:46     ` Konrad Rzeszutek Wilk
2014-07-08 19:28       ` Konrad Rzeszutek Wilk
2014-07-09 12:32       ` David Vrabel
2014-07-09 14:11         ` [Xen-devel] " David Vrabel
2014-07-09 14:12         ` Konrad Rzeszutek Wilk
2014-07-09 14:26           ` David Vrabel
2014-07-09 15:07             ` Konrad Rzeszutek Wilk
2014-07-08 18:17   ` [Xen-devel] " Andrew Cooper
2014-07-08 18:58 ` [PATCH v3 5/7] xen/pciback: Include the domain id if removing the device whilst still in use konrad
2014-07-09 12:34   ` David Vrabel
2014-07-08 18:58 ` [PATCH v3 6/7] xen/pciback: Print out the domain owning the device konrad
2014-07-09 13:04   ` David Vrabel
2014-07-08 18:58 ` [PATCH v3 7/7] xen/pciback: Remove tons of dereferences konrad
2014-07-08 19:15 ` [Xen-devel] [PATCH] Xen PCIbackend support for slot and bus reset (v3) Sander Eikelenboom

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140709144744.GC27881@laptop.dumpdata.com \
    --to=konrad.wilk@oracle.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=boris.ostrovsky@oracle.com \
    --cc=david.vrabel@citrix.com \
    --cc=konrad@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=xen-devel@lists.xenproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox