[openib-general] [PATCH 1/3] iWARP Header Files
Sean Hefty
mshefty at ichips.intel.com
Fri Mar 10 15:10:38 PST 2006
Tom Tucker wrote:
> +struct iw_cm_id;
> +struct iw_cm_event;
Forward declaration of iw_cm_event is not needed.
> +struct iw_cm_event {
> + enum iw_cm_event_type event;
> + int status;
> + u32 provider_id;
Can you explain how provider_id is used? It's defined here as u32, and below as
u64.
> +struct iw_cm_id {
> + iw_cm_handler cm_handler; /* client callback function */
> + void *context; /* context to provide to client cb */
> + enum iw_cm_state state;
> + struct ib_device *device;
> + struct ib_qp *qp; /* If the qp is null, use qp_num */
> + u32 qp_num;
> + struct sockaddr_in local_addr;
> + struct sockaddr_in remote_addr;
> + u64 provider_id; /* device handle for this conn. */
Unsure how provider_id is used.
> +struct iw_cm_verbs {
> + int (*connect)(struct iw_cm_id *cm_id,
> + const void *pdata, u8 pdata_len);
> +
> + int (*disconnect)(struct iw_cm_id *cm_id,
> + int abrupt);
> +
> + int (*accept)(struct iw_cm_id *cm_id,
> + const void *pdata, u8 pdata_len);
> +
> + int (*reject)(struct iw_cm_id *cm_id,
> + const void *pdata, u8 pdata_len);
> +
> + int (*getpeername)(struct iw_cm_id *cm_id,
> + struct sockaddr_in *local_addr,
> + struct sockaddr_in *remote_addr);
> +
> + int (*create_listen)(struct iw_cm_id *cm_id,
> + int backlog);
> +
> + int (*destroy_listen)(struct iw_cm_id *cm_id);
> +
> +};
I just noticed that you don't have create/destroy cm_id calls as part of verbs.
It looks like you're allocating the cm_id in the iWarp connection manager. Do
you expect that the lower-level driver will allocate their own context
structure? If so, how are these related?
- Sean
More information about the general
mailing list