Skip to content

Commit

Permalink
iw_cxgb4: allocate wait object for each memory object
Browse files Browse the repository at this point in the history
Remove the local stack allocated c4iw_wr_wait object in preparation for
correctly handling timeouts.

Also refactored some code to simplify it and make errpath unwinding
more readable.

Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
  • Loading branch information
Steve Wise authored and Doug Ledford committed Sep 29, 2017
1 parent e930b4d commit a3f12da
Show file tree
Hide file tree
Showing 2 changed files with 141 additions and 89 deletions.
2 changes: 2 additions & 0 deletions drivers/infiniband/hw/cxgb4/iw_cxgb4.h
Original file line number Diff line number Diff line change
Expand Up @@ -394,6 +394,7 @@ struct c4iw_mr {
dma_addr_t mpl_addr;
u32 max_mpl_len;
u32 mpl_len;
struct c4iw_wr_wait *wr_waitp;
};

static inline struct c4iw_mr *to_c4iw_mr(struct ib_mr *ibmr)
Expand All @@ -407,6 +408,7 @@ struct c4iw_mw {
struct sk_buff *dereg_skb;
u64 kva;
struct tpt_attributes attr;
struct c4iw_wr_wait *wr_waitp;
};

static inline struct c4iw_mw *to_c4iw_mw(struct ib_mw *ibmw)
Expand Down
Loading

0 comments on commit a3f12da

Please sign in to comment.