[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YrOea1PQbSA09A6r@iweiny-desk3>
Date: Wed, 22 Jun 2022 15:57:47 -0700
From: Ira Weiny <ira.weiny@...el.com>
To: Jonathan Cameron <Jonathan.Cameron@...wei.com>
CC: Dan Williams <dan.j.williams@...el.com>,
Bjorn Helgaas <bhelgaas@...gle.com>,
Alison Schofield <alison.schofield@...el.com>,
"Vishal Verma" <vishal.l.verma@...el.com>,
Dave Jiang <dave.jiang@...el.com>,
"Ben Widawsky" <bwidawsk@...nel.org>,
<linux-kernel@...r.kernel.org>, <linux-cxl@...r.kernel.org>,
<linux-pci@...r.kernel.org>
Subject: Re: [PATCH V11 3/8] PCI: Create PCI library functions in support of
DOE mailboxes.
On Mon, Jun 20, 2022 at 11:23:28AM +0100, Jonathan Cameron wrote:
> On Fri, 17 Jun 2022 15:56:38 -0700
> Dan Williams <dan.j.williams@...el.com> wrote:
>
[snip]
> > > +static int pci_doe_enable_irq(struct pci_doe_mb *doe_mb, unsigned int irq)
> > > +{
> > > + struct pci_dev *pdev = doe_mb->pdev;
> > > + int offset = doe_mb->cap_offset;
> > > + int rc;
> > > +
> > > + /*
> > > + * Enabling bus mastering is required for MSI/MSIx. It is safe to call
> > > + * this multiple times and thus is called here to ensure that mastering
> > > + * is enabled even if the driver has done so.
> > > + */
> >
> > It is required for MSI/MSIx to work, yes, but if the caller that created
> > the doe object has not set it yet that's its prerogative.
>
> We went around this in one of the earlier threads, and I think consensus
> was that it made sense to have this in core code.
Yes we did. This is where Bjorn asked for this to be done I thought.
I verified that pci_set_master() is fine to call more than one time. If the
caller asks for irq support I think it is fine to do this here to ensure that
support is enabled.
Ira
Powered by blists - more mailing lists