[PATCH net] net: ethernet: mtk_eth_soc: fix NULL pointer on hw reset
Simon Horman
horms at kernel.org
Fri Aug 18 05:12:29 PDT 2023
On Thu, Aug 17, 2023 at 01:01:11PM +0100, Daniel Golle wrote:
> When a hardware reset is triggered on devices not initializing WED the
> calls to mtk_wed_fe_reset and mtk_wed_fe_reset_complete dereference a
> pointer on uninitialized stack memory.
> Initialize the hw_list will 0s and break out of both functions in case
> a hw_list entry is 0.
>
> Fixes: 08a764a7c51b ("net: ethernet: mtk_wed: add reset/reset_complete callbacks")
> Signed-off-by: Daniel Golle <daniel at makrotopia.org>
Reviewed-by: Simon Horman <horms at kernel.org>
More information about the Linux-mediatek
mailing list