git: d78bef0ebefd - main - hwpmc: further fix build (__diagused/debug/missing files entries)
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 27 Jun 2022 01:37:22 UTC
The branch main has been updated by bz:
URL: https://cgit.FreeBSD.org/src/commit/?id=d78bef0ebefdcd231f6583b6fafc03d4dda39525
commit d78bef0ebefdcd231f6583b6fafc03d4dda39525
Author: Bjoern A. Zeeb <bz@FreeBSD.org>
AuthorDate: 2022-06-27 01:23:24 +0000
Commit: Bjoern A. Zeeb <bz@FreeBSD.org>
CommitDate: 2022-06-27 01:36:52 +0000
hwpmc: further fix build (__diagused/debug/missing files entries)
Fix builds after 1459a22787ea16e3798694067c8dcb20325dca4b and
59191f3573f6cb2ea055ac319cbcb68823ca8e17 by using __diagused
for variables only used in KASSERT().
In addition remove two debug lines that look like a copy and paste error
from dmc620 to cmn600.
Further add the newly introduced files to sys/confg/files.arm64 as well
so that LINT compiles without missing symbols.
---
sys/conf/files.arm64 | 4 ++++
sys/dev/hwpmc/hwpmc_cmn600.c | 8 ++------
sys/dev/hwpmc/hwpmc_dmc620.c | 6 +++---
3 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/sys/conf/files.arm64 b/sys/conf/files.arm64
index 256b67975092..26b9c8ae2215 100644
--- a/sys/conf/files.arm64
+++ b/sys/conf/files.arm64
@@ -198,6 +198,10 @@ dev/gpio/qoriq_gpio.c optional SOC_NXP_LS gpio fdt
dev/hwpmc/hwpmc_arm64.c optional hwpmc
dev/hwpmc/hwpmc_arm64_md.c optional hwpmc
+dev/hwpmc/hwpmc_cmn600.c optional hwpmc
+arm64/arm64/cmn600.c optional hwpmc
+dev/hwpmc/hwpmc_dmc620.c optional hwpmc
+dev/hwpmc/pmu_dmc620.c optional hwpmc
dev/ice/if_ice_iflib.c optional ice pci \
compile-with "${NORMAL_C} -I$S/dev/ice"
diff --git a/sys/dev/hwpmc/hwpmc_cmn600.c b/sys/dev/hwpmc/hwpmc_cmn600.c
index b33dd2693b25..2e6ea41abff8 100644
--- a/sys/dev/hwpmc/hwpmc_cmn600.c
+++ b/sys/dev/hwpmc/hwpmc_cmn600.c
@@ -375,8 +375,6 @@ cmn600_allocate_pmc(int cpu, int ri, struct pmc *pm,
desc->pd_local_counter = pm->pm_md.pm_cmn600.pm_cmn600_local_counter =
local_counter;
- PMCDBG3(MDP, ALL, 2, "%s ri=%d -> control=0x%x", __func__, ri, control);
-
return (0);
}
@@ -387,7 +385,7 @@ cmn600_release_pmc(int cpu, int ri, struct pmc *pmc)
{
struct cmn600_descr *desc;
struct pmc_hw *phw;
- struct pmc *pm;
+ struct pmc *pm __diagused;
int err;
(void) pmc;
@@ -535,8 +533,6 @@ cmn600_start_pmc(int cpu, int ri)
pmu_cmn600_set8(arg, nodeid, NODE_TYPE_DTC, POR_DT_PMCR,
POR_DT_PMCR_PMU_EN);
- PMCDBG2(MDP, STA, 2, "%s control=0x%x", __func__, control);
-
return (0);
}
@@ -674,7 +670,7 @@ cmn600_pcpu_fini(struct pmc_mdep *md, int cpu)
static int
cmn600_pmu_intr(struct trapframe *tf, int unit, int i)
{
- struct pmc_cpu *pc;
+ struct pmc_cpu *pc __diagused;
struct pmc_hw *phw;
struct pmc *pm;
int error, cpu, ri;
diff --git a/sys/dev/hwpmc/hwpmc_dmc620.c b/sys/dev/hwpmc/hwpmc_dmc620.c
index bd17d8a78093..653013e3f2ab 100644
--- a/sys/dev/hwpmc/hwpmc_dmc620.c
+++ b/sys/dev/hwpmc/hwpmc_dmc620.c
@@ -232,7 +232,7 @@ CLASSDEP_FN3(dmc620_read_pmc, int, cpu, int, ri, pmc_value_t *, v)
CLASSDEP_FN3(dmc620_write_pmc, int, cpu, int, ri, pmc_value_t, v)
{
struct dmc620_descr *desc;
- struct pmc *pm;
+ struct pmc *pm __diagused;
KASSERT(cpu >= 0 && cpu < pmc_cpu_max(),
("[dmc620,%d] illegal CPU value %d", __LINE__, cpu));
@@ -353,7 +353,7 @@ CLASSDEP_FN4(dmc620_allocate_pmc, int, cpu, int, ri, struct pmc *,pm,
/* ARGSUSED0 */
CLASSDEP_FN3(dmc620_release_pmc, int, cpu, int, ri, struct pmc *, pmc)
{
- struct pmc_hw *phw;
+ struct pmc_hw *phw __diagused;
(void) pmc;
@@ -537,7 +537,7 @@ CLASSDEP_FN2(dmc620_pcpu_fini, struct pmc_mdep *, md, int, cpu)
int
dmc620_intr(struct trapframe *tf, int class, int unit, int i)
{
- struct pmc_cpu *pc;
+ struct pmc_cpu *pc __diagused;
struct pmc_hw *phw;
struct pmc *pm;
int error, cpu, ri;