diff options
| author | Houston Hoffman <hhoffman@codeaurora.org> | 2017-03-08 16:02:41 -0800 |
|---|---|---|
| committer | Sandeep Puligilla <spuligil@codeaurora.org> | 2017-03-20 13:36:52 -0700 |
| commit | f75754ad5ccac13f25f4122d7ab0c7712030d6a8 (patch) | |
| tree | 4b92061d676f64dd200d231ba420345142789be8 | |
| parent | 3d70199bc719acbd1c2c3aa82ca7640639b26e14 (diff) | |
qcacld-3.0: Allocate hif_napi_info structures dynamically
The hif_napi_info structure has a dummy netdev included.
The dummy netdev is large. Avoiding unneeded allocation
save 30kb of memory. Dynamically allocating the
hif_napi_info structures also reduces the size of
the contiguous memory needed for the parent structure.
Change-Id: Ib2d0772cf793e25a10329169ddd8ef1dc1022e82
CRs-Fixed: 2020752
| -rw-r--r-- | core/hdd/src/wlan_hdd_napi.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/core/hdd/src/wlan_hdd_napi.c b/core/hdd/src/wlan_hdd_napi.c index 53b1b34a15c3..f616a5be3abd 100644 --- a/core/hdd/src/wlan_hdd_napi.c +++ b/core/hdd/src/wlan_hdd_napi.c @@ -302,7 +302,7 @@ static int hdd_napi_perfd_cpufreq(enum qca_napi_tput_state req_state) goto hnpc_ret; } /* switch */ - NAPI_DEBUG("CPU min freq to %d", + NAPI_DEBUG("CPU min freq to %s %d", (req.freq == 0)?"Resetting":"Setting", req.freq); /* the following service function returns void */ wlan_hdd_send_svc_nlink_msg(hdd_ctx->radio_index, @@ -479,7 +479,10 @@ int hdd_display_napi_stats(void) for (i = 0; i < CE_COUNT_MAX; i++) if (napid->ce_map & (0x01 << i)) { - napii = &(napid->napis[i]); + napii = napid->napis[i]; + if (!napii) + continue; + for (j = 0; j < NR_CPUS; j++) { napis = &(napii->stats[j]); n = 0; |
