OSDN Git Service

greybus: operation: fix incoming-response corruption
authorJohan Hovold <johan@hovoldconsulting.com>
Thu, 9 Jul 2015 13:18:01 +0000 (15:18 +0200)
committerGreg Kroah-Hartman <gregkh@google.com>
Mon, 13 Jul 2015 22:29:27 +0000 (15:29 -0700)
commite4340b13fd2cf9bcf1f0a40ae15de454ffdb74f8
treef1ee5860175a2a613032f3a28e25ff97805f4d9e
parent048a7ffe274280c27fc572ba3ec7150eba6efc40
greybus: operation: fix incoming-response corruption

Make sure not to update the response message buffer for an operation
that is already scheduled for completion.

Currently if we get two incoming responses with the same id, the second
one would overwrite the response message buffer.

Reviewed-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Johan Hovold <johan@hovoldconsulting.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
drivers/staging/greybus/operation.c