aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/ulp/ipoib/ipoib_cm.c
diff options
context:
space:
mode:
authorRoland Dreier <rolandd@cisco.com>2007-10-23 22:57:54 -0400
committerRoland Dreier <rolandd@cisco.com>2008-01-25 17:15:23 -0500
commit2337f80941ac22f747ce6fd2c7a79e91d911a3ce (patch)
treee813aa78a5ec8fc07bad4826ac083ac83ae35f5c /drivers/infiniband/ulp/ipoib/ipoib_cm.c
parent657c2f2cbccbac88689ac5174fc13dd3f9aece34 (diff)
IPoIB: Trivial formatting cleanups
Fix whitespace blunders, convert "foo* bar" to "foo *bar", etc. Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband/ulp/ipoib/ipoib_cm.c')
-rw-r--r--drivers/infiniband/ulp/ipoib/ipoib_cm.c48
1 files changed, 24 insertions, 24 deletions
diff --git a/drivers/infiniband/ulp/ipoib/ipoib_cm.c b/drivers/infiniband/ulp/ipoib/ipoib_cm.c
index 059cf92b60a5..5d2da1676928 100644
--- a/drivers/infiniband/ulp/ipoib/ipoib_cm.c
+++ b/drivers/infiniband/ulp/ipoib/ipoib_cm.c
@@ -155,7 +155,7 @@ partial_error:
155 return NULL; 155 return NULL;
156} 156}
157 157
158static void ipoib_cm_start_rx_drain(struct ipoib_dev_priv* priv) 158static void ipoib_cm_start_rx_drain(struct ipoib_dev_priv *priv)
159{ 159{
160 struct ib_send_wr *bad_wr; 160 struct ib_send_wr *bad_wr;
161 struct ipoib_cm_rx *p; 161 struct ipoib_cm_rx *p;
@@ -495,10 +495,10 @@ static inline int post_send(struct ipoib_dev_priv *priv,
495{ 495{
496 struct ib_send_wr *bad_wr; 496 struct ib_send_wr *bad_wr;
497 497
498 priv->tx_sge.addr = addr; 498 priv->tx_sge.addr = addr;
499 priv->tx_sge.length = len; 499 priv->tx_sge.length = len;
500 500
501 priv->tx_wr.wr_id = wr_id | IPOIB_OP_CM; 501 priv->tx_wr.wr_id = wr_id | IPOIB_OP_CM;
502 502
503 return ib_post_send(tx->qp, &priv->tx_wr, &bad_wr); 503 return ib_post_send(tx->qp, &priv->tx_wr, &bad_wr);
504} 504}
@@ -540,7 +540,7 @@ void ipoib_cm_send(struct net_device *dev, struct sk_buff *skb, struct ipoib_cm_
540 tx_req->mapping = addr; 540 tx_req->mapping = addr;
541 541
542 if (unlikely(post_send(priv, tx, tx->tx_head & (ipoib_sendq_size - 1), 542 if (unlikely(post_send(priv, tx, tx->tx_head & (ipoib_sendq_size - 1),
543 addr, skb->len))) { 543 addr, skb->len))) {
544 ipoib_warn(priv, "post_send failed\n"); 544 ipoib_warn(priv, "post_send failed\n");
545 ++dev->stats.tx_errors; 545 ++dev->stats.tx_errors;
546 ib_dma_unmap_single(priv->ca, addr, skb->len, DMA_TO_DEVICE); 546 ib_dma_unmap_single(priv->ca, addr, skb->len, DMA_TO_DEVICE);
@@ -799,7 +799,7 @@ static struct ib_qp *ipoib_cm_create_tx_qp(struct net_device *dev, struct ipoib_
799 .sq_sig_type = IB_SIGNAL_ALL_WR, 799 .sq_sig_type = IB_SIGNAL_ALL_WR,
800 .qp_type = IB_QPT_RC, 800 .qp_type = IB_QPT_RC,
801 .qp_context = tx 801 .qp_context = tx
802 }; 802 };
803 803
804 return ib_create_qp(priv->pd, &attr); 804 return ib_create_qp(priv->pd, &attr);
805} 805}
@@ -816,28 +816,28 @@ static int ipoib_cm_send_req(struct net_device *dev,
816 data.qpn = cpu_to_be32(priv->qp->qp_num); 816 data.qpn = cpu_to_be32(priv->qp->qp_num);
817 data.mtu = cpu_to_be32(IPOIB_CM_BUF_SIZE); 817 data.mtu = cpu_to_be32(IPOIB_CM_BUF_SIZE);
818 818
819 req.primary_path = pathrec; 819 req.primary_path = pathrec;
820 req.alternate_path = NULL; 820 req.alternate_path = NULL;
821 req.service_id = cpu_to_be64(IPOIB_CM_IETF_ID | qpn); 821 req.service_id = cpu_to_be64(IPOIB_CM_IETF_ID | qpn);
822 req.qp_num = qp->qp_num; 822 req.qp_num = qp->qp_num;
823 req.qp_type = qp->qp_type; 823 req.qp_type = qp->qp_type;
824 req.private_data = &data; 824 req.private_data = &data;
825 req.private_data_len = sizeof data; 825 req.private_data_len = sizeof data;
826 req.flow_control = 0; 826 req.flow_control = 0;
827 827
828 req.starting_psn = 0; /* FIXME */ 828 req.starting_psn = 0; /* FIXME */
829 829
830 /* 830 /*
831 * Pick some arbitrary defaults here; we could make these 831 * Pick some arbitrary defaults here; we could make these
832 * module parameters if anyone cared about setting them. 832 * module parameters if anyone cared about setting them.
833 */ 833 */
834 req.responder_resources = 4; 834 req.responder_resources = 4;
835 req.remote_cm_response_timeout = 20; 835 req.remote_cm_response_timeout = 20;
836 req.local_cm_response_timeout = 20; 836 req.local_cm_response_timeout = 20;
837 req.retry_count = 0; /* RFC draft warns against retries */ 837 req.retry_count = 0; /* RFC draft warns against retries */
838 req.rnr_retry_count = 0; /* RFC draft warns against retries */ 838 req.rnr_retry_count = 0; /* RFC draft warns against retries */
839 req.max_cm_retries = 15; 839 req.max_cm_retries = 15;
840 req.srq = 1; 840 req.srq = 1;
841 return ib_send_cm_req(id, &req); 841 return ib_send_cm_req(id, &req);
842} 842}
843 843
@@ -1150,7 +1150,7 @@ static void ipoib_cm_skb_reap(struct work_struct *work)
1150 spin_unlock_irq(&priv->tx_lock); 1150 spin_unlock_irq(&priv->tx_lock);
1151} 1151}
1152 1152
1153void ipoib_cm_skb_too_long(struct net_device* dev, struct sk_buff *skb, 1153void ipoib_cm_skb_too_long(struct net_device *dev, struct sk_buff *skb,
1154 unsigned int mtu) 1154 unsigned int mtu)
1155{ 1155{
1156 struct ipoib_dev_priv *priv = netdev_priv(dev); 1156 struct ipoib_dev_priv *priv = netdev_priv(dev);
@@ -1212,7 +1212,7 @@ static void ipoib_cm_stale_task(struct work_struct *work)
1212} 1212}
1213 1213
1214 1214
1215static ssize_t show_mode(struct device *d, struct device_attribute *attr, 1215static ssize_t show_mode(struct device *d, struct device_attribute *attr,
1216 char *buf) 1216 char *buf)
1217{ 1217{
1218 struct ipoib_dev_priv *priv = netdev_priv(to_net_dev(d)); 1218 struct ipoib_dev_priv *priv = netdev_priv(to_net_dev(d));