From: Mark Lord <mlord@pobox.com>
To: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Bjorn Helgaas <bhelgaas@google.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
Yinghai Lu <yinghai@kernel.org>, "Theodore Ts'o" <tytso@mit.edu>,
"linux-pci@vger.kernel.org" <linux-pci@vger.kernel.org>
Subject: Re: driver skip pci_set_master, fix it? No.
Date: Wed, 09 Apr 2014 09:08:48 -0400 [thread overview]
Message-ID: <53454660.5090603@pobox.com> (raw)
In-Reply-To: <1397011868.3671.94.camel@pasglop>
On 14-04-08 10:51 PM, Benjamin Herrenschmidt wrote:
> On Tue, 2014-04-08 at 17:18 -0400, Mark Lord wrote:
>>> I assume you're talking about the one added by cf3e1feba7f9 ("PCI:
>>> Workaround missing pci_set_master in pci drivers"), but as far as I
>>> can tell, it only calls pci_set_master() for *bridge* devices. What
>>> am I missing? Is pci_set_master() being called for your endpoint?
>>> What path is that?
>>
>> Yes, it is being called during execution of the _probe() function in my driver,
>> as evidenced by the annoying (and wrong) message it produces.
>>
>> Next time I've got the hardware at hand, I'll put a "dump_stack()" into there
>> to see the exact calling path.
>
> Note that one of the reason we want to do it early on bridges is that without it,
> we may also not get the PCIe error messages.
Sure, for bridges.
I'll get a stack trace later today, but what I suspect is happening
is that this multi-function card is being treated by the PCI layers
as a "bridge" for purposes of the multiple virtual functions it implements.
We will probably need to distinguish this kind of device from real bridges here.
--
Mark Lord
Real-Time Remedies Inc.
mlord@pobox.com
next prev parent reply other threads:[~2014-04-09 13:08 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-08 16:34 driver skip pci_set_master, fix it? No Mark Lord
2014-04-08 18:27 ` Bjorn Helgaas
2014-04-08 21:18 ` Mark Lord
2014-04-09 2:51 ` Benjamin Herrenschmidt
2014-04-09 13:08 ` Mark Lord [this message]
2014-04-09 14:12 ` Mark Lord
2014-04-09 14:18 ` Mark Lord
2014-04-09 15:52 ` Bjorn Helgaas
2014-04-09 16:40 ` Mark Lord
2014-04-09 17:26 ` Bjorn Helgaas
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=53454660.5090603@pobox.com \
--to=mlord@pobox.com \
--cc=benh@kernel.crashing.org \
--cc=bhelgaas@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=tytso@mit.edu \
--cc=yinghai@kernel.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;
as well as URLs for NNTP newsgroup(s).