linux/net/ncsi
Paul Fertser 2677640f7f net/ncsi: wait for the last response to Deselect Package before configuring channel
commit 6bb194d036 upstream.

The NCSI state machine as it's currently implemented assumes that
transition to the next logical state is performed either explicitly by
calling `schedule_work(&ndp->work)` to re-queue itself or implicitly
after processing the predefined (ndp->pending_req_num) number of
replies. Thus to avoid the configuration FSM from advancing prematurely
and getting out of sync with the process it's essential to not skip
waiting for a reply.

This patch makes the code wait for reception of the Deselect Package
response for the last package probed before proceeding to channel
configuration.

Thanks go to Potin Lai and Cosmo Chou for the initial investigation and
testing.

Fixes: 8e13f70be0 ("net/ncsi: Probe single packages to avoid conflict")
Cc: stable@vger.kernel.org
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Link: https://patch.msgid.link/20250116152900.8656-1-fercerpav@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2025-02-17 10:05:41 +01:00
..
internal.h net/ncsi: fix locking in Get MAC Address handling 2025-01-23 17:23:00 +01:00
Kconfig net/ncsi: add NCSI Intel OEM command to keep PHY up 2021-07-08 14:16:39 -07:00
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
ncsi-aen.c Revert ncsi: Propagate carrier gain/loss events to the NCSI controller 2023-11-15 09:59:44 +00:00
ncsi-cmd.c net/ncsi: Add NC-SI 1.2 Get MC MAC Address command 2023-11-18 15:00:51 +00:00
ncsi-manage.c net/ncsi: wait for the last response to Deselect Package before configuring channel 2025-02-17 10:05:41 +01:00
ncsi-netlink.c net/ncsi: Fix netlink major/minor version numbers 2023-11-18 15:00:51 +00:00
ncsi-netlink.h genetlink: make genl_info->nlhdr const 2023-08-15 14:54:44 -07:00
ncsi-pkt.h net/ncsi: Add NC-SI 1.2 Get MC MAC Address command 2023-11-18 15:00:51 +00:00
ncsi-rsp.c net/ncsi: use dev_set_mac_address() for Get MC MAC Address handling 2025-02-08 09:58:05 +01:00