summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorjake <jake@FreeBSD.org>2001-07-31 04:09:52 +0000
committerjake <jake@FreeBSD.org>2001-07-31 04:09:52 +0000
commitb4050e8494dfef8b7a3aa9449d11b1f4c7c0201e (patch)
tree2208947b903ff776bdc63df5d2ec25adc6b85fbe /sys
parent2c20bb4e7b91ede8ffbf678ec91a6a634cdaff07 (diff)
downloadFreeBSD-src-b4050e8494dfef8b7a3aa9449d11b1f4c7c0201e.zip
FreeBSD-src-b4050e8494dfef8b7a3aa9449d11b1f4c7c0201e.tar.gz
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
Diffstat (limited to 'sys')
-rw-r--r--sys/vm/vm_object.h1
-rw-r--r--sys/vm/vm_page.c10
-rw-r--r--sys/vm/vm_page.h1
3 files changed, 4 insertions, 8 deletions
diff --git a/sys/vm/vm_object.h b/sys/vm/vm_object.h
index 339ee2a..c126cb6 100644
--- a/sys/vm/vm_object.h
+++ b/sys/vm/vm_object.h
@@ -72,7 +72,6 @@
#define _VM_OBJECT_
#include <sys/queue.h>
-#include <machine/atomic.h>
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 39e8603..b3eb945 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 c2a10df..c31aa49 100644
--- a/sys/vm/vm_page.h
+++ b/sys/vm/vm_page.h
@@ -76,7 +76,6 @@
#endif
#include <vm/pmap.h>
-#include <machine/atomic.h>
/*
* Management of resident (logical) pages.
OpenPOWER on IntegriCloud