From patchwork Mon Sep 30 14:05:55 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Netes X-Patchwork-Id: 2965191 X-Patchwork-Delegate: hal@mellanox.com Return-Path: X-Original-To: patchwork-linux-rdma@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id A5B9B9F288 for ; Mon, 30 Sep 2013 14:06:06 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 84EDE20138 for ; Mon, 30 Sep 2013 14:06:05 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E66CF200EA for ; Mon, 30 Sep 2013 14:06:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754512Ab3I3OF7 (ORCPT ); Mon, 30 Sep 2013 10:05:59 -0400 Received: from mail-ee0-f48.google.com ([74.125.83.48]:56715 "EHLO mail-ee0-f48.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754044Ab3I3OF7 (ORCPT ); Mon, 30 Sep 2013 10:05:59 -0400 Received: by mail-ee0-f48.google.com with SMTP id l10so2718254eei.35 for ; Mon, 30 Sep 2013 07:05:58 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:date:from:to:subject:message-id :mime-version:content-type:content-disposition:user-agent; bh=W5bPufzbmdF75eeTHrqf+06ruizwpy4C8ieZPH0h27U=; b=CQaYP140YUYrSXzdESKcUzxWIN3XKB6JjIt76fzQRgrW0/+6/3uCwefyrqltjTA4BG vtEcc5veQm6qnnnY6Sw9TUCs00FZthMDuOQ2Dgm3AUwb9k+9GvbOYZxnCJpA1uxJgfSO ErAkis+8WYci0SADXrMOK+6wkQdHE5RJbbxZZwwZmqg05RY8T/zdfRseCC8PAcdQBx6T dVSfWIqx4wTqOaou4nV/o7GrTqySKlOfYB5aCgivmgNImtpwTRseMHGTD0twxGpZo5AS IZupTZBN3EXAOt+H56MxEe6/PZCDBELSe9SUCVsa6FnY9wy1+vINwgBEACNKq3zdlnYZ birw== X-Gm-Message-State: ALoCoQnNV0z976I6COyFV309wUdwx2eIgOOleTdME5POQgGLH+jjBUqQrgmJJ+XLvGh5pmwYZjjL X-Received: by 10.15.54.199 with SMTP id t47mr13947042eew.46.1380549957793; Mon, 30 Sep 2013 07:05:57 -0700 (PDT) Received: from localhost (out.voltaire.com. [193.47.165.251]) by mx.google.com with ESMTPSA id i1sm1617956eeg.0.1969.12.31.16.00.00 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Mon, 30 Sep 2013 07:05:57 -0700 (PDT) Date: Mon, 30 Sep 2013 17:05:55 +0300 From: Alex Netes To: linux-rdma@vger.kernel.org, Hal Rosenstock Subject: [PATCH] opensm: Fix GUIDInfo SET function Message-ID: <20130930140555.GA3668@calypso.mtr.labs.mlnx> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP osm_req_set parameters order is incorrect. Because of this only block 0 is incorrectly altered. Signed-off-by: Alex Netes --- opensm/osm_guid_mgr.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/opensm/osm_guid_mgr.c b/opensm/osm_guid_mgr.c index d826366..e4d1de7 100644 --- a/opensm/osm_guid_mgr.c +++ b/opensm/osm_guid_mgr.c @@ -73,10 +73,9 @@ static void guidinfo_set(IN osm_sa_t *sa, IN osm_port_t *p_port, status = osm_req_set(sa->sm, osm_physp_get_dr_path_ptr(p_port->p_physp), payload, sizeof(payload), IB_MAD_ATTR_GUID_INFO, - FALSE, + cl_hton32((uint32_t)block_num), FALSE, ib_port_info_get_m_key(&p_port->p_physp->port_info), - cl_hton32((uint32_t)block_num), - CL_DISP_MSGID_NONE, &context); + CL_DISP_MSGID_NONE, &context); if (status != IB_SUCCESS) OSM_LOG(sa->p_log, OSM_LOG_ERROR, "ERR 5109: " "Failure initiating GUIDInfo request (%s)\n",