target/arm: Update CNTP for PREDDESC
[qemu/ar7.git] / tests / tcg / arm / semiconsole.c
blob6ef0bd245009be39104e44e60fb84489e2b1d11e
1 /*
2 * linux-user semihosting console
4 * Copyright (c) 2019
5 * Written by Alex Bennée <alex.bennee@linaro.org>
7 * SPDX-License-Identifier: GPL-3.0-or-later
8 */
10 #include <stdio.h>
11 #include <stdint.h>
12 #include "semicall.h"
14 int main(void)
16 char c;
18 printf("Semihosting Console Test\n");
19 printf("hit X to exit:");
21 do {
22 c = __semi_call(SYS_READC, 0);
23 printf("got '%c'\n", c);
24 } while (c != 'X');
26 return 0;