git: 32cf376a01d4 - main - net80211: enhance (disabled) debugging
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 14 Feb 2022 22:18:57 UTC
The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=32cf376a01d42710ccbb1d6664ebd0a85c9e0064 commit 32cf376a01d42710ccbb1d6664ebd0a85c9e0064 Author: Bjoern A. Zeeb <bz@FreeBSD.org> AuthorDate: 2022-02-14 22:16:59 +0000 Commit: Bjoern A. Zeeb <bz@FreeBSD.org> CommitDate: 2022-02-14 22:16:59 +0000 net80211: enhance (disabled) debugging Add maxchans to the disabled debugging in addchan() and copychan_prev() to aid debugging possible errors rreturned due to reaching maxchans limits. Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/net80211/ieee80211.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/net80211/ieee80211.c b/sys/net80211/ieee80211.c index 35cf7abdbf3b..4bed673a78b9 100644 --- a/sys/net80211/ieee80211.c +++ b/sys/net80211/ieee80211.c @@ -1287,8 +1287,8 @@ addchan(struct ieee80211_channel chans[], int maxchans, int *nchans, return (ENOBUFS); #if 0 - printf("%s: %d: ieee=%d, freq=%d, flags=0x%08x\n", - __func__, *nchans, ieee, freq, flags); + printf("%s: %d of %d: ieee=%d, freq=%d, flags=0x%08x\n", + __func__, *nchans, maxchans, ieee, freq, flags); #endif c = &chans[(*nchans)++]; @@ -1317,8 +1317,8 @@ copychan_prev(struct ieee80211_channel chans[], int maxchans, int *nchans, return (ENOBUFS); #if 0 - printf("%s: %d: flags=0x%08x\n", - __func__, *nchans, flags); + printf("%s: %d of %d: flags=0x%08x\n", + __func__, *nchans, maxchans, flags); #endif c = &chans[(*nchans)++];