Commit 4d45b757 authored by Bharat Potnuri's avatar Bharat Potnuri Committed by Doug Ledford

iw_cxgb4: change pr_debug to appropriate log level

Error logs of iw_cxgb4 needs to be printed by default. This patch
changes the necessary pr_debug() to appropriate pr_<log level>.
Signed-off-by: default avatarPotnuri Bharat Teja <bharat@chelsio.com>
Reviewed-by: default avatarSteve Wise <swise@opengridcomputing.com>
Signed-off-by: default avatarDoug Ledford <dledford@redhat.com>
parent 548ddb19
...@@ -212,7 +212,7 @@ static int c4iw_l2t_send(struct c4iw_rdev *rdev, struct sk_buff *skb, ...@@ -212,7 +212,7 @@ static int c4iw_l2t_send(struct c4iw_rdev *rdev, struct sk_buff *skb,
if (c4iw_fatal_error(rdev)) { if (c4iw_fatal_error(rdev)) {
kfree_skb(skb); kfree_skb(skb);
pr_debug("%s - device in error state - dropping\n", __func__); pr_err("%s - device in error state - dropping\n", __func__);
return -EIO; return -EIO;
} }
error = cxgb4_l2t_send(rdev->lldi.ports[0], skb, l2e); error = cxgb4_l2t_send(rdev->lldi.ports[0], skb, l2e);
...@@ -229,7 +229,7 @@ int c4iw_ofld_send(struct c4iw_rdev *rdev, struct sk_buff *skb) ...@@ -229,7 +229,7 @@ int c4iw_ofld_send(struct c4iw_rdev *rdev, struct sk_buff *skb)
if (c4iw_fatal_error(rdev)) { if (c4iw_fatal_error(rdev)) {
kfree_skb(skb); kfree_skb(skb);
pr_debug("%s - device in error state - dropping\n", __func__); pr_err("%s - device in error state - dropping\n", __func__);
return -EIO; return -EIO;
} }
error = cxgb4_ofld_send(rdev->lldi.ports[0], skb); error = cxgb4_ofld_send(rdev->lldi.ports[0], skb);
...@@ -263,8 +263,8 @@ static void set_emss(struct c4iw_ep *ep, u16 opt) ...@@ -263,8 +263,8 @@ static void set_emss(struct c4iw_ep *ep, u16 opt)
if (ep->emss < 128) if (ep->emss < 128)
ep->emss = 128; ep->emss = 128;
if (ep->emss & 7) if (ep->emss & 7)
pr_debug("Warning: misaligned mtu idx %u mss %u emss=%u\n", pr_warn("Warning: misaligned mtu idx %u mss %u emss=%u\n",
TCPOPT_MSS_G(opt), ep->mss, ep->emss); TCPOPT_MSS_G(opt), ep->mss, ep->emss);
pr_debug("mss_idx %u mss %u emss=%u\n", TCPOPT_MSS_G(opt), ep->mss, pr_debug("mss_idx %u mss %u emss=%u\n", TCPOPT_MSS_G(opt), ep->mss,
ep->emss); ep->emss);
} }
...@@ -2314,7 +2314,7 @@ static int pass_open_rpl(struct c4iw_dev *dev, struct sk_buff *skb) ...@@ -2314,7 +2314,7 @@ static int pass_open_rpl(struct c4iw_dev *dev, struct sk_buff *skb)
struct c4iw_listen_ep *ep = get_ep_from_stid(dev, stid); struct c4iw_listen_ep *ep = get_ep_from_stid(dev, stid);
if (!ep) { if (!ep) {
pr_debug("%s stid %d lookup failure!\n", __func__, stid); pr_warn("%s stid %d lookup failure!\n", __func__, stid);
goto out; goto out;
} }
pr_debug("ep %p status %d error %d\n", ep, pr_debug("ep %p status %d error %d\n", ep,
...@@ -2332,7 +2332,7 @@ static int close_listsrv_rpl(struct c4iw_dev *dev, struct sk_buff *skb) ...@@ -2332,7 +2332,7 @@ static int close_listsrv_rpl(struct c4iw_dev *dev, struct sk_buff *skb)
struct c4iw_listen_ep *ep = get_ep_from_stid(dev, stid); struct c4iw_listen_ep *ep = get_ep_from_stid(dev, stid);
if (!ep) { if (!ep) {
pr_debug("%s stid %d lookup failure!\n", __func__, stid); pr_warn("%s stid %d lookup failure!\n", __func__, stid);
goto out; goto out;
} }
pr_debug("ep %p\n", ep); pr_debug("ep %p\n", ep);
...@@ -2464,13 +2464,13 @@ static int pass_accept_req(struct c4iw_dev *dev, struct sk_buff *skb) ...@@ -2464,13 +2464,13 @@ static int pass_accept_req(struct c4iw_dev *dev, struct sk_buff *skb)
parent_ep = (struct c4iw_ep *)get_ep_from_stid(dev, stid); parent_ep = (struct c4iw_ep *)get_ep_from_stid(dev, stid);
if (!parent_ep) { if (!parent_ep) {
pr_debug("%s connect request on invalid stid %d\n", pr_err("%s connect request on invalid stid %d\n",
__func__, stid); __func__, stid);
goto reject; goto reject;
} }
if (state_read(&parent_ep->com) != LISTEN) { if (state_read(&parent_ep->com) != LISTEN) {
pr_debug("%s - listening ep not in LISTEN\n", __func__); pr_err("%s - listening ep not in LISTEN\n", __func__);
goto reject; goto reject;
} }
...@@ -2739,9 +2739,9 @@ static int peer_abort(struct c4iw_dev *dev, struct sk_buff *skb) ...@@ -2739,9 +2739,9 @@ static int peer_abort(struct c4iw_dev *dev, struct sk_buff *skb)
return 0; return 0;
if (cxgb_is_neg_adv(req->status)) { if (cxgb_is_neg_adv(req->status)) {
pr_debug("%s Negative advice on abort- tid %u status %d (%s)\n", pr_warn("%s Negative advice on abort- tid %u status %d (%s)\n",
__func__, ep->hwtid, req->status, __func__, ep->hwtid, req->status,
neg_adv_str(req->status)); neg_adv_str(req->status));
ep->stats.abort_neg_adv++; ep->stats.abort_neg_adv++;
mutex_lock(&dev->rdev.stats.lock); mutex_lock(&dev->rdev.stats.lock);
dev->rdev.stats.neg_adv++; dev->rdev.stats.neg_adv++;
...@@ -2781,8 +2781,8 @@ static int peer_abort(struct c4iw_dev *dev, struct sk_buff *skb) ...@@ -2781,8 +2781,8 @@ static int peer_abort(struct c4iw_dev *dev, struct sk_buff *skb)
* do some housekeeping so as to re-initiate the * do some housekeeping so as to re-initiate the
* connection * connection
*/ */
pr_debug("%s: mpa_rev=%d. Retrying with mpav1\n", pr_info("%s: mpa_rev=%d. Retrying with mpav1\n",
__func__, mpa_rev); __func__, mpa_rev);
ep->retry_with_mpa_v1 = 1; ep->retry_with_mpa_v1 = 1;
} }
break; break;
...@@ -2808,7 +2808,7 @@ static int peer_abort(struct c4iw_dev *dev, struct sk_buff *skb) ...@@ -2808,7 +2808,7 @@ static int peer_abort(struct c4iw_dev *dev, struct sk_buff *skb)
case ABORTING: case ABORTING:
break; break;
case DEAD: case DEAD:
pr_debug("%s PEER_ABORT IN DEAD STATE!!!!\n", __func__); pr_warn("%s PEER_ABORT IN DEAD STATE!!!!\n", __func__);
mutex_unlock(&ep->com.mutex); mutex_unlock(&ep->com.mutex);
goto deref_ep; goto deref_ep;
default: default:
...@@ -3218,7 +3218,7 @@ int c4iw_connect(struct iw_cm_id *cm_id, struct iw_cm_conn_param *conn_param) ...@@ -3218,7 +3218,7 @@ int c4iw_connect(struct iw_cm_id *cm_id, struct iw_cm_conn_param *conn_param)
ep->com.dev = dev; ep->com.dev = dev;
ep->com.qp = get_qhp(dev, conn_param->qpn); ep->com.qp = get_qhp(dev, conn_param->qpn);
if (!ep->com.qp) { if (!ep->com.qp) {
pr_debug("%s qpn 0x%x not found!\n", __func__, conn_param->qpn); pr_warn("%s qpn 0x%x not found!\n", __func__, conn_param->qpn);
err = -EINVAL; err = -EINVAL;
goto fail2; goto fail2;
} }
...@@ -3571,8 +3571,8 @@ int c4iw_ep_disconnect(struct c4iw_ep *ep, int abrupt, gfp_t gfp) ...@@ -3571,8 +3571,8 @@ int c4iw_ep_disconnect(struct c4iw_ep *ep, int abrupt, gfp_t gfp)
case MORIBUND: case MORIBUND:
case ABORTING: case ABORTING:
case DEAD: case DEAD:
pr_debug("%s ignoring disconnect ep %p state %u\n", pr_info("%s ignoring disconnect ep %p state %u\n",
__func__, ep, ep->com.state); __func__, ep, ep->com.state);
break; break;
default: default:
BUG(); BUG();
...@@ -3676,7 +3676,7 @@ static void passive_ofld_conn_reply(struct c4iw_dev *dev, struct sk_buff *skb, ...@@ -3676,7 +3676,7 @@ static void passive_ofld_conn_reply(struct c4iw_dev *dev, struct sk_buff *skb,
rpl_skb = (struct sk_buff *)(unsigned long)req->cookie; rpl_skb = (struct sk_buff *)(unsigned long)req->cookie;
BUG_ON(!rpl_skb); BUG_ON(!rpl_skb);
if (req->retval) { if (req->retval) {
pr_debug("%s passive open failure %d\n", __func__, req->retval); pr_err("%s passive open failure %d\n", __func__, req->retval);
mutex_lock(&dev->rdev.stats.lock); mutex_lock(&dev->rdev.stats.lock);
dev->rdev.stats.pas_ofld_conn_fails++; dev->rdev.stats.pas_ofld_conn_fails++;
mutex_unlock(&dev->rdev.stats.lock); mutex_unlock(&dev->rdev.stats.lock);
...@@ -3893,8 +3893,8 @@ static int rx_pkt(struct c4iw_dev *dev, struct sk_buff *skb) ...@@ -3893,8 +3893,8 @@ static int rx_pkt(struct c4iw_dev *dev, struct sk_buff *skb)
lep = (struct c4iw_ep *)get_ep_from_stid(dev, stid); lep = (struct c4iw_ep *)get_ep_from_stid(dev, stid);
if (!lep) { if (!lep) {
pr_debug("%s connect request on invalid stid %d\n", pr_warn("%s connect request on invalid stid %d\n",
__func__, stid); __func__, stid);
goto reject; goto reject;
} }
...@@ -4209,8 +4209,8 @@ static int peer_abort_intr(struct c4iw_dev *dev, struct sk_buff *skb) ...@@ -4209,8 +4209,8 @@ static int peer_abort_intr(struct c4iw_dev *dev, struct sk_buff *skb)
return 0; return 0;
} }
if (cxgb_is_neg_adv(req->status)) { if (cxgb_is_neg_adv(req->status)) {
pr_debug("%s Negative advice on abort- tid %u status %d (%s)\n", pr_warn("%s Negative advice on abort- tid %u status %d (%s)\n",
__func__, ep->hwtid, req->status, __func__, ep->hwtid, req->status,
neg_adv_str(req->status)); neg_adv_str(req->status));
goto out; goto out;
} }
......
...@@ -234,7 +234,7 @@ int c4iw_ev_handler(struct c4iw_dev *dev, u32 qid) ...@@ -234,7 +234,7 @@ int c4iw_ev_handler(struct c4iw_dev *dev, u32 qid)
if (atomic_dec_and_test(&chp->refcnt)) if (atomic_dec_and_test(&chp->refcnt))
wake_up(&chp->wait); wake_up(&chp->wait);
} else { } else {
pr_debug("%s unknown cqid 0x%x\n", __func__, qid); pr_warn("%s unknown cqid 0x%x\n", __func__, qid);
spin_unlock_irqrestore(&dev->lock, flag); spin_unlock_irqrestore(&dev->lock, flag);
} }
return 0; return 0;
......
...@@ -230,8 +230,8 @@ static inline int c4iw_wait_for_reply(struct c4iw_rdev *rdev, ...@@ -230,8 +230,8 @@ static inline int c4iw_wait_for_reply(struct c4iw_rdev *rdev,
ret = wait_for_completion_timeout(&wr_waitp->completion, C4IW_WR_TO); ret = wait_for_completion_timeout(&wr_waitp->completion, C4IW_WR_TO);
if (!ret) { if (!ret) {
pr_debug("%s - Device %s not responding (disabling device) - tid %u qpid %u\n", pr_err("%s - Device %s not responding (disabling device) - tid %u qpid %u\n",
func, pci_name(rdev->lldi.pdev), hwtid, qpid); func, pci_name(rdev->lldi.pdev), hwtid, qpid);
rdev->flags |= T4_FATAL_ERROR; rdev->flags |= T4_FATAL_ERROR;
wr_waitp->ret = -EIO; wr_waitp->ret = -EIO;
} }
......
...@@ -958,8 +958,8 @@ int c4iw_post_send(struct ib_qp *ibqp, struct ib_send_wr *wr, ...@@ -958,8 +958,8 @@ int c4iw_post_send(struct ib_qp *ibqp, struct ib_send_wr *wr,
c4iw_invalidate_mr(qhp->rhp, wr->ex.invalidate_rkey); c4iw_invalidate_mr(qhp->rhp, wr->ex.invalidate_rkey);
break; break;
default: default:
pr_debug("%s post of type=%d TBD!\n", __func__, pr_warn("%s post of type=%d TBD!\n", __func__,
wr->opcode); wr->opcode);
err = -EINVAL; err = -EINVAL;
} }
if (err) { if (err) {
......
...@@ -597,8 +597,8 @@ static inline void t4_swcq_produce(struct t4_cq *cq) ...@@ -597,8 +597,8 @@ static inline void t4_swcq_produce(struct t4_cq *cq)
{ {
cq->sw_in_use++; cq->sw_in_use++;
if (cq->sw_in_use == cq->size) { if (cq->sw_in_use == cq->size) {
pr_debug("%s cxgb4 sw cq overflow cqid %u\n", pr_warn("%s cxgb4 sw cq overflow cqid %u\n",
__func__, cq->cqid); __func__, cq->cqid);
cq->error = 1; cq->error = 1;
BUG_ON(1); BUG_ON(1);
} }
...@@ -669,8 +669,8 @@ static inline int t4_next_hw_cqe(struct t4_cq *cq, struct t4_cqe **cqe) ...@@ -669,8 +669,8 @@ static inline int t4_next_hw_cqe(struct t4_cq *cq, struct t4_cqe **cqe)
static inline struct t4_cqe *t4_next_sw_cqe(struct t4_cq *cq) static inline struct t4_cqe *t4_next_sw_cqe(struct t4_cq *cq)
{ {
if (cq->sw_in_use == cq->size) { if (cq->sw_in_use == cq->size) {
pr_debug("%s cxgb4 sw cq overflow cqid %u\n", pr_warn("%s cxgb4 sw cq overflow cqid %u\n",
__func__, cq->cqid); __func__, cq->cqid);
cq->error = 1; cq->error = 1;
BUG_ON(1); BUG_ON(1);
return NULL; return NULL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment