提交 15869303 编写于 作者: T Tejun Heo

[PATCH] libata: hold host_set lock while finishing internal qc

Hold host_set lock while finishing internal qc.
Signed-off-by: NTejun Heo <htejun@gmail.com>
上级 7401abf2
......@@ -1031,6 +1031,9 @@ unsigned ata_exec_internal(struct ata_port *ap, struct ata_device *dev,
spin_unlock_irqrestore(&ap->host_set->lock, flags);
}
/* finish up */
spin_lock_irqsave(&ap->host_set->lock, flags);
*tf = qc->tf;
err_mask = qc->err_mask;
......@@ -1052,6 +1055,8 @@ unsigned ata_exec_internal(struct ata_port *ap, struct ata_device *dev,
ata_port_probe(ap);
}
spin_unlock_irqrestore(&ap->host_set->lock, flags);
return err_mask;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册