[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210326215516.GA916324@bjorn-Precision-5520>
Date: Fri, 26 Mar 2021 16:55:16 -0500
From: Bjorn Helgaas <helgaas@...nel.org>
To: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Cc: Heiner Kallweit <hkallweit1@...il.com>,
Bjorn Helgaas <bhelgaas@...gle.com>,
Jonathan Corbet <corbet@....net>, Jens Axboe <axboe@...nel.dk>,
Viresh Kumar <vireshk@...nel.org>,
Dan Williams <dan.j.williams@...el.com>,
Vinod Koul <vkoul@...nel.org>,
David Miller <davem@...emloft.net>,
Lee Jones <lee.jones@...aro.org>,
Ion Badulescu <ionut@...ula.org>,
Jakub Kicinski <kuba@...nel.org>,
Lino Sanfilippo <LinoSanfilippo@....de>,
Christian Lamparter <chunkeey@...glemail.com>,
Kalle Valo <kvalo@...eaurora.org>,
Luis Chamberlain <mcgrof@...nel.org>,
Adam Radford <aradford@...il.com>,
"James E.J. Bottomley" <jejb@...ux.ibm.com>,
"Martin K. Petersen" <martin.petersen@...cle.com>,
James Smart <james.smart@...adcom.com>,
Dick Kennedy <dick.kennedy@...adcom.com>,
Nilesh Javali <njavali@...vell.com>,
GR-QLogic-Storage-Upstream@...vell.com,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Jiri Slaby <jirislaby@...nel.org>,
Peter Chen <Peter.Chen@....com>,
Felipe Balbi <balbi@...nel.org>,
"linux-pci@...r.kernel.org" <linux-pci@...r.kernel.org>,
linux-doc@...r.kernel.org,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
linux-ide@...r.kernel.org, dmaengine@...r.kernel.org,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
linux-parisc@...r.kernel.org,
linux-wireless <linux-wireless@...r.kernel.org>,
SCSI development list <linux-scsi@...r.kernel.org>,
linux-serial@...r.kernel.org,
Linux USB Mailing List <linux-usb@...r.kernel.org>,
Randy Dunlap <rdunlap@...radead.org>,
Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: [PATCH] PCI: Remove pci_try_set_mwi
On Fri, Mar 26, 2021 at 11:42:46PM +0200, Andy Shevchenko wrote:
> On Fri, Mar 26, 2021 at 04:26:55PM -0500, Bjorn Helgaas wrote:
> > [+cc Randy, Andrew (though I'm sure you have zero interest in this
> > ancient question :))]
> >
> > On Wed, Dec 09, 2020 at 09:31:21AM +0100, Heiner Kallweit wrote:
> > > pci_set_mwi() and pci_try_set_mwi() do exactly the same, just that the
> > > former one is declared as __must_check. However also some callers of
> > > pci_set_mwi() have a comment that it's an optional feature. I don't
> > > think there's much sense in this separation and the use of
> > > __must_check. Therefore remove pci_try_set_mwi() and remove the
> > > __must_check attribute from pci_set_mwi().
> > > I don't expect either function to be used in new code anyway.
> >
> > There's not much I like better than removing things. But some
> > significant thought went into adding pci_try_set_mwi() in the first
> > place, so I need a little more convincing about why it's safe to
> > remove it.
> >
> > The argument should cite the discussion about adding it. I think one
> > of the earliest conversations is here:
> > https://lore.kernel.org/linux-ide/20070404213704.224128ec.randy.dunlap@oracle.com/
>
> It's solely PCI feature which is absent on PCIe.
>
> So, if there is a guarantee that the driver never services a device connected
> to old PCI bus, it's okay to remove the call (it's no-op on PCIe anyway).
Yes, I'm aware that MWI is a no-op on PCIe. If we want to argue that
we don't need to support Conventional PCI devices, that should be
explicit, and we could remove pci_set_mwi() completely. But I don't
think we're ready to drop Conventional PCI support.
> OTOH, PCI core may try MWI itself for every device (but this is an opposite,
> what should we do on broken devices that do change their state based on that
> bit while violating specification).
>
> In any case
>
> Acked-by: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Thanks!
Bjorn
Powered by blists - more mailing lists