- remove target specific variant and use target->variant member
[fw/openocd] / src / jtag / presto.c
index 21f80f00a1d90fe31198d872429122379f1d4b33..0e532817fc4453f7704b761ac09ae312182b9cf9 100644 (file)
@@ -49,7 +49,6 @@
 #error "BUG: either FTD2XX and LIBFTDI has to be used"
 #endif
 
-
 int presto_jtag_speed(int speed);
 int presto_jtag_khz(int khz, int *jtag_speed);
 int presto_jtag_speed_div(int speed, int *khz);
@@ -69,7 +68,6 @@ jtag_interface_t presto_interface =
        .quit = presto_jtag_quit,
 };
 
-
 int presto_bitq_out(int tms, int tdi, int tdo_req);
 int presto_bitq_flush(void);
 int presto_bitq_sleep(unsigned long us);
@@ -87,10 +85,8 @@ bitq_interface_t presto_bitq =
        .in = presto_bitq_in,
 };
 
-
 /* -------------------------------------------------------------------------- */
 
-
 #define FT_DEVICE_NAME_LEN 64
 #define FT_DEVICE_SERNUM_LEN 64
 
@@ -486,7 +482,6 @@ int presto_close(void)
        return result;
 }
 
-
 int presto_flush(void)
 {
        if (presto->buff_out_pos == 0)
@@ -530,7 +525,6 @@ int presto_flush(void)
        return ERROR_OK;
 }
 
-
 int presto_sendbyte(int data)
 {
        if (data == EOF) return presto_flush();
@@ -555,7 +549,6 @@ int presto_sendbyte(int data)
        return ERROR_OK;
 }
 
-
 int presto_getbyte(void)
 {
        if (presto->buff_in_pos < presto->buff_in_len)
@@ -573,10 +566,8 @@ int presto_getbyte(void)
        return -1;
 }
 
-
 /* -------------------------------------------------------------------------- */
 
-
 int presto_tdi_flush(void)
 {
        if (presto->jtag_tdi_count == 0)
@@ -596,7 +587,6 @@ int presto_tdi_flush(void)
        return 0;
 }
 
-
 int presto_tck_idle(void)
 {
        if (presto->jtag_tck == 1)
@@ -608,10 +598,8 @@ int presto_tck_idle(void)
        return 0;
 }
 
-
 /* -------------------------------------------------------------------------- */
 
-
 int presto_bitq_out(int tms, int tdi, int tdo_req)
 {
        int i;
@@ -658,7 +646,6 @@ int presto_bitq_out(int tms, int tdi, int tdo_req)
        return 0;
 }
 
-
 int presto_bitq_flush(void)
 {
        presto_tdi_flush();
@@ -669,7 +656,6 @@ int presto_bitq_flush(void)
        return presto_flush();
 }
 
-
 int presto_bitq_in_rdy(void)
 {
        if (presto->buff_in_pos>=presto->buff_in_len)
@@ -677,7 +663,6 @@ int presto_bitq_in_rdy(void)
        return presto->buff_in_len-presto->buff_in_pos;
 }
 
-
 int presto_bitq_in(void)
 {
        if (presto->buff_in_pos>=presto->buff_in_len)
@@ -686,7 +671,6 @@ int presto_bitq_in(void)
        return 0;
 }
 
-
 int presto_bitq_sleep(unsigned long us)
 {
        long waits;
@@ -708,7 +692,6 @@ int presto_bitq_sleep(unsigned long us)
        return 0;
 }
 
-
 int presto_bitq_reset(int trst, int srst)
 {
        presto_tdi_flush();
@@ -724,10 +707,8 @@ int presto_bitq_reset(int trst, int srst)
        return 0;
 }
 
-
 /* -------------------------------------------------------------------------- */
 
-
 int presto_jtag_khz(int khz, int *jtag_speed)
 {
        if (khz < 0)
@@ -742,7 +723,6 @@ int presto_jtag_khz(int khz, int *jtag_speed)
        return 0;
 }
 
-
 int presto_jtag_speed_div(int speed, int *khz)
 {
        if ((speed < 0) || (speed > 1000))
@@ -757,7 +737,6 @@ int presto_jtag_speed_div(int speed, int *khz)
        return 0;
 }
 
-
 int presto_jtag_speed(int speed)
 {
        int khz;
@@ -777,7 +756,6 @@ int presto_jtag_speed(int speed)
        return 0;
 }
 
-
 char *presto_serial;
 
 int presto_handle_serial_command(struct command_context_s *cmd_ctx, char *cmd, char **args, int argc)
@@ -796,7 +774,6 @@ int presto_handle_serial_command(struct command_context_s *cmd_ctx, char *cmd, c
        return ERROR_OK;
 }
 
-
 int presto_jtag_register_commands(struct command_context_s *cmd_ctx)
 {
        register_command(cmd_ctx, NULL, "presto_serial", presto_handle_serial_command,
@@ -804,7 +781,6 @@ int presto_jtag_register_commands(struct command_context_s *cmd_ctx)
        return ERROR_OK;
 }
 
-
 int presto_jtag_init(void)
 {
        if (presto_open(presto_serial) != ERROR_OK)
@@ -825,7 +801,6 @@ int presto_jtag_init(void)
        return ERROR_OK;
 }
 
-
 int presto_jtag_quit(void)
 {
        bitq_cleanup();