A question about the block_read_full_page()



Hi, all.
In a test, I need to collect data block retrieving from the disk
into a dedicated file. It needs to collect the block data from disk
for generic file reading but rather for block device. But I found both
ext2_readpage and blkdev_readpage wrapped with block_read_full_page().
So I have to use the block_read_full_page for the next step.
First question : Is there a function only for generic file
reading?

Assume using the block_read_full_page(), Looks at the following
code snippets from block_read_full_page().

/* Stage 3: start the IO */
for (i = 0; i < nr; i++) {
struct buffer_head * bh = arr[i];
if (buffer_uptodate(bh))
end_buffer_io_async(bh, 1);
else
submit_bh(READ, bh);
}

return 0;

It invokes the submit_bh() for every invalid buffer block. But
according to the disk delay mechnism, when the IO completed is depend
on the lower level disk function. What I want is that after the block
data become valid , I need to record the retreival data into a
dedicated file.
So , my second question : Is there a way to acheive this goal?

Thanks a lot.

.



Relevant Pages

  • Re: Damn you, FEDEX! or Nikon D40 lost in Springfield, MO blackhole.
    ... the 2 mp Mavica he had been using with a Nikon D40. ... After shopping around, he got me to order one for him. ... The shipper had it insured, but from what I have read it could take weeks to sort this crap out. ... You may get your insurance from FedEx and a couple weeks later they find it and deliver it. ...
    (alt.photography)
  • Re: Inserting a blank disk in RW drive reboots PC!
    ... First question: has that drive ever worked right? ... disk, ... drivers install at startup time; they often have a Tray Icon too. ... tell you the firmware version). ...
    (microsoft.public.windowsxp.general)
  • Re: Science on Radio
    ... In sci.physics habshi wrote: ... The vertical component of gravity is directly below and the ... Jim Pennino ...
    (sci.physics)
  • Re: Replacement disk needed
    ... but your wise guy answer doesn't address my first question. ... > How to Replace Lost, Broken, or Missing Microsoft Software or Hardware ... I do not have the disk. ... > | to screw up my installed programs. ...
    (microsoft.public.windowsxp.security_admin)
  • Re: wiping windows xp laptop computer clean and starting over
    ... i just ordered a new recovery disk for her laptop. ... problem was that they sent me 2 disks and that is my first question in this ... I'm guessing it is the operating system CD, ... "Don't pick a fight with an old man. ...
    (microsoft.public.windowsxp.general)