From: Sagi Grimberg <sagig-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org>
To: Yann Droneaud <ydroneaud-RlY5vtjFyJ3QT0dZR+AlfA@public.gmane.org>,
Sagi Grimberg <sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH v5 5/6] xprtrdma: Switch to generic logging helpers
Date: Tue, 12 May 2015 16:08:45 +0300 [thread overview]
Message-ID: <5551FB5D.4060509@dev.mellanox.co.il> (raw)
In-Reply-To: <1431434425.25060.65.camel-RlY5vtjFyJ3QT0dZR+AlfA@public.gmane.org>
On 5/12/2015 3:40 PM, Yann Droneaud wrote:
> Hi,
>
> Le mardi 12 mai 2015 à 15:05 +0300, Sagi Grimberg a écrit :
>> Reviewed-by: Chuck Lever <chuck.lever-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
>> Signed-off-by: Sagi Grimberg <sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
>> Signed-off-by: Anna Schumaker <anna.schumaker-HgOvQuBEEgTQT0dZR+AlfA@public.gmane.org>
>> ---
>> net/sunrpc/xprtrdma/frwr_ops.c | 4 +-
>> net/sunrpc/xprtrdma/svc_rdma_transport.c | 29 ++++++----
>> net/sunrpc/xprtrdma/verbs.c | 90 ++----------------------------
>> 3 files changed, 25 insertions(+), 98 deletions(-)
>>
>> diff --git a/net/sunrpc/xprtrdma/frwr_ops.c b/net/sunrpc/xprtrdma/frwr_ops.c
>> index dff0481..b3fda09 100644
>> --- a/net/sunrpc/xprtrdma/frwr_ops.c
>> +++ b/net/sunrpc/xprtrdma/frwr_ops.c
>> @@ -128,8 +128,8 @@ frwr_sendcompletion(struct ib_wc *wc)
>>
>> /* WARNING: Only wr_id and status are reliable at this point */
>> r = (struct rpcrdma_mw *)(unsigned long)wc->wr_id;
>> - dprintk("RPC: %s: frmr %p (stale), status %d\n",
>> - __func__, r, wc->status);
>> + dprintk("RPC: %s: frmr %p (stale), status %s(%d)\n",
>> + __func__, r, ib_wc_status_msg(wc->status), wc->status);
>> r->r.frmr.fr_state = FRMR_IS_STALE;
>> }
>>
>> diff --git a/net/sunrpc/xprtrdma/svc_rdma_transport.c b/net/sunrpc/xprtrdma/svc_rdma_transport.c
>> index f609c1c..abd2d51 100644
>> --- a/net/sunrpc/xprtrdma/svc_rdma_transport.c
>> +++ b/net/sunrpc/xprtrdma/svc_rdma_transport.c
>> @@ -175,8 +175,8 @@ void svc_rdma_put_req_map(struct svc_rdma_req_map *map)
>> static void cq_event_handler(struct ib_event *event, void *context)
>> {
>> struct svc_xprt *xprt = context;
>> - dprintk("svcrdma: received CQ event id=%d, context=%p\n",
>> - event->event, context);
>> + dprintk("svcrdma: received CQ event %s(%d), context=%p\n",
>> + ib_event_msg(event->event), event->event, context);
>> set_bit(XPT_CLOSE, &xprt->xpt_flags);
>> }
>>
>> @@ -191,8 +191,9 @@ static void qp_event_handler(struct ib_event *event, void *context)
>> case IB_EVENT_COMM_EST:
>> case IB_EVENT_SQ_DRAINED:
>> case IB_EVENT_QP_LAST_WQE_REACHED:
>> - dprintk("svcrdma: QP event %d received for QP=%p\n",
>> - event->event, event->element.qp);
>> + dprintk("svcrdma: QP event %s(%d) received for QP=%p\n",
>> + ib_event_msg(event->event), event->event,
>> + event->element.qp);
>> break;
>> /* These are considered fatal events */
>> case IB_EVENT_PATH_MIG_ERR:
>> @@ -201,9 +202,10 @@ static void qp_event_handler(struct ib_event *event, void *context)
>> case IB_EVENT_QP_ACCESS_ERR:
>> case IB_EVENT_DEVICE_FATAL:
>> default:
>> - dprintk("svcrdma: QP ERROR event %d received for QP=%p, "
>> + dprintk("svcrdma: QP ERROR event %s(%d) received for QP=%p, "
>> "closing transport\n",
>> - event->event, event->element.qp);
>> + ib_event_msg(event->event), event->event,
>> + event->element.qp);
>> set_bit(XPT_CLOSE, &xprt->xpt_flags);
>> break;
>> }
>> @@ -402,7 +404,8 @@ static void sq_cq_reap(struct svcxprt_rdma *xprt)
>> for (i = 0; i < ret; i++) {
>> wc = &wc_a[i];
>> if (wc->status != IB_WC_SUCCESS) {
>> - dprintk("svcrdma: sq wc err status %d\n",
>> + dprintk("svcrdma: sq wc err status %s(%d)\n",
>> + ib_wc_status_msg(wc->status),
>> wc->status);
>>
>> /* Close the transport */
>> @@ -616,7 +619,8 @@ static int rdma_listen_handler(struct rdma_cm_id *cma_id,
>> switch (event->event) {
>> case RDMA_CM_EVENT_CONNECT_REQUEST:
>> dprintk("svcrdma: Connect request on cma_id=%p, xprt = %p, "
>> - "event=%d\n", cma_id, cma_id->context, event->event);
>> + "event=%s(%d)\n", cma_id, cma_id->context,
>> + rdma_event_msg(event->event), event->event);
>> handle_connect_req(cma_id,
>> event->param.conn.initiator_depth);
>> break;
>> @@ -636,7 +640,8 @@ static int rdma_listen_handler(struct rdma_cm_id *cma_id,
>>
>> default:
>> dprintk("svcrdma: Unexpected event on listening endpoint %p, "
>> - "event=%d\n", cma_id, event->event);
>> + "event=%s(%d)\n", cma_id, rdma_event_msg(event->event),
>> + event->event);
>> break;
>> }
>>
>> @@ -669,7 +674,8 @@ static int rdma_cma_handler(struct rdma_cm_id *cma_id,
>> break;
>> case RDMA_CM_EVENT_DEVICE_REMOVAL:
>> dprintk("svcrdma: Device removal cma_id=%p, xprt = %p, "
>> - "event=%d\n", cma_id, xprt, event->event);
>> + "event=%s(%d)\n", cma_id, xprt,
>> + rdma_event_msg(event->event), event->event);
>> if (xprt) {
>> set_bit(XPT_CLOSE, &xprt->xpt_flags);
>> svc_xprt_enqueue(xprt);
>> @@ -677,7 +683,8 @@ static int rdma_cma_handler(struct rdma_cm_id *cma_id,
>> break;
>> default:
>> dprintk("svcrdma: Unexpected event on DTO endpoint %p, "
>> - "event=%d\n", cma_id, event->event);
>> + "event=%d\n", cma_id, rdma_event_msg(event->event),
>> + event->event);
>
> There's something wrong here, %s is missing.
>
Yep, I'll fix that too...
Thanks!
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2015-05-12 13:08 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-12 12:05 Generic logging helpers [v5] Sagi Grimberg
[not found] ` <1431432329-859-1-git-send-email-sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2015-05-12 12:05 ` [PATCH v5 1/6] IB/core, cma: Nice log-friendly string helpers Sagi Grimberg
[not found] ` <1431432329-859-2-git-send-email-sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2015-05-12 12:59 ` Or Gerlitz
[not found] ` <CAJ3xEMhOnrZJrUfwtMs7Tod7YeGy_Be6yF543+xds_05hO-F-A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-05-12 13:33 ` Sagi Grimberg
2015-05-12 13:56 ` Chuck Lever
[not found] ` <E27932C3-BDF3-4FED-ABD6-416454EFA5C0-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
2015-05-12 17:21 ` Doug Ledford
2015-05-12 12:05 ` [PATCH v5 2/6] IB/srp: Align to generic logging helpers Sagi Grimberg
2015-05-12 12:05 ` [PATCH v5 3/6] IB/iser: " Sagi Grimberg
2015-05-12 12:05 ` [PATCH v5 4/6] iser-target: " Sagi Grimberg
2015-05-12 12:05 ` [PATCH v5 5/6] xprtrdma: Switch " Sagi Grimberg
[not found] ` <1431432329-859-6-git-send-email-sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2015-05-12 12:40 ` Yann Droneaud
[not found] ` <1431434425.25060.65.camel-RlY5vtjFyJ3QT0dZR+AlfA@public.gmane.org>
2015-05-12 13:08 ` Sagi Grimberg [this message]
2015-05-12 12:05 ` [PATCH v5 6/6] RDS: " Sagi Grimberg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5551FB5D.4060509@dev.mellanox.co.il \
--to=sagig-ldsdmyg8hgv8yrgs2mwiifqbs+8scbdb@public.gmane.org \
--cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org \
--cc=ydroneaud-RlY5vtjFyJ3QT0dZR+AlfA@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox