Commit eb100b8f authored by Mika Westerberg's avatar Mika Westerberg

thunderbolt: Use the actual buffer in tb_async_error()

The received notification packet is held in pkg->buffer and not in pkg
itself. Fix this by using the correct buffer.

Fixes: 81a54b5e ("thunderbolt: Let the connection manager handle all notifications")
Cc: stable@vger.kernel.org
Signed-off-by: default avatarMika Westerberg <mika.westerberg@linux.intel.com>
parent 568035b0
...@@ -407,7 +407,7 @@ static void tb_ctl_rx_submit(struct ctl_pkg *pkg) ...@@ -407,7 +407,7 @@ static void tb_ctl_rx_submit(struct ctl_pkg *pkg)
static int tb_async_error(const struct ctl_pkg *pkg) static int tb_async_error(const struct ctl_pkg *pkg)
{ {
const struct cfg_error_pkg *error = (const struct cfg_error_pkg *)pkg; const struct cfg_error_pkg *error = pkg->buffer;
if (pkg->frame.eof != TB_CFG_PKG_ERROR) if (pkg->frame.eof != TB_CFG_PKG_ERROR)
return false; return false;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment