From 6b6152842350f855579701d2405910411c6a6e81 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Wed, 4 Jan 2006 20:08:04 +0000 Subject: [PATCH] Add clarifying comment. Via Bruce Schechter. --- src/userprog/process.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/userprog/process.c b/src/userprog/process.c index 6150a06..a81ca59 100644 --- a/src/userprog/process.c +++ b/src/userprog/process.c @@ -386,8 +386,12 @@ setup_stack (void **esp) } /* Adds a mapping from user virtual address UPAGE to kernel - virtual address KPAGE to the page table. Fails if UPAGE is - already mapped or if memory allocation fails. */ + virtual address KPAGE to the page table. + UPAGE must not already be mapped. + KPAGE should probably be a page obtained from the user pool + with palloc_get_page(). + Returns true on success, false if UPAGE is already mapped or + if memory allocation fails. */ static bool install_page (void *upage, void *kpage) { -- 2.30.2