diff --git a/ext2spice/ext2hier.c b/ext2spice/ext2hier.c index 390937e0..e5a23549 100644 --- a/ext2spice/ext2hier.c +++ b/ext2spice/ext2hier.c @@ -1683,8 +1683,18 @@ esMakePorts(hc, cdata) if (nn->efnn_node && !(nn->efnn_node->efnode_flags & EF_PORT)) { - nn->efnn_node->efnode_flags |= EF_PORT; - nn->efnn_port = -1; // Will be sorted later + /* If a node is marked EF_SUBS_NODE (is substrate) */ + /* but not EF_SUBS_PORT (connects to no devices) */ + /* and parasitic output is disabled, then do not */ + /* force the substrate connection to be a port. */ + + if ((EFCapThreshold != (EFCapValue)INFINITE_THRESHOLD_F) || + (!(nn->efnn_node->efnode_flags & EF_SUBS_NODE)) || + (nn->efnn_node->efnode_flags & EF_SUBS_PORT)) + { + nn->efnn_node->efnode_flags |= EF_PORT; + nn->efnn_port = -1; // Will be sorted later + } // Diagnostic // TxPrintf("Port connection in %s from net %s to net %s (%s)\n", diff --git a/extflat/EFbuild.c b/extflat/EFbuild.c index d8db412d..88281ea9 100644 --- a/extflat/EFbuild.c +++ b/extflat/EFbuild.c @@ -1844,6 +1844,8 @@ efNodeMerge(node1ptr, node2ptr) keeping->efnode_flags |= EF_PORT; if (removing->efnode_flags & EF_TOP_PORT) keeping->efnode_flags |= EF_TOP_PORT; + if (removing->efnode_flags & EF_SUBS_PORT) + keeping->efnode_flags |= EF_SUBS_PORT; /* * If "removing" has the EF_SUBS_NODE flag set, then copy the port