Bläddra i källkod

cnss_prealloc: clean up prealloc mempool and cache on deinit

Cnss prealloc is trying to allocate memory from mempool
for wlan host driver even after cnss prealloc pool has been
destroyed by platform driver because mempool and cache is
not cleaned up on cnss pool deinit. Clean up mempool and
cache on prealloc deinit.

Change-Id: If28a27f5a21441e8650bb846ded889a33580ceaf
CRs-Fixed: 3488178
Sandeep Singh 1 år sedan
förälder
incheckning
32e1756a19
1 ändrade filer med 2 tillägg och 0 borttagningar
  1. 2 0
      cnss_prealloc/cnss_prealloc.c

+ 2 - 0
cnss_prealloc/cnss_prealloc.c

@@ -166,6 +166,8 @@ static void cnss_pool_deinit(void)
 			cnss_pools[i].name);
 		mempool_destroy(cnss_pools[i].mp);
 		kmem_cache_destroy(cnss_pools[i].cache);
+		cnss_pools[i].mp = NULL;
+		cnss_pools[i].cache = NULL;
 	}
 }