Linux 4.20 compat: wrapper function for iov_iter type access
commit8be6308e85cffb2247753033fbfc3641f731af51
authorColeman Kane <ckane@colemankane.org>
Sun, 30 Jul 2023 19:23:47 +0000 (30 15:23 -0400)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 19 Sep 2023 15:50:01 +0000 (19 08:50 -0700)
tree0fc6dbc4ee885f312aa4bb1c06d3f003bc0c3418
parent0bf2c5365ed3afa65545393d8da2317699f18b30
Linux 4.20 compat: wrapper function for iov_iter type access

An iov_iter_type() function to access the "type" member of the struct
iov_iter was added at one point. Move the conditional logic to decide
which method to use for accessing it into a macro and simplify the
zpl_uio_init code.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Brian Atkinson <batkinson@lanl.gov>
Signed-off-by: Coleman Kane <ckane@colemankane.org>
Closes #15100
include/os/linux/spl/sys/uio.h
module/os/linux/zfs/zpl_file.c