summaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
Diffstat (limited to 'common')
-rw-r--r--common/console.c10
-rw-r--r--common/console_countdown.c2
-rw-r--r--common/console_simple.c6
-rw-r--r--common/password.c2
4 files changed, 10 insertions, 10 deletions
diff --git a/common/console.c b/common/console.c
index f0988b8bc0..37574b9b01 100644
--- a/common/console.c
+++ b/common/console.c
@@ -164,7 +164,7 @@ int console_set_baudrate(struct console_device *cdev, unsigned baudrate)
if (cdev->f_active) {
mdelay(50);
do {
- c = getc();
+ c = getchar();
} while (c != '\r' && c != '\n');
}
@@ -345,7 +345,7 @@ static int tstc_raw(void)
return 0;
}
-int getc(void)
+int getchar(void)
{
unsigned char ch;
uint64_t start;
@@ -380,14 +380,14 @@ int getc(void)
return ch;
}
-EXPORT_SYMBOL(getc);
+EXPORT_SYMBOL(getchar);
int fgetc(int fd)
{
char c;
if (!fd)
- return getc();
+ return getchar();
return read(fd, &c, 1);
}
EXPORT_SYMBOL(fgetc);
@@ -476,7 +476,7 @@ int ctrlc (void)
{
poller_call();
- if (tstc() && getc() == 3)
+ if (tstc() && getchar() == 3)
return 1;
return 0;
}
diff --git a/common/console_countdown.c b/common/console_countdown.c
index ffbdb4fa2d..c0c8c95022 100644
--- a/common/console_countdown.c
+++ b/common/console_countdown.c
@@ -39,7 +39,7 @@ int console_countdown(int timeout_s, unsigned flags, char *out_key)
do {
if (tstc()) {
- key = getc();
+ key = getchar();
if (flags & CONSOLE_COUNTDOWN_ANYKEY)
goto out;
if (flags & CONSOLE_COUNTDOWN_RETURN && key == '\n')
diff --git a/common/console_simple.c b/common/console_simple.c
index 69e76593ad..9675cbb0a6 100644
--- a/common/console_simple.c
+++ b/common/console_simple.c
@@ -48,13 +48,13 @@ int tstc(void)
}
EXPORT_SYMBOL(tstc);
-int getc(void)
+int getchar(void)
{
if (!console)
return -EINVAL;
return console->getc(console);
}
-EXPORT_SYMBOL(getc);
+EXPORT_SYMBOL(getchar);
void console_flush(void)
{
@@ -67,7 +67,7 @@ EXPORT_SYMBOL(console_flush);
/* test if ctrl-c was pressed */
int ctrlc (void)
{
- if (tstc() && getc() == 3)
+ if (tstc() && getchar() == 3)
return 1;
return 0;
}
diff --git a/common/password.c b/common/password.c
index 05e61801f0..d52b746f0f 100644
--- a/common/password.c
+++ b/common/password.c
@@ -63,7 +63,7 @@ int password(unsigned char *passwd, size_t length, int flags, int timeout)
do {
if (tstc()) {
- ch = getc();
+ ch = getchar();
switch (ch) {
case '\r':