[PATCH V6 5/5] nvme: centralize setting req end_io_data

Sagi Grimberg sagi at grimberg.me
Wed Nov 4 17:17:05 EST 2020


> The host side code allocates the request in several places using
> nvme_alloc_request() and initialises the allocated request->end_io_data,
> which repeats the code and will have duplicate code in the future.
> 
> Add an end_io_data request parameter which initializes the block
> layer request in nvme_alloc_request(), update the respective callers
> and remove the duplicate code.

There are less callers that actually put something there so not sure
if this is an improvement.. The alloc signature is getting kinda bloated
now...



More information about the Linux-nvme mailing list