From 3a9b5daf48d53cd0edd1a1f89d3e502a48fdceab Mon Sep 17 00:00:00 2001 From: Jake Burkholder Date: Tue, 31 Jul 2001 04:09:52 +0000 Subject: [PATCH] Oops. Last commit to vm_object.c should have got these files too. Remove the use of atomic ops to manipulate vm_object and vm_page flags. Giant is required here, so they are superfluous. Discussed with: dillon --- sys/vm/vm_object.h | 1 - sys/vm/vm_page.c | 10 ++++------ sys/vm/vm_page.h | 1 - 3 files changed, 4 insertions(+), 8 deletions(-) diff --git a/sys/vm/vm_object.h b/sys/vm/vm_object.h index 339ee2aff59..c126cb6ecd4 100644 --- a/sys/vm/vm_object.h +++ b/sys/vm/vm_object.h @@ -72,7 +72,6 @@ #define _VM_OBJECT_ #include -#include enum obj_type { OBJT_DEFAULT, OBJT_SWAP, OBJT_VNODE, OBJT_DEVICE, OBJT_PHYS, OBJT_DEAD }; diff --git a/sys/vm/vm_page.c b/sys/vm/vm_page.c index 39e86032428..b3eb9458e01 100644 --- a/sys/vm/vm_page.c +++ b/sys/vm/vm_page.c @@ -324,16 +324,14 @@ void vm_page_flag_set(vm_page_t m, unsigned short bits) { GIANT_REQUIRED; - atomic_set_short(&(m)->flags, bits); - /* m->flags |= bits; */ + m->flags |= bits; } void vm_page_flag_clear(vm_page_t m, unsigned short bits) { GIANT_REQUIRED; - atomic_clear_short(&(m)->flags, bits); - /* m->flags &= ~bits; */ + m->flags &= ~bits; } void @@ -384,14 +382,14 @@ void vm_page_io_start(vm_page_t m) { GIANT_REQUIRED; - atomic_add_char(&(m)->busy, 1); + m->busy++; } void vm_page_io_finish(vm_page_t m) { GIANT_REQUIRED; - atomic_subtract_char(&(m)->busy, 1); + m->busy--; if (m->busy == 0) vm_page_flash(m); } diff --git a/sys/vm/vm_page.h b/sys/vm/vm_page.h index c2a10df25c5..c31aa49185e 100644 --- a/sys/vm/vm_page.h +++ b/sys/vm/vm_page.h @@ -76,7 +76,6 @@ #endif #include -#include /* * Management of resident (logical) pages.