git: e19883539ab8 - main - hwpmc: Use __diagused for variables only used in KASSERT().
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 13 Apr 2022 23:09:49 UTC
The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=e19883539ab886097f170622395b18c0193f5faa commit e19883539ab886097f170622395b18c0193f5faa Author: John Baldwin <jhb@FreeBSD.org> AuthorDate: 2022-04-13 23:08:22 +0000 Commit: John Baldwin <jhb@FreeBSD.org> CommitDate: 2022-04-13 23:08:22 +0000 hwpmc: Use __diagused for variables only used in KASSERT(). --- sys/dev/hwpmc/hwpmc_arm64.c | 2 +- sys/dev/hwpmc/hwpmc_armv7.c | 2 +- sys/dev/hwpmc/hwpmc_powerpc.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/dev/hwpmc/hwpmc_arm64.c b/sys/dev/hwpmc/hwpmc_arm64.c index e2609dfcb474..03f85a593d1a 100644 --- a/sys/dev/hwpmc/hwpmc_arm64.c +++ b/sys/dev/hwpmc/hwpmc_arm64.c @@ -346,7 +346,7 @@ arm64_stop_pmc(int cpu, int ri) static int arm64_release_pmc(int cpu, int ri, struct pmc *pmc) { - struct pmc_hw *phw; + struct pmc_hw *phw __diagused; KASSERT(cpu >= 0 && cpu < pmc_cpu_max(), ("[arm64,%d] illegal CPU value %d", __LINE__, cpu)); diff --git a/sys/dev/hwpmc/hwpmc_armv7.c b/sys/dev/hwpmc/hwpmc_armv7.c index 95ac9a56abb7..b742fa4c3110 100644 --- a/sys/dev/hwpmc/hwpmc_armv7.c +++ b/sys/dev/hwpmc/hwpmc_armv7.c @@ -314,7 +314,7 @@ armv7_stop_pmc(int cpu, int ri) static int armv7_release_pmc(int cpu, int ri, struct pmc *pmc) { - struct pmc_hw *phw; + struct pmc_hw *phw __diagused; KASSERT(cpu >= 0 && cpu < pmc_cpu_max(), ("[armv7,%d] illegal CPU value %d", __LINE__, cpu)); diff --git a/sys/dev/hwpmc/hwpmc_powerpc.c b/sys/dev/hwpmc/hwpmc_powerpc.c index 4377c3075bca..8302cfd84992 100644 --- a/sys/dev/hwpmc/hwpmc_powerpc.c +++ b/sys/dev/hwpmc/hwpmc_powerpc.c @@ -252,7 +252,7 @@ powerpc_allocate_pmc(int cpu, int ri, struct pmc *pm, int powerpc_release_pmc(int cpu, int ri, struct pmc *pmc) { - struct pmc_hw *phw; + struct pmc_hw *phw __diagused; KASSERT(cpu >= 0 && cpu < pmc_cpu_max(), ("[powerpc,%d] illegal CPU value %d", __LINE__, cpu));