Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp3918374rwi; Sat, 22 Oct 2022 02:11:24 -0700 (PDT) X-Google-Smtp-Source: AMsMyM42HdlwjPwGMLdzisqIaM4gSqnnwlwrhai1a3W+RlwVAgUyR4fBAeIXWeGhVMsitZf3X7J4 X-Received: by 2002:a17:90a:5e04:b0:20b:1f20:5069 with SMTP id w4-20020a17090a5e0400b0020b1f205069mr60826115pjf.126.1666429873152; Sat, 22 Oct 2022 02:11:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666429873; cv=none; d=google.com; s=arc-20160816; b=vGjUchhs9laj8bemr1mkQzzFv7u8g5Axmd8sozgbtoHCUuUsNuvHZY6RPBzfXabXhQ BG8Pw7TEz7EXaVSLJAAzILpcyvY1FNAjc2qyOCCD/54Dhg/ADSiIwDcE9X3VOsYcgaky gOCzl8DzWISw1Vm5ZiNE6lim1K2o2lXGKhnoyzLRvUZ+YKQJGj7PUXOXs7o+Aq+RiHHh VkohBSWYCL9FmVlaorAz7iBKsyppGUL/Md8pTdCipez12XS8W1rpuG9D74wlXAQdzRML oavhUIg/fS/6lhocEOsLbfCslVJq0P/Gzu+kl3WXdIFZbQsbelZxFxc6nbL+2bnFAJ05 RPHw== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=1unh5gNOM//0lURzWdG+dqOhsOfQoCT5wRTk73W49Es=; b=ijtKDuxVEia5DS5sFXyeNnwbVAQg5og0FO5HvOKSW39ixdqB8IDIqGDDuySdetqqlQ iEAQFQ7dM/ozcNtRT+JWpS1oSOIjvEJQCLPUl5zVqKv8LuNS3KP7RNhp8UID/npx5Ms2 vNB9fjCMpR/GLzzqELbOi6TbfKoyHuBb0bmHaLSj4MVmFVGOtN3c2r+Igb4wg2YR/CRF S5uU8wVGQVi4NVUul6U/8jG4a9mtl/kd69zWiwcEI1mK/cvaxtUL99kCc8pLuf7+9s+D /38RQrJ4BSMEK8fMLajm6o8DDkTUWGIqfzB07eragXz8sj1fq9dEL+5rbLK0P20KQ66v MTFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=GMsJVDNu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f1-20020a637541000000b0045a2b6e23b6si28898561pgn.290.2022.10.22.02.11.00; Sat, 22 Oct 2022 02:11:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=GMsJVDNu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231236AbiJVHmF (ORCPT + 99 others); Sat, 22 Oct 2022 03:42:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46264 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231228AbiJVHlo (ORCPT ); Sat, 22 Oct 2022 03:41:44 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9858A31EE9; Sat, 22 Oct 2022 00:39:40 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 4E58BB82DF9; Sat, 22 Oct 2022 07:38:45 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id BA311C433D6; Sat, 22 Oct 2022 07:38:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666424324; bh=5dmX0BxH8ERt9C6w6xHEfRy2uRICDLXXIjsgURNzIo4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=GMsJVDNuQGkLxooE2l/mKD0S4lI4bx6cmqDCXDufqpfTXArvC42RSbXUATVRoUOHq gkB3HWdOlw946emZYg+hzWjyZYULu2+6FefRxp/4/lYFnHczwtjoN5WC5OiTKPfkQI gqH7iLjDEH/MPLOIqKXAxKRipo6IIfofMZRFU/K4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Guangwu Zhang , John Meneghini , Saurav Kashyap , Nilesh Javali , "Martin K. Petersen" Subject: [PATCH 5.19 096/717] scsi: qedf: Populate sysfs attributes for vport Date: Sat, 22 Oct 2022 09:19:35 +0200 Message-Id: <20221022072432.361102673@linuxfoundation.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221022072415.034382448@linuxfoundation.org> References: <20221022072415.034382448@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS 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 From: Saurav Kashyap commit 592642e6b11e620e4b43189f8072752429fc8dc3 upstream. Few vport parameters were displayed by systool as 'Unknown' or 'NULL'. Copy speed, supported_speed, frame_size and update port_type for NPIV port. Link: https://lore.kernel.org/r/20220919134434.3513-1-njavali@marvell.com Cc: stable@vger.kernel.org Tested-by: Guangwu Zhang Reviewed-by: John Meneghini Signed-off-by: Saurav Kashyap Signed-off-by: Nilesh Javali Signed-off-by: Martin K. Petersen Signed-off-by: Greg Kroah-Hartman --- drivers/scsi/qedf/qedf_main.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) --- a/drivers/scsi/qedf/qedf_main.c +++ b/drivers/scsi/qedf/qedf_main.c @@ -1921,6 +1921,27 @@ static int qedf_vport_create(struct fc_v fc_vport_setlink(vn_port); } + /* Set symbolic node name */ + if (base_qedf->pdev->device == QL45xxx) + snprintf(fc_host_symbolic_name(vn_port->host), 256, + "Marvell FastLinQ 45xxx FCoE v%s", QEDF_VERSION); + + if (base_qedf->pdev->device == QL41xxx) + snprintf(fc_host_symbolic_name(vn_port->host), 256, + "Marvell FastLinQ 41xxx FCoE v%s", QEDF_VERSION); + + /* Set supported speed */ + fc_host_supported_speeds(vn_port->host) = n_port->link_supported_speeds; + + /* Set speed */ + vn_port->link_speed = n_port->link_speed; + + /* Set port type */ + fc_host_port_type(vn_port->host) = FC_PORTTYPE_NPIV; + + /* Set maxframe size */ + fc_host_maxframe_size(vn_port->host) = n_port->mfs; + QEDF_INFO(&(base_qedf->dbg_ctx), QEDF_LOG_NPIV, "vn_port=%p.\n", vn_port);