linux_dsm_epyc7002/drivers/crypto/caam
Xulin Sun 430f13389b crypto: caam - free qman_fq after kill_fq
kill_fq removes a complete frame queue, it needs to free the qman_fq
in the last. Else kmemleak will report the below warning:

unreferenced object 0xffff800073085c80 (size 128):
  comm "cryptomgr_test", pid 199, jiffies 4294937850 (age 67.840s)
  hex dump (first 32 bytes):
    00 00 00 00 00 00 00 00 a0 80 7e 00 00 80 ff ff
    00 00 00 00 00 00 00 00 04 00 04 00 5c 01 00 00
  backtrace:
    [<ffff8000001e5760>] create_object+0xf8/0x258
    [<ffff800000994e38>] kmemleak_alloc+0x58/0xa0
    [<ffff8000001d5f18>] kmem_cache_alloc_trace+0x2c8/0x358
    [<ffff8000007e8410>] create_caam_req_fq+0x40/0x170
    [<ffff8000007e870c>] caam_drv_ctx_update+0x54/0x248
    [<ffff8000007fca54>] aead_setkey+0x154/0x300
    [<ffff800000452120>] setkey+0x50/0xf0
    [<ffff80000045b144>] __test_aead+0x5ec/0x1028
    [<ffff80000045c28c>] test_aead+0x44/0xc8
    [<ffff80000045c368>] alg_test_aead+0x58/0xd0
    [<ffff80000045bdb4>] alg_test+0x14c/0x308
    [<ffff8000004588e8>] cryptomgr_test+0x50/0x58
    [<ffff8000000c3b2c>] kthread+0xdc/0xf0
    [<ffff800000083c00>] ret_from_fork+0x10/0x50

And check where the function kill_fq() is called to remove
the additional kfree to qman_fq and avoid re-calling the released qman_fq.

Signed-off-by: Xulin Sun <xulin.sun@windriver.com>
Acked-by: Horia Geantă <horia.geanta@nxp.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2017-07-28 17:55:50 +08:00
..
caamalg_desc.c crypto: caam - fix condition for the jump over key(s) command 2017-07-18 18:16:07 +08:00
caamalg_desc.h crypto: caam/qi - add ablkcipher and authenc algorithms 2017-03-24 22:02:59 +08:00
caamalg_qi.c crypto: caam/qi - remove unused header sg_sw_sec4.h 2017-07-18 18:16:04 +08:00
caamalg.c crypto: caam/qi - fix compilation with DEBUG enabled 2017-07-18 18:16:00 +08:00
caamhash.c crypto: caam - fix signals handling 2017-07-12 18:38:04 +08:00
caampkc.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 2017-07-05 15:17:26 +08:00
caampkc.h crypto: caam - add support for RSA key form 3 2017-05-18 13:19:51 +08:00
caamrng.c crypto: caam - clean-up in caam_init_rng() 2017-07-18 18:16:07 +08:00
compat.h crypto: caam - add support for RSA algorithm 2016-07-05 23:05:24 +08:00
ctrl.c crypto: caam - remove unused variables in caam_drv_private 2017-07-18 18:16:06 +08:00
ctrl.h crypto: caam - fix ERA retrieval function 2014-02-09 09:59:27 +08:00
desc_constr.h crypto: caam - avoid double inclusion in desc_constr.h 2017-03-24 22:02:59 +08:00
desc.h crypto: caam - move sec4_sg_entry to sg_sw_sec4.h 2016-11-13 17:45:14 +08:00
error.c crypto: caam/qi - fix compilation with DEBUG enabled 2017-07-18 18:16:00 +08:00
error.h crypto: caam/qi - fix compilation with DEBUG enabled 2017-07-18 18:16:00 +08:00
intern.h crypto: caam - remove unused variables in caam_drv_private 2017-07-18 18:16:06 +08:00
jr.c crypto: caam - make of_device_ids const. 2017-06-20 11:21:49 +08:00
jr.h crypto: caam - Add API's to allocate/free Job Rings 2013-10-30 12:02:57 +08:00
Kconfig crypto: caam/qi - add ablkcipher and authenc algorithms 2017-03-24 22:02:59 +08:00
key_gen.c crypto: caam - fix signals handling 2017-07-12 18:38:04 +08:00
key_gen.h crypto: caam - consolidate split key length computation 2016-11-28 21:23:23 +08:00
Makefile crypto: caam/qi - add ablkcipher and authenc algorithms 2017-03-24 22:02:59 +08:00
pdb.h crypto: caam - add support for RSA key form 3 2017-05-18 13:19:51 +08:00
pkc_desc.c crypto: caam - add support for RSA key form 3 2017-05-18 13:19:51 +08:00
qi.c crypto: caam - free qman_fq after kill_fq 2017-07-28 17:55:50 +08:00
qi.h crypto: caam/qi - handle large number of S/Gs case 2017-07-18 18:16:02 +08:00
regs.h crypto: caam - treat SGT address pointer as u64 2016-10-02 22:33:45 +08:00
sg_sw_qm.h crypto: caam/qi - add ablkcipher and authenc algorithms 2017-03-24 22:02:59 +08:00
sg_sw_sec4.h crypto: caam - remove unused sg_to_sec4_sg_len() 2017-07-18 18:16:05 +08:00