From patchwork Mon Apr 4 19:25:02 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hal Rosenstock X-Patchwork-Id: 685341 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p34JPAuA020110 for ; Mon, 4 Apr 2011 19:25:11 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755187Ab1DDTZI (ORCPT ); Mon, 4 Apr 2011 15:25:08 -0400 Received: from mail-fx0-f46.google.com ([209.85.161.46]:42546 "EHLO mail-fx0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755139Ab1DDTZH (ORCPT ); Mon, 4 Apr 2011 15:25:07 -0400 Received: by fxm17 with SMTP id 17so4142808fxm.19 for ; Mon, 04 Apr 2011 12:25:05 -0700 (PDT) Received: by 10.223.59.146 with SMTP id l18mr1093325fah.58.1301945105746; Mon, 04 Apr 2011 12:25:05 -0700 (PDT) Received: from [192.168.1.103] (c-75-69-247-31.hsd1.ma.comcast.net [75.69.247.31]) by mx.google.com with ESMTPS id o17sm1848220fal.1.2011.04.04.12.25.03 (version=SSLv3 cipher=OTHER); Mon, 04 Apr 2011 12:25:04 -0700 (PDT) Message-ID: <4D9A1B0E.9010904@dev.mellanox.co.il> Date: Mon, 04 Apr 2011 15:25:02 -0400 From: Hal Rosenstock User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.15) Gecko/20110303 Thunderbird/3.1.9 MIME-Version: 1.0 To: Alex Netes CC: "linux-rdma@vger.kernel.org" Subject: [PATCH] osmtest/osmt_multicast.c: In some multicast flows, insufficient comps should be a warning Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Mon, 04 Apr 2011 19:25:13 +0000 (UTC) rather than error (it's preferred but not required) Signed-off-by: Hal Rosenstock --- * @@ -738,13 +738,15 @@ ib_api_status_t osmt_run_mcast_flow(IN osmtest_t * const p_osmt) sa_mad); OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, EXPECTING_ERRORS_END "\n"); - if (status != IB_REMOTE_ERROR || - ((ib_net16_t) (sa_mad->status & IB_SMP_STATUS_MASK)) != - IB_SA_MAD_STATUS_INSUF_COMPS) { - OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, "ERR 02EE: " - "Expected REMOTE ERROR IB_SA_MAD_STATUS_INSUF_COMPS got:%s/%s\n", - ib_get_err_str(status), + if (((ib_net16_t) (sa_mad->status & IB_SMP_STATUS_MASK)) != + IB_SA_MAD_STATUS_INSUF_COMPS) + OSM_LOG(&p_osmt->log, OSM_LOG_INFO, + "Expected IB_SA_MAD_STATUS_INSUF_COMPS got:%s\n", ib_get_mad_status_str((ib_mad_t *) sa_mad)); + if (status != IB_REMOTE_ERROR) { + OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, "ERR 02EE: " + "Expected REMOTE ERROR got:%s\n", + ib_get_err_str(status)); status = IB_ERROR; goto Exit; } @@ -769,13 +771,15 @@ ib_api_status_t osmt_run_mcast_flow(IN osmtest_t * const p_osmt) sa_mad); OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, EXPECTING_ERRORS_END "\n"); - if (status != IB_REMOTE_ERROR || - ((ib_net16_t) (sa_mad->status & IB_SMP_STATUS_MASK)) != - IB_SA_MAD_STATUS_INSUF_COMPS) { - OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, "ERR 02ED: " - "Expected REMOTE ERROR IB_SA_MAD_STATUS_INSUF_COMPS got:%s/%s\n", - ib_get_err_str(status), + if (((ib_net16_t) (sa_mad->status & IB_SMP_STATUS_MASK)) != + IB_SA_MAD_STATUS_INSUF_COMPS) + OSM_LOG(&p_osmt->log, OSM_LOG_INFO, + "Expected IB_SA_MAD_STATUS_INSUF_COMPS got:%s\n", ib_get_mad_status_str((ib_mad_t *) sa_mad)); + if (status != IB_REMOTE_ERROR) { + OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, "ERR 02ED: " + "Expected REMOTE ERROR got:%s\n", + ib_get_err_str(status)); status = IB_ERROR; goto Exit; } @@ -1073,6 +1077,7 @@ ib_api_status_t osmt_run_mcast_flow(IN osmtest_t * const p_osmt) /* no MGID */ memset(&mc_req_rec.mgid, 0, sizeof(ib_gid_t)); /* Request Join */ + mc_req_rec.pkey = IB_DEFAULT_PKEY; ib_member_set_join_state(&mc_req_rec, IB_MC_REC_STATE_FULL_MEMBER); comp_mask = @@ -1087,13 +1092,15 @@ ib_api_status_t osmt_run_mcast_flow(IN osmtest_t * const p_osmt) sa_mad); OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, EXPECTING_ERRORS_END "\n"); - if (status != IB_REMOTE_ERROR || - ((ib_net16_t) (sa_mad->status & IB_SMP_STATUS_MASK)) != - IB_SA_MAD_STATUS_INSUF_COMPS) { - OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, "ERR 02A8: " - "Expected REMOTE ERROR IB_SA_MAD_STATUS_INSUF_COMPS got:%s/%s\n", - ib_get_err_str(status), + if (((ib_net16_t) (sa_mad->status & IB_SMP_STATUS_MASK)) != + IB_SA_MAD_STATUS_INSUF_COMPS) + OSM_LOG(&p_osmt->log, OSM_LOG_INFO, + "Expected IB_SA_MAD_STATUS_INSUF_COMPS got:%s\n", ib_get_mad_status_str((ib_mad_t *) sa_mad)); + if (status != IB_REMOTE_ERROR) { + OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, "ERR 02A8: " + "Expected REMOTE ERROR got:%s\n", + ib_get_err_str(status)); status = IB_ERROR; goto Exit; } @@ -1165,6 +1172,7 @@ ib_api_status_t osmt_run_mcast_flow(IN osmtest_t * const p_osmt) /* no MGID */ memset(&mc_req_rec.mgid, 0, sizeof(ib_gid_t)); /* Request Join */ + mc_req_rec.pkey = IB_DEFAULT_PKEY; ib_member_set_join_state(&mc_req_rec, IB_MC_REC_STATE_FULL_MEMBER); comp_mask = @@ -1180,13 +1188,15 @@ ib_api_status_t osmt_run_mcast_flow(IN osmtest_t * const p_osmt) sa_mad); OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, EXPECTING_ERRORS_END "\n"); - if (status != IB_REMOTE_ERROR || - ((ib_net16_t) (sa_mad->status & IB_SMP_STATUS_MASK)) != - IB_SA_MAD_STATUS_INSUF_COMPS) { - OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, "ERR 02A6: " - "Expected REMOTE ERROR IB_SA_MAD_STATUS_INSUF_COMPS got:%s/%s\n", - ib_get_err_str(status), + if (((ib_net16_t) (sa_mad->status & IB_SMP_STATUS_MASK)) != + IB_SA_MAD_STATUS_INSUF_COMPS) + OSM_LOG(&p_osmt->log, OSM_LOG_INFO, + "Expected IB_SA_MAD_STATUS_INSUF_COMPS got:%s\n", ib_get_mad_status_str((ib_mad_t *) sa_mad)); + if (status != IB_REMOTE_ERROR) { + OSM_LOG(&p_osmt->log, OSM_LOG_ERROR, "ERR 02A6: " + "Expected REMOTE ERROR got:%s\n", + ib_get_err_str(status)); status = IB_ERROR; goto Exit; } -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/osmtest/osmt_multicast.c b/osmtest/osmt_multicast.c index b4e2a54..52577bc 100644 --- a/osmtest/osmt_multicast.c +++ b/osmtest/osmt_multicast.c @@ -1,6 +1,6 @@ /* * Copyright (c) 2006-2009 Voltaire, Inc. All rights reserved. - * Copyright (c) 2002-2005,2008 Mellanox Technologies LTD. All rights reserved. + * Copyright (c) 2002-2011 Mellanox Technologies LTD. All rights reserved. * Copyright (c) 1996-2003 Intel Corporation. All rights reserved. * Copyright (c) 2010 HNR Consulting. All rights reserved.