From patchwork Thu Apr 13 14:48:25 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hal Rosenstock X-Patchwork-Id: 9679501 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 5989C60381 for ; Thu, 13 Apr 2017 14:48:31 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4ADA82866E for ; Thu, 13 Apr 2017 14:48:31 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3F56A2867A; Thu, 13 Apr 2017 14:48:31 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.3 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C95D12866E for ; Thu, 13 Apr 2017 14:48:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754030AbdDMOsa (ORCPT ); Thu, 13 Apr 2017 10:48:30 -0400 Received: from mail-wr0-f196.google.com ([209.85.128.196]:33332 "EHLO mail-wr0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754026AbdDMOs3 (ORCPT ); Thu, 13 Apr 2017 10:48:29 -0400 Received: by mail-wr0-f196.google.com with SMTP id l28so8926197wre.0 for ; Thu, 13 Apr 2017 07:48:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dev-mellanox-co-il.20150623.gappssmtp.com; s=20150623; h=to:cc:from:subject:message-id:date:user-agent:mime-version :content-transfer-encoding; bh=4Yts3JlY0PDw0GuKK7PMu7jLfAk/ykdVSOuDG2X/mW0=; b=OH6uybvT4opgdgPB7F8HaJmBKGiRmi+ofEMLFVnuK3PLYI5z0rgrrQBDvrp3fko9+C eNxeB8nYj8d6lBB/XP0fYCZSpGLB+u9pBDtVVs/JDRz0QW3aE1WJSrWVgK0jWrNbLyOg LBAvFk47sME5nA6vM2QAb2lccAM3ffVdry4Q4/YBxjDODb56mX54JSq3uQfSyc9w2kkh yNOXcCGL9gilVwDTCWIl1ZvH/3QYnG3wGTI1dCbxSEV9opDgMYrlMS5fVLuZ3g4pvqmU iyAcWonpM4El+p4Kz1kSsd+GCWFI3P4NYXZiik/U0MG6/0YCtwShWvUGI3FzgVVGQVJn tMiw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:cc:from:subject:message-id:date:user-agent :mime-version:content-transfer-encoding; bh=4Yts3JlY0PDw0GuKK7PMu7jLfAk/ykdVSOuDG2X/mW0=; b=GxIJFthOjfvXUOsxaIfpa0JrLp68CzwUkUfmjryL2J6st8TsZD5KpFehovc0vor9b0 UgQnWMo2VI/d6eeS2B0LtUr15Ir8JY1FebkSHcz4keiH77CbfLBTz4nrtH7UwlBefGOG 2KvyalBwM1U7sm7z6fuLTHB9mfa1IVjunihUEdgsZ4+carZqYgBKTncOByAUne9C/UML MMY/8bgORQzGA6K6NMxBy9zkgA41wB0AZQyq2aEBQqXZwOTuPZisUjbQkEkBzXWPAy1e XzCEKp/yNoiJeP0KkONgZa95ZSRVc/+Q1IMYRr8IYTdnol+eCa38xgoAPZj/+OJkTYwR lVcA== X-Gm-Message-State: AN3rC/4a6/M4rH6HeIDqBX+lJqU77JJguGToDR9EYl27vh/xHVuJhrcZ KJ/zyhGoMv9yzQ== X-Received: by 10.223.157.37 with SMTP id k37mr3461107wre.156.1492094907935; Thu, 13 Apr 2017 07:48:27 -0700 (PDT) Received: from [192.168.1.183] (c-67-189-170-197.hsd1.ma.comcast.net. [67.189.170.197]) by smtp.googlemail.com with ESMTPSA id g15sm9953762wmc.14.2017.04.13.07.48.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 13 Apr 2017 07:48:27 -0700 (PDT) To: Doug Ledford Cc: Honggang LI , Bart Van Assche , "linux-rdma@vger.kernel.org" From: Hal Rosenstock Subject: [PATCH rdma-core 2/3] srp_daemon/srp_daemon.c: Eliminate some unneeded code in get_shared_pkeys Message-ID: Date: Thu, 13 Apr 2017 10:48:25 -0400 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP PathRecords are obtained using SubAdmGet and not SubAdmGetTable so RMPP is not involved. Eliminate unneeded initialization of MAD RMPP fields. Signed-off-by: Hal Rosenstock Reviewed-by: Bart Van Assche -- Reviewed-by: Honggang Li --- srp_daemon/srp_daemon.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/srp_daemon/srp_daemon.c b/srp_daemon/srp_daemon.c index 9fb2ecc..59a6137 100644 --- a/srp_daemon/srp_daemon.c +++ b/srp_daemon/srp_daemon.c @@ -1134,8 +1134,6 @@ static int get_shared_pkeys(struct resources *res, /* Mark components: DLID, SLID, PKEY */ out_sa_mad->comp_mask = htobe64(1 << 4 | 1 << 5 | 1 << 13); - out_sa_mad->rmpp_hdr.rmpp_version = UMAD_RMPP_VERSION; - out_sa_mad->rmpp_hdr.rmpp_type = 1; path_rec = (struct ib_path_rec *)out_sa_mad->data; path_rec->slid = htobe16(local_port_lid); path_rec->dlid = htobe16(dest_port_lid);