Subject: Re: I/O error check in sw_reg_iodone()
To: Stephan Uphoff <ups@stups.com>
From: Chuck Silvers <chuq@chuq.com>
List: tech-kern
Date: 10/27/2002 08:53:57
hi,
you're right. I've applied an equivalent change.
thanks,
-Chuck
On Wed, Oct 02, 2002 at 03:26:11PM -0400, Stephan Uphoff wrote:
>
> The error detection for failed buffer I/O in function sw_reg_iodone()
> file uvm_swap.c is inconsistent with the rest of the kernel.
>
> I recommend changing:
>
> if (vbp->vb_buf.b_error) {
> UVMHIST_LOG(pdhist, " got error=%d !",
> vbp->vb_buf.b_error, 0, 0, 0);
>
> /* pass error upward */
> vnx->vx_error = vbp->vb_buf.b_error;
> }
>
> to:
>
> if (vbp->vb_buf.b_flags & B_ERROR ) {
> int error;
> error = ( vbp->vb_buf.b_error ) ? vbp->vb_buf.b_error : EIO;
>
> UVMHIST_LOG(pdhist, " got error=%d !",
> error, 0, 0, 0);
>
> /* pass error upward */
> vnx->vx_error = error;
> }
>
>
> Stephan