From patchwork Fri Sep 22 06:17:26 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Smart X-Patchwork-Id: 9965229 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 910D16057C for ; Fri, 22 Sep 2017 06:18:14 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7F15029707 for ; Fri, 22 Sep 2017 06:18:14 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6816C297D0; Fri, 22 Sep 2017 06:18:14 +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.5 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM 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 D9DE629707 for ; Fri, 22 Sep 2017 06:18:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751864AbdIVGSC (ORCPT ); Fri, 22 Sep 2017 02:18:02 -0400 Received: from mail-pg0-f68.google.com ([74.125.83.68]:34576 "EHLO mail-pg0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751809AbdIVGR7 (ORCPT ); Fri, 22 Sep 2017 02:17:59 -0400 Received: by mail-pg0-f68.google.com with SMTP id u18so126547pgo.1 for ; Thu, 21 Sep 2017 23:17:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=/i4+DoZkXEl65nNvoPBZShhBOueNXDA+XlPfExpf5io=; b=meizH2pPc5XJ8W7FziES38qeF9eGyvV9sXD0rBofoThHwW5dYqdrKoA21vIXFDgZw8 C8DPmLoCo6LKll9xUJkeWPrBZJA12TpLz53FylZAPvSGKVoEpbt2c9h6KTqPauQxcBrv M7pGncJHX14njqwQRq5+2Sk3Iu6P9dL+rPyyrb6FWC+EG6lMeRXU/gFvEZyby5O71tPk +xsW5QWP4SC6zkI4NRPFLQa/9SlullJnPtRzVK4RjDWtG/qiUYITeTOznRpI8psWIxkI huISESWS5hNuL+aP/uz4yaCtVRnRh2XZPu1qrxRmZM8HF0xWmBYa/ohTiI4WSakZhq0v 7ILg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=/i4+DoZkXEl65nNvoPBZShhBOueNXDA+XlPfExpf5io=; b=QN8kjlHiT6tc4NARdI8CnVC9+cqUAGwJpRxrbVgPLOPEgwu7yzhsc4gBbRhFoS+HvB iWgPax4uOrZEZgb+anRfy06zI7ZoIIMh2p9j6So3PkjB7LnRvDbmZjAeKZGRyg7iCV1O JAcPAXP8hslz7s+nJqSgB24XFl/eUGSDUyJdBZLVzxAfpI0gwwx2VVug1bm4XHAlBFlZ zzEuurlvp2C6IMUamfhGWCLCo35VE67cExyrAuOlf0WhAV0DaeA/nEpB3eUWHYwOO2hB Jk7ZRDCm9bvYTqql3MD8piy1zijf3qg0zf0dc6Qlma/LW25ooyrvR4IKZN/MDfO4KHox AHDA== X-Gm-Message-State: AHPjjUigmdAV2VV4fCz1BB+AsxTl9EzBhvv1cpUM9MoNOrzhZ0E42Bj3 K6sZ1XjXgIPq6ji0u1quR108xA== X-Google-Smtp-Source: AOwi7QBLW8k5U5QprVpFVYPZsenTCe0uBToGk106OUJpxuKfzBuG+Pqh6FL2r2bMIaaxVqN5EdYBRA== X-Received: by 10.99.126.23 with SMTP id z23mr8200758pgc.58.1506061079279; Thu, 21 Sep 2017 23:17:59 -0700 (PDT) Received: from os42.localdomain (ip68-4-115-207.oc.oc.cox.net. [68.4.115.207]) by smtp.gmail.com with ESMTPSA id e87sm5911355pfl.46.2017.09.21.23.17.58 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 21 Sep 2017 23:17:58 -0700 (PDT) From: James Smart To: linux-scsi@vger.kernel.org Cc: Dick Kennedy , James Smart Subject: [PATCH 04/19] lpfc: Fix warning messages when NVME_TARGET_FC not defined Date: Thu, 21 Sep 2017 23:17:26 -0700 Message-Id: <20170922061741.12347-5-jsmart2021@gmail.com> X-Mailer: git-send-email 2.13.1 In-Reply-To: <20170922061741.12347-1-jsmart2021@gmail.com> References: <20170922061741.12347-1-jsmart2021@gmail.com> Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Dick Kennedy Warning messages when NVME_TARGET_FC not defined on ppc builds The lpfc_nvmet_replenish_context() function is only meaningful when NVME target mode enabled. Surround the function body with ifdefs for target mode enablement. Signed-off-by: Dick Kennedy Signed-off-by: James Smart Reported-by: Stephen Rothwell Reviewed-by: Johannes Thumshirn --- drivers/scsi/lpfc/lpfc_nvmet.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/scsi/lpfc/lpfc_nvmet.c b/drivers/scsi/lpfc/lpfc_nvmet.c index 0b7c1a49e203..313d5c10e0ad 100644 --- a/drivers/scsi/lpfc/lpfc_nvmet.c +++ b/drivers/scsi/lpfc/lpfc_nvmet.c @@ -1457,6 +1457,7 @@ static struct lpfc_nvmet_ctxbuf * lpfc_nvmet_replenish_context(struct lpfc_hba *phba, struct lpfc_nvmet_ctx_info *current_infop) { +#if (IS_ENABLED(CONFIG_NVME_TARGET_FC)) struct lpfc_nvmet_ctxbuf *ctx_buf = NULL; struct lpfc_nvmet_ctx_info *get_infop; int i; @@ -1504,6 +1505,7 @@ lpfc_nvmet_replenish_context(struct lpfc_hba *phba, get_infop = get_infop->nvmet_ctx_next_cpu; } +#endif /* Nothing found, all contexts for the MRQ are in-flight */ return NULL; }