From patchwork Fri Sep 13 17:38:25 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Antonio Alecrim Jr X-Patchwork-Id: 2892341 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 483E29F23C for ; Fri, 13 Sep 2013 20:38:17 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 7524D20266 for ; Fri, 13 Sep 2013 20:38:16 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 7FE7D20263 for ; Fri, 13 Sep 2013 20:38:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753552Ab3IMUiO (ORCPT ); Fri, 13 Sep 2013 16:38:14 -0400 Received: from mail-qc0-f175.google.com ([209.85.216.175]:50432 "EHLO mail-qc0-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752516Ab3IMUiN (ORCPT ); Fri, 13 Sep 2013 16:38:13 -0400 Received: by mail-qc0-f175.google.com with SMTP id v2so1220303qcr.34 for ; Fri, 13 Sep 2013 13:38:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:mime-version:content-type :content-transfer-encoding; bh=xmiCezJkztKq1523EsGKrHbY4Ko2eTVNYuVBU8wKkUc=; b=Cq/6W1M+BGgvFnOOVZkwB69UHuhWfE0AgDPqyWiA1kUJXmUZLOlg8Fpfv6jnyDSPDp +iExXhQ0CFCKWyoAQSFY83UxQvokYYipMqwwc4qC0MWqXYnQum0MPwZcLjrXkYeQ6lch dYS6puWx9sme17jzde5JUauTPqewrNiMp7b7SVqDLpQiEJA0kRhth0b3b5q5IDWBf6Vz cv6De4m3HzVrW0EyhB5O205PAmjedFXmGqxuXAt++00z6AVI18ucj8Jmnhk7Pj34YwLl lZDuuP358SBZ3xogiplcVcvncN7NUOoL8X0irSazHq2fzGV8IqNWeS1ehtQIkG3WVBS6 S2Tg== X-Received: by 10.49.105.1 with SMTP id gi1mr28810565qeb.8.1379104692716; Fri, 13 Sep 2013 13:38:12 -0700 (PDT) Received: from linux-ok44.site (201-66-161-133.paemt701.dsl.brasiltelecom.net.br. [201.66.161.133]) by mx.google.com with ESMTPSA id f5sm22854254qev.8.1969.12.31.16.00.00 (version=TLSv1.2 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 13 Sep 2013 13:38:12 -0700 (PDT) From: Antonio Alecrim Jr To: Roland Dreier , Sean Hefty , linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Antonio Alecrim Jr Subject: [PATCH 1/1] =?UTF-8?q?infiniband:=20hw:=20fix=20uninitialized=20?= =?UTF-8?q?=E2=80=98old=5Fqps=E2=80=99?= Date: Fri, 13 Sep 2013 14:38:25 -0300 Message-Id: <1379093905-5968-1-git-send-email-antonio.alecrim@gmail.com> X-Mailer: git-send-email 1.8.3.1 MIME-Version: 1.0 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.7 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable 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 Added missing old_qps initialization in order to fix the following warnings: drivers/infiniband/hw/ocrdma/ocrdma_verbs.c: In function ‘_ocrdma_modify_qp’: drivers/infiniband/hw/ocrdma/ocrdma_verbs.c:1299:31: warning: ‘old_qps’ may be used uninitialized in this function [-Wmaybe-uninitialized] status = ocrdma_mbx_modify_qp(dev, qp, attr, attr_mask, old_qps); Signed-off-by: Antonio Alecrim Jr --- drivers/infiniband/hw/ocrdma/ocrdma_verbs.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c b/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c index 6e982bb..da6c23f 100644 --- a/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c +++ b/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c @@ -1289,6 +1289,7 @@ int _ocrdma_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, qp = get_ocrdma_qp(ibqp); dev = qp->dev; + old_qps = get_ibqp_state(qp->state); if (attr_mask & IB_QP_STATE) status = ocrdma_qp_state_change(qp, attr->qp_state, &old_qps); /* if new and previous states are same hw doesn't need to