From patchwork Mon Dec 17 16:55:31 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hal Rosenstock X-Patchwork-Id: 1888071 X-Patchwork-Delegate: alexne@voltaire.com Return-Path: X-Original-To: patchwork-linux-rdma@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 1A9283FCA5 for ; Mon, 17 Dec 2012 16:55:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753141Ab2LQQzf (ORCPT ); Mon, 17 Dec 2012 11:55:35 -0500 Received: from mail-vb0-f46.google.com ([209.85.212.46]:62592 "EHLO mail-vb0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752716Ab2LQQze (ORCPT ); Mon, 17 Dec 2012 11:55:34 -0500 Received: by mail-vb0-f46.google.com with SMTP id b13so7313385vby.19 for ; Mon, 17 Dec 2012 08:55:34 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :content-type:content-transfer-encoding:x-gm-message-state; bh=G+m0m/c1lPm5gtdlktIbSCuZL20Shsdi6YT4wpyZ1v4=; b=IB6dQlhwMqlGLqHAa/myoJEHbhE9a6luKZd7UzlVVNgMH8ct+k8AB4wuDPZK4+9Ba6 J+QXud9EoayeUNGXRDPE5ysvLScmDDNiEbwAycwS8LdaZoiZ5zeKgMD/JuGU4tMZVrVO uDBmvga30r3K+ur7X0jTTp3ETXyPYuBa8Hld3EcoKGolSAlZiVuvDALfQp0pCdoz04vL u7DXs7ECEC8G1aVz6TD6I6inuutZzUPAYgLrMWbNk9zs+ym18vxqNaOjStOi3ry3HIri IFG0yqtHp+JXFQyf2f28yjqTXqdjQDmFDAuyCyoYXuaqjygcxqFG9K3mb0v3ljAfCEJb C24g== Received: by 10.52.72.66 with SMTP id b2mr21307010vdv.31.1355763334016; Mon, 17 Dec 2012 08:55:34 -0800 (PST) Received: from [192.168.1.102] (c-71-192-10-85.hsd1.ma.comcast.net. [71.192.10.85]) by mx.google.com with ESMTPS id dl18sm12370020vdb.2.2012.12.17.08.55.32 (version=SSLv3 cipher=OTHER); Mon, 17 Dec 2012 08:55:33 -0800 (PST) Message-ID: <50CF4E83.6030501@dev.mellanox.co.il> Date: Mon, 17 Dec 2012 11:55:31 -0500 From: Hal Rosenstock User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:9.0) Gecko/20111222 Thunderbird/9.0.1 MIME-Version: 1.0 To: Alex Netes CC: "linux-rdma (linux-rdma@vger.kernel.org)" Subject: [PATCH] opensm/osm_dump.c: Fix output port on SL2VL table for non switch nodes X-Gm-Message-State: ALoCoQk6FbMfA31JwgKyaEBVGMt8eqilrGBHjNLwM/7TT7TXbuEKS4Z6D5op8c3iaDvi2thUiFNi Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org Rather than actual port number as out port, use port number 0 for out port when CA or router as in/out ports are reserved Signed-off-by: Hal Rosenstock --- -- 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/opensm/osm_dump.c b/opensm/osm_dump.c index b9bd6ed..aae6a18 100644 --- a/opensm/osm_dump.c +++ b/opensm/osm_dump.c @@ -529,8 +529,7 @@ static void dump_sl2vl_tbl(cl_map_item_t * item, FILE * file, void *cxt) for (i = 0, n = 0; i < 16; i++) n += sprintf(buf + n, " %-2d", ib_slvl_table_get(p_tbl, i)); - fprintf(file, "%-3d %-3d :%s\n", - 0, p_physp->port_num, buf); + fprintf(file, "%-3d %-3d :%s\n", 0, 0, buf); } fprintf(file, "%s\n\n", separator_line);