Thread (179 messages) 179 messages, 3 authors, 2015-03-19
STALE4126d

[PATCH 3.12 105/175] mei: make device disabled on stop unconditionally

From: Jiri Slaby <hidden>
Date: 2015-03-17 09:02:40
Also in: lkml
Subsystem: char and misc drivers, intel management engine (mei), the rest · Maintainers: Arnd Bergmann, Greg Kroah-Hartman, Alexander Usyskin, Linus Torvalds

From: Alexander Usyskin <alexander.usyskin@intel.com>

3.12-stable review patch.  If anyone has any objections, please let me know.

===============

commit 6c15a8516b8118eb19a59fd0bd22df41b9101c32 upstream.

Set the internal device state to to disabled after hardware reset in stop flow.
This will cover cases when driver was not brought to disabled state because of
an error and in stop flow we wish not to retry the reset.

Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com>
Signed-off-by: Tomas Winkler <redacted>
Signed-off-by: Jiri Slaby <redacted>
---
 drivers/misc/mei/init.c | 2 ++
 1 file changed, 2 insertions(+)
diff --git a/drivers/misc/mei/init.c b/drivers/misc/mei/init.c
index 3fd43b0e69d1..65bcebb89260 100644
--- a/drivers/misc/mei/init.c
+++ b/drivers/misc/mei/init.c
@@ -228,6 +228,8 @@ void mei_stop(struct mei_device *dev)
 
 	dev->dev_state = MEI_DEV_POWER_DOWN;
 	mei_reset(dev, 0);
+	/* move device to disabled state unconditionally */
+	dev->dev_state = MEI_DEV_DISABLED;
 
 	mutex_unlock(&dev->device_lock);
 
-- 
2.3.0
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help