From d4ee2cfc3f2dde7263ed34f33361272b2fbb6503 Mon Sep 17 00:00:00 2001 From: Jessie Yang Date: Tue, 7 Jan 2025 11:41:27 -0800 Subject: [PATCH] prov/efa: Add missing mock for wc_is_unsolicited in unit test Signed-off-by: Jessie Yang --- prov/efa/test/efa_unit_test_cq.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/prov/efa/test/efa_unit_test_cq.c b/prov/efa/test/efa_unit_test_cq.c index df415f7cd9a..c5b93cd5e66 100644 --- a/prov/efa/test/efa_unit_test_cq.c +++ b/prov/efa/test/efa_unit_test_cq.c @@ -878,6 +878,12 @@ static void test_efa_cq_read(struct efa_resource *resource, fi_addr_t *addr, will_return_maybe(efa_mock_ibv_read_src_qp_return_mock, raw_addr.qpn); will_return_maybe(efa_mock_ibv_read_wc_flags_return_mock, 0); #endif +#if HAVE_CAPS_UNSOLICITED_WRITE_RECV + if (efa_use_unsolicited_write_recv()) { + efadv_cq_from_ibv_cq_ex(ibv_cqx)->wc_is_unsolicited = &efa_mock_efadv_wc_is_unsolicited; + will_return_maybe(efa_mock_efadv_wc_is_unsolicited, false); + } +#endif } /**