From f6d8fcaed18e5ccb8e77952c23ec09be39e71cef Mon Sep 17 00:00:00 2001 From: deraadt Date: Sun, 16 May 2021 15:12:37 +0000 Subject: [PATCH] panic does not require a \n at the end. When one is provided, it looks wrong. --- sys/arch/octeon/octeon/machdep.c | 4 ++-- sys/dev/audio.c | 6 +++--- sys/dev/softraid_raid1.c | 10 +++++----- sys/dev/softraid_raid5.c | 6 +++--- sys/dev/softraid_raid6.c | 6 +++--- 5 files changed, 16 insertions(+), 16 deletions(-) diff --git a/sys/arch/octeon/octeon/machdep.c b/sys/arch/octeon/octeon/machdep.c index c2397924c46..f9868a58eb0 100644 --- a/sys/arch/octeon/octeon/machdep.c +++ b/sys/arch/octeon/octeon/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.130 2021/03/09 14:13:33 visa Exp $ */ +/* $OpenBSD: machdep.c,v 1.131 2021/05/16 15:12:38 deraadt Exp $ */ /* * Copyright (c) 2009, 2010 Miodrag Vallat. @@ -1287,7 +1287,7 @@ hw_cpu_boot_secondary(struct cpu_info *ci) kstack = alloc_contiguous_pages(USPACE); if (kstack == 0) - panic("unable to allocate idle stack\n"); + panic("unable to allocate idle stack"); ci->ci_curprocpaddr = (void *)kstack; cpu_spinup_a0 = (uint64_t)ci; diff --git a/sys/dev/audio.c b/sys/dev/audio.c index 0c01bb9e54d..012eb252e2b 100644 --- a/sys/dev/audio.c +++ b/sys/dev/audio.c @@ -1,4 +1,4 @@ -/* $OpenBSD: audio.c,v 1.192 2020/12/25 12:59:51 visa Exp $ */ +/* $OpenBSD: audio.c,v 1.193 2021/05/16 15:12:37 deraadt Exp $ */ /* * Copyright (c) 2015 Alexandre Ratchov * @@ -362,7 +362,7 @@ audio_buf_rdiscard(struct audio_buf *buf, size_t count) #ifdef AUDIO_DEBUG if (count > buf->used) { panic("audio_buf_rdiscard: bad count = %zu, " - "start = %zu, used = %zu\n", count, buf->start, buf->used); + "start = %zu, used = %zu", count, buf->start, buf->used); } #endif buf->used -= count; @@ -380,7 +380,7 @@ audio_buf_wcommit(struct audio_buf *buf, size_t count) #ifdef AUDIO_DEBUG if (count > (buf->len - buf->used)) { panic("audio_buf_wcommit: bad count = %zu, " - "start = %zu, used = %zu\n", count, buf->start, buf->used); + "start = %zu, used = %zu", count, buf->start, buf->used); } #endif buf->used += count; diff --git a/sys/dev/softraid_raid1.c b/sys/dev/softraid_raid1.c index b24183c879d..153e6989805 100644 --- a/sys/dev/softraid_raid1.c +++ b/sys/dev/softraid_raid1.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid_raid1.c,v 1.66 2020/12/08 17:33:49 stsp Exp $ */ +/* $OpenBSD: softraid_raid1.c,v 1.67 2021/05/16 15:12:37 deraadt Exp $ */ /* * Copyright (c) 2007 Marco Peereboom * @@ -173,8 +173,8 @@ sr_raid1_set_chunk_state(struct sr_discipline *sd, int c, int new_state) default: die: splx(s); /* XXX */ - panic("%s: %s: %s: invalid chunk state transition " - "%d -> %d\n", DEVNAME(sd->sd_sc), + panic("%s: %s: %s: invalid chunk state transition %d -> %d", + DEVNAME(sd->sd_sc), sd->sd_meta->ssd_devname, sd->sd_vol.sv_chunks[c]->src_meta.scmi.scm_devname, old_state, new_state); @@ -307,8 +307,8 @@ sr_raid1_set_vol_state(struct sr_discipline *sd) default: die: - panic("%s: %s: invalid volume state transition " - "%d -> %d\n", DEVNAME(sd->sd_sc), + panic("%s: %s: invalid volume state transition %d -> %d", + DEVNAME(sd->sd_sc), sd->sd_meta->ssd_devname, old_state, new_state); /* NOTREACHED */ diff --git a/sys/dev/softraid_raid5.c b/sys/dev/softraid_raid5.c index 6f5ea68d9ea..c8c4925a3d2 100644 --- a/sys/dev/softraid_raid5.c +++ b/sys/dev/softraid_raid5.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid_raid5.c,v 1.31 2020/12/16 18:16:34 cheloha Exp $ */ +/* $OpenBSD: softraid_raid5.c,v 1.32 2021/05/16 15:12:37 deraadt Exp $ */ /* * Copyright (c) 2014 Joel Sing * Copyright (c) 2009 Marco Peereboom @@ -201,8 +201,8 @@ sr_raid5_set_chunk_state(struct sr_discipline *sd, int c, int new_state) default: die: splx(s); /* XXX */ - panic("%s: %s: %s: invalid chunk state transition " - "%d -> %d", DEVNAME(sd->sd_sc), + panic("%s: %s: %s: invalid chunk state transition %d -> %d", + DEVNAME(sd->sd_sc), sd->sd_meta->ssd_devname, sd->sd_vol.sv_chunks[c]->src_meta.scmi.scm_devname, old_state, new_state); diff --git a/sys/dev/softraid_raid6.c b/sys/dev/softraid_raid6.c index 14eb9f98369..2b319f75be2 100644 --- a/sys/dev/softraid_raid6.c +++ b/sys/dev/softraid_raid6.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid_raid6.c,v 1.71 2016/04/12 16:26:54 krw Exp $ */ +/* $OpenBSD: softraid_raid6.c,v 1.72 2021/05/16 15:12:37 deraadt Exp $ */ /* * Copyright (c) 2009 Marco Peereboom * Copyright (c) 2009 Jordan Hargrave @@ -219,8 +219,8 @@ sr_raid6_set_chunk_state(struct sr_discipline *sd, int c, int new_state) default: die: splx(s); /* XXX */ - panic("%s: %s: %s: invalid chunk state transition " - "%d -> %d", DEVNAME(sd->sd_sc), + panic("%s: %s: %s: invalid chunk state transition %d -> %d", + DEVNAME(sd->sd_sc), sd->sd_meta->ssd_devname, sd->sd_vol.sv_chunks[c]->src_meta.scmi.scm_devname, old_state, new_state); -- 2.20.1