- Use malloc(9) for ieee80211req_wpaie2 (518 bytes, used in ieee80211_ioctl_getwpaie()) and ieee80211_scan_req (128 bytes, used in setmlme_assoc_adhoc() and ieee80211_ioctl_scanreq()) structures.
- Drop __noinline workarounds; stack overflow is not reproducible with recent compilers.
Details
- Reviewers
adrian - Commits
- rS294697: net80211: reduce stack usage for ieee80211_ioctl*() methods.
Tested with Clang 3.7.1, GCC 4.2.1 (from 9.3-RELEASE) and 4.9.4 (with -fstack-usage flag)
Stats from GCC 4.9.4:
ieee80211_ioctl.c:254:1:get_scan_space 8 static
ieee80211_ioctl.c:755:1:dummy_ioctl_get 4 static
ieee80211_ioctl.c:1830:1:findchannel 48 static
ieee80211_ioctl.c:2577:1:dummy_ioctl_set 4 static
ieee80211_ioctl.c:263:1:get_scan_result 64 dynamic,bounded
ieee80211_ioctl.c:377:1:get_sta_info 56 dynamic,bounded
ieee80211_ioctl.c:2404:1:ieee80211_scanreq 72 dynamic,bounded
ieee80211_ioctl.c:363:1:get_sta_space 4 static
ieee80211_ioctl.c:622:1:getappie.isra.8 24 dynamic,bounded
ieee80211_ioctl.c:2222:1:setappie.isra.17 40 dynamic,bounded
ieee80211_ioctl.c:1492:1:mlmelookup 24 dynamic,bounded
ieee80211_ioctl.c:1916:1:setcurchan 32 dynamic,bounded
ieee80211_ioctl.c:1251:1:mlmedebug 28 dynamic,bounded
ieee80211_ioctl.c:1292:1:domlme 24 dynamic,bounded
ieee80211_ioctl.c:3292:1:ieee80211_ioctl 188 dynamic,bounded
Diff Detail
- Repository
- rS FreeBSD src repository - subversion
- Lint
Lint Skipped - Unit
Tests Skipped
Event Timeline
looks fine!
sys/net80211/ieee80211_ioctl.c | ||
---|---|---|
925 | Just a as a note - I'd rather you just commit this duplicate code removal as a separate commit, rather than part of the memory allocation tidyup. |