summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Pavone <pavone@retrodev.com>2017-06-05 23:03:46 -0700
committerMichael Pavone <pavone@retrodev.com>2017-06-05 23:03:46 -0700
commita051322e49249d9a2a276346d4b3bd76968c5117 (patch)
treeb47da461e54136baea6091078d3d8b6303acd546
parent590720bbcfc6a3744bc6e73e588812d79eba3ae9 (diff)
Small fix to handling of the "bus" option in a RAM type ROM DB memory map
-rw-r--r--romdb.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/romdb.c b/romdb.c
index ea23a2c..7756185 100644
--- a/romdb.c
+++ b/romdb.c
@@ -814,9 +814,9 @@ void map_iter_fun(char *key, tern_val val, uint8_t valtype, void *data)
map->mask = calc_mask(size, start, end);
map->flags = MMAP_READ | MMAP_WRITE;
char *bus = tern_find_ptr_default(node, "bus", "both");
- if (!strcmp(dtype, "odd")) {
+ if (!strcmp(bus, "odd")) {
map->flags |= MMAP_ONLY_ODD;
- } else if (!strcmp(dtype, "even")) {
+ } else if (!strcmp(bus, "even")) {
map->flags |= MMAP_ONLY_EVEN;
} else {
map->flags |= MMAP_CODE;