Re: [PATCH v9 6/6] block: loop: support DIO & AIO

From: Christoph Hellwig
Date: Fri Aug 07 2015 - 03:43:50 EST


I really disagree with the per-cmd use_dio tracking.

If we know at setup time that the loop device sector size is smaller
than the sector size of the underlying device we should never allow
dio, and othewise it should always work for data.

The ->transfer check also is one to be done at setup time, and there
is no need for draining or mode checking for an fsync - FLUSH is always
only guranteed to flush out I/O that has completed by the time it's
issued.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/