]> git.baikalelectronics.ru Git - kernel.git/commit
IB/ipoib: Add handling for sending of skb with many frags
authorHans Westgaard Ry <hans.westgaard.ry@oracle.com>
Wed, 2 Mar 2016 12:44:28 +0000 (13:44 +0100)
committerDoug Ledford <dledford@redhat.com>
Thu, 3 Mar 2016 14:49:44 +0000 (09:49 -0500)
commit4c35eaa2f98f6077d044a74664b94bdbaf559697
treef3d16185b8e004c08c63aa37ff78fb0ddefe1457
parentb4c6e182f5b636364ef191076c0c02fb76bae986
IB/ipoib: Add handling for sending of skb with many frags

IPoIB converts skb-fragments to sge adding 1 extra sge when SG is enabled.
Current codepath assumes that the max number of sge a device support
is at least MAX_SKB_FRAGS+1, there is no interaction with upper layers
to limit number of fragments in an skb if a device suports fewer
sges. The assumptions also lead to requesting a fixed number of sge
when IPoIB creates queue-pairs with SG enabled.

A fallback/slowpath is implemented using skb_linearize to
handle cases where the conversion would result in more sges than supported.

Signed-off-by: Hans Westgaard Ry <hans.westgaard.ry@oracle.com>
Reviewed-by: HÃ¥kon Bugge <haakon.bugge@oracle.com>
Reviewed-by: Wei Lin Guay <wei.lin.guay@oracle.com>
Reviewed-by: Yuval Shaia <yuval.shaia@oracle.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/ulp/ipoib/ipoib.h
drivers/infiniband/ulp/ipoib/ipoib_cm.c
drivers/infiniband/ulp/ipoib/ipoib_ib.c
drivers/infiniband/ulp/ipoib/ipoib_verbs.c