diff options
author | Michael Brown <mcb30@ipxe.org> | 2012-08-29 22:11:58 +0100 |
---|---|---|
committer | Michael Brown <mcb30@ipxe.org> | 2012-08-31 21:22:57 +0100 |
commit | f747fac3e1dad31378579326d8e9dce0df85c214 (patch) | |
tree | 68393b4686b7d28737b16b26c6f49c4d2db431d0 /src/net/infiniband/ib_mi.c | |
parent | 96be171be572496f0ee4c1cfdc9c507b97caba00 (diff) | |
download | ipxe-f747fac3e1dad31378579326d8e9dce0df85c214.tar.gz |
[infiniband] Allow queue pairs to have a custom allocator for receive iobufs
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/net/infiniband/ib_mi.c')
-rw-r--r-- | src/net/infiniband/ib_mi.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/net/infiniband/ib_mi.c b/src/net/infiniband/ib_mi.c index ced2eea17..31fe71a48 100644 --- a/src/net/infiniband/ib_mi.c +++ b/src/net/infiniband/ib_mi.c @@ -164,6 +164,11 @@ static struct ib_completion_queue_operations ib_mi_completion_ops = { .complete_recv = ib_mi_complete_recv, }; +/** Management interface queue pair operations */ +static struct ib_queue_pair_operations ib_mi_queue_pair_ops = { + .alloc_iob = alloc_iob, +}; + /** * Transmit MAD * @@ -353,7 +358,8 @@ struct ib_mad_interface * ib_create_mi ( struct ib_device *ibdev, /* Create queue pair */ mi->qp = ib_create_qp ( ibdev, type, IB_MI_NUM_SEND_WQES, mi->cq, - IB_MI_NUM_RECV_WQES, mi->cq ); + IB_MI_NUM_RECV_WQES, mi->cq, + &ib_mi_queue_pair_ops ); if ( ! mi->qp ) { DBGC ( mi, "MI %p could not allocate queue pair\n", mi ); goto err_create_qp; |