summaryrefslogtreecommitdiffstats
path: root/sys/kern
diff options
context:
space:
mode:
authorjake <jake@FreeBSD.org>2002-08-25 20:48:45 +0000
committerjake <jake@FreeBSD.org>2002-08-25 20:48:45 +0000
commitee427569aeea414cc14812285cd4609e558a6e76 (patch)
treec539a03f10a0b75a789492bacbdfa40d7f1ca1f3 /sys/kern
parent4608c6048ddce82cf69fefa104b137abe16f4cac (diff)
downloadFreeBSD-src-ee427569aeea414cc14812285cd4609e558a6e76.zip
FreeBSD-src-ee427569aeea414cc14812285cd4609e558a6e76.tar.gz
Fixed placement of operators. Wrapped long lines.
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/imgact_elf.c12
-rw-r--r--sys/kern/kern_exec.c26
2 files changed, 23 insertions, 15 deletions
diff --git a/sys/kern/imgact_elf.c b/sys/kern/imgact_elf.c
index f639a0b..e6be17e 100644
--- a/sys/kern/imgact_elf.c
+++ b/sys/kern/imgact_elf.c
@@ -203,7 +203,8 @@ __elfN(map_partial)(vm_map_t map, vm_object_t object, vm_ooffset_t offset,
}
off = offset - trunc_page(offset);
- error = copyout((caddr_t)data_buf + off, (caddr_t)start, end - start);
+ error = copyout((caddr_t)data_buf + off, (caddr_t)start,
+ end - start);
vm_map_remove(exec_map, data_buf, data_buf + PAGE_SIZE);
if (error) {
return (KERN_FAILURE);
@@ -372,7 +373,8 @@ __elfN(load_section)(struct proc *p, struct vmspace *vmspace,
*/
copy_len = (offset + filsz) - trunc_page_ps(offset + filsz, pagesize);
map_addr = trunc_page_ps((vm_offset_t)vmaddr + filsz, pagesize);
- map_len = round_page_ps((vm_offset_t)vmaddr + memsz, pagesize) - map_addr;
+ map_len = round_page_ps((vm_offset_t)vmaddr + memsz, pagesize) -
+ map_addr;
/* This had damn well better be true! */
if (map_len != 0) {
@@ -557,7 +559,8 @@ __elfN(load_file)(struct proc *p, const char *file, u_long *addr,
* first segment.
*/
if (numsegs == 0)
- base_addr = trunc_page(phdr[i].p_vaddr + rbase);
+ base_addr = trunc_page(phdr[i].p_vaddr +
+ rbase);
numsegs++;
}
}
@@ -811,7 +814,8 @@ __CONCAT(exec_, __elfN(imgact))(struct image_params *imgp)
if ((error = __elfN(load_file)
(imgp->proc, interp, &addr,
&imgp->entry_addr, pagesize)) != 0) {
- uprintf("ELF interpreter %s not found\n", path);
+ uprintf("ELF interpreter %s not found\n",
+ path);
free(path, M_TEMP);
goto fail;
}
diff --git a/sys/kern/kern_exec.c b/sys/kern/kern_exec.c
index 12374c2..9b80db1 100644
--- a/sys/kern/kern_exec.c
+++ b/sys/kern/kern_exec.c
@@ -89,7 +89,8 @@ static register_t *exec_copyout_strings(struct image_params *);
/* XXX This should be vm_size_t. */
static u_long ps_strings = PS_STRINGS;
-SYSCTL_ULONG(_kern, KERN_PS_STRINGS, ps_strings, CTLFLAG_RD, &ps_strings, 0, "");
+SYSCTL_ULONG(_kern, KERN_PS_STRINGS, ps_strings, CTLFLAG_RD, &ps_strings,
+ 0, "");
/* XXX This should be vm_size_t. */
static u_long usrstack = USRSTACK;
@@ -201,7 +202,8 @@ execve(td, uap)
* Allocate temporary demand zeroed space for argument and
* environment strings
*/
- imgp->stringbase = (char *)kmem_alloc_wait(exec_map, ARG_MAX + PAGE_SIZE);
+ imgp->stringbase = (char *)kmem_alloc_wait(exec_map, ARG_MAX +
+ PAGE_SIZE);
if (imgp->stringbase == NULL) {
error = ENOMEM;
mtx_lock(&Giant);
@@ -625,7 +627,8 @@ exec_map_first_page(imgp)
break;
vm_page_busy(ma[i]);
} else {
- ma[i] = vm_page_alloc(object, i, VM_ALLOC_NORMAL);
+ ma[i] = vm_page_alloc(object, i,
+ VM_ALLOC_NORMAL);
if (ma[i] == NULL)
break;
}
@@ -635,7 +638,8 @@ exec_map_first_page(imgp)
rv = vm_pager_get_pages(object, ma, initial_pagein, 0);
ma[0] = vm_page_lookup(object, 0);
- if ((rv != VM_PAGER_OK) || (ma[0] == NULL) || (ma[0]->valid == 0)) {
+ if ((rv != VM_PAGER_OK) || (ma[0] == NULL) ||
+ (ma[0]->valid == 0)) {
if (ma[0]) {
vm_page_lock_queues();
vm_page_protect(ma[0], VM_PROT_NONE);
@@ -703,9 +707,9 @@ exec_new_vmspace(imgp, minuser, maxuser, stack_addr)
* otherwise, create a new VM space so that other threads are
* not disrupted
*/
- if (vmspace->vm_refcnt == 1
- && vm_map_min(&vmspace->vm_map) == minuser
- && vm_map_max(&vmspace->vm_map) == maxuser) {
+ if (vmspace->vm_refcnt == 1 &&
+ vm_map_min(&vmspace->vm_map) == minuser &&
+ vm_map_max(&vmspace->vm_map) == maxuser) {
if (vmspace->vm_shm)
shmexit(p);
pmap_remove_pages(vmspace_pmap(vmspace), minuser, maxuser);
@@ -859,8 +863,8 @@ exec_copyout_strings(imgp)
* 'AT_COUNT*2' is size for the ELF Auxargs data. This is for
* lower compatibility.
*/
- imgp->auxarg_size = (imgp->auxarg_size) ? imgp->auxarg_size
- : (AT_COUNT * 2);
+ imgp->auxarg_size = (imgp->auxarg_size) ? imgp->auxarg_size :
+ (AT_COUNT * 2);
/*
* The '+ 2' is for the null pointers at the end of each of
* the arg and env vector sets,and imgp->auxarg_size is room
@@ -874,8 +878,8 @@ exec_copyout_strings(imgp)
* The '+ 2' is for the null pointers at the end of each of
* the arg and env vector sets
*/
- vectp = (char **)
- (destp - (imgp->argc + imgp->envc + 2) * sizeof(char *));
+ vectp = (char **)(destp - (imgp->argc + imgp->envc + 2) *
+ sizeof(char *));
/*
* vectp also becomes our initial stack base
OpenPOWER on IntegriCloud