From: Gavin Shan <gwshan@linux.vnet.ibm.com>
To: Yinghai Lu <yinghai@kernel.org>
Cc: "Benjamin Herrenschmidt" <benh@kernel.crashing.org>,
"Bjorn Helgaas" <bhelgaas@google.com>,
"Gavin Shan" <gwshan@linux.vnet.ibm.com>,
"Marek Kordík" <kordikmarek@gmail.com>,
"Alexey Voronkov" <zermond@gmail.com>,
"linux-pci@vger.kernel.org" <linux-pci@vger.kernel.org>,
"Linux Kernel Mailing List" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] PCI: Clear bridge MEM_64 flag if one child does not support it
Date: Tue, 9 Dec 2014 12:08:03 +1100 [thread overview]
Message-ID: <20141209010803.GA30604@shangw> (raw)
In-Reply-To: <CAE9FiQX-vMu5+Kr09ngr95WvtoZTUSL5R2+NiVFeiN6q-BXLLg@mail.gmail.com>
On Mon, Dec 08, 2014 at 03:59:54PM -0800, Yinghai Lu wrote:
>On Mon, Dec 8, 2014 at 2:56 PM, Benjamin Herrenschmidt
><benh@kernel.crashing.org> wrote:
>> On Mon, 2014-12-08 at 13:52 -0800, Yinghai Lu wrote:
>>> 2. or scan the children resource other than ROM to clear bridge MEM_64
>>> for mmio pref.
>>>
>>> The patch is using second way so will keep child mmio pref into bridge
>>> mmio pref range.
>>
>> That means that having a single ROM BAR that is 32-bit and prefetchable
>> will downgrade the entire window to 32-bit ? That's not going to work
>> either.
>
>the ROM BAR get skipped during the checking.
>
>+ if (i != PCI_ROM_RESOURCE)
>+ mem64_mask &= r->flags & IORESOURCE_MEM_64;
>+ }
>
>>
>> I have GPUs with 16G BARs for example... suddenly they don't fit
>> anaymore because we downgraded the window to 32 bit because somewhere
>> there's a 32-bit pref resource ?
>>
>> That will break more than it fixes...
>
>Please check if this patch break your platform. I tried on my setup on
>x86. and it is still
>working on 64 bit resource allocation.
>
Yinghai, With the patch, the Power8 machine boots up and have resources
assigned properly: 64-bits pref BARs are covered by 64-bits pref windows
and left memory BARs are covered by 32-bits non-pref windows. Note that
I didn't find an 32-bits-pref BAR on the system.
For SRIOV case, Richard still need test.
Thanks,
Gavin
>Thanks
>
>Yinghai
>
next prev parent reply other threads:[~2014-12-09 1:09 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-08 21:52 [PATCH] PCI: Clear bridge MEM_64 flag if one child does not support it Yinghai Lu
2014-12-08 22:56 ` Benjamin Herrenschmidt
2014-12-08 23:00 ` Benjamin Herrenschmidt
2014-12-09 0:09 ` Yinghai Lu
2014-12-09 21:39 ` Yinghai Lu
2014-12-08 23:59 ` Yinghai Lu
2014-12-09 0:11 ` Gavin Shan
2014-12-09 2:26 ` Wei Yang
2014-12-09 7:20 ` Yinghai Lu
2014-12-09 7:56 ` Wei Yang
2014-12-09 18:21 ` Bjorn Helgaas
2014-12-10 9:42 ` Wei Yang
2014-12-09 19:49 ` Yinghai Lu
2014-12-09 18:07 ` Marek Kordík
2014-12-09 18:22 ` Bjorn Helgaas
2014-12-09 19:42 ` Yinghai Lu
2014-12-09 22:15 ` Marek Kordík
2014-12-09 23:16 ` Yinghai Lu
2014-12-09 1:08 ` Gavin Shan [this message]
2014-12-09 1:38 ` Yinghai Lu
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=20141209010803.GA30604@shangw \
--to=gwshan@linux.vnet.ibm.com \
--cc=benh@kernel.crashing.org \
--cc=bhelgaas@google.com \
--cc=kordikmarek@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=yinghai@kernel.org \
--cc=zermond@gmail.com \
/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.