diff options
author | dzwdz | 2022-08-19 18:03:59 +0200 |
---|---|---|
committer | dzwdz | 2022-08-19 18:03:59 +0200 |
commit | 7a4bc281958c639cd52ff4f192933aa161ba81a4 (patch) | |
tree | 6afc254b32bc724d872227f4fb3699ef03f511a0 /src/kernel/arch/amd64/pagedir.c | |
parent | e9161cdcda9e5170f3ea5f18a8275395004ffce4 (diff) |
kernel: kzalloc
Diffstat (limited to 'src/kernel/arch/amd64/pagedir.c')
-rw-r--r-- | src/kernel/arch/amd64/pagedir.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/kernel/arch/amd64/pagedir.c b/src/kernel/arch/amd64/pagedir.c index 75c9746..f0e45d5 100644 --- a/src/kernel/arch/amd64/pagedir.c +++ b/src/kernel/arch/amd64/pagedir.c @@ -31,9 +31,7 @@ static __user void *addr_canonize(const __user void *addr) { struct pagedir *pagedir_new(void) { - struct pagedir *dir = page_alloc(1); - memset(dir, 0, sizeof *dir); - return dir; + return page_zalloc(1); } void pagedir_free(struct pagedir *dir) { |