block,fs: use REQ_* flags directly
[linux-block.git] / include / linux / fs.h
index 46a74209917fa58d9c282a1f88778d3b1054fc1f..7a1b78ab7c1527cda6bb419aa02f4f8c58551e75 100644 (file)
@@ -151,58 +151,11 @@ typedef int (dio_iodone_t)(struct kiocb *iocb, loff_t offset,
  */
 #define CHECK_IOVEC_ONLY -1
 
-/*
- * The below are the various read and write flags that we support. Some of
- * them include behavioral modifiers that send information down to the
- * block layer and IO scheduler. They should be used along with a req_op.
- * Terminology:
- *
- *     The block layer uses device plugging to defer IO a little bit, in
- *     the hope that we will see more IO very shortly. This increases
- *     coalescing of adjacent IO and thus reduces the number of IOs we
- *     have to send to the device. It also allows for better queuing,
- *     if the IO isn't mergeable. If the caller is going to be waiting
- *     for the IO, then he must ensure that the device is unplugged so
- *     that the IO is dispatched to the driver.
- *
- *     All IO is handled async in Linux. This is fine for background
- *     writes, but for reads or writes that someone waits for completion
- *     on, we want to notify the block layer and IO scheduler so that they
- *     know about it. That allows them to make better scheduling
- *     decisions. So when the below references 'sync' and 'async', it
- *     is referencing this priority hint.
- *
- * With that in mind, the available types are:
- *
- * READ                        A normal read operation. Device will be plugged.
- * READ_SYNC           A synchronous read. Device is not plugged, caller can
- *                     immediately wait on this read without caring about
- *                     unplugging.
- * WRITE               A normal async write. Device will be plugged.
- * WRITE_SYNC          Synchronous write. Identical to WRITE, but passes down
- *                     the hint that someone will be waiting on this IO
- *                     shortly. The write equivalent of READ_SYNC.
- * WRITE_ODIRECT       Special case write for O_DIRECT only.
- * WRITE_FLUSH         Like WRITE_SYNC but with preceding cache flush.
- * WRITE_FUA           Like WRITE_SYNC but data is guaranteed to be on
- *                     non-volatile media on completion.
- * WRITE_FLUSH_FUA     Combination of WRITE_FLUSH and FUA. The IO is preceded
- *                     by a cache flush and data is guaranteed to be on
- *                     non-volatile media on completion.
- *
- */
 #define RW_MASK                        REQ_OP_WRITE
 
 #define READ                   REQ_OP_READ
 #define WRITE                  REQ_OP_WRITE
 
-#define READ_SYNC              0
-#define WRITE_SYNC             REQ_SYNC
-#define WRITE_ODIRECT          (REQ_SYNC | REQ_IDLE)
-#define WRITE_FLUSH            REQ_PREFLUSH
-#define WRITE_FUA              REQ_FUA
-#define WRITE_FLUSH_FUA                (REQ_PREFLUSH | REQ_FUA)
-
 /*
  * Attribute flags.  These should be or-ed together to figure out what
  * has been changed!