From 103867a750d3b3ff8424340eadb33d4886c740f7 Mon Sep 17 00:00:00 2001 From: ian Date: Fri, 14 Jul 2023 01:04:48 +0000 Subject: kernel/vm: Disable debug logging git-svn-id: https://svn.vegaa.systems/svn/vega-Vega/trunk@14 a8a8aea2-181d-ee11-89e8-15fd0e089fc4 --- sys/vm/vm_physseg.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'sys') diff --git a/sys/vm/vm_physseg.c b/sys/vm/vm_physseg.c index 3b546e7..5a80723 100644 --- a/sys/vm/vm_physseg.c +++ b/sys/vm/vm_physseg.c @@ -38,12 +38,9 @@ #include __MODULE_NAME("vm_physseg"); - __KERNEL_META("$Vega$: vm_physseg.c, Ian Marco Moffett, " "The Vega physical memory manager"); -#define VM_PHYSSEG_DEBUG - #if defined(VM_PHYSSEG_DEBUG) #define DPRINTF(...) KDEBUG(__VA_ARGS__) #else @@ -107,7 +104,9 @@ static void vm_physseg_bitmap_populate(void) { struct limine_memmap_entry *entry; +#if defined(VM_PHYSSEG_DEBUG) size_t start, end; +#endif /* defined(VM_PHYSSEG_DEBUG) */ for (size_t i = 0; i < resp->entry_count; ++i) { entry = resp->entries[i]; @@ -117,12 +116,14 @@ vm_physseg_bitmap_populate(void) continue; } +#if defined(VM_PHYSSEG_DEBUG) /* Dump the memory map if we are debugging */ start = entry->base; end = entry->base + entry->length; DPRINTF("0x%x - 0x%x, size: 0x%x, type: %s\n", start, end, entry->length, segment_name[entry->type]); +#endif /* defined(VM_PHYSSEG_DEBUG) */ /* Don't set non-usable entries as free */ if (entry->type != LIMINE_MEMMAP_USABLE) { -- cgit v1.2.3