Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions prov/sockets/include/sock.h
Original file line number Diff line number Diff line change
Expand Up @@ -611,6 +611,7 @@ struct sock_rx_entry {
uint64_t flags;
uint64_t context;
uint64_t addr;
union ofi_sock_ip sock_addr;
uint64_t data;
uint64_t tag;
uint64_t ignore;
Expand Down
9 changes: 9 additions & 0 deletions prov/sockets/src/sock_progress.c
Original file line number Diff line number Diff line change
Expand Up @@ -1216,6 +1216,12 @@ static int sock_pe_progress_buffered_rx(struct sock_rx_ctx *rx_ctx,
if (!rx_buffered->is_complete || rx_buffered->is_claimed)
continue;

if (rx_buffered->addr == FI_ADDR_NOTAVAIL) {
rx_buffered->addr = sock_av_get_addr_index(rx_ctx->av, &rx_buffered->sock_addr);
if (rx_buffered->addr == FI_ADDR_NOTAVAIL) {
continue;
}
}
rx_posted = sock_rx_get_entry(rx_ctx, rx_buffered->addr,
rx_buffered->tag,
rx_buffered->is_tagged);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Question: do we allow FI_ADDR_NOTAVAIL to be matched? If so, what is the use case?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It should be allowed. The posted recv may not care who the sender is (i.e. rx_entry->addr == FI_ADDR_UNSPEC).

Expand Down Expand Up @@ -1375,6 +1381,9 @@ static int sock_pe_process_rx_send(struct sock_pe *pe,
}

rx_entry->addr = pe_entry->addr;
if (rx_entry->addr == FI_ADDR_NOTAVAIL) {
rx_entry->sock_addr = pe_entry->conn->addr;
}
rx_entry->tag = pe_entry->tag;
rx_entry->data = pe_entry->data;
rx_entry->ignore = 0;
Expand Down