diff options
author | Guy-Fleury Iteriteka <gfleury@disroot.org> | 2022-05-26 18:07:41 +0200 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2022-05-27 00:29:29 +0200 |
commit | 151dfe9971ac2bd4d9afb440f2a5b2a4f9a58969 (patch) | |
tree | a4f405b8d09270e20a0db24a126ec68adea1f227 /i386 | |
parent | 96b925573917679a5899a74c1c279c734e614211 (diff) | |
download | gnumach-151dfe9971ac2bd4d9afb440f2a5b2a4f9a58969.tar.gz gnumach-151dfe9971ac2bd4d9afb440f2a5b2a4f9a58969.tar.bz2 gnumach-151dfe9971ac2bd4d9afb440f2a5b2a4f9a58969.zip |
convert K&R into ansi
Message-Id: <Yo+lzS7RtW5ZjQHN@debian>
Diffstat (limited to 'i386')
-rw-r--r-- | i386/i386/ast_check.c | 6 | ||||
-rw-r--r-- | i386/i386/fpu.c | 10 | ||||
-rw-r--r-- | i386/i386/kttd_interface.c | 3 | ||||
-rw-r--r-- | i386/i386/pcb.c | 9 | ||||
-rw-r--r-- | i386/i386/trap.c | 3 | ||||
-rw-r--r-- | i386/i386/user_ldt.c | 12 | ||||
-rw-r--r-- | i386/i386at/kd_event.c | 8 | ||||
-rw-r--r-- | i386/i386at/kd_mouse.c | 5 | ||||
-rw-r--r-- | i386/i386at/kd_queue.c | 10 | ||||
-rw-r--r-- | i386/i386at/model_dep.c | 5 | ||||
-rw-r--r-- | i386/intel/pmap.c | 28 |
11 files changed, 35 insertions, 64 deletions
diff --git a/i386/i386/ast_check.c b/i386/i386/ast_check.c index f3e1c350..36c665b2 100644 --- a/i386/i386/ast_check.c +++ b/i386/i386/ast_check.c @@ -37,16 +37,14 @@ /* * Initialize for remote invocation of ast_check. */ -void init_ast_check(processor) - const processor_t processor; +void init_ast_check(const processor_t processor) { } /* * Cause remote invocation of ast_check. Caller is at splsched(). */ -void cause_ast_check(processor) - const processor_t processor; +void cause_ast_check(const processor_t processor) { } diff --git a/i386/i386/fpu.c b/i386/i386/fpu.c index b47bd339..e57227d5 100644 --- a/i386/i386/fpu.c +++ b/i386/i386/fpu.c @@ -380,9 +380,8 @@ twd_fxsr_to_i387 (struct i386_xfp_save *fxsave) * concurrent fpu_set_state or fpu_get_state. */ kern_return_t -fpu_set_state(thread, state) - const thread_t thread; - struct i386_float_state *state; +fpu_set_state(const thread_t thread, + struct i386_float_state *state) { pcb_t pcb = thread->pcb; struct i386_fpsave_state *ifps; @@ -491,9 +490,8 @@ ASSERT_IPL(SPL0); * concurrent fpu_set_state or fpu_get_state. */ kern_return_t -fpu_get_state(thread, state) - const thread_t thread; - struct i386_float_state *state; +fpu_get_state(const thread_t thread, + struct i386_float_state *state) { pcb_t pcb = thread->pcb; struct i386_fpsave_state *ifps; diff --git a/i386/i386/kttd_interface.c b/i386/i386/kttd_interface.c index c6caa76d..f48fe8eb 100644 --- a/i386/i386/kttd_interface.c +++ b/i386/i386/kttd_interface.c @@ -499,8 +499,7 @@ struct int_regs { }; void -kttd_netentry(int_regs) - struct int_regs *int_regs; +kttd_netentry(struct int_regs *int_regs) { struct i386_interrupt_state *is = int_regs->is; int s; diff --git a/i386/i386/pcb.c b/i386/i386/pcb.c index 23585323..03245848 100644 --- a/i386/i386/pcb.c +++ b/i386/i386/pcb.c @@ -829,11 +829,10 @@ user_stack_low(vm_size_t stack_size) * Allocate argument area and set registers for first user thread. */ vm_offset_t -set_user_regs(stack_base, stack_size, exec_info, arg_size) - vm_offset_t stack_base; /* low address */ - vm_offset_t stack_size; - const struct exec_info *exec_info; - vm_size_t arg_size; +set_user_regs(vm_offset_t stack_base, /* low address */ + vm_offset_t stack_size, + const struct exec_info *exec_info, + vm_size_t arg_size) { vm_offset_t arg_addr; struct i386_saved_state *saved_state; diff --git a/i386/i386/trap.c b/i386/i386/trap.c index cbf45914..4f8612bc 100644 --- a/i386/i386/trap.c +++ b/i386/i386/trap.c @@ -643,8 +643,7 @@ i386_exception( * return saved state for interrupted user thread */ unsigned -interrupted_pc(t) - const thread_t t; +interrupted_pc(const thread_t t) { struct i386_saved_state *iss; diff --git a/i386/i386/user_ldt.c b/i386/i386/user_ldt.c index 09500b4d..fdff518e 100644 --- a/i386/i386/user_ldt.c +++ b/i386/i386/user_ldt.c @@ -253,12 +253,12 @@ i386_set_ldt( } kern_return_t -i386_get_ldt(thread, first_selector, selector_count, desc_list, count) - const thread_t thread; - int first_selector; - int selector_count; /* number wanted */ - struct real_descriptor **desc_list; /* in/out */ - unsigned int *count; /* in/out */ +i386_get_ldt(const thread_t thread, + int first_selector, + int selector_count, /* number wanted */ + struct real_descriptor **desc_list, /* in/out */ + unsigned int *count /* in/out */ + ) { struct user_ldt *user_ldt; pcb_t pcb; diff --git a/i386/i386at/kd_event.c b/i386/i386at/kd_event.c index bed9240f..518e4859 100644 --- a/i386/i386at/kd_event.c +++ b/i386/i386at/kd_event.c @@ -110,10 +110,7 @@ kbdinit(void) /*ARGSUSED*/ int -kbdopen(dev, flags, ior) - dev_t dev; - int flags; - io_req_t ior; +kbdopen(dev_t dev, int flags, io_req_t ior) { spl_t o_pri = spltty(); kdinit(); @@ -308,8 +305,7 @@ u_int X_kdb_enter_str[512], X_kdb_exit_str[512]; int X_kdb_enter_len = 0, X_kdb_exit_len = 0; void -kdb_in_out(p) -const u_int *p; +kdb_in_out(const u_int *p) { int t = p[0]; diff --git a/i386/i386at/kd_mouse.c b/i386/i386at/kd_mouse.c index 4b883ba8..afef0e63 100644 --- a/i386/i386at/kd_mouse.c +++ b/i386/i386at/kd_mouse.c @@ -146,10 +146,7 @@ int track_man[10]; /*ARGSUSED*/ int -mouseopen(dev, flags, ior) - dev_t dev; - int flags; - io_req_t ior; +mouseopen(dev_t dev, int flags, io_req_t ior) { if (mouse_in_use) return (D_ALREADY_OPEN); diff --git a/i386/i386at/kd_queue.c b/i386/i386at/kd_queue.c index 57d6fbf7..78035b18 100644 --- a/i386/i386at/kd_queue.c +++ b/i386/i386at/kd_queue.c @@ -71,23 +71,19 @@ WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. #define q_next(index) (((index)+1) % KDQSIZE) boolean_t -kdq_empty(q) - const kd_event_queue *q; +kdq_empty(const kd_event_queue *q) { return(q->firstfree == q->firstout); } boolean_t -kdq_full(q) - const kd_event_queue *q; +kdq_full(const kd_event_queue *q) { return(q_next(q->firstfree) == q->firstout); } void -kdq_put(q, ev) - kd_event_queue *q; - kd_event *ev; +kdq_put(kd_event_queue *q, kd_event *ev) { kd_event *qp = q->events + q->firstfree; diff --git a/i386/i386at/model_dep.c b/i386/i386at/model_dep.c index 21a36bf2..e3a56dba 100644 --- a/i386/i386at/model_dep.c +++ b/i386/i386at/model_dep.c @@ -677,10 +677,7 @@ void c_boot_entry(vm_offset_t bi) #include <mach/time_value.h> vm_offset_t -timemmap(dev, off, prot) - dev_t dev; - vm_offset_t off; - vm_prot_t prot; +timemmap(dev_t dev, vm_offset_t off, vm_prot_t prot) { extern time_value_t *mtime; diff --git a/i386/intel/pmap.c b/i386/intel/pmap.c index d57040cf..5302b092 100644 --- a/i386/intel/pmap.c +++ b/i386/intel/pmap.c @@ -2347,12 +2347,12 @@ phys_addr_t pmap_extract( * This routine is only advisory and need not do anything. */ #if 0 -void pmap_copy(dst_pmap, src_pmap, dst_addr, len, src_addr) - pmap_t dst_pmap; - pmap_t src_pmap; - vm_offset_t dst_addr; - vm_size_t len; - vm_offset_t src_addr; +void pmap_copy( + pmap_t dst_pmap, + pmap_t src_pmap, + vm_offset_t dst_addr, + vm_size_t len, + vm_offset_t src_addr) { } #endif /* 0 */ @@ -2500,10 +2500,7 @@ void pmap_collect(pmap_t p) * processor, and returns a hardware map description. */ #if 0 -void pmap_activate(my_pmap, th, my_cpu) - pmap_t my_pmap; - thread_t th; - int my_cpu; +void pmap_activate(pmap_t my_pmap, thread_t th, int my_cpu) { PMAP_ACTIVATE(my_pmap, th, my_cpu); } @@ -2517,10 +2514,7 @@ void pmap_activate(my_pmap, th, my_cpu) * in pmap.h) */ #if 0 -void pmap_deactivate(pmap, th, which_cpu) - pmap_t pmap; - thread_t th; - int which_cpu; +void pmap_deactivate(pmap_t pmap, thread_t th, int which_cpu) { PMAP_DEACTIVATE(pmap, th, which_cpu); } @@ -2543,8 +2537,7 @@ pmap_t pmap_kernel() * See machine/phys.c or machine/phys.s for implementation. */ #if 0 -pmap_zero_page(phys) - vm_offset_t phys; +pmap_zero_page(vm_offset_t phys) { int i; @@ -2562,8 +2555,7 @@ pmap_zero_page(phys) * See machine/phys.c or machine/phys.s for implementation. */ #if 0 -pmap_copy_page(src, dst) - vm_offset_t src, dst; +pmap_copy_page(vm_offset_t src, vm_offset_t dst) { int i; |