aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAntonio Borneo <borneo.antonio@gmail.com>2021-04-25 22:38:32 +0200
committerAntonio Borneo <borneo.antonio@gmail.com>2021-07-02 17:10:03 +0100
commit9e358ac2c0a759982064dd53a974b50ebaeb19f5 (patch)
treea877d741b77854da4d220cbabf4a6de1d4dd7c6b /src
parent3d135a5c70db67ed13cc93eeab0b700f6ef8a412 (diff)
downloadriscv-openocd-9e358ac2c0a759982064dd53a974b50ebaeb19f5.zip
riscv-openocd-9e358ac2c0a759982064dd53a974b50ebaeb19f5.tar.gz
riscv-openocd-9e358ac2c0a759982064dd53a974b50ebaeb19f5.tar.bz2
helper: rename camelcase symbols
No cross dependency, just changes internal to each file/function. Change-Id: I16568ddcd8304f5e6748c2e19f32421b047b0357 Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com> Reviewed-on: http://openocd.zylin.com/6300 Tested-by: jenkins
Diffstat (limited to 'src')
-rw-r--r--src/helper/log.c8
-rw-r--r--src/helper/replacements.c6
-rw-r--r--src/helper/util.c4
3 files changed, 9 insertions, 9 deletions
diff --git a/src/helper/log.c b/src/helper/log.c
index 36b59fe..785a8bd 100644
--- a/src/helper/log.c
+++ b/src/helper/log.c
@@ -473,11 +473,11 @@ void kept_alive(void)
/* if we sleep for extended periods of time, we must invoke keep_alive() intermittently */
void alive_sleep(uint64_t ms)
{
- uint64_t napTime = 10;
- for (uint64_t i = 0; i < ms; i += napTime) {
+ uint64_t nap_time = 10;
+ for (uint64_t i = 0; i < ms; i += nap_time) {
uint64_t sleep_a_bit = ms - i;
- if (sleep_a_bit > napTime)
- sleep_a_bit = napTime;
+ if (sleep_a_bit > nap_time)
+ sleep_a_bit = nap_time;
usleep(sleep_a_bit * 1000);
keep_alive();
diff --git a/src/helper/replacements.c b/src/helper/replacements.c
index f4ecb8d..f898997 100644
--- a/src/helper/replacements.c
+++ b/src/helper/replacements.c
@@ -235,14 +235,14 @@ int win_select(int max_fd, fd_set *rfds, fd_set *wfds, fd_set *efds, struct time
for (i = 0; i < n_handles; i++) {
if (WAIT_OBJECT_0 == WaitForSingleObject(handles[i], 0)) {
if (SAFE_FD_ISSET(handle_slot_to_fd[i], rfds)) {
- DWORD dwBytes;
+ DWORD bytes;
intptr_t handle = (intptr_t) _get_osfhandle(
handle_slot_to_fd[i]);
if (PeekNamedPipe((HANDLE)handle, NULL, 0,
- NULL, &dwBytes, NULL)) {
+ NULL, &bytes, NULL)) {
/* check to see if gdb pipe has data available */
- if (dwBytes) {
+ if (bytes) {
FD_SET(handle_slot_to_fd[i], &aread);
retcode++;
}
diff --git a/src/helper/util.c b/src/helper/util.c
index dcd59e6..be163b2 100644
--- a/src/helper/util.c
+++ b/src/helper/util.c
@@ -24,7 +24,7 @@
#include "log.h"
#include "time_support.h"
-static int util_Jim_Command_ms(Jim_Interp *interp,
+static int jim_util_ms(Jim_Interp *interp,
int argc,
Jim_Obj * const *argv)
{
@@ -45,7 +45,7 @@ static const struct command_registration util_command_handlers[] = {
{
.name = "ms",
.mode = COMMAND_ANY,
- .jim_handler = util_Jim_Command_ms,
+ .jim_handler = jim_util_ms,
.help =
"Returns ever increasing milliseconds. Used to calculate differences in time.",
.usage = "",