Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp3392673pxf; Mon, 15 Mar 2021 08:35:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx1RQqwAw2huvQ2hs6MJqogoL0rI25fKhQSMUnm8Ufxj/tXS99ukW1QlAS1Fig5J51Jksmb X-Received: by 2002:a05:6402:d07:: with SMTP id eb7mr29846148edb.242.1615822544833; Mon, 15 Mar 2021 08:35:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1615822544; cv=none; d=google.com; s=arc-20160816; b=AF2aB5pbgQTgpX1w4X07zxyzCIor8fwFbSYeQWewSxKBjh+KKVlvDplc2mFQqANP+R IuUfEXbjEvCPuu3i8HftqoVlpup4vkLY4er7XH01lgsXTgKoJCGNrLuScI2yLhY7G6ty wOkq2g/hO7PKGxcgowP7jABw23J+Kv04v1IyOF4QMTt2PPqfPwBKQAzNLIqk2WhKeja8 ag3fjyLAyGojRd8NXptFktYdWNTnhQdKkLGN0wk83xB8z0h4FOntg70l5kQ/BQ2665CU 5wSN2vtzcNWjpbpVeuu1hLeG7iYxH8/jliwQYqqh+bTetGpqd02ZC6SZqTN4FtNrKJOb n3/w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=gYbVLatmMXxxm3XlETOvCj+hkAugf9rbLUg+H5BCo3U=; b=aSlLfTDAs7DjxsNw26XoXIvuQKonie62hgKJRu1dwXxLpY181cOk4up+Rf4TYSbU8p d7VnjN+wL5yb2Gf/HW8VA2OSAHKEUj6GwD1prbi3wsd+A5B1wq2VplG1CbzTIbfXw1bB sFuDYKvR1tTdg/Y5kCqT9jBsBwYpZAyjmPHWlqIHnvd68n5k3tsGp+NSnq5eGzI/a9g/ /GDPysx5j30b6ePh1dsU6g5JZFgXoGfZorqlNaJRRUpMClod86AutUiBul5J2Vseb7VX W8Ojx5WWMr1+jz0ybu1YSx8qCtknCmMxhoep59op7MQTKRv55Kam1XtFm5I+eh3F866d ea0w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=MF4CRoTe; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id jo5si12010982ejb.644.2021.03.15.08.35.21; Mon, 15 Mar 2021 08:35:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=MF4CRoTe; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231894AbhCOPe1 (ORCPT + 99 others); Mon, 15 Mar 2021 11:34:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36826 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231142AbhCOPeW (ORCPT ); Mon, 15 Mar 2021 11:34:22 -0400 Received: from mail-pl1-x62b.google.com (mail-pl1-x62b.google.com [IPv6:2607:f8b0:4864:20::62b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AEF57C06174A; Mon, 15 Mar 2021 08:34:22 -0700 (PDT) Received: by mail-pl1-x62b.google.com with SMTP id d23so12278587plq.2; Mon, 15 Mar 2021 08:34:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to; bh=gYbVLatmMXxxm3XlETOvCj+hkAugf9rbLUg+H5BCo3U=; b=MF4CRoTe3dDmLPYiOBeMZOx1Sy5eseHTJvatZ+mZ+uFDf4Z5/yso9pMRYDVseq7TDP HKzs4D03mAVFFByBMuLtF5t/nLqdWWfsZ1hTd5NdM6x43L12LrpIIHbTMol9b4pZVHip zUI3D+FaKjgzZzQEhrIwqw1jo/2CZIqv6JSTXY3sCb7SAY2MgFbRT0CfT1UlkUWKufzF 3b3MOFym590Mgu91nwWLRVORE/ffCWZ93hD/5tyej1Ckh0rw7kFjSCmvHXseVD471g7R BYjVoOUql4vGxU63yczfxdOLy8YQ6t+/KRm5DLaQuMisPOTCeYoMVal1KGC/NfCNsceK BDXg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to; bh=gYbVLatmMXxxm3XlETOvCj+hkAugf9rbLUg+H5BCo3U=; b=QxyzGgBrVsQmuIlq7wOFDOPChzKr0Q/n4k8EAHxfnoA0pE1zg/nu9mEMeAMiBLLoMz +XEb2e9vywACoE0zvrl452WlU/YQC9ye1mD98g8OrQytr3ZFOqynQjBjD0ultZgPtzNH VCafjEhHMO3Lj48UOFKNH8lEiE3vCi3AXh4IwbGVgMHiNYnt+jP2LSTNCzqcwTmpo/sY xHai1oRtKDVgXiVC2aHiS8Ybcw3EKkJ1YC7EP0EBvJRdBbvk7pS4eMVcPet1am+tr3VG HF9xLgbQhMzVUyiYABXdozVVbsu3erme8ISiof9a7h09SD4L1DWOMIYhhgOhuU3S3v/L LX3g== X-Gm-Message-State: AOAM532P/u1XXTOaLG6PucYJEChjC01pxgvFQBM+pef2zBewUBI+Yt3X wHqncM9Ojf7rmx+2CDM6+fk= X-Received: by 2002:a17:902:d893:b029:e6:7a98:6919 with SMTP id b19-20020a170902d893b02900e67a986919mr12138229plz.58.1615822462251; Mon, 15 Mar 2021 08:34:22 -0700 (PDT) Received: from localhost ([103.248.31.158]) by smtp.gmail.com with ESMTPSA id a20sm14731673pfl.97.2021.03.15.08.34.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 15 Mar 2021 08:34:21 -0700 (PDT) Date: Mon, 15 Mar 2021 21:03:41 +0530 From: Amey Narkhede To: Leon Romanovsky Cc: alex.williamson@redhat.com, linux-pci@vger.kernel.org, bhelgaas@google.com, raphael.norwitz@nutanix.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH 4/4] PCI/sysfs: Allow userspace to query and set device reset mechanism Message-ID: <20210315153341.miip637z35mwv7fv@archlinux> References: <20210312173452.3855-1-ameynarkhede03@gmail.com> <20210312173452.3855-5-ameynarkhede03@gmail.com> <20210314235545.girtrazsdxtrqo2q@pali> <20210315134323.llz2o7yhezwgealp@archlinux> <20210315135226.avwmnhkfsgof6ihw@pali> <20210315083409.08b1359b@x1.home.shazbot.org> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 21/03/15 05:07PM, Leon Romanovsky wrote: > On Mon, Mar 15, 2021 at 08:34:09AM -0600, Alex Williamson wrote: > > On Mon, 15 Mar 2021 14:52:26 +0100 > > Pali Roh?r wrote: > > > > > On Monday 15 March 2021 19:13:23 Amey Narkhede wrote: > > > > slot reset (pci_dev_reset_slot_function) and secondary bus > > > > reset(pci_parent_bus_reset) which I think are hot reset and > > > > warm reset respectively. > > > > > > No. PCI secondary bus reset = PCIe Hot Reset. Slot reset is just another > > > type of reset, which is currently implemented only for PCIe hot plug > > > bridges and for PowerPC PowerNV platform and it just call PCI secondary > > > bus reset with some other hook. PCIe Warm Reset does not have API in > > > kernel and therefore drivers do not export this type of reset via any > > > kernel function (yet). > > > > Warm reset is beyond the scope of this series, but could be implemented > > in a compatible way to fit within the pci_reset_fn_methods[] array > > defined here. Note that with this series the resets available through > > pci_reset_function() and the per device reset attribute is sysfs remain > > exactly the same as they are currently. The bus and slot reset > > methods used here are limited to devices where only a single function is > > affected by the reset, therefore it is not like the patch you proposed > > which performed a reset irrespective of the downstream devices. This > > series only enables selection of the existing methods. Thanks, > > Alex, > > I asked the patch author here [1], but didn't get any response, maybe > you can answer me. What is the use case scenario for this functionality? > > Thanks > > [1] https://lore.kernel.org/lkml/YE389lAqjJSeTolM@unreal > Sorry for not responding immediately. There were some buggy wifi cards which needed FLR explicitly not sure if that behavior is fixed in drivers. Also there is use a case at Nutanix but the engineer who is involved is on PTO that is why I did not respond immediately as I don't know the details yet. Thanks, Amey