OpenCloudOS-Kernel/drivers/hsi/clients
Iago Abal 3c13ab1d96 HSI: cmt_speech: Fix double spin_lock
Release &hi->lock before calling `cs_hsi_control_read_error' to avoid deadlock.

The bug was found using EBA (https://github.com/models-team/eba), which reported
the following:

    Double lock
    first at drivers/hsi/clients/cmt_speech.c:443
    second at drivers/hsi/clients/cmt_speech.c:447
    In cs_hsi_read_on_control_complete defined at drivers/hsi/clients/cmt_speech.c:438:
    (!) drivers/hsi/clients/cmt_speech.c:443: spin_lock(& hi->lock);
    (?) drivers/hsi/clients/cmt_speech.c:445: msg->status == 4 -> true
    (!) drivers/hsi/clients/cmt_speech.c:447: cs_hsi_control_read_error(hi, msg);
        (!) drivers/hsi/clients/cmt_speech.c:407: __cs_hsi_error_pre(hi, msg, "control read",
                       & hi->control_state);
            (!) drivers/hsi/clients/cmt_speech.c:382: spin_lock(& hi->lock);

Signed-off-by: Iago Abal <mail@iagoabal.eu>
Signed-off-by: Sebastian Reichel <sre@kernel.org>
2016-06-10 00:08:10 +02:00
..
Kconfig HSI: nokia-modem: Add cmt-speech support 2015-03-31 22:19:43 +02:00
Makefile HSI: cmt_speech: Add cmt-speech driver 2015-03-31 22:14:04 +02:00
cmt_speech.c HSI: cmt_speech: Fix double spin_lock 2016-06-10 00:08:10 +02:00
hsi_char.c HSI: Add channel resource support to HSI clients 2014-05-16 00:54:36 +02:00
nokia-modem.c HSI: nokia-modem: add n950 and n9 support 2016-01-28 17:46:08 +01:00
ssi_protocol.c HSI: ssi-protocol: Use handshake logic from n950 2016-01-28 17:47:56 +01:00