aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2013-07-17 17:12:34 -0700
committerH. Peter Anvin <hpa@zytor.com>2013-07-17 17:12:34 -0700
commite6451bde4b7f2936acbdfd5c4e5817b6df687a7c (patch)
treeabca23b8eb8920c71bcaca2df32ffdc153a87c13
parente94cce1ad1183afa39c1f01e9b49345ddb1a0404 (diff)
downloadsyslinux-e6451bde4b7f2936acbdfd5c4e5817b6df687a7c.tar.gz
syslinux-e6451bde4b7f2936acbdfd5c4e5817b6df687a7c.tar.xz
syslinux-e6451bde4b7f2936acbdfd5c4e5817b6df687a7c.zip
movebits: add an inline to test for SMT_FREE || SMT_TERMINAL
Introduce a predicate inline to test for a valid terminal address. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
-rw-r--r--com32/include/syslinux/movebits.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/com32/include/syslinux/movebits.h b/com32/include/syslinux/movebits.h
index d5c903a0..d12fb584 100644
--- a/com32/include/syslinux/movebits.h
+++ b/com32/include/syslinux/movebits.h
@@ -44,6 +44,11 @@ struct syslinux_memmap {
struct syslinux_memmap *next;
};
+static inline bool valid_terminal_type(enum syslinux_memmap_types type)
+{
+ return (type == SMT_FREE) || (type == SMT_TERMINAL);
+}
+
/*
* moves is computed from "fraglist" and "memmap". Areas that are
* to be zeroed should be marked as such in the memmap, not in the