p->cid, p->id, v, r, p->sr, p->a, p->dr);
}
-static int __ses_path_va_transistor(ScfEfunction* f, ses_path_t* path)
+static int __ses_path_va_transistor(ScfEfunction* f, ses_path_t* path, int* changed)
{
ses_path_t* parent = path->parent;
ses_path_t* child;
return 0;
}
-static int ses_path_va_transistor(ScfEfunction* f, ses_path_t* path)
+static int ses_path_va_transistor(ScfEfunction* f, ses_path_t* path, int* changed)
{
+ ses_path_t* child;
ScfEcomponent* B;
ScfEpin* p0;
ScfEpin* p1;
p0 = path->pins->data[0];
p1 = path->pins->data[path->pins->size - 1];
- int ret = __ses_path_va_transistor(f, path);
+ int ret = __ses_path_va_transistor(f, path, changed);
if (ret < 0)
return ret;
if (path->childs) {
for (j = 0; j < path->childs->size; j++) {
+ child = path->childs->data[j];
- ret = ses_path_va_transistor(f, path->childs->data[j]);
+ ret = ses_path_va_transistor(f, child, changed);
if (ret < 0)
return ret;
}
{
ses_path_t* path;
- size_t i;
+ int changed = 0;
+ int i;
for (i = 0; i < ctx->paths->size; i++) {
path = ctx->paths->data[i];
- scf_logi("i: %ld, path->type: %d\n", i, path->type);
+ scf_logi("i: %d, path->index: %d\n", i, path->index);
- int ret = ses_path_va_transistor(f, path);
+ int ret = ses_path_va_transistor(f, path, &changed);
if (ret < 0)
return ret;
printf("\n");
}
- return 0;
+ return changed > 0 ? -EAGAIN : 0;
}
ses_step_t ses_step_va_transistor =