From patchwork Tue Nov 14 22:31:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Karan Tilak Kumar (kartilak)" X-Patchwork-Id: 165108 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:6358:a59:b0:164:83eb:24d7 with SMTP id 25csp2243064rwb; Tue, 14 Nov 2023 14:32:07 -0800 (PST) X-Google-Smtp-Source: AGHT+IGsQGg11DBcUP7xM9aLDARF3U8MjPjwvqQtPT7m/ew75mZ8H2HSDDyXX7UfkfEnejv6DYfE X-Received: by 2002:a17:902:dace:b0:1bb:6875:5a73 with SMTP id q14-20020a170902dace00b001bb68755a73mr4370412plx.2.1700001127257; Tue, 14 Nov 2023 14:32:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700001127; cv=none; d=google.com; s=arc-20160816; b=uvbTj9cARPzdOpANB7SmEPQvpRmtlS0LtYQJa6+2CYLIS75Jv6GY3QUT8V6mswOO/D Hr11Feg+000GPdp6aQG/l7P0g7Zz5755S6Anxm9CKhEPhH8Z50rEPEdZPGi8MAiujYzL uwvzhiIQlHOxNFcGaVnhQZXJVByu0fmrGLaChKuixHOc+0EdLUkVKYLQO9wR1x67+hyH cjXf6xspVY9veVVpJ4TLdQqSY37i1qKiopzOVOFlA4mf9amcso/m3w0dPYbW1bnIx6tj dJGz8LwZuJLofHsABFn4poc2Bg2NlIct94uD4j452Ek3JUtzNOTAWpxsyWV9wp9W9+H3 LOZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=vKMcJbVI16nKTuw5jMpXehmO07rhNZFlAtgMRWXtmPU=; fh=cjiSjcSDv/XIT1wsutvtplR3SRaqRNwT1M35P++mOs8=; b=s4RlLVjqpA1aFrQEv5GSWJ9t47S+UdT7Bqp4NEmxzPCFHO8tVDZXIgSdOYmXcUm2Zf 8hF5w1wmlLYeQ0Wsblggf7ebI6IyTlapPty0N3gqMdt8yuAC/eCAGFsIAygQwJZ324Gz fTianyju9fGZBk+cEclVPB50Q5E0DH67SMjqqFT6RY/UbEy/25VE2PZeWUEbVB9mNNwd mS+8jARMFgQUSYSYz+S63kqgVj9ujtm/STrUrnuG7hRgvNwGTKoHZcbcwTqN9GRHX5Lc sUfMlnOsIm+/glyMrE4Si78fNj2l5p1ajUENIVba6+VCkH0JzCHJnzGHXNNvJymDzGij UyuA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cisco.com header.s=iport header.b=VUqDF1Qy; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=cisco.com Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id c10-20020a170903234a00b001cc4107a515si9396442plh.48.2023.11.14.14.32.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Nov 2023 14:32:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@cisco.com header.s=iport header.b=VUqDF1Qy; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=cisco.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 55D5280D44C5; Tue, 14 Nov 2023 14:32:06 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234127AbjKNWcD (ORCPT + 29 others); Tue, 14 Nov 2023 17:32:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58582 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234112AbjKNWcC (ORCPT ); Tue, 14 Nov 2023 17:32:02 -0500 Received: from rcdn-iport-9.cisco.com (rcdn-iport-9.cisco.com [173.37.86.80]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 521A3DB; Tue, 14 Nov 2023 14:31:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=@cisco.com; l=1974; q=dns/txt; s=iport; t=1700001119; x=1701210719; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=cAUkkq9AKnGLq+kxdOrbr7ZaaBIeDQKT3XyG1iC0jTE=; b=VUqDF1Qya1TuDsYY99g39wFvuByvpcAkCy/fLWiH2yBFcbjEzjtjtj4P /AC4x6dv/lghTr9CqMAMABFnwT8wCB3oBncyHCRdDW2vo/MF5YjLv6y5E nPFo2TmUkYl3ic5pg1SllOTuQslWbj96GnyriQYMfRlSCvZ/bl5nraWSI w=; X-CSE-ConnectionGUID: bl05Q2I6TGuhFkNknoN57A== X-CSE-MsgGUID: I2u/PwrmSIOqOwXZZSPlXQ== X-IronPort-AV: E=Sophos;i="6.03,303,1694736000"; d="scan'208";a="138077491" Received: from rcdn-core-12.cisco.com ([173.37.93.148]) by rcdn-iport-9.cisco.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Nov 2023 22:31:58 +0000 Received: from localhost.cisco.com ([10.193.101.253]) (authenticated bits=0) by rcdn-core-12.cisco.com (8.15.2/8.15.2) with ESMTPSA id 3AEMVh1Z001762 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 14 Nov 2023 22:31:57 GMT From: Karan Tilak Kumar To: sebaddel@cisco.com Cc: arulponn@cisco.com, djhawar@cisco.com, gcboffa@cisco.com, mkai2@cisco.com, satishkh@cisco.com, jejb@linux.ibm.com, martin.petersen@oracle.com, linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, Karan Tilak Kumar , Hannes Reinecke Subject: [PATCH v3 01/13] scsi: fnic: Modify definitions to sync with VIC firmware Date: Tue, 14 Nov 2023 14:31:41 -0800 Message-Id: <20231114223141.633658-1-kartilak@cisco.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 X-Authenticated-User: kartilak@cisco.com X-Outbound-SMTP-Client: 10.193.101.253, [10.193.101.253] X-Outbound-Node: rcdn-core-12.cisco.com X-Spam-Status: No, score=-9.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIMWL_WL_MED,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL, SPF_HELO_PASS,SPF_NONE,T_SCC_BODY_TEXT_LINE,USER_IN_DEF_DKIM_WL autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Tue, 14 Nov 2023 14:32:06 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1782580381697093252 X-GMAIL-MSGID: 1782580381697093252 VIC firmware has updated definitions. Modify structure and definitions to sync with the latest VIC firmware. Reviewed-by: Sesidhar Baddela Reviewed-by: Arulprabhu Ponnusamy Reviewed-by: Hannes Reinecke Signed-off-by: Karan Tilak Kumar --- drivers/scsi/fnic/vnic_scsi.h | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/fnic/vnic_scsi.h b/drivers/scsi/fnic/vnic_scsi.h index 4e12f7b32d9d..f715f7942bfe 100644 --- a/drivers/scsi/fnic/vnic_scsi.h +++ b/drivers/scsi/fnic/vnic_scsi.h @@ -26,7 +26,7 @@ #define VNIC_FNIC_RATOV_MAX 255000 #define VNIC_FNIC_MAXDATAFIELDSIZE_MIN 256 -#define VNIC_FNIC_MAXDATAFIELDSIZE_MAX 2112 +#define VNIC_FNIC_MAXDATAFIELDSIZE_MAX 2048 #define VNIC_FNIC_FLOGI_RETRIES_MIN 0 #define VNIC_FNIC_FLOGI_RETRIES_MAX 0xffffffff @@ -55,7 +55,7 @@ #define VNIC_FNIC_PORT_DOWN_IO_RETRIES_MAX 255 #define VNIC_FNIC_LUNS_PER_TARGET_MIN 1 -#define VNIC_FNIC_LUNS_PER_TARGET_MAX 1024 +#define VNIC_FNIC_LUNS_PER_TARGET_MAX 4096 /* Device-specific region: scsi configuration */ struct vnic_fc_config { @@ -79,10 +79,19 @@ struct vnic_fc_config { u16 ra_tov; u16 intr_timer; u8 intr_timer_type; + u8 intr_mode; + u8 lun_queue_depth; + u8 io_timeout_retry; + u16 wq_copy_count; }; #define VFCF_FCP_SEQ_LVL_ERR 0x1 /* Enable FCP-2 Error Recovery */ #define VFCF_PERBI 0x2 /* persistent binding info available */ #define VFCF_FIP_CAPABLE 0x4 /* firmware can handle FIP */ +#define VFCF_FC_INITIATOR 0x20 /* FC Initiator Mode */ +#define VFCF_FC_TARGET 0x40 /* FC Target Mode */ +#define VFCF_FC_NVME_INITIATOR 0x80 /* FC-NVMe Initiator Mode */ +#define VFCF_FC_NVME_TARGET 0x100 /* FC-NVMe Target Mode */ + #endif /* _VNIC_SCSI_H_ */