@@ -703,7 +703,7 @@ static inline int post_send(struct ipoib_dev_priv *priv,
703
703
void ipoib_cm_send (struct net_device * dev , struct sk_buff * skb , struct ipoib_cm_tx * tx )
704
704
{
705
705
struct ipoib_dev_priv * priv = netdev_priv (dev );
706
- struct ipoib_tx_buf * tx_req ;
706
+ struct ipoib_cm_tx_buf * tx_req ;
707
707
u64 addr ;
708
708
709
709
if (unlikely (skb -> len > tx -> mtu )) {
@@ -734,7 +734,7 @@ void ipoib_cm_send(struct net_device *dev, struct sk_buff *skb, struct ipoib_cm_
734
734
return ;
735
735
}
736
736
737
- tx_req -> mapping [ 0 ] = addr ;
737
+ tx_req -> mapping = addr ;
738
738
739
739
if (unlikely (post_send (priv , tx , tx -> tx_head & (ipoib_sendq_size - 1 ),
740
740
addr , skb -> len ))) {
@@ -759,7 +759,7 @@ void ipoib_cm_handle_tx_wc(struct net_device *dev, struct ib_wc *wc)
759
759
struct ipoib_dev_priv * priv = netdev_priv (dev );
760
760
struct ipoib_cm_tx * tx = wc -> qp -> qp_context ;
761
761
unsigned int wr_id = wc -> wr_id & ~IPOIB_OP_CM ;
762
- struct ipoib_tx_buf * tx_req ;
762
+ struct ipoib_cm_tx_buf * tx_req ;
763
763
unsigned long flags ;
764
764
765
765
ipoib_dbg_data (priv , "cm send completion: id %d, status: %d\n" ,
@@ -773,7 +773,7 @@ void ipoib_cm_handle_tx_wc(struct net_device *dev, struct ib_wc *wc)
773
773
774
774
tx_req = & tx -> tx_ring [wr_id ];
775
775
776
- ib_dma_unmap_single (priv -> ca , tx_req -> mapping [ 0 ] , tx_req -> skb -> len , DMA_TO_DEVICE );
776
+ ib_dma_unmap_single (priv -> ca , tx_req -> mapping , tx_req -> skb -> len , DMA_TO_DEVICE );
777
777
778
778
/* FIXME: is this right? Shouldn't we only increment on success? */
779
779
++ dev -> stats .tx_packets ;
@@ -1143,7 +1143,7 @@ static int ipoib_cm_tx_init(struct ipoib_cm_tx *p, u32 qpn,
1143
1143
static void ipoib_cm_tx_destroy (struct ipoib_cm_tx * p )
1144
1144
{
1145
1145
struct ipoib_dev_priv * priv = netdev_priv (p -> dev );
1146
- struct ipoib_tx_buf * tx_req ;
1146
+ struct ipoib_cm_tx_buf * tx_req ;
1147
1147
unsigned long flags ;
1148
1148
unsigned long begin ;
1149
1149
@@ -1171,7 +1171,7 @@ static void ipoib_cm_tx_destroy(struct ipoib_cm_tx *p)
1171
1171
1172
1172
while ((int ) p -> tx_tail - (int ) p -> tx_head < 0 ) {
1173
1173
tx_req = & p -> tx_ring [p -> tx_tail & (ipoib_sendq_size - 1 )];
1174
- ib_dma_unmap_single (priv -> ca , tx_req -> mapping [ 0 ] , tx_req -> skb -> len ,
1174
+ ib_dma_unmap_single (priv -> ca , tx_req -> mapping , tx_req -> skb -> len ,
1175
1175
DMA_TO_DEVICE );
1176
1176
dev_kfree_skb_any (tx_req -> skb );
1177
1177
++ p -> tx_tail ;
0 commit comments