Print this page
const-ify make segment ops structures
There is no reason to keep the segment ops structures writable.
*** 54,65 ****
#include <vm/seg_dev.h>
#include <vm/seg_vn.h>
#include <vm/seg_spt.h>
#include <vm/seg_kmem.h>
! extern struct seg_ops segdev_ops; /* needs a header file */
! extern struct seg_ops segspt_shmops; /* needs a header file */
static int
page_valid(struct seg *seg, caddr_t addr)
{
struct segvn_data *svd;
--- 54,65 ----
#include <vm/seg_dev.h>
#include <vm/seg_vn.h>
#include <vm/seg_spt.h>
#include <vm/seg_kmem.h>
! extern const struct seg_ops segdev_ops; /* needs a header file */
! extern const struct seg_ops segspt_shmops; /* needs a header file */
static int
page_valid(struct seg *seg, caddr_t addr)
{
struct segvn_data *svd;