aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMateusz Guzik <mjg@FreeBSD.org>2023-02-07 22:52:06 +0000
committerMateusz Guzik <mjg@FreeBSD.org>2023-02-07 22:52:06 +0000
commitb2c68dc6d9b31de853664ac9277816678d2c9181 (patch)
treed3fdb9c3a2a6c94a697b5d4eda7d0b698a7446d9
parent232b4f33b4352cc84f3f07721345117d2486b013 (diff)
downloadsrc-b2c68dc6d9b31de853664ac9277816678d2c9181.tar.gz
src-b2c68dc6d9b31de853664ac9277816678d2c9181.zip
amd64: ansify
Reported by: clang 15 Sponsored by: Rubicon Communications, LLC ("Netgate")
-rw-r--r--sys/amd64/amd64/db_disasm.c23
-rw-r--r--sys/amd64/amd64/machdep.c15
-rw-r--r--sys/amd64/amd64/sys_machdep.c8
3 files changed, 11 insertions, 35 deletions
diff --git a/sys/amd64/amd64/db_disasm.c b/sys/amd64/amd64/db_disasm.c
index ac71d7e06609..54f7beda1169 100644
--- a/sys/amd64/amd64/db_disasm.c
+++ b/sys/amd64/amd64/db_disasm.c
@@ -1045,12 +1045,8 @@ static db_addr_t
* Read address at location and return updated location.
*/
static db_addr_t
-db_read_address(loc, short_addr, rex, regmodrm, addrp)
- db_addr_t loc;
- int short_addr;
- int rex;
- int regmodrm;
- struct i_addr * addrp; /* out */
+db_read_address(db_addr_t loc, int short_addr, int rex, int regmodrm,
+ struct i_addr *addrp)
{
int mod, rm, sib, index, disp, size, have_sib;
@@ -1113,11 +1109,7 @@ db_read_address(loc, short_addr, rex, regmodrm, addrp)
}
static void
-db_print_address(seg, size, rex, addrp)
- const char * seg;
- int size;
- int rex;
- struct i_addr * addrp;
+db_print_address(const char *seg, int size, int rex, struct i_addr *addrp)
{
if (addrp->is_reg) {
db_printf("%s", db_reg[rex != 0 ? 1 : 0][(size == LONG && (rex & REX_W)) ? QUAD : size][addrp->disp]);
@@ -1145,13 +1137,8 @@ db_print_address(seg, size, rex, addrp)
* and return updated location.
*/
static db_addr_t
-db_disasm_esc(loc, inst, rex, short_addr, size, seg)
- db_addr_t loc;
- int inst;
- int rex;
- int short_addr;
- int size;
- const char * seg;
+db_disasm_esc(db_addr_t loc, int inst, int rex, int short_addr, int size,
+ const char *seg)
{
int regmodrm;
const struct finst * fp;
diff --git a/sys/amd64/amd64/machdep.c b/sys/amd64/amd64/machdep.c
index a14c3e408541..f33f2c6509f0 100644
--- a/sys/amd64/amd64/machdep.c
+++ b/sys/amd64/amd64/machdep.c
@@ -220,8 +220,7 @@ void (*vmm_resume_p)(void);
bool efi_boot;
static void
-cpu_startup(dummy)
- void *dummy;
+cpu_startup(void *dummy)
{
uintmax_t memsize;
char *sysenv;
@@ -584,9 +583,7 @@ DB_SHOW_COMMAND_FLAGS(dbregs, db_show_dbregs, DB_CMD_MEMSAFE)
#endif
void
-sdtossd(sd, ssd)
- struct user_segment_descriptor *sd;
- struct soft_segment_descriptor *ssd;
+sdtossd(struct user_segment_descriptor *sd, struct soft_segment_descriptor *ssd)
{
ssd->ssd_base = (sd->sd_hibase << 24) | sd->sd_lobase;
@@ -600,9 +597,7 @@ sdtossd(sd, ssd)
}
void
-ssdtosd(ssd, sd)
- struct soft_segment_descriptor *ssd;
- struct user_segment_descriptor *sd;
+ssdtosd(struct soft_segment_descriptor *ssd, struct user_segment_descriptor *sd)
{
sd->sd_lobase = (ssd->ssd_base) & 0xffffff;
@@ -618,9 +613,7 @@ ssdtosd(ssd, sd)
}
void
-ssdtosyssd(ssd, sd)
- struct soft_segment_descriptor *ssd;
- struct system_segment_descriptor *sd;
+ssdtosyssd(struct soft_segment_descriptor *ssd, struct system_segment_descriptor *sd)
{
sd->sd_lobase = (ssd->ssd_base) & 0xffffff;
diff --git a/sys/amd64/amd64/sys_machdep.c b/sys/amd64/amd64/sys_machdep.c
index 05c90f57ec6c..a3716a354448 100644
--- a/sys/amd64/amd64/sys_machdep.c
+++ b/sys/amd64/amd64/sys_machdep.c
@@ -391,9 +391,7 @@ sysarch(struct thread *td, struct sysarch_args *uap)
}
int
-amd64_set_ioperm(td, uap)
- struct thread *td;
- struct i386_ioperm_args *uap;
+amd64_set_ioperm(struct thread *td, struct i386_ioperm_args *uap)
{
char *iomap;
struct amd64tss *tssp;
@@ -447,9 +445,7 @@ amd64_set_ioperm(td, uap)
}
int
-amd64_get_ioperm(td, uap)
- struct thread *td;
- struct i386_ioperm_args *uap;
+amd64_get_ioperm(struct thread *td, struct i386_ioperm_args *uap)
{
int i, state;
char *iomap;