ice: use bitmap_free instead of devm_kfree
Subsystems (2)
PATCH 1/1 ice: use bitmap_free instead of devm_kfree
pf->avail_txqs was allocated using bitmap_zalloc, bitmap_free should be used to free this memory.
Fixes 78b5713ac1241 ("ice: Alloc queue management bitmaps and arrays dynamically")
Signed-off-by Michal Swiatkowski <[email protected]>
--- drivers/net/ethernet/intel/ice/ice_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/intel/ice/ice_main.c +1 -1
@@ -3926,7 +3926,7 @@ static int ice_init_pf(struct ice_pf *pf) pf->avail_rxqs =bitmap_zalloc (pf->max_pf_rxqs,GFP_KERNEL );if (!pf->avail_rxqs) { -devm_kfree (ice_pf_to_dev (pf), pf->avail_txqs); +bitmap_free (pf->avail_txqs); pf->avail_txqs =NULL ;return -ENOMEM ; }
Signature · 6 lines
2.36.1 _______________________________________________ Intel-wired-lan mailing list [email protected] https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
Quoted 13 lines
-----Original Message-----
From: Intel-wired-lan <[email protected]> On Behalf Of Michal Swiatkowski
Sent: Wednesday, August 17, 2022 2:23 PM
To: [email protected]
Subject: [Intel-wired-lan] [PATCH net v1] ice: usebitmap_freeinstead ofdevm_kfree
pf->avail_txqswas allocated usingbitmap_zalloc,bitmap_freeshould be used to free this memory.
Quoted 7 lines
Fixes 78b5713ac1241 ("ice: Alloc queue management bitmaps and arraysdynamically")
Signed-off-by Michal Swiatkowski <[email protected]>--- drivers/net/ethernet/intel/ice/ice_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan