mei: fix NULL dereferencing during FW initiated disconnection
In the case when disconnection is initiated from the FW the driver is flushing items from the write control list while iterating over it: mei_irq_write_handler() list_for_each_entry_safe(ctrl_wr_list) <-- outer loop mei_cl_irq_disconnect_rsp() mei_cl_set_disconnected() mei_io_list_flush(ctrl_wr_list) <-- destorying list We move the list flushing to the completion routine. Cc: <stable@vger.kernel.org> #4.2+ Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Šī revīzija ir iekļauta:

revīziju iesūtīja
Greg Kroah-Hartman

vecāks
cc25aa94e4
revīzija
6a8d648c8d
@@ -1766,6 +1766,10 @@ void mei_cl_complete(struct mei_cl *cl, struct mei_cl_cb *cb)
|
||||
if (waitqueue_active(&cl->wait))
|
||||
wake_up(&cl->wait);
|
||||
|
||||
break;
|
||||
case MEI_FOP_DISCONNECT_RSP:
|
||||
mei_io_cb_free(cb);
|
||||
mei_cl_set_disconnected(cl);
|
||||
break;
|
||||
default:
|
||||
BUG_ON(0);
|
||||
|
Atsaukties uz šo jaunā problēmā
Block a user