Make usermode variable the bool type. It's already used that way.

Suggested by:	kib
Approved by:	kib (mentor)
This commit is contained in:
skra 2015-11-08 08:31:34 +00:00
parent bfeca53302
commit 7424055389
3 changed files with 8 additions and 8 deletions

View File

@ -6133,7 +6133,7 @@ CTASSERT(powerof2(PT2MAP_SIZE));
* Handle access and R/W emulation faults.
*/
int
pmap_fault(pmap_t pmap, vm_offset_t far, uint32_t fsr, int idx, int usermode)
pmap_fault(pmap_t pmap, vm_offset_t far, uint32_t fsr, int idx, bool usermode)
{
pt1_entry_t *pte1p, pte1;
pt2_entry_t *pte2p, pte2;

View File

@ -211,7 +211,7 @@ call_trapsignal(struct thread *td, int sig, int code, vm_offset_t addr)
* FAULT_IS_NOT_MINE value, then the abort is fatal.
*/
static __inline void
abort_imprecise(struct trapframe *tf, u_int fsr, u_int prefetch, u_int usermode)
abort_imprecise(struct trapframe *tf, u_int fsr, u_int prefetch, bool usermode)
{
/*
@ -243,7 +243,7 @@ abort_imprecise(struct trapframe *tf, u_int fsr, u_int prefetch, u_int usermode)
*
*/
static __inline void
abort_debug(struct trapframe *tf, u_int fsr, u_int prefetch, u_int usermode,
abort_debug(struct trapframe *tf, u_int fsr, u_int prefetch, bool usermode,
u_int far)
{
@ -277,7 +277,7 @@ abort_handler(struct trapframe *tf, int prefetch)
{
struct thread *td;
vm_offset_t far, va;
int idx, usermode;
int idx, rv;
uint32_t fsr;
struct ksig ksig;
struct proc *p;
@ -285,7 +285,7 @@ abort_handler(struct trapframe *tf, int prefetch)
struct vm_map *map;
struct vmspace *vm;
vm_prot_t ftype;
int rv;
bool usermode;
#ifdef INVARIANTS
void *onfault;
#endif
@ -556,7 +556,7 @@ static int
abort_fatal(struct trapframe *tf, u_int idx, u_int fsr, u_int far,
u_int prefetch, struct thread *td, struct ksig *ksig)
{
u_int usermode;
bool usermode;
const char *mode;
const char *rw_mode;
@ -617,7 +617,7 @@ static int
abort_align(struct trapframe *tf, u_int idx, u_int fsr, u_int far,
u_int prefetch, struct thread *td, struct ksig *ksig)
{
u_int usermode;
bool usermode;
usermode = TRAPF_USERMODE(tf);
if (!usermode) {

View File

@ -201,7 +201,7 @@ void pmap_tlb_flush_ng(pmap_t );
void pmap_dcache_wb_range(vm_paddr_t , vm_size_t , vm_memattr_t );
vm_paddr_t pmap_kextract(vm_offset_t );
int pmap_fault(pmap_t , vm_offset_t , uint32_t , int , int );
int pmap_fault(pmap_t , vm_offset_t , uint32_t , int , bool);
#define vtophys(va) pmap_kextract((vm_offset_t)(va))
void pmap_set_tex(void);