]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ice: Fix a null pointer dereference in ice_copy_and_init_pkg()
authorHaoxiang Li <haoxiang_li2024@163.com>
Thu, 3 Jul 2025 09:52:32 +0000 (17:52 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 15 Aug 2025 10:04:49 +0000 (12:04 +0200)
commit1c30093d58cd3d02d8358e2b1f4a06a0aae0bf5b
treed4b92d33cd1cfa29a205b1b99fefa3cd8a28fc9e
parent136319408756fc1083eb5c09a97ba5a07938e12c
ice: Fix a null pointer dereference in ice_copy_and_init_pkg()

commit 4ff12d82dac119b4b99b5a78b5af3bf2474c0a36 upstream.

Add check for the return value of devm_kmemdup()
to prevent potential null pointer dereference.

Fixes: c76488109616 ("ice: Implement Dynamic Device Personalization (DDP) download")
Cc: stable@vger.kernel.org
Signed-off-by: Haoxiang Li <haoxiang_li2024@163.com>
Reviewed-by: Michal Swiatkowski <michal.swiatkowski@linux.intel.com>
Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Tested-by: Rinitha S <sx.rinitha@intel.com> (A Contingent worker at Intel)
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/ethernet/intel/ice/ice_flex_pipe.c