lkml.org 
[lkml]   [1999]   [Nov]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectDoing end_that_request_last first and vice versa
Date
From
In a block device driver's request function, there are now two
functions that one is supposed to call when a request has been
completed: end_that_request_first and end_that_request_last. The former
does the appropriate stuff to mark the buffer_head up to date, end I/O
on it (or adjust the request on error). The latter frees up the request
slot.

I'm writing a block device driver where I'd like to take all the
requests out of the queue and record the relevant buffer_head pointers
elsewhere. I want to end I/O on the buffer_heads asynchronously later
(potentially much later). In other words, I'd like to call
end_that_request_last first (after recording the READ/WRITE commands
and buffer_head pointers) and do the equivalent of
end_that_request_first last, much later. Is this a valid thing to do?
I'm fairly sure it will work but is it the Right Way (TM) to code it
or do I risk it breaking when the buffer_heads get even closer to
being just I/O tags? Also, is emptying the request queue a reasonable
thing to do (since I don't want the system to run out of global
request slots and this block device may be very, very slow)?

--Malcolm

--
Malcolm Beattie <mbeattie@sable.ox.ac.uk>
Unix Systems Programmer
Oxford University Computing Services

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:54    [W:0.036 / U:0.092 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site