From: Roberto E. Vargas Caballero Date: Mon, 26 Feb 2018 18:54:35 +0000 (+0000) Subject: kernel: Initialize dirty and time flags of bb X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=54b728cc6a9769ab82e70fb119871ad6f7c9e510;p=FUZIX.git kernel: Initialize dirty and time flags of bb The buffer cache is not located in bss in some configurations, and it means that the memory is not initialized when the system boots. When emulators allocate the memory, it is initialized to 0 by the operating system, but it doesn't happen in actual hardware. --- diff --git a/Kernel/start.c b/Kernel/start.c index c1ee2597..4d69898c 100644 --- a/Kernel/start.c +++ b/Kernel/start.c @@ -45,6 +45,8 @@ void bufinit(void) for (bp = bufpool; bp < bufpool_end; ++bp) { bp->bf_dev = NO_DEVICE; bp->bf_busy = BF_FREE; + bp->bf_dirty = 0; + bp->bf_time = 0; } }