Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1617897

Re: [PATCH 7/9] Guard bvec iteration logic v3

From Christoph Hellwig <hch@infradead.org>
Newsgroups linux.kernel
Subject Re: [PATCH 7/9] Guard bvec iteration logic v3
Date 2017-04-06 13:50 +0200
Message-ID <tte5k-7Y4-17@gated-at.bofh.it> (permalink)
References <tsBQl-hL-3@gated-at.bofh.it> <tsBQl-hL-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


>  	if (bio_no_advance_iter(bio))
>  		iter->bi_size -= bytes;
> -	else
> -		bvec_iter_advance(bio->bi_io_vec, iter, bytes);
> +	else {
> +		int err;
> +		err = bvec_iter_advance(bio->bi_io_vec, iter, bytes);
> +		if (unlikely(err))
> +			bio->bi_error = err;
> +	}

I don't think that setting bi_error here is a good idea without actually
completing the bio, which would be a much bigger change.

Maybe leave the error ignored here for now with a fixme comment, and
then we can look into proper error handling in a separate series.

Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

[PATCH 7/9] Guard bvec iteration logic v3 Dmitry Monakhov <dmonakhov@openvz.org> - 2017-04-04 21:00 +0200
  Re: [PATCH 7/9] Guard bvec iteration logic v3 Hannes Reinecke <hare@suse.de> - 2017-04-05 08:40 +0200
  Re: [PATCH 7/9] Guard bvec iteration logic v3 Christoph Hellwig <hch@infradead.org> - 2017-04-06 13:50 +0200

csiph-web