From: Yijing Wang <wangyijing@huawei.com>
To: Bjorn Helgaas <bhelgaas@google.com>, Keith Busch <keith.busch@intel.com>
Cc: "linux-pci@vger.kernel.org" <linux-pci@vger.kernel.org>,
Jordan Hargrave <Jordan_Hargrave@dell.com>,
Jon Mason <jon.mason@intel.com>, Jon Mason <jdmason@kudzu.us>
Subject: Re: [PATCH] PCI: update device mps when doing pci hotplug
Date: Thu, 25 Sep 2014 09:23:07 +0800 [thread overview]
Message-ID: <54236E7B.5000905@huawei.com> (raw)
In-Reply-To: <CAErSpo5upA7KYVo=_SvwJ9pdNot_5ENi3OtiPpuzZjpwj3ghPA@mail.gmail.com>
On 2014/9/25 7:30, Bjorn Helgaas wrote:
> On Wed, Sep 24, 2014 at 4:41 PM, Keith Busch <keith.busch@intel.com> wrote:
>> Just poking this thread to make sure it's not dead. :)
>>
>> I tested Yijing's proposal and it is successful on our Intel server
>> platforms; hoping either this or something that derives similar behavior
>> will be applied so we can remove bus tuning kernel parameters.
>>
>> Tested-by: Keith Busch <keith.busch@intel.com>
>
> Oops, thanks for poking me, because this was indeed dead.
>
> My main objection was to testing "is_hotplug_bridge". That doesn't
> seem right, because this issue really isn't specific to hotplug. I
> didn't see a resolution of that, but let me know if I missed it.
Why I introduced "is_hotplug_bridge" is to avoid to touch the MPS which is not
in hotplug case when pcie_bus_config == PCIE_BUS_TUNE_OFF.
It's so sad that PCIe spec doesn't give a detailed guide to configure MPS.
I'd like to refactor current MPS framework, but now there are still some puzzles
to me. I need to have a deeper understanding of pcie mps. I read Jon's mps patch
log from git, I found he turn off all this MPS config, because some issues were found
in some platforms, but no platforms detailed info and no bugzilla records.
>
> Bjorn
>
>> On Thu, 4 Sep 2014, Yijing Wang wrote:
>>>>>>>
>>>>>>> if (pcie_bus_config == PCIE_BUS_TUNE_OFF) {
>>>>>>> + pcie_bus_update_set(dev);
>>>>>>
>>>>>>
>>>>>> You're only adding this to the PCIE_BUS_TUNE_OFF path. Can't the same
>>>>>> problem occur for other pcie_bus_config settings?
>>>>>
>>>>>
>>>>> We only found the problem during PCIE_BUS_TUNE_OFF set. Other mode like
>>>>> PCIE_BUS_SAFE and PCIE_BUS_PEER2PEER.
>>>>> This issue won't happen.
>>>>
>>>>
>>>> Sorry, I can't parse this. Are you saying the problem won't happen in
>>>> the other modes? Why not?
>>>
>>>
>>> Hi Bjorn, when in PCIE_BUS_SAFE mode, pcie_find_smpss() will find the
>>> largest available mpss in a pcie path.
>>> Then call pcie_bus_configure_set() to set all devices' mps to the largest
>>> available mps in this path, so
>>> all devices in the path will have the same mps. When in
>>> PCIE_BUS_PEER2PEER, all devices' mps will be set to 128B
>>> for safety. And to the PCIE_BUS_PERFORMANCE mode, I found Jon's comment in
>>> pcie_write_mps(),
>>>
>>> /* For "Performance", the assumption is made that
>>> * downstream communication will never be larger
>>> than
>>> * the MRRS. So, the MPS only needs to be
>>> configured
>>> * for the upstream communication. This being the
>>> case, <------
>>> * walk from the top down and set the MPS of the
>>> child
>>> * to that of the parent bus.
>>>
>>> So I think the problem won't happen in other modes.
>>>
>>> Thanks!
>>> Yijing.
>>>
>>>
>>>>
>>>>>>> pcie_bus_detect_mps(dev);
>>>>>>> return 0;
>>>>>>> }
>>>>
>>>>
>>>> .
>>>>
>>>
>>>
>>> --
>>> Thanks!
>>> Yijing
>>>
>>>
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-pci" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
> .
>
--
Thanks!
Yijing
next prev parent reply other threads:[~2014-09-25 1:23 UTC|newest]
Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-29 8:17 [PATCH] PCI: update device mps when doing pci hotplug Yijing Wang
2014-07-29 16:18 ` Alex Williamson
2014-07-29 16:30 ` Keith Busch
2014-07-29 16:42 ` Alex Williamson
2014-07-29 19:04 ` Keith Busch
2014-07-30 3:35 ` Yijing Wang
2014-07-30 3:27 ` Yijing Wang
2014-07-30 3:33 ` Ethan Zhao
2014-07-30 3:42 ` Yijing Wang
2014-07-30 3:58 ` Ethan Zhao
2014-07-30 4:42 ` Yijing Wang
2014-07-30 6:26 ` Ethan Zhao
2014-07-30 6:57 ` Yijing Wang
2014-07-30 7:17 ` Ethan Zhao
2014-07-30 8:13 ` Yijing Wang
2014-07-30 8:38 ` Ethan Zhao
2014-07-30 9:17 ` Yijing Wang
2014-07-30 19:41 ` Jordan_Hargrave
2014-09-03 19:20 ` Bjorn Helgaas
2014-09-03 22:42 ` Bjorn Helgaas
2014-09-04 6:12 ` Yijing Wang
2014-09-04 13:16 ` Bjorn Helgaas
2014-09-05 1:27 ` Yijing Wang
2014-09-05 14:37 ` Keith Busch
2014-09-24 22:41 ` Keith Busch
2014-09-24 23:30 ` Bjorn Helgaas
2014-09-25 1:23 ` Yijing Wang [this message]
2014-09-25 16:46 ` Keith Busch
2014-09-26 3:22 ` Yijing Wang
2014-10-02 15:31 ` Jordan_Hargrave
-- strict thread matches above, loose matches on Subject: below --
2014-07-29 8:23 Yijing Wang
2013-02-05 3:55 Yijing Wang
2013-05-28 3:15 ` Yijing Wang
2013-07-29 23:33 ` Bjorn Helgaas
2013-07-30 3:20 ` Yijing Wang
2013-07-30 3:42 ` Bjorn Helgaas
2013-07-30 22:29 ` Bjorn Helgaas
2013-07-31 9:15 ` Yijing Wang
2013-07-31 17:53 ` Bjorn Helgaas
2013-07-31 20:42 ` Bjorn Helgaas
2013-08-01 1:23 ` Yijing Wang
2013-08-01 1:21 ` Yijing Wang
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=54236E7B.5000905@huawei.com \
--to=wangyijing@huawei.com \
--cc=Jordan_Hargrave@dell.com \
--cc=bhelgaas@google.com \
--cc=jdmason@kudzu.us \
--cc=jon.mason@intel.com \
--cc=keith.busch@intel.com \
--cc=linux-pci@vger.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.