summaryrefslogtreecommitdiffstats
path: root/semihosting
diff options
context:
space:
mode:
authorRichard Henderson2022-06-07 19:50:43 +0200
committerRichard Henderson2022-06-28 01:05:07 +0200
commita1a2a3e609f619857fcdd8302fe1e832490216a7 (patch)
treee5ed44f322d4e7c95f99ca6f71951f5fdd12b8e7 /semihosting
parentsemihosting: Move common-semi.h to include/semihosting/ (diff)
downloadqemu-a1a2a3e609f619857fcdd8302fe1e832490216a7.tar.gz
qemu-a1a2a3e609f619857fcdd8302fe1e832490216a7.tar.xz
qemu-a1a2a3e609f619857fcdd8302fe1e832490216a7.zip
semihosting: Remove GDB_O_BINARY
The value is zero, and gdb always opens files in binary mode. Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'semihosting')
-rw-r--r--semihosting/arm-compat-semi.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/semihosting/arm-compat-semi.c b/semihosting/arm-compat-semi.c
index cebbad2355..92c1375b15 100644
--- a/semihosting/arm-compat-semi.c
+++ b/semihosting/arm-compat-semi.c
@@ -92,21 +92,20 @@
#define GDB_O_APPEND 0x008
#define GDB_O_CREAT 0x200
#define GDB_O_TRUNC 0x400
-#define GDB_O_BINARY 0
static int gdb_open_modeflags[12] = {
GDB_O_RDONLY,
- GDB_O_RDONLY | GDB_O_BINARY,
+ GDB_O_RDONLY,
+ GDB_O_RDWR,
GDB_O_RDWR,
- GDB_O_RDWR | GDB_O_BINARY,
GDB_O_WRONLY | GDB_O_CREAT | GDB_O_TRUNC,
- GDB_O_WRONLY | GDB_O_CREAT | GDB_O_TRUNC | GDB_O_BINARY,
+ GDB_O_WRONLY | GDB_O_CREAT | GDB_O_TRUNC,
GDB_O_RDWR | GDB_O_CREAT | GDB_O_TRUNC,
- GDB_O_RDWR | GDB_O_CREAT | GDB_O_TRUNC | GDB_O_BINARY,
+ GDB_O_RDWR | GDB_O_CREAT | GDB_O_TRUNC,
+ GDB_O_WRONLY | GDB_O_CREAT | GDB_O_APPEND,
GDB_O_WRONLY | GDB_O_CREAT | GDB_O_APPEND,
- GDB_O_WRONLY | GDB_O_CREAT | GDB_O_APPEND | GDB_O_BINARY,
GDB_O_RDWR | GDB_O_CREAT | GDB_O_APPEND,
- GDB_O_RDWR | GDB_O_CREAT | GDB_O_APPEND | GDB_O_BINARY
+ GDB_O_RDWR | GDB_O_CREAT | GDB_O_APPEND,
};
static int open_modeflags[12] = {