All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] xfs: chain bios the right way around in xfs_rw_bdev
@ 2019-07-09 15:23 Christoph Hellwig
  2019-07-09 15:45 ` Darrick J. Wong
  2019-07-09 22:27 ` Dave Chinner
  0 siblings, 2 replies; 3+ messages in thread
From: Christoph Hellwig @ 2019-07-09 15:23 UTC (permalink / raw)
  To: linux-xfs; +Cc: Dave Chinner

We need to chain the earlier bios to the later ones, so that
submit_bio_wait waits on the bio that all the completions are
dispatched to.

Fixes: 6ad5b3255b9e ("xfs: use bios directly to read and write the log recovery buffers")
Reported-by: Dave Chinner <david@fromorbit.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 fs/xfs/xfs_bio_io.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/xfs/xfs_bio_io.c b/fs/xfs/xfs_bio_io.c
index 757c1d9293eb..e2148f2d5d6b 100644
--- a/fs/xfs/xfs_bio_io.c
+++ b/fs/xfs/xfs_bio_io.c
@@ -43,7 +43,7 @@ xfs_rw_bdev(
 			bio_copy_dev(bio, prev);
 			bio->bi_iter.bi_sector = bio_end_sector(prev);
 			bio->bi_opf = prev->bi_opf;
-			bio_chain(bio, prev);
+			bio_chain(prev, bio);
 
 			submit_bio(prev);
 		}
-- 
2.20.1

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] xfs: chain bios the right way around in xfs_rw_bdev
  2019-07-09 15:23 [PATCH] xfs: chain bios the right way around in xfs_rw_bdev Christoph Hellwig
@ 2019-07-09 15:45 ` Darrick J. Wong
  2019-07-09 22:27 ` Dave Chinner
  1 sibling, 0 replies; 3+ messages in thread
From: Darrick J. Wong @ 2019-07-09 15:45 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: linux-xfs, Dave Chinner

On Tue, Jul 09, 2019 at 08:23:52AM -0700, Christoph Hellwig wrote:
> We need to chain the earlier bios to the later ones, so that
> submit_bio_wait waits on the bio that all the completions are
> dispatched to.
> 
> Fixes: 6ad5b3255b9e ("xfs: use bios directly to read and write the log recovery buffers")
> Reported-by: Dave Chinner <david@fromorbit.com>
> Signed-off-by: Christoph Hellwig <hch@lst.de>

Looks ok to me; anyone else want to add a tested-by?

Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>

--D

> ---
>  fs/xfs/xfs_bio_io.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/fs/xfs/xfs_bio_io.c b/fs/xfs/xfs_bio_io.c
> index 757c1d9293eb..e2148f2d5d6b 100644
> --- a/fs/xfs/xfs_bio_io.c
> +++ b/fs/xfs/xfs_bio_io.c
> @@ -43,7 +43,7 @@ xfs_rw_bdev(
>  			bio_copy_dev(bio, prev);
>  			bio->bi_iter.bi_sector = bio_end_sector(prev);
>  			bio->bi_opf = prev->bi_opf;
> -			bio_chain(bio, prev);
> +			bio_chain(prev, bio);
>  
>  			submit_bio(prev);
>  		}
> -- 
> 2.20.1
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] xfs: chain bios the right way around in xfs_rw_bdev
  2019-07-09 15:23 [PATCH] xfs: chain bios the right way around in xfs_rw_bdev Christoph Hellwig
  2019-07-09 15:45 ` Darrick J. Wong
@ 2019-07-09 22:27 ` Dave Chinner
  1 sibling, 0 replies; 3+ messages in thread
From: Dave Chinner @ 2019-07-09 22:27 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: linux-xfs

On Tue, Jul 09, 2019 at 08:23:52AM -0700, Christoph Hellwig wrote:
> We need to chain the earlier bios to the later ones, so that
> submit_bio_wait waits on the bio that all the completions are
> dispatched to.
> 
> Fixes: 6ad5b3255b9e ("xfs: use bios directly to read and write the log recovery buffers")
> Reported-by: Dave Chinner <david@fromorbit.com>

Reported-and-Tested-by: Dave Chinner <david@fromorbit.com>

-- 
Dave Chinner
david@fromorbit.com

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-07-09 22:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-09 15:23 [PATCH] xfs: chain bios the right way around in xfs_rw_bdev Christoph Hellwig
2019-07-09 15:45 ` Darrick J. Wong
2019-07-09 22:27 ` Dave Chinner

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.