From a051322e49249d9a2a276346d4b3bd76968c5117 Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Mon, 5 Jun 2017 23:03:46 -0700 Subject: Small fix to handling of the "bus" option in a RAM type ROM DB memory map --- romdb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'romdb.c') 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; -- cgit v1.2.3