patch "mei: hbm: drop hbm responses on early shutdown" added to char-misc-linus
Subsystems (3)
This is a note to let you know that I've just added the patch titled
mei: hbm: drop hbm responses on early shutdown
to my char-misc git tree which can be found at
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc.git
in the char-misc-linus branch.
The patch will show up in the next release of the linux-next tree (usually sometime within the next 24 hours during the week.)
The patch will hopefully also be merged in Linus's tree for the next -rc kernel release.
If you have any questions about this process, please let me know.
From 6d7163f2c49fda5658e43105a96b555c89a4548d Mon Sep 17 00:00:00 2001
From: Alexander Usyskin <[email protected]>
Date: Wed, 13 Oct 2021 10:45:52 +0300
Subject: mei: hbm: drop hbm responses on early shutdown
Drop HBM responses also in the early shutdown phase where
the usual traffic is allowed.
Extend the rule that drop HBM responses received during the shutdown phase by also in MEI_DEV_POWERING_DOWN state.
This resolves the stall if the driver is stopping in the middle of the link init or link reset.
--- drivers/misc/mei/hbm.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-)
drivers/misc/mei/hbm.c +8 -4
@@ -1298,7 +1298,8 @@ int mei_hbm_dispatch(struct mei_device *dev, struct mei_msg_hdr *hdr)if (dev->dev_state !=MEI_DEV_INIT_CLIENTS || dev->hbm_state !=MEI_HBM_STARTING ) { -if (dev->dev_state ==MEI_DEV_POWER_DOWN ) { +if (dev->dev_state ==MEI_DEV_POWER_DOWN || + dev->dev_state ==MEI_DEV_POWERING_DOWN ) {dev_dbg (dev->dev,"hbm: start: on shutdown, ignoring\n" );return 0 ; }
@@ -1381,7 +1382,8 @@ int mei_hbm_dispatch(struct mei_device *dev, struct mei_msg_hdr *hdr)if (dev->dev_state !=MEI_DEV_INIT_CLIENTS || dev->hbm_state !=MEI_HBM_DR_SETUP ) { -if (dev->dev_state ==MEI_DEV_POWER_DOWN ) { +if (dev->dev_state ==MEI_DEV_POWER_DOWN || + dev->dev_state ==MEI_DEV_POWERING_DOWN ) {dev_dbg (dev->dev,"hbm: dma setup response: on shutdown, ignoring\n" );return 0 ; }
@@ -1448,7 +1450,8 @@ int mei_hbm_dispatch(struct mei_device *dev, struct mei_msg_hdr *hdr)if (dev->dev_state !=MEI_DEV_INIT_CLIENTS || dev->hbm_state !=MEI_HBM_CLIENT_PROPERTIES ) { -if (dev->dev_state ==MEI_DEV_POWER_DOWN ) { +if (dev->dev_state ==MEI_DEV_POWER_DOWN || + dev->dev_state ==MEI_DEV_POWERING_DOWN ) {dev_dbg (dev->dev,"hbm: properties response: on shutdown, ignoring\n" );return 0 ; }
@@ -1490,7 +1493,8 @@ int mei_hbm_dispatch(struct mei_device *dev, struct mei_msg_hdr *hdr)if (dev->dev_state !=MEI_DEV_INIT_CLIENTS || dev->hbm_state !=MEI_HBM_ENUM_CLIENTS ) { -if (dev->dev_state ==MEI_DEV_POWER_DOWN ) { +if (dev->dev_state ==MEI_DEV_POWER_DOWN || + dev->dev_state ==MEI_DEV_POWERING_DOWN ) {dev_dbg (dev->dev,"hbm: enumeration response: on shutdown, ignoring\n" );return 0 ; }
Signature · 1 line
2.33.0