From 9cbb00f5dda058b43259c59558eadca9d955d57b Mon Sep 17 00:00:00 2001 From: Marcel Telka Date: Mon, 26 Aug 2002 19:29:47 +0000 Subject: [PATCH] Added idr field to the part. git-svn-id: https://urjtag.svn.sourceforge.net/svnroot/urjtag/trunk@109 b68d4a1b-bc3d-0410-92ed-d4ac073336b7 --- include/jtag/part.h | 1 + jtag/src/part/parse.c | 4 +++- jtag/src/part/part.c | 4 ++++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/include/jtag/part.h b/include/jtag/part.h index 5941c06d..917200f1 100644 --- a/include/jtag/part.h +++ b/include/jtag/part.h @@ -40,6 +40,7 @@ struct part { instruction *active_instruction; int boundary_length; bsbit **bsbits; + tap_register *idr; tap_register *bsr; tap_register *prev_bsr; }; diff --git a/jtag/src/part/parse.c b/jtag/src/part/parse.c index 64658a81..5e809189 100644 --- a/jtag/src/part/parse.c +++ b/jtag/src/part/parse.c @@ -38,7 +38,7 @@ get_token( char *buf ) } part * -read_part( FILE *f ) +read_part( FILE *f, tap_register *idr ) { int line = 0; part *part; @@ -52,6 +52,8 @@ read_part( FILE *f ) return NULL; } + part->idr = register_duplicate( idr ); + for (;;) { char *t; char buf[1024]; diff --git a/jtag/src/part/part.c b/jtag/src/part/part.c index a66a4876..2386159d 100644 --- a/jtag/src/part/part.c +++ b/jtag/src/part/part.c @@ -42,6 +42,7 @@ part_alloc( void ) p->active_instruction = NULL; p->boundary_length = 0; p->bsbits = NULL; + p->idr = NULL; p->bsr = NULL; p->prev_bsr = NULL; @@ -75,6 +76,9 @@ part_free( part *p ) bsbit_free( p->bsbits[i] ); free( p->bsbits ); + /* idr */ + register_free( p->idr ); + /* bsr */ register_free( p->bsr ); register_free( p->prev_bsr );