]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
EDAC/igen6: Fix error handling in igen6_edac driver
authorMa Ke <make24@iscas.ac.cn>
Wed, 5 Nov 2025 09:02:44 +0000 (17:02 +0800)
committerTony Luck <tony.luck@intel.com>
Fri, 21 Nov 2025 18:20:51 +0000 (10:20 -0800)
commitef1b6d904993d3a21baa7d4105e1a4e4ba9dd6de
tree72e8b100b2b619c7e405f91238296ac133862dbc
parent5f40ea7f41773d996d92db8bde600199200adc11
EDAC/igen6: Fix error handling in igen6_edac driver

The igen6_edac driver calls device_initialize() for all memory
controllers in igen6_register_mci(), but misses corresponding
put_device() calls in error paths and during normal shutdown in
igen6_unregister_mcis().

Adding the missing put_device() calls improves code readability and
ensures proper reference counting for the device structure.

Found by code review.

Signed-off-by: Ma Ke <make24@iscas.ac.cn>
Reviewed-by: Qiuxu Zhuo <qiuxu.zhuo@intel.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
Link: https://patch.msgid.link/20251105090244.23327-1-make24@iscas.ac.cn
drivers/edac/igen6_edac.c