diff options
author | Steve Wise <swise@opengridcomputing.com> | 2007-03-06 15:44:05 -0500 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2007-03-06 15:50:57 -0500 |
commit | 1f6a849b7ce6c3007088cd437dfc2b9c7cb5d21e (patch) | |
tree | 94e44196c86c85b332afd83bf5ab903e1d34d620 /drivers/infiniband | |
parent | 8cfccf02bb63b9733e852d475a8be58baaefef8a (diff) |
RDMA/cxgb3: Don't reuse skbs that are non-linear or cloned
Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r-- | drivers/infiniband/hw/cxgb3/iwch_cm.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/infiniband/hw/cxgb3/iwch_cm.c b/drivers/infiniband/hw/cxgb3/iwch_cm.c index 3cf79ce64bd3..d0ed1d35ca3e 100644 --- a/drivers/infiniband/hw/cxgb3/iwch_cm.c +++ b/drivers/infiniband/hw/cxgb3/iwch_cm.c | |||
@@ -305,8 +305,7 @@ static int status2errno(int status) | |||
305 | */ | 305 | */ |
306 | static struct sk_buff *get_skb(struct sk_buff *skb, int len, gfp_t gfp) | 306 | static struct sk_buff *get_skb(struct sk_buff *skb, int len, gfp_t gfp) |
307 | { | 307 | { |
308 | if (skb) { | 308 | if (skb && !skb_is_nonlinear(skb) && !skb_cloned(skb)) { |
309 | BUG_ON(skb_cloned(skb)); | ||
310 | skb_trim(skb, 0); | 309 | skb_trim(skb, 0); |
311 | skb_get(skb); | 310 | skb_get(skb); |
312 | } else { | 311 | } else { |