Module Name: src
Committed By: matt
Date: Fri Mar 30 01:04:48 UTC 2012
Modified Files:
src/sys/arch/mips/rmi [matt-nb5-mips64]: rmixl_fmn.c
Log Message:
Deal with station ids without names (not all XLS have all stations).
To generate a diff of this commit:
cvs rdiff -u -r1.1.2.11 -r1.1.2.12 src/sys/arch/mips/rmi/rmixl_fmn.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/mips/rmi/rmixl_fmn.c
diff -u src/sys/arch/mips/rmi/rmixl_fmn.c:1.1.2.11 src/sys/arch/mips/rmi/rmixl_fmn.c:1.1.2.12
--- src/sys/arch/mips/rmi/rmixl_fmn.c:1.1.2.11 Thu Jan 19 10:29:34 2012
+++ src/sys/arch/mips/rmi/rmixl_fmn.c Fri Mar 30 01:04:47 2012
@@ -790,8 +790,10 @@ rmixl_fmn_cpu_attach(struct cpu_info *ci
KASSERT(xname != NULL);
for (size_t i = 1; i < fmn_info.fmn_nstid; i++) {
- evcnt_attach_dynamic(&sc->sc_fmn_stid_evcnts[i],
- EVCNT_TYPE_MISC, NULL, xname, fmn_stid_ev_names[i]);
+ if (fmn_stid_ev_names[i][0] != '\0') {
+ evcnt_attach_dynamic(&sc->sc_fmn_stid_evcnts[i],
+ EVCNT_TYPE_MISC, NULL, xname, fmn_stid_ev_names[i]);
+ }
}
for (size_t i = 0; i < fmn_info.fmn_nbucket; i++) {
@@ -811,9 +813,11 @@ rmixl_fmn_init_thread(void)
KASSERT(fmn->fmn_stinfo[0].si_name == NULL);
for (size_t i = 1; i < fmn_info.fmn_nstid; i++) {
- KASSERT(fmn->fmn_stinfo[i].si_name != NULL);
- snprintf(fmn_stid_ev_names[i], sizeof(fmn_stid_ev_names[i]),
- "fmn %s rx msgs", fmn->fmn_stinfo[i].si_name);
+ if (fmn->fmn_stinfo[i].si_name != NULL) {
+ snprintf(fmn_stid_ev_names[i],
+ sizeof(fmn_stid_ev_names[i]),
+ "fmn %s rx msgs", fmn->fmn_stinfo[i].si_name);
+ }
}
if (CPU_IS_PRIMARY(ci)) {