added 'prototype' bus driver (Detrick Martin)

since this driver requires a parameter string upon initialization, the
API had to be extended for bus_new()
all other drivers need to follow the new function prototype


git-svn-id: https://urjtag.svn.sourceforge.net/svnroot/urjtag/trunk@914 b68d4a1b-bc3d-0410-92ed-d4ac073336b7
master
Arnim Läuger 17 years ago
parent 4ad3f1ae26
commit cb72f1c1da

@ -1,3 +1,33 @@
2008-01-08 Arnim Laeuger <arniml@users.sourceforge.net>
* src/bus/prototype.c: new prototype bus driver (Detrick Martin)
* src/bus/zefant-xs3.c (zefant_xs3_bus_new): API extension: cmd_params for new_bus()
* src/bus/sharc21065l.c (sharc_21065L_bus_new): API extension
* src/bus/jopcyc.c (jopcyc_bus_new): API extension
* src/bus/tx4925.c (tx4925_bus_new): API extension
* src/bus/slsup3.c (slsup3_bus_new): API extension
* src/bus/sh7751r.c (sh7751r_bus_new): API extension
* src/bus/sh7750r.c (sh7750r_bus_new): API extension
* src/bus/sh7727.c (sh7727_bus_new): API extension
* src/bus/s3c4510x.c (s3c4510_bus_new): API extension
* src/bus/sa1110.c (sa1110_bus_new): API extension
* src/bus/pxa2x0.c (pxa2x0_bus_new): API extension
(pxa27x_bus_new): API extension
* src/bus/ppc405ep.c (ppc405ep_bus_new): API extension
* src/bus/ppc440gx_ebc8.c (ppc440gx_ebc8_bus_new): API extension
* src/bus/mpc5200.c (mpc5200_bus_new): API extension
* src/bus/mpc824x.c (mpc824x_bus_new): API extension
* src/bus/lh7a400.c (lh7a400_bus_new): API extension
* src/bus/ixp425.c (ixp425_bus_new): API extension
* src/bus/bf533_ezkit.c (bf533_ezkit_bus_new): API extension
* src/bus/bf533_stamp.c (bf533_stamp_bus_new): API extension
* src/bus/ejtag.c (ejtag_bus_new): API extension
* src/bus/bcm1250.c (bcm1250_bus_new): API extension
* src/bus/au1500.c (au1500_bus_new): API extension
* src/bus/Makefile.am (libbus_a_SOURCES): added prototype.c
* src/bus/buses.c: added prototype_bus (Detrick Martin)
* src/cmd/initbus.c (cmd_initbus_run): hand down command parameters to bus_new()
2008-01-06 Arnim Laeuger <arniml@users.sourceforge.net>
* src/tap/cable/wiggler.c (wiggler_connect): enable bit<->pin mapping from parameter string

@ -5,6 +5,8 @@ Also see libbrux/NEWS for more news, especially regarding the flash support.
urjtag-n/a
* Integration of BSDL parser (Arnim Laeuger)
* New and updated bus drivers
- Prototype bus driver (Detrick Martin)
* New and updated cable drivers
- Vision EP9307 GPIO (Hartley Sweeten)
* Added new JTAG declarations for

@ -33,6 +33,7 @@ Guennadi Liakhovetski
Lesly A. M
Raphael Mack
Trevor Man
Detrick Martin
Andreas Mohr
Jani Monoses
Tony K Nadackal

@ -1,3 +1,7 @@
2008-01-08 Arnim Laeuger <arniml@users.sourceforge.net>
* brux/bus.h: new_bus gets command parameters to enable configuration from comamnd lien
2007-12-02 17:56 kawk
* openwince "include" package moved into "jtag" (now named "inclow")

@ -49,7 +49,7 @@ typedef struct bus bus_t;
typedef struct bus_driver {
const char *name;
const char *description;
bus_t *(*new_bus)( void );
bus_t *(*new_bus)( char *cmd_params[] );
void (*free_bus)( bus_t *bus );
void (*printinfo)( bus_t *bus );
void (*prepare)( bus_t *bus );

@ -39,6 +39,7 @@ libbus_a_SOURCES = \
mpc5200.c \
ppc440gx_ebc8.c \
ppc405ep.c \
prototype.c \
pxa2x0.c \
sa1110.c \
s3c4510x.c \

@ -114,7 +114,7 @@ setup_data( bus_t *bus, uint32_t d)
part_set_signal( p, RD[i], 1, ( d>>i ) & 1 );
}
static bus_t *au1500_bus_new(void)
static bus_t *au1500_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -268,7 +268,7 @@ bcm1250_bus_free( bus_t *bus )
free( bus );
}
static bus_t *bcm1250_bus_new( void );
static bus_t *bcm1250_bus_new( char *cmd_params[] );
const bus_driver_t bcm1250_bus = {
"bcm1250",
@ -287,7 +287,7 @@ const bus_driver_t bcm1250_bus = {
};
static bus_t *
bcm1250_bus_new( void )
bcm1250_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -252,7 +252,7 @@ bf533_ezkit_bus_free( bus_t *bus )
free( bus );
}
static bus_t *bf533_ezkit_bus_new( void );
static bus_t *bf533_ezkit_bus_new( char *cmd_params[] );
const bus_driver_t bf533_ezkit_bus = {
"bf533_ezkit",
@ -270,7 +270,7 @@ const bus_driver_t bf533_ezkit_bus = {
};
static bus_t *
bf533_ezkit_bus_new( void )
bf533_ezkit_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[15];

@ -252,7 +252,7 @@ bf533_stamp_bus_free( bus_t *bus )
free( bus );
}
static bus_t *bf533_stamp_bus_new( void );
static bus_t *bf533_stamp_bus_new( char *cmd_params[] );
const bus_driver_t bf533_stamp_bus = {
"bf533_stamp",
@ -270,7 +270,7 @@ const bus_driver_t bf533_stamp_bus = {
};
static bus_t *
bf533_stamp_bus_new( void )
bf533_stamp_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[15];

@ -41,6 +41,7 @@ const bus_driver_t *bus_drivers[] = {
&mpc5200_bus,
&ppc440gx_ebc8_bus,
&ppc405ep_bus,
&prototype_bus,
&pxa2x0_bus,
&pxa27x_bus,
&s3c4510_bus,

@ -36,6 +36,7 @@ extern const bus_driver_t mpc824x_bus;
extern const bus_driver_t mpc5200_bus;
extern const bus_driver_t ppc440gx_ebc8_bus;
extern const bus_driver_t ppc405ep_bus;
extern const bus_driver_t prototype_bus;
extern const bus_driver_t pxa2x0_bus;
extern const bus_driver_t pxa27x_bus;
extern const bus_driver_t s3c4510_bus;

@ -449,7 +449,7 @@ ejtag_bus_free( bus_t *bus )
free( bus );
}
static bus_t *ejtag_bus_new( void );
static bus_t *ejtag_bus_new( char *cmd_params[] );
const bus_driver_t ejtag_bus = {
"ejtag",
@ -467,7 +467,7 @@ const bus_driver_t ejtag_bus = {
};
static bus_t *
ejtag_bus_new( void )
ejtag_bus_new( char *cmd_params[] )
{
bus_t *bus;

@ -231,7 +231,7 @@ ixp425_bus_free( bus_t *bus )
free( bus );
}
static bus_t *ixp425_bus_new( void );
static bus_t *ixp425_bus_new( char *cmd_params[] );
const bus_driver_t ixp425_bus = {
"ixp425",
@ -250,7 +250,7 @@ const bus_driver_t ixp425_bus = {
};
static bus_t *
ixp425_bus_new( void )
ixp425_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[15];

@ -500,7 +500,7 @@ attach_sig( bus_t *bus, signal_t **sig, char *id )
}
static bus_t *
jopcyc_bus_new( void )
jopcyc_bus_new( char *cmd_params[] )
{
bus_t *bus;
int failed = 0;

@ -257,7 +257,7 @@ lh7a400_bus_free( bus_t *bus )
free( bus );
}
static bus_t *lh7a400_bus_new( void );
static bus_t *lh7a400_bus_new( char *cmd_params[] );
const bus_driver_t lh7a400_bus = {
"lh7a400",
@ -276,7 +276,7 @@ const bus_driver_t lh7a400_bus = {
};
static bus_t *
lh7a400_bus_new( void )
lh7a400_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -243,7 +243,7 @@ mpc5200_bus_free( bus_t *bus )
}
static bus_t *
mpc5200_bus_new( void )
mpc5200_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -270,7 +270,7 @@ mpc824x_bus_free( bus_t *bus )
}
static bus_t *
mpc824x_bus_new( void )
mpc824x_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -216,7 +216,7 @@ ppc405ep_bus_free( bus_t *bus )
free( bus );
}
static bus_t *ppc405ep_bus_new( void );
static bus_t *ppc405ep_bus_new( char *cmd_params[] );
const bus_driver_t ppc405ep_bus = {
"ppc405ep",
@ -234,7 +234,7 @@ const bus_driver_t ppc405ep_bus = {
};
static bus_t *
ppc405ep_bus_new( void )
ppc405ep_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -214,7 +214,7 @@ ppc440gx_ebc8_bus_free( bus_t *bus )
free( bus );
}
static bus_t *ppc440gx_ebc8_bus_new( void );
static bus_t *ppc440gx_ebc8_bus_new( char *cmd_params[] );
const bus_driver_t ppc440gx_ebc8_bus = {
"ppc440gx_ebc8",
@ -233,7 +233,7 @@ const bus_driver_t ppc440gx_ebc8_bus = {
};
static bus_t *
ppc440gx_ebc8_bus_new( void )
ppc440gx_ebc8_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -606,8 +606,8 @@ pxa2xx_bus_free( bus_t *bus )
free( bus );
}
static bus_t *pxa2x0_bus_new( void );
static bus_t *pxa27x_bus_new( void );
static bus_t *pxa2x0_bus_new( char *cmd_params[] );
static bus_t *pxa27x_bus_new( char *cmd_params[] );
const bus_driver_t pxa2x0_bus = {
"pxa2x0",
@ -753,7 +753,7 @@ pxa2xx_bus_new_common(bus_t * bus)
}
static bus_t *
pxa2x0_bus_new( void )
pxa2x0_bus_new( char *cmd_params[] )
{
bus_t *bus;
int failed = 0;
@ -790,7 +790,7 @@ pxa2x0_bus_new( void )
}
static bus_t *
pxa27x_bus_new( void )
pxa27x_bus_new( char *cmd_params[] )
{
bus_t *bus;
int failed = 0;

@ -308,7 +308,7 @@ s3c4510_bus_free( bus_t *bus )
free( bus );
}
static bus_t *s3c4510_bus_new( void );
static bus_t *s3c4510_bus_new( char *cmd_params[] );
const bus_driver_t s3c4510_bus = {
"s3c4510x",
@ -327,7 +327,7 @@ const bus_driver_t s3c4510_bus = {
};
static bus_t *
s3c4510_bus_new( void )
s3c4510_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -245,7 +245,7 @@ sa1110_bus_free( bus_t *bus )
free( bus );
}
static bus_t *sa1110_bus_new( void );
static bus_t *sa1110_bus_new( char *cmd_params[] );
const bus_driver_t sa1110_bus = {
"sa1110",
@ -264,7 +264,7 @@ const bus_driver_t sa1110_bus = {
};
static bus_t *
sa1110_bus_new( void )
sa1110_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -277,7 +277,7 @@ sh7727_bus_free( bus_t *bus )
free( bus );
}
static bus_t *sh7727_bus_new( void );
static bus_t *sh7727_bus_new( char *cmd_params[] );
const bus_driver_t sh7727_bus = {
"sh7727",
@ -296,7 +296,7 @@ const bus_driver_t sh7727_bus = {
};
static bus_t *
sh7727_bus_new( void )
sh7727_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -259,7 +259,7 @@ sh7750r_bus_free( bus_t *bus )
free( bus );
}
static bus_t *sh7750r_bus_new( void );
static bus_t *sh7750r_bus_new( char *cmd_params[] );
const bus_driver_t sh7750r_bus = {
"sh7750r",
@ -278,7 +278,7 @@ const bus_driver_t sh7750r_bus = {
};
static bus_t *
sh7750r_bus_new( void )
sh7750r_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -252,7 +252,7 @@ sh7751r_bus_free( bus_t *bus )
free( bus );
}
static bus_t *sh7751r_bus_new( void );
static bus_t *sh7751r_bus_new( char *cmd_params[] );
const bus_driver_t sh7751r_bus = {
"sh7751r",
@ -271,7 +271,7 @@ const bus_driver_t sh7751r_bus = {
};
static bus_t *
sh7751r_bus_new( void )
sh7751r_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -258,7 +258,7 @@ static void sharc_21065L_bus_free( bus_t *bus )
free( bus );
}
static bus_t *sharc_21065L_bus_new( void );
static bus_t *sharc_21065L_bus_new( char *cmd_params[] );
const bus_driver_t sharc_21065L_bus = {
"SHARC_21065L",
@ -276,7 +276,7 @@ const bus_driver_t sharc_21065L_bus = {
};
static bus_t *sharc_21065L_bus_new( void )
static bus_t *sharc_21065L_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[15];

@ -356,7 +356,7 @@ slsup3_bus_free( bus_t *bus )
}
static bus_t *
slsup3_bus_new( void )
slsup3_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[10];

@ -249,7 +249,7 @@ tx4925_bus_free( bus_t *bus )
free( bus );
}
static bus_t *tx4925_bus_new( void );
static bus_t *tx4925_bus_new( char *cmd_params[] );
const bus_driver_t tx4925_bus = {
"tx4925",
@ -269,7 +269,7 @@ const bus_driver_t tx4925_bus = {
static bus_t *
tx4925_bus_new( void )
tx4925_bus_new( char *cmd_params[] )
{
bus_t *bus;
char buff[15];

@ -723,7 +723,7 @@ attach_sig( bus_t *bus, signal_t **sig, char *id )
}
static bus_t *
zefant_xs3_bus_new( void )
zefant_xs3_bus_new( char *cmd_params[] )
{
bus_t *bus;
int failed = 0;

@ -36,7 +36,7 @@ cmd_initbus_run( char *params[] )
{
int i;
if (cmd_params( params ) != 2)
if (cmd_params( params ) < 2)
return -1;
if (!cmd_test_cable())
@ -54,7 +54,7 @@ cmd_initbus_run( char *params[] )
for (i = 0; bus_drivers[i] != NULL; i++) {
if (strcasecmp( bus_drivers[i]->name, params[1] ) == 0) {
bus_t *bus = bus_drivers[i]->new_bus();
bus_t *bus = bus_drivers[i]->new_bus( params );
if (bus == NULL) {
printf( _("bus initialization failed!\n") );
return 1;

Loading…
Cancel
Save