This is an automated email from Gerrit. Spencer Oliver ([email protected]) just uploaded a new patch set to Gerrit, which you can find at http://openocd.zylin.com/2294
-- gerrit commit 4c8bdb5972eb19d12ab1f28a54bf330cf97a536f Author: Spencer Oliver <[email protected]> Date: Thu Sep 11 22:09:36 2014 +0100 jtag: constify driver arrays Change-Id: I81574fa8ca3cc748526dc61b75a2c75d6335ef04 Signed-off-by: Spencer Oliver <[email protected]> diff --git a/src/jtag/drivers/amt_jtagaccel.c b/src/jtag/drivers/amt_jtagaccel.c index 45f2d5c..5aacead 100644 --- a/src/jtag/drivers/amt_jtagaccel.c +++ b/src/jtag/drivers/amt_jtagaccel.c @@ -124,7 +124,7 @@ static const int data_mode = IEEE1284_MODE_EPP | IEEE1284_DATA; * 4: Shift-IR * 5: Pause-IR */ -static uint8_t amt_jtagaccel_tap_move[6][6][2] = { +static const uint8_t amt_jtagaccel_tap_move[6][6][2] = { /* RESET IDLE DRSHIFT DRPAUSE IRSHIFT IRPAUSE */ { {0x1f, 0x00}, {0x0f, 0x00}, {0x05, 0x00}, {0x0a, 0x00}, {0x06, 0x00}, {0x96, 0x00} }, /* RESET */ { {0x1f, 0x00}, {0x00, 0x00}, {0x04, 0x00}, {0x05, 0x00}, {0x06, 0x00}, {0x0b, 0x00} }, /* IDLE */ diff --git a/src/jtag/drivers/at91rm9200.c b/src/jtag/drivers/at91rm9200.c index f823ab6..19322f2 100644 --- a/src/jtag/drivers/at91rm9200.c +++ b/src/jtag/drivers/at91rm9200.c @@ -94,7 +94,7 @@ struct device_t { uint32_t SRST_MASK; /* SRST bitmask */ }; -static struct device_t devices[] = { +static const struct device_t devices[] = { { "rea_ecr", PIOD, P27, PIOA, NC, PIOD, P23, PIOD, P24, PIOD, P26, PIOC, P5 }, { .name = NULL }, }; @@ -104,7 +104,7 @@ static char *at91rm9200_device; /* interface variables */ -static struct device_t *device; +static const struct device_t *device; static int dev_mem_fd; static void *sys_controller; static uint32_t *pio_base; @@ -196,7 +196,7 @@ struct jtag_interface at91rm9200_interface = { static int at91rm9200_init(void) { - struct device_t *cur_device; + const struct device_t *cur_device; cur_device = devices; diff --git a/src/jtag/drivers/cmsis_dap_usb.c b/src/jtag/drivers/cmsis_dap_usb.c index b8f004c..8c96a17 100644 --- a/src/jtag/drivers/cmsis_dap_usb.c +++ b/src/jtag/drivers/cmsis_dap_usb.c @@ -137,7 +137,7 @@ static bool swd_mode; /* CMSIS-DAP Vendor Commands * None as yet... */ -static char *info_caps_str[] = { +static const char *info_caps_str[] = { "SWD Supported", "JTAG Supported" }; diff --git a/src/jtag/drivers/opendous.c b/src/jtag/drivers/opendous.c index 8bfaf0d..065aaf2 100644 --- a/src/jtag/drivers/opendous.c +++ b/src/jtag/drivers/opendous.c @@ -50,7 +50,7 @@ struct opendous_probe { int BUFFERSIZE; }; -static struct opendous_probe opendous_probes[] = { +static const struct opendous_probe opendous_probes[] = { {"usbprog-jtag", {0x1781, 0}, {0x0C63, 0}, 0x82, 0x02, 0x00, 510 }, {"opendous", {0x1781, 0x03EB, 0}, {0xC0C0, 0x204F, 0}, 0x81, 0x02, 0x00, 360 }, {"usbvlab", {0x16C0, 0}, {0x05DC, 0}, 0x81, 0x02, 0x01, 360 }, @@ -109,7 +109,7 @@ static struct pending_scan_result *pending_scan_results_buffer; #define FUNC_READ_DATA 0x51 static char *opendous_type; -static struct opendous_probe *opendous_probe; +static const struct opendous_probe *opendous_probe; /* External interface functions */ static int opendous_execute_queue(void); @@ -321,7 +321,7 @@ static int opendous_execute_queue(void) static int opendous_init(void) { int check_cnt; - struct opendous_probe *cur_opendous_probe; + const struct opendous_probe *cur_opendous_probe; cur_opendous_probe = opendous_probes; diff --git a/src/jtag/drivers/parport.c b/src/jtag/drivers/parport.c index 59c542c..8b1d500 100644 --- a/src/jtag/drivers/parport.c +++ b/src/jtag/drivers/parport.c @@ -74,7 +74,7 @@ struct cable { uint8_t LED_MASK; /* data port bit for LED */ }; -static struct cable cables[] = { +static const struct cable cables[] = { /* name tdo trst tms tck tdi srst o_inv i_inv init exit led */ { "wiggler", 0x80, 0x10, 0x02, 0x04, 0x08, 0x01, 0x01, 0x80, 0x80, 0x80, 0x00 }, { "wiggler2", 0x80, 0x10, 0x02, 0x04, 0x08, 0x01, 0x01, 0x80, 0x80, 0x00, 0x20 }, @@ -108,7 +108,7 @@ static int wait_states; /* interface variables */ -static struct cable *cable; +static const struct cable *cable; static uint8_t dataport_value; #if PARPORT_USE_PPDEV == 1 @@ -262,7 +262,7 @@ static struct bitbang_interface parport_bitbang = { static int parport_init(void) { - struct cable *cur_cable; + const struct cable *cur_cable; #if PARPORT_USE_PPDEV == 1 char buffer[256]; #endif -- ------------------------------------------------------------------------------ Want excitement? Manually upgrade your production database. When you want reliability, choose Perforce Perforce version control. Predictably reliable. http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk _______________________________________________ OpenOCD-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/openocd-devel
