lkml.org 
[lkml]   [2018]   [Dec]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Spurious EIO on AIO+DIO+RWF_NOWAIT
On 13:19 09/12, Avi Kivity wrote:
> I have an application that receives spurious EIO when running with
> RWF_NOWAIT enabled. Removing RWF_NOWAIT causes those EIOs to disappear. The
> application uses AIO+DIO, and errors were seen on both xfs and ext4.
>
>
> I suspect the following code:
>
>
> /*
>  * Process one completed BIO.  No locks are held.
>  */
> static blk_status_t dio_bio_complete(struct dio *dio, struct bio *bio)
> {
>         struct bio_vec *bvec;
>         unsigned i;
>         blk_status_t err = bio->bi_status;
>
>         if (err) {
>                 if (err == BLK_STS_AGAIN && (bio->bi_opf & REQ_NOWAIT))
>                         dio->io_error = -EAGAIN;
>                 else
>                         dio->io_error = -EIO;
>         }
>
> Could it be that REQ_NOWAIT was dropped from bio->bi_opf? or that
> bio->bi_status got changed along the way?
>

I don't think REQ_NOWAIT is dropped. I am assuming bio->bi_status error
is set differently. Is the blk queue being stopped? Is it possible to
instrument the kernel in your testcase?

--
Goldwyn

\
 
 \ /
  Last update: 2018-12-10 13:48    [W:0.054 / U:1.116 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site