From c40896dfedb7b872d988cb3c3d7d63086ba42a5d Mon Sep 17 00:00:00 2001 From: ArchStacker Date: Sun, 10 May 2015 00:41:07 +0800 Subject: [PATCH] Add tests in lab8_result:swap_fifo.c --- labcodes_answer/lab8_result/kern/mm/swap_fifo.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/labcodes_answer/lab8_result/kern/mm/swap_fifo.c b/labcodes_answer/lab8_result/kern/mm/swap_fifo.c index ae6caf3..4f9dc8f 100644 --- a/labcodes_answer/lab8_result/kern/mm/swap_fifo.c +++ b/labcodes_answer/lab8_result/kern/mm/swap_fifo.c @@ -110,6 +110,13 @@ _fifo_check_swap(void) { cprintf("write Virt Page d in fifo_check_swap\n"); *(unsigned char *)0x4000 = 0x0d; assert(pgfault_num==9); + cprintf("write Virt Page e in fifo_check_swap\n"); + *(unsigned char *)0x5000 = 0x0e; + assert(pgfault_num==10); + cprintf("write Virt Page a in fifo_check_swap\n"); + assert(*(unsigned char *)0x1000 == 0x0a); + *(unsigned char *)0x1000 = 0x0a; + assert(pgfault_num==11); return 0; }