diff options
author | William Kucharski <william.kucharski@oracle.com> | 2024-02-02 12:15:49 +0300 |
---|---|---|
committer | Leon Romanovsky <leon@kernel.org> | 2024-02-04 12:44:50 +0300 |
commit | c21a8870c98611e8f892511825c9607f1e2cd456 (patch) | |
tree | bed91ea7e2c6a6870489780b19debc3f2d9f6d73 /lib/libcrc32c.c | |
parent | 926e8ea4b8dac84f6d14a4b60d0653f1f2ba9431 (diff) | |
download | linux-c21a8870c98611e8f892511825c9607f1e2cd456.tar.xz |
RDMA/srpt: Do not register event handler until srpt device is fully setup
Upon rare occasions, KASAN reports a use-after-free Write
in srpt_refresh_port().
This seems to be because an event handler is registered before the
srpt device is fully setup and a race condition upon error may leave a
partially setup event handler in place.
Instead, only register the event handler after srpt device initialization
is complete.
Fixes: a42d985bd5b2 ("ib_srpt: Initial SRP Target merge for v3.3-rc1")
Signed-off-by: William Kucharski <william.kucharski@oracle.com>
Link: https://lore.kernel.org/r/20240202091549.991784-2-william.kucharski@oracle.com
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Diffstat (limited to 'lib/libcrc32c.c')
0 files changed, 0 insertions, 0 deletions