On 10/8/19 9:35 AM, Gabriel Krisman Bertazi wrote:
André Almeida <andrealm...@collabora.com> writes:
diff --git a/include/linux/blk-mq.h b/include/linux/blk-mq.h
index e0fce93ac127..8b745f229789 100644
--- a/include/linux/blk-mq.h
+++ b/include/linux/blk-mq.h
@@ -10,74 +10,153 @@ struct blk_mq_tags;
struct blk_flush_queue;
/**
- * struct blk_mq_hw_ctx - State for a hardware queue facing the hardware block
device
+ * struct blk_mq_hw_ctx - State for a hardware queue facing the hardware
+ * block device
*/
struct blk_mq_hw_ctx {
struct {
+ /** @lock: Lock for accessing dispatch queue */
spinlock_t lock;
+ /**
+ * @dispatch: Queue of dispatched requests, waiting for
+ * workers to send them to the hardware.
+ */
It's been a few years since I looked at the block layer, but isn't
this used to hold requests that were taken from the blk_mq_ctx, but
couldn't be dispatched because the queue was full?
I don't think so. I think that you are looking for the requeue_list
member of struct request_queue.
Bart.