]> www.infradead.org Git - users/jedix/linux-maple.git/commit
target/user: Refactor data area allocation code
authorIlias Tsitsimpis <iliastsi@arrikto.com>
Thu, 23 Apr 2015 18:47:00 +0000 (21:47 +0300)
committerChuck Anderson <chuck.anderson@oracle.com>
Fri, 23 Jun 2017 04:10:42 +0000 (21:10 -0700)
commit511d656ee2a13862ad627877c4eed6664e0fa1be
treef9cc9b8d2632d731d77c9ab203b832633c14311e
parent628b3b47b2aa0f94a704c507a3092f8a7d1b7523
target/user: Refactor data area allocation code

Introduce alloc_and_scatter_data_area()/gather_and_free_data_area()
functions that allocate/deallocate space from the data area and copy
data to/from a given scatter-gather list. These functions are needed so
the next patch, introducing support for bidirectional commands in TCMU,
can use the same code path both for t_data_sg and for t_bidi_data_sg.

Signed-off-by: Ilias Tsitsimpis <iliastsi@arrikto.com>
Signed-off-by: Vangelis Koukis <vkoukis@arrikto.com>
Reviewed-by: Andy Grover <agrover@redhat.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Orabug: 25395066
(cherry picked from commit f97ec7db1606875666366bfcba8476f8c917db96)
Signed-off-by: Kyle Fortin <kyle.fortin@oracle.com>
Reviewed-by: Shan Hai <shan.hai@oracle.com>
drivers/target/target_core_user.c