Changeset View
Changeset View
Standalone View
Standalone View
head/sys/sys/sysctl.h
Show First 20 Lines • Show All 159 Lines • ▼ Show 20 Lines | |||||
*/ | */ | ||||
struct sysctl_req { | struct sysctl_req { | ||||
struct thread *td; /* used for access checking */ | struct thread *td; /* used for access checking */ | ||||
int lock; /* wiring state */ | int lock; /* wiring state */ | ||||
void *oldptr; | void *oldptr; | ||||
size_t oldlen; | size_t oldlen; | ||||
size_t oldidx; | size_t oldidx; | ||||
int (*oldfunc)(struct sysctl_req *, const void *, size_t); | int (*oldfunc)(struct sysctl_req *, const void *, size_t); | ||||
void *newptr; | const void *newptr; | ||||
size_t newlen; | size_t newlen; | ||||
size_t newidx; | size_t newidx; | ||||
int (*newfunc)(struct sysctl_req *, void *, size_t); | int (*newfunc)(struct sysctl_req *, void *, size_t); | ||||
size_t validlen; | size_t validlen; | ||||
int flags; | int flags; | ||||
}; | }; | ||||
SLIST_HEAD(sysctl_oid_list, sysctl_oid); | SLIST_HEAD(sysctl_oid_list, sysctl_oid); | ||||
▲ Show 20 Lines • Show All 901 Lines • ▼ Show 20 Lines | |||||
int kernel_sysctl(struct thread *td, int *name, u_int namelen, void *old, | int kernel_sysctl(struct thread *td, int *name, u_int namelen, void *old, | ||||
size_t *oldlenp, void *new, size_t newlen, size_t *retval, | size_t *oldlenp, void *new, size_t newlen, size_t *retval, | ||||
int flags); | int flags); | ||||
int kernel_sysctlbyname(struct thread *td, char *name, void *old, | int kernel_sysctlbyname(struct thread *td, char *name, void *old, | ||||
size_t *oldlenp, void *new, size_t newlen, size_t *retval, | size_t *oldlenp, void *new, size_t newlen, size_t *retval, | ||||
int flags); | int flags); | ||||
int userland_sysctl(struct thread *td, int *name, u_int namelen, void *old, | int userland_sysctl(struct thread *td, int *name, u_int namelen, void *old, | ||||
size_t *oldlenp, int inkernel, void *new, size_t newlen, | size_t *oldlenp, int inkernel, const void *new, size_t newlen, | ||||
size_t *retval, int flags); | size_t *retval, int flags); | ||||
int sysctl_find_oid(int *name, u_int namelen, struct sysctl_oid **noid, | int sysctl_find_oid(int *name, u_int namelen, struct sysctl_oid **noid, | ||||
int *nindx, struct sysctl_req *req); | int *nindx, struct sysctl_req *req); | ||||
void sysctl_wlock(void); | void sysctl_wlock(void); | ||||
void sysctl_wunlock(void); | void sysctl_wunlock(void); | ||||
int sysctl_wire_old_buffer(struct sysctl_req *req, size_t len); | int sysctl_wire_old_buffer(struct sysctl_req *req, size_t len); | ||||
struct sbuf; | struct sbuf; | ||||
Show All 13 Lines |