APIs to submit bios at block layer
Hi all, Could anyone explain the difference between submit_bio() and generic_make_request() ? How they are different in functionality? How lower layers treat bios submitted via submit_bio() / generic_make_request() ? When is it preferable to use api generic_make_request() than submit_bio() api? -- Regards, Kashish Bhatia
On April 14, 2014 8:21:05 PM GMT+05:30, KASHISH BHATIA <kashish.bhatia1989@gmail.com> wrote:
Hi all,
Could anyone explain the difference between submit_bio() and generic_make_request() ? How they are different in functionality? How lower layers treat bios submitted via submit_bio() / generic_make_request() ? When is it preferable to use api generic_make_request() than submit_bio()
A request has bio(s). You normally would bio_alloc then set up your bio and finally get a reference to it and submit_bio. At this point you would be in file system layer. After submit you enter block layer which would either try to merge that bio with an existing request or create a new request for the lower level driver.
api?
The usage is clearly separate. Submit the bio from file system, create the request for the driver in block layer. -- Sent from my Android device with K-9 Mail. Please excuse my brevity.
participants (2)
-
KASHISH BHATIA -
Pranay Kr. Srivastava