Re: [PATCH 12/30] blk_end_request: changing ub (take 4)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 11 Dec 2007 17:46:47 -0500 (EST), Kiyoshi Ueda <[email protected]> wrote:

>  	if (scsi_status == 0) {
> -		uptodate = 1;
> +		error = 0;
>  	} else {
> -		uptodate = 0;
> +		error = -EIO;
>  		rq->errors = scsi_status;
>  	}
> -	end_that_request_first(rq, uptodate, rq->hard_nr_sectors);
> -	end_that_request_last(rq, uptodate);
> +	if (__blk_end_request(rq, error, blk_rq_bytes(rq)))
> +		BUG();

Acked-by: Pete Zaitcev <[email protected]>

I follow the discussion, actually, and wanted to ask someone to look
closer if it's appropriate to use __blk_end_request() here.
My understanding was, blk_end_request() is the same thing, only
takes the queue lock. But then, should I refactor ub so that it
calls __blk_end_request if request function ends with an error
and blk_end_request if the end-of-IO even is processed? If not,
and the above is sufficient, why have blk_end_request at all?

-- Pete
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux