diff mbox

[3/7] block: move REQ_RAHEAD to common flags

Message ID 1476969135-32732-4-git-send-email-hch@lst.de (mailing list archive)
State New, archived
Headers show

Commit Message

Christoph Hellwig Oct. 20, 2016, 1:12 p.m. UTC
The information that am I/O is a read-ahead can be useful for drivers.
In fact the NVMe driver already checks it, even if it won't ever be set
at the moment.

Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 include/linux/blk_types.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Shaun Tancheff Oct. 28, 2016, 7:11 a.m. UTC | #1
On Thu, Oct 20, 2016 at 8:12 AM, Christoph Hellwig <hch@lst.de> wrote:
> The information that am I/O is a read-ahead can be useful for drivers.
> In fact the NVMe driver already checks it, even if it won't ever be set
> at the moment.
>
> Signed-off-by: Christoph Hellwig <hch@lst.de>
> ---
>  include/linux/blk_types.h | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/include/linux/blk_types.h b/include/linux/blk_types.h
> index b541425..44f9bca 100644
> --- a/include/linux/blk_types.h
> +++ b/include/linux/blk_types.h
> @@ -163,9 +163,9 @@ enum rq_flag_bits {
>         __REQ_INTEGRITY,        /* I/O includes block integrity payload */
>         __REQ_FUA,              /* forced unit access */
>         __REQ_PREFLUSH,         /* request for cache flush */
> +       __REQ_RAHEAD,           /* read ahead, can fail anytime */
>
>         /* bio only flags */
> -       __REQ_RAHEAD,           /* read ahead, can fail anytime */
>         __REQ_THROTTLED,        /* This bio has already been subjected to
>                                  * throttling rules. Don't do it again. */
>
> @@ -205,7 +205,7 @@ enum rq_flag_bits {
>         (REQ_FAILFAST_DEV | REQ_FAILFAST_TRANSPORT | REQ_FAILFAST_DRIVER)
>  #define REQ_COMMON_MASK \
>         (REQ_FAILFAST_MASK | REQ_SYNC | REQ_META | REQ_PRIO | REQ_NOIDLE | \
> -        REQ_PREFLUSH | REQ_FUA | REQ_INTEGRITY | REQ_NOMERGE)
> +        REQ_PREFLUSH | REQ_FUA | REQ_INTEGRITY | REQ_NOMERGE | REQ_RAHEAD)
>  #define REQ_CLONE_MASK         REQ_COMMON_MASK
>
>  /* This mask is used for both bio and request merge checking */
> --
> 2.1.4

Reviewed-by: Shaun Tancheff <shaun.tancheff@seagate.com>

>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-block" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  https://urldefense.proofpoint.com/v2/url?u=http-3A__vger.kernel.org_majordomo-2Dinfo.html&d=DQIBAg&c=IGDlg0lD0b-nebmJJ0Kp8A&r=Wg5NqlNlVTT7Ugl8V50qIHLe856QW0qfG3WVYGOrWzA&m=XkkC-0hl62SE88NTIGyxf05FrIFOVR74KhU2MfZe7RU&s=6Clviz-d2h1fRYEApTAKfnBboE81JScmM43jCtDQeMU&e=
diff mbox

Patch

diff --git a/include/linux/blk_types.h b/include/linux/blk_types.h
index b541425..44f9bca 100644
--- a/include/linux/blk_types.h
+++ b/include/linux/blk_types.h
@@ -163,9 +163,9 @@  enum rq_flag_bits {
 	__REQ_INTEGRITY,	/* I/O includes block integrity payload */
 	__REQ_FUA,		/* forced unit access */
 	__REQ_PREFLUSH,		/* request for cache flush */
+	__REQ_RAHEAD,		/* read ahead, can fail anytime */
 
 	/* bio only flags */
-	__REQ_RAHEAD,		/* read ahead, can fail anytime */
 	__REQ_THROTTLED,	/* This bio has already been subjected to
 				 * throttling rules. Don't do it again. */
 
@@ -205,7 +205,7 @@  enum rq_flag_bits {
 	(REQ_FAILFAST_DEV | REQ_FAILFAST_TRANSPORT | REQ_FAILFAST_DRIVER)
 #define REQ_COMMON_MASK \
 	(REQ_FAILFAST_MASK | REQ_SYNC | REQ_META | REQ_PRIO | REQ_NOIDLE | \
-	 REQ_PREFLUSH | REQ_FUA | REQ_INTEGRITY | REQ_NOMERGE)
+	 REQ_PREFLUSH | REQ_FUA | REQ_INTEGRITY | REQ_NOMERGE | REQ_RAHEAD)
 #define REQ_CLONE_MASK		REQ_COMMON_MASK
 
 /* This mask is used for both bio and request merge checking */