Files
ipxe/src/include/gpxe/ib_qset.h
Michael Brown 887d296b88 [infiniband] Poll completion queues automatically
Currently, all Infiniband users must create a process for polling
their completion queues (or rely on a regular hook such as
netdev_poll() in ipoib.c).

Move instead to a model whereby the Infiniband core maintains a single
process calling ib_poll_eq(), and polling the event queue triggers
polls of the applicable completion queues.  (At present, the
Infiniband core simply polls all of the device's completion queues.)
Polling a completion queue will now implicitly refill all attached
receive work queues; this is analogous to the way that netdev_poll()
implicitly refills the RX ring.

Infiniband users no longer need to create a process just to poll their
completion queues and refill their receive rings.
2009-07-17 23:06:33 +01:00

32 lines
717 B
C

#ifndef _GPXE_IB_QSET_H
#define _GPXE_IB_QSET_H
/** @file
*
* Infiniband queue sets
*
*/
FILE_LICENCE ( GPL2_OR_LATER );
#include <stdint.h>
#include <gpxe/infiniband.h>
/** An Infiniband queue set */
struct ib_queue_set {
/** Completion queue */
struct ib_completion_queue *cq;
/** Queue pair */
struct ib_queue_pair *qp;
};
extern int ib_create_qset ( struct ib_device *ibdev,
struct ib_queue_set *qset, unsigned int num_cqes,
struct ib_completion_queue_operations *cq_op,
unsigned int num_send_wqes,
unsigned int num_recv_wqes, unsigned long qkey );
extern void ib_destroy_qset ( struct ib_device *ibdev,
struct ib_queue_set *qset );
#endif /* _GPXE_IB_QSET_H */