diff options
| author | Jacob Moroni <jmoroni@google.com> | 2026-07-13 17:12:54 +0000 |
|---|---|---|
| committer | Leon Romanovsky <leon@kernel.org> | 2026-07-20 09:45:43 -0400 |
| commit | aa5967095c7d53f1405a8bed995bf355efc1ffae (patch) | |
| tree | afb187ec3190bb422200a1a7eb47ef78bc3916d8 /include | |
| parent | 91a74a238631ef7b7c6bda17328014ab7160c888 (diff) | |
| download | linux-aa5967095c7d53f1405a8bed995bf355efc1ffae.tar.gz linux-aa5967095c7d53f1405a8bed995bf355efc1ffae.zip | |
RDMA/irdma: Use robust input copy helpers
Replace the use of ib_copy_from_udata() with
ib_copy_validate_udata_in() where applicable.
For each modified call site, the last argument of
ib_copy_validate_udata_in() was determined by taking
the last member of the ABI struct as per its original
definition (i.e., when it was first committed).
Some methods like irdma_create_cq required special care
because the last member of the current ABI def is beyond
that of the legacy i40iw's ABI def which we need to
remain compatible with. In some other cases like modify_qp,
the legacy i40iw provider never provided any udata at all
so the validation is only performed if inlen > 0.
irdma_create_qp is more challenging because the legacy ABI
was actually larger but the additional fields were never used,
and even worse, never initialized in the provider. This will
be handled in a followup commit.
Signed-off-by: Jacob Moroni <jmoroni@google.com>
Link: https://patch.msgid.link/20260713171257.3131493-4-jmoroni@google.com
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions
