diff mbox series

hdata/iohub: Use only wildcard slots for pluggables

Message ID 1512689298-9458-1-git-send-email-arbab@linux.vnet.ibm.com
State Accepted
Headers show
Series hdata/iohub: Use only wildcard slots for pluggables | expand

Commit Message

Reza Arbab Dec. 7, 2017, 11:28 p.m. UTC
From: Oliver O'Halloran <oohall@gmail.com>

We don't want to cause a VID:DID check against pluggable devices, as
they may use multiple devids.

Narrow the condition under which VID:DID is listed in the dt, so that
we'll end up creating a wildcard slot for these instead.

Cc: stable # 5.9.x
Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
Signed-off-by: Reza Arbab <arbab@linux.vnet.ibm.com>
---
 hdata/iohub.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Reza Arbab Feb. 12, 2018, 5:57 p.m. UTC | #1
On Thu, Dec 07, 2017 at 05:28:16PM -0600, Reza Arbab wrote:
>We don't want to cause a VID:DID check against pluggable devices, as
>they may use multiple devids.
>
>Narrow the condition under which VID:DID is listed in the dt, so that
>we'll end up creating a wildcard slot for these instead.

Ping! Could this go in?

It resolves an issue for us where the GPU-to-NVlink PCI bindings aren't 
created in systems with ES parts, which have a slightly different ID 
than QS parts, eg. 10de:1dbd instead of 10de:1db1.
Stewart Smith Feb. 21, 2018, 3:26 a.m. UTC | #2
Reza Arbab <arbab@linux.vnet.ibm.com> writes:
> On Thu, Dec 07, 2017 at 05:28:16PM -0600, Reza Arbab wrote:
>>We don't want to cause a VID:DID check against pluggable devices, as
>>they may use multiple devids.
>>
>>Narrow the condition under which VID:DID is listed in the dt, so that
>>we'll end up creating a wildcard slot for these instead.
>
> Ping! Could this go in?
>
> It resolves an issue for us where the GPU-to-NVlink PCI bindings aren't 
> created in systems with ES parts, which have a slightly different ID 
> than QS parts, eg. 10de:1dbd instead of 10de:1db1.

It can!

Merged to master as of 7a1f035b57ab83ec980c487a03c333e2bca8362c
and made it into -rc4.
diff mbox series

Patch

diff --git a/hdata/iohub.c b/hdata/iohub.c
index a5f12fd..2260f60 100644
--- a/hdata/iohub.c
+++ b/hdata/iohub.c
@@ -705,7 +705,7 @@  static void parse_one_slot(const struct slot_map_entry *entry,
 			st_name(type), vid, did);
 
 		/* The VID:DID is only meaningful for builtins and switches */
-		if (vid && did) {
+		if (type == st_sw_upstream && vid && did) {
 			node = dt_new_2addr(parent, st_name(type), vid, did);
 			dt_add_property_cells(node, "reg", vid, did);
 		} else {