1
0
Fork 0
mirror of synced 2025-03-06 20:59:54 +01:00
linux/drivers/crypto/intel/qat/qat_common
Herbert Xu d3b17c6d9d crypto: qat - Fix ADF_DEV_RESET_SYNC memory leak
Using completion_done to determine whether the caller has gone
away only works after a complete call.  Furthermore it's still
possible that the caller has not yet called wait_for_completion,
resulting in another potential UAF.

Fix this by making the caller use cancel_work_sync and then freeing
the memory safely.

Fixes: 7d42e09760 ("crypto: qat - resolve race condition during AER recovery")
Cc: <stable@vger.kernel.org> #6.8+
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Reviewed-by: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2024-05-17 18:55:07 +08:00
..
adf_accel_devices.h crypto: qat - implement interface for live migration 2024-04-02 10:47:43 +08:00
adf_accel_engine.c crypto: qat - change signature of uof_get_num_objs() 2023-12-22 12:30:19 +08:00
adf_admin.c crypto: qat - add admin msgs for telemetry 2023-12-29 11:25:55 +08:00
adf_admin.h crypto: qat - add admin msgs for telemetry 2023-12-29 11:25:55 +08:00
adf_aer.c crypto: qat - Fix ADF_DEV_RESET_SYNC memory leak 2024-05-17 18:55:07 +08:00
adf_cfg.c
adf_cfg.h
adf_cfg_common.h crypto: qat - add support for 420xx devices 2023-12-22 12:30:19 +08:00
adf_cfg_services.c crypto: qat - relocate and rename get_service_enabled() 2023-12-22 12:30:19 +08:00
adf_cfg_services.h crypto: qat - relocate and rename get_service_enabled() 2023-12-22 12:30:19 +08:00
adf_cfg_strings.h crypto: qat - re-enable sriov after pf reset 2024-02-09 12:57:18 +08:00
adf_cfg_user.h
adf_clock.c crypto: qat - avoid division by zero 2024-02-24 08:41:20 +08:00
adf_clock.h crypto: qat - add measure clock frequency 2023-07-20 22:16:11 +12:00
adf_cnv_dbgfs.c crypto: qat - removed unused macro in adf_cnv_dbgfs.c 2024-02-24 08:41:20 +08:00
adf_cnv_dbgfs.h crypto: qat - add cnv_errors debugfs file 2023-10-13 18:31:07 +08:00
adf_common_drv.h crypto: qat - adf_get_etr_base() helper 2024-04-02 10:47:43 +08:00
adf_ctl_drv.c
adf_dbgfs.c crypto: qat - add support for device telemetry 2023-12-29 11:25:55 +08:00
adf_dbgfs.h crypto: qat - add missing function declaration in adf_dbgfs.h 2023-06-06 12:13:19 +08:00
adf_dev_mgr.c crypto: qat - remove unnecessary description from comment 2024-02-24 08:41:20 +08:00
adf_fw_config.h crypto: qat - move fw config related structures 2023-12-22 12:30:19 +08:00
adf_fw_counters.c crypto: qat - move admin api 2023-10-27 18:04:28 +08:00
adf_fw_counters.h crypto: qat - add fw_counters debugfs file 2023-07-20 22:15:30 +12:00
adf_gen2_config.c crypto: qat - add heartbeat feature 2023-07-20 22:16:23 +12:00
adf_gen2_config.h
adf_gen2_dc.c
adf_gen2_dc.h
adf_gen2_hw_csr_data.c crypto: qat - relocate CSR access code 2024-04-02 10:47:43 +08:00
adf_gen2_hw_csr_data.h crypto: qat - relocate CSR access code 2024-04-02 10:47:43 +08:00
adf_gen2_hw_data.c crypto: qat - relocate CSR access code 2024-04-02 10:47:43 +08:00
adf_gen2_hw_data.h crypto: qat - relocate CSR access code 2024-04-02 10:47:43 +08:00
adf_gen2_pfvf.c
adf_gen2_pfvf.h
adf_gen4_config.c crypto: qat - relocate portions of qat_4xxx code 2023-12-22 12:30:19 +08:00
adf_gen4_config.h crypto: qat - relocate portions of qat_4xxx code 2023-12-22 12:30:19 +08:00
adf_gen4_dc.c
adf_gen4_dc.h
adf_gen4_hw_csr_data.c crypto: qat - expand CSR operations for QAT GEN4 devices 2024-04-02 10:47:43 +08:00
adf_gen4_hw_csr_data.h crypto: qat - expand CSR operations for QAT GEN4 devices 2024-04-02 10:47:43 +08:00
adf_gen4_hw_data.c crypto: qat - add bank save and restore flows 2024-04-02 10:47:43 +08:00
adf_gen4_hw_data.h crypto: qat - implement interface for live migration 2024-04-02 10:47:43 +08:00
adf_gen4_pfvf.c crypto: qat - relocate and rename 4xxx PF2VM definitions 2024-04-02 10:47:43 +08:00
adf_gen4_pfvf.h
adf_gen4_pm.c crypto: qat - move admin api 2023-10-27 18:04:28 +08:00
adf_gen4_pm.h crypto: qat - add pm_status debugfs file 2023-10-13 18:31:07 +08:00
adf_gen4_pm_debugfs.c crypto: qat - move admin api 2023-10-27 18:04:28 +08:00
adf_gen4_ras.c crypto: qat - remove double initialization of value 2024-02-24 08:41:20 +08:00
adf_gen4_ras.h crypto: qat - add handling of errors from ERRSOU3 for QAT GEN4 2023-10-27 18:04:27 +08:00
adf_gen4_timer.c crypto: qat - move admin api 2023-10-27 18:04:28 +08:00
adf_gen4_timer.h crypto: qat - add internal timer for qat 4xxx 2023-07-20 22:16:01 +12:00
adf_gen4_tl.c crypto: qat - validate slices count returned by FW 2024-04-26 17:26:09 +08:00
adf_gen4_tl.h crypto: qat - add support for ring pair level telemetry 2023-12-29 11:25:56 +08:00
adf_gen4_vf_mig.c crypto: qat - Fix spelling mistake "Invalide" -> "Invalid" 2024-04-12 15:07:51 +08:00
adf_gen4_vf_mig.h crypto: qat - add interface for live migration 2024-04-02 10:47:43 +08:00
adf_heartbeat.c crypto: qat - limit heartbeat notifications 2024-02-09 12:57:18 +08:00
adf_heartbeat.h crypto: qat - limit heartbeat notifications 2024-02-09 12:57:18 +08:00
adf_heartbeat_dbgfs.c crypto: qat - uninitialized variable in adf_hb_error_inject_write() 2024-02-24 08:41:20 +08:00
adf_heartbeat_dbgfs.h crypto: qat - add heartbeat feature 2023-07-20 22:16:23 +12:00
adf_heartbeat_inject.c crypto: qat - add heartbeat error simulator 2024-02-09 12:57:18 +08:00
adf_hw_arbiter.c crypto: qat - add heartbeat error simulator 2024-02-09 12:57:18 +08:00
adf_init.c crypto: qat - add fatal error notify method 2024-02-09 12:57:18 +08:00
adf_isr.c crypto: qat - remove unnecessary description from comment 2024-02-24 08:41:20 +08:00
adf_mstate_mgr.c crypto: qat - implement interface for live migration 2024-04-02 10:47:43 +08:00
adf_mstate_mgr.h crypto: qat - implement interface for live migration 2024-04-02 10:47:43 +08:00
adf_pfvf_msg.h crypto: qat - update PFVF protocol for recovery 2024-02-09 12:57:18 +08:00
adf_pfvf_pf_msg.c crypto: qat - update PFVF protocol for recovery 2024-02-09 12:57:18 +08:00
adf_pfvf_pf_msg.h crypto: qat - update PFVF protocol for recovery 2024-02-09 12:57:18 +08:00
adf_pfvf_pf_proto.c crypto: qat - move PFVF compat checker to a function 2024-04-02 10:47:43 +08:00
adf_pfvf_pf_proto.h
adf_pfvf_utils.c
adf_pfvf_utils.h crypto: qat - move PFVF compat checker to a function 2024-04-02 10:47:43 +08:00
adf_pfvf_vf_msg.c
adf_pfvf_vf_msg.h
adf_pfvf_vf_proto.c crypto: qat - update PFVF protocol for recovery 2024-02-09 12:57:18 +08:00
adf_pfvf_vf_proto.h
adf_pm_dbgfs.c crypto: qat - add pm_status debugfs file 2023-10-13 18:31:07 +08:00
adf_pm_dbgfs.h crypto: qat - add pm_status debugfs file 2023-10-13 18:31:07 +08:00
adf_rl.c crypto: qat - improve error logging to be consistent across features 2024-04-19 18:54:19 +08:00
adf_rl.h crypto: qat - rename get_sla_arr_of_type() 2024-04-02 10:47:43 +08:00
adf_rl_admin.c crypto: qat - add rate limiting feature to qat_4xxx 2023-10-27 18:04:28 +08:00
adf_rl_admin.h crypto: qat - add rate limiting feature to qat_4xxx 2023-10-27 18:04:28 +08:00
adf_sriov.c crypto: qat - implement interface for live migration 2024-04-02 10:47:43 +08:00
adf_sysfs.c crypto: qat - add auto reset on error 2024-02-09 12:57:18 +08:00
adf_sysfs_ras_counters.c crypto: qat - add sysfs_added flag for ras 2023-12-01 18:03:26 +08:00
adf_sysfs_ras_counters.h crypto: qat - add error counters 2023-10-27 18:04:27 +08:00
adf_sysfs_rl.c crypto: qat - add sysfs_added flag for rate limiting 2023-12-01 18:03:26 +08:00
adf_sysfs_rl.h crypto: qat - add rate limiting sysfs interface 2023-10-27 18:04:28 +08:00
adf_telemetry.c crypto: qat - validate slices count returned by FW 2024-04-26 17:26:09 +08:00
adf_telemetry.h crypto: qat - validate slices count returned by FW 2024-04-26 17:26:09 +08:00
adf_tl_debugfs.c crypto: qat - add support for ring pair level telemetry 2023-12-29 11:25:56 +08:00
adf_tl_debugfs.h crypto: qat - add support for ring pair level telemetry 2023-12-29 11:25:56 +08:00
adf_transport.c crypto: qat - adf_get_etr_base() helper 2024-04-02 10:47:43 +08:00
adf_transport.h
adf_transport_access_macros.h
adf_transport_debug.c crypto: qat - increase size of buffers 2023-10-01 16:28:15 +08:00
adf_transport_internal.h
adf_vf_isr.c crypto: qat - remove unnecessary description from comment 2024-02-24 08:41:20 +08:00
icp_qat_fw.h
icp_qat_fw_comp.h
icp_qat_fw_init_admin.h crypto: qat - add admin msgs for telemetry 2023-12-29 11:25:55 +08:00
icp_qat_fw_la.h
icp_qat_fw_loader_handle.h
icp_qat_fw_pke.h
icp_qat_hal.h
icp_qat_hw.h crypto: qat - add support for 420xx devices 2023-12-22 12:30:19 +08:00
icp_qat_hw_20_comp.h
icp_qat_hw_20_comp_defs.h
icp_qat_uclo.h crypto: qat - add support for 420xx devices 2023-12-22 12:30:19 +08:00
Makefile crypto: qat - implement interface for live migration 2024-04-02 10:47:43 +08:00
qat_algs.c crypto: qat - move returns to default case 2023-06-16 20:30:35 +08:00
qat_algs_send.c crypto: qat - fix deadlock in backlog processing 2023-10-27 18:04:28 +08:00
qat_algs_send.h
qat_asym_algs.c crypto: qat - implement dh fallback for primes > 4K 2024-04-19 18:54:18 +08:00
qat_bl.c crypto: qat - Avoid -Wflex-array-member-not-at-end warnings 2024-04-05 15:45:59 +08:00
qat_bl.h crypto: qat - Avoid -Wflex-array-member-not-at-end warnings 2024-04-05 15:45:59 +08:00
qat_comp_algs.c crypto: qat - remove unused macros in qat_comp_alg.c 2024-02-24 08:41:20 +08:00
qat_comp_req.h
qat_compression.c crypto: qat - use kfree_sensitive instead of memset/kfree() 2023-08-11 19:19:27 +08:00
qat_compression.h
qat_crypto.c crypto: qat - fix comment structure 2024-02-24 08:41:20 +08:00
qat_crypto.h
qat_hal.c crypto: qat - add support for 420xx devices 2023-12-22 12:30:19 +08:00
qat_mig_dev.c crypto: qat - add interface for live migration 2024-04-02 10:47:43 +08:00
qat_uclo.c crypto: qat - add support for 420xx devices 2023-12-22 12:30:19 +08:00