aboutsummaryrefslogtreecommitdiff
path: root/src/jtag/adapter.h
diff options
context:
space:
mode:
authorAntonio Borneo <borneo.antonio@gmail.com>2021-10-07 14:59:29 +0200
committerAntonio Borneo <borneo.antonio@gmail.com>2021-11-13 10:50:34 +0000
commit3c50288612cde9ce5d8f3004f5ad287abd80753e (patch)
tree7d1c59568b488a11f47fc5cde17425d2a9568c28 /src/jtag/adapter.h
parent679dcd0b52f6bafe848eb48e714764d37a101bb5 (diff)
downloadriscv-openocd-3c50288612cde9ce5d8f3004f5ad287abd80753e.zip
riscv-openocd-3c50288612cde9ce5d8f3004f5ad287abd80753e.tar.gz
riscv-openocd-3c50288612cde9ce5d8f3004f5ad287abd80753e.tar.bz2
jtag: align adapter speed code to new structure
Rename the jtag_XXX functions as adapter_XXX. Rename internal variables. Adapt log messages and comments text. Change-Id: I67f209c67074899cd58bad495055def03f0d1bcf Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com> Reviewed-on: https://review.openocd.org/c/openocd/+/6644 Tested-by: jenkins Reviewed-by: Tarek BOCHKATI <tarek.bouchkati@gmail.com>
Diffstat (limited to 'src/jtag/adapter.h')
-rw-r--r--src/jtag/adapter.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/jtag/adapter.h b/src/jtag/adapter.h
index b2405e9..a66fef1 100644
--- a/src/jtag/adapter.h
+++ b/src/jtag/adapter.h
@@ -27,28 +27,28 @@ const char *adapter_usb_get_location(void);
/** @returns true if USB location string is "<dev_bus>-<port_path[0]>[.<port_path[1]>[...]]" */
bool adapter_usb_location_equal(uint8_t dev_bus, uint8_t *port_path, size_t path_len);
-/** @returns The current JTAG speed setting. */
-int jtag_get_speed(int *speed);
+/** @returns The current adapter speed setting. */
+int adapter_get_speed(int *speed);
/**
* Given a @a speed setting, use the interface @c speed_div callback to
* adjust the setting.
- * @param speed The speed setting to convert back to readable KHz.
+ * @param speed The speed setting to convert back to readable kHz.
* @returns ERROR_OK if the interface has not been initialized or on success;
* otherwise, the error code produced by the @c speed_div callback.
*/
-int jtag_get_speed_readable(int *speed);
+int adapter_get_speed_readable(int *speed);
-/** Attempt to configure the interface for the specified KHz. */
-int jtag_config_khz(unsigned khz);
+/** Attempt to configure the adapter for the specified kHz. */
+int adapter_config_khz(unsigned int khz);
/**
* Attempt to enable RTCK/RCLK. If that fails, fallback to the
* specified frequency.
*/
-int jtag_config_rclk(unsigned fallback_speed_khz);
+int adapter_config_rclk(unsigned int fallback_speed_khz);
-/** Retrieves the clock speed of the JTAG interface in KHz. */
-unsigned jtag_get_speed_khz(void);
+/** Retrieves the clock speed of the adapter in kHz. */
+unsigned int adapter_get_speed_khz(void);
#endif /* OPENOCD_JTAG_ADAPTER_H */