From patchwork Wed Oct 31 16:40:54 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Madhani, Himanshu" X-Patchwork-Id: 10662939 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id DB9FF1751 for ; Wed, 31 Oct 2018 16:49:33 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CD1D32B314 for ; Wed, 31 Oct 2018 16:49:33 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C13472B317; Wed, 31 Oct 2018 16:49:33 +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=-7.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI 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 B9BE62B314 for ; Wed, 31 Oct 2018 16:49:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729954AbeKABsT (ORCPT ); Wed, 31 Oct 2018 21:48:19 -0400 Received: from mail-eopbgr810082.outbound.protection.outlook.com ([40.107.81.82]:13502 "EHLO NAM01-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729938AbeKABsS (ORCPT ); Wed, 31 Oct 2018 21:48:18 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=+sZ7nW0aMobBuMdohzdHSMJrScO89TYCVp2fSxY+7+A=; b=Pt4jqqc7L7yf5CX1nHpt8V7XWgYFlzUbqdZh4bVwQcauaNxrLrXI3qe0r7Ubui23OwpygA1us1GK7aTYPgknvsAJh+AEJxADTFc5oneFUx4gW39F2Z/iX5ExxF+dsGm4KGxmyFMLIJhKepAekGwpcf9Xk8wztC2BbFY1lnZHOzQ= Received: from SN4PR0701CA0013.namprd07.prod.outlook.com (2603:10b6:803:28::23) by BY2PR0701MB2087.namprd07.prod.outlook.com (2a01:111:e400:5335::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1294.21; Wed, 31 Oct 2018 16:49:27 +0000 Received: from DM3NAM05FT007.eop-nam05.prod.protection.outlook.com (2a01:111:f400:7e51::201) by SN4PR0701CA0013.outlook.office365.com (2603:10b6:803:28::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1294.21 via Frontend Transport; Wed, 31 Oct 2018 16:49:26 +0000 Received-SPF: Pass (protection.outlook.com: domain of cavium.com designates 50.232.66.26 as permitted sender) receiver=protection.outlook.com; client-ip=50.232.66.26; helo=CAEXCH02.caveonetworks.com; Received: from CAEXCH02.caveonetworks.com (50.232.66.26) by DM3NAM05FT007.mail.protection.outlook.com (10.152.98.113) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA) id 15.20.1318.5 via Frontend Transport; Wed, 31 Oct 2018 16:49:25 +0000 Received: from dut1171.mv.qlogic.com (172.29.51.171) by CAEXCH02.caveonetworks.com (10.17.4.29) with Microsoft SMTP Server id 14.2.347.0; Wed, 31 Oct 2018 09:40:59 -0700 Received: from dut1171.mv.qlogic.com (localhost [127.0.0.1]) by dut1171.mv.qlogic.com (8.14.7/8.14.7) with ESMTP id w9VGf0I3006321; Wed, 31 Oct 2018 09:41:00 -0700 Received: (from root@localhost) by dut1171.mv.qlogic.com (8.14.7/8.14.7/Submit) id w9VGexHl006320; Wed, 31 Oct 2018 09:40:59 -0700 From: Himanshu Madhani To: , , , , , , CC: Subject: [PATCH v4 0/5] qla2xxx: Add FC-NVMe Target support Date: Wed, 31 Oct 2018 09:40:54 -0700 Message-ID: <20181031164059.6286-1-himanshu.madhani@cavium.com> X-Mailer: git-send-email 2.12.0 MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-Forefront-Antispam-Report: CIP:50.232.66.26;IPV:NLI;CTRY:US;EFV:NLI;SFV:NSPM;SFS:(10009020)(39860400002)(376002)(346002)(396003)(136003)(2980300002)(438002)(189003)(199004)(36756003)(14444005)(305945005)(126002)(476003)(486006)(44832011)(4326008)(107886003)(6666004)(356004)(69596002)(1076002)(2906002)(80596001)(87636003)(47776003)(16586007)(110136005)(106002)(42186006)(316002)(48376002)(86362001)(478600001)(72206003)(50466002)(2201001)(51416003)(336012)(106466001)(8676002)(50226002)(186003)(5660300001)(6346003)(81166006)(8936002)(2616005)(26005)(81156014);DIR:OUT;SFP:1101;SCL:1;SRVR:BY2PR0701MB2087;H:CAEXCH02.caveonetworks.com;FPR:;SPF:Pass;LANG:en;PTR:50-232-66-26-static.hfc.comcastbusiness.net;MX:1;A:1; X-Microsoft-Exchange-Diagnostics: 1;DM3NAM05FT007;1:de6zC2fN8xdcHDVfWDnrcEf8OsLyw+V/DltPMbURX8J9+vCcjOAdypVmYD0nKYGlms9Fing2y6HG+0A8qk49M00HJ0/Bhf9WaR3CF9INzqyrbxXv8S1aUUm8rEED/USB X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 6797e8dc-faa6-4618-e275-08d63f50d1a8 X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600074)(711020)(4608076)(2017052603328)(7153060);SRVR:BY2PR0701MB2087; X-Microsoft-Exchange-Diagnostics: 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Ys1XEBI/rrLl4y9ziiRtyjA1Ei67CYwvfT8E6sU4RxrCqCrdtqH140IceKA3NFRrxKYKXjSvY/RtoPN8u4bRC7zLSas1TWhFzEZVFeX1/hFpAgTvgSf7fqfnT27CRk/q9BYt8W7KXapKG5DREtek7wjLd2NrjamHdiFCZG0Dx6zfUr4a/qVK34im0pzBJ/FZg3gpLqr+a8MQT6SM+NjpXe89LOtKJgatpBQZo2NNhL69BNpvC6mu/YeeNUnOjRYfioVYH6Q89znMeOa4RcyuulUSPkSf4MOb9GJcXYNJAzYOIIPjj7xv9nBmg4GvuhupTHm9V5vo4So8mqS9xH8C1oOoM2m+4SPAwiS0Wv0zKNyWObZAPpe4a92O5bYJyIY2S33627ogzeQRBl380ADRd/FVies+Biyk1zNsuhe9QlrNHkC4y/9rUcgflk4HNpg6BFwuCxS2vQMclWiOtzLUqK/qN+B8RgsTlEl9ZSZ X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(10201501046)(3002001)(3231382)(944501410)(52105095)(93006095)(93004095)(148016)(149066)(150057)(6041310)(20161123562045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(20161123564045)(201708071742011)(7699051)(76991095);SRVR:BY2PR0701MB2087;BCL:0;PCL:0;RULEID:;SRVR:BY2PR0701MB2087; X-Microsoft-Exchange-Diagnostics: 1;BY2PR0701MB2087;4:vtAlkAL+iAPJj6kaM90c1N5XAAAajTA8O0IEEZzV8ojVNNopIvdZH45NUjcNSD/KHLjCiXc7BSXkLZgbqlPB8z8Ui0dhC+rFerqArxjcGsWIGx35Gw8NcH2mgSDpYH+ZYwVWm2Qql7D52BLpFXlUOtwQfKPN1Km56Ubq65qj6Z2DXtwcyN9IO9xJMOfHcomnJyx3saLoBLAYEsXc8AhnVsji7jR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CMjiJB+GhFnXtvBQFPA5vCWmpSkpzlTrTXh8opQWUAGf4+LjPuYfeahMT5dgkPY1asE8YdXmIuSjA1fASi71TbM7FXkjnH6bi/VFiAwCqH/RksjVaTFDXX+TcEtY9buDNKa2J2W4rn3WJ6V66b5ZcE4m5tuBOY=;7:ljp59JzJfuwo7C5n/ZHoPJYPH6OZE8iSidW4L4OG+WcDp6R3dfzffIyyYEm6ot7xJZ/bCDnLlAFw4TGkaJPde+91UhdyqJuEcOpka+ApWbrA9jC7ZQ5JyhxxBqFq08D7KfPHqdVqJBsxHxNzZQfYxQ== SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: cavium.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 31 Oct 2018 16:49:25.8974 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 6797e8dc-faa6-4618-e275-08d63f50d1a8 X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=711e4ccf-2e9b-4bcf-a551-4094005b6194;Ip=[50.232.66.26];Helo=[CAEXCH02.caveonetworks.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY2PR0701MB2087 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 Hi Martin, This series adds support for FC-NVMe Target. Patch #1 adds infrastructure to support FC-NVMeT Link Service processing. Patch #2 adds addes new qla_nvmet.[ch] files for FC-NVMe Target support. Patch #3 has bulk of changes to add hooks into common code infrastucture and adds support for FC-NVMe Target LS4 processing via Purex path. Patch #4 adds SysFS hook to enable NVMe Target for the port. Please apply them to 4.21/scsi-queue at your earliest convenience. Changes from v3 -> v4 o Rebased Series on current 4.20/scsi-queue o Removed NVMET_FCTGTFEAT_{CMD|OPDONE}_IN_ISR as per James Smart's review comment. Changes from v2 -> v3 o Reordered patches so that each patch compiles individually and is bisectable. Changes from v1 -> v2 o Addressed all comments from Bart. o Consolidated Patch 1 and Patch 2 into single patch. o Fixed smatch warning reported by kbuild autommation. o NVMe Target mode is exclusive at the moment. Cavium driver does not support both FCP Target and NVMe Target at the same time. This will be fixed in later updates. Thanks, Himanshu Anil Gurumurthy (4): qla2xxx_nvmet: Add FC-NVMe Target Link Service request handling qla2xxx_nvmet: Add files for FC-NVMe Target support qla2xxx_nvmet: Add FC-NVMe Target handling qla2xxx_nvmet: Add SysFS node for FC-NVMe Target Himanshu Madhani (1): qla2xxx: Update driver version to 11.00.00.00-k drivers/scsi/qla2xxx/Makefile | 3 +- drivers/scsi/qla2xxx/qla_attr.c | 33 ++ drivers/scsi/qla2xxx/qla_dbg.c | 1 + drivers/scsi/qla2xxx/qla_dbg.h | 2 + drivers/scsi/qla2xxx/qla_def.h | 35 +- drivers/scsi/qla2xxx/qla_fw.h | 263 ++++++++++ drivers/scsi/qla2xxx/qla_gbl.h | 24 +- drivers/scsi/qla2xxx/qla_gs.c | 16 +- drivers/scsi/qla2xxx/qla_init.c | 49 +- drivers/scsi/qla2xxx/qla_iocb.c | 8 +- drivers/scsi/qla2xxx/qla_isr.c | 112 ++++- drivers/scsi/qla2xxx/qla_mbx.c | 101 +++- drivers/scsi/qla2xxx/qla_nvme.h | 33 -- drivers/scsi/qla2xxx/qla_nvmet.c | 831 +++++++++++++++++++++++++++++++ drivers/scsi/qla2xxx/qla_nvmet.h | 129 +++++ drivers/scsi/qla2xxx/qla_os.c | 75 ++- drivers/scsi/qla2xxx/qla_target.c | 977 ++++++++++++++++++++++++++++++++++++- drivers/scsi/qla2xxx/qla_target.h | 90 ++++ drivers/scsi/qla2xxx/qla_version.h | 4 +- 19 files changed, 2711 insertions(+), 75 deletions(-) create mode 100644 drivers/scsi/qla2xxx/qla_nvmet.c create mode 100644 drivers/scsi/qla2xxx/qla_nvmet.h