summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorAnca Jeanina FLOAREA <anca.floarea@freescale.com>2013-10-02 11:22:13 (GMT)
committerRivera Jose-B46482 <German.Rivera@freescale.com>2013-10-02 22:07:35 (GMT)
commite24a4496ed2c184db5cd401abbfca5f304d751c6 (patch)
tree3933f90fa4a9b371daffa280291399515f84a9bd /drivers
parentc47eaed207b4c979000215bf38da5ec291ccb02f (diff)
downloadlinux-fsl-qoriq-e24a4496ed2c184db5cd401abbfca5f304d751c6.tar.xz
dpa_offload: Fix de-allocation of uninitialized value
The tbl pointer is dereference without it being previously initialized. The code should use variable cnode instead of tbl in case DPA Stats counters of type DPA_STATS_CNT_CLASSIF_NODE is being created. Signed-off-by: Anca Jeanina FLOAREA <anca.floarea@freescale.com> Change-Id: I10f8cd233f850c339e82d44522f2005dfb9ab27f Reviewed-on: http://git.am.freescale.net:8181/5149 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Marian-Cornel Chereji <marian.chereji@freescale.com> Reviewed-by: Rivera Jose-B46482 <German.Rivera@freescale.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/staging/fsl_dpa_offload/wrp_dpa_stats.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/fsl_dpa_offload/wrp_dpa_stats.c b/drivers/staging/fsl_dpa_offload/wrp_dpa_stats.c
index 6784cf5..f141aa8 100644
--- a/drivers/staging/fsl_dpa_offload/wrp_dpa_stats.c
+++ b/drivers/staging/fsl_dpa_offload/wrp_dpa_stats.c
@@ -1047,7 +1047,7 @@ create_cls_counter_cleanup:
kfree(cnode->keys[i]);
}
/* Restore user-space pointers */
- tbl->keys = us_keys;
+ cnode->keys = us_keys;
break;
case DPA_STATS_CNT_IPSEC:
kfree(sa_ids);