Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F167879052
D19399.id54513.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
629 B
Referenced Files
None
Subscribers
None
D19399.id54513.diff
View Options
Index: sys/dev/cxgbe/t4_main.c
===================================================================
--- sys/dev/cxgbe/t4_main.c
+++ sys/dev/cxgbe/t4_main.c
@@ -1372,10 +1372,19 @@
static int
t4_child_location_str(device_t bus, device_t dev, char *buf, size_t buflen)
{
+ struct adapter *sc;
struct port_info *pi;
+ int i;
- pi = device_get_softc(dev);
- snprintf(buf, buflen, "port=%d", pi->port_id);
+ sc = device_get_softc(bus);
+ buf[0] = '\0';
+ for_each_port(sc, i) {
+ pi = sc->port[i];
+ if (pi != NULL && pi->dev == dev) {
+ snprintf(buf, buflen, "port=%d", pi->port_id);
+ break;
+ }
+ }
return (0);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Aug 26, 5:13 AM (22 h, 1 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
37269198
Default Alt Text
D19399.id54513.diff (629 B)
Attached To
Mode
D19399: Don't assume all children of a nexus are ports.
Attached
Detach File
Event Timeline
Log In to Comment