Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp3294477ybi; Tue, 2 Jul 2019 05:30:59 -0700 (PDT) X-Google-Smtp-Source: APXvYqzbBrhiUjv1ZIXOgvI05RGTx/RtlsacqaNGwcXnqrJHzV15mTNUEN90amOsmKMtUuNXXBzJ X-Received: by 2002:a17:90a:5806:: with SMTP id h6mr5212860pji.126.1562070659115; Tue, 02 Jul 2019 05:30:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562070659; cv=none; d=google.com; s=arc-20160816; b=vuQ4JxY4V/V4GX5XK1ouEgeafo4CgCQzHI3jnDCcuJdbQBagAlzyMhV9yYPY1wYniB E2rHaV9G6phuZjdPqKSBI32Zsve/3UgwYj5107mmMOvhpHgP9dqqBkMGIMznJreXeYcs H2vXLCaserrBLyrDVew3UgJ0UVttKVOCcVPZsPtcbVnKtVfF8N67IZkKL46h4Z+Qaxuo SADNC6rM006k+gjtMaDgEDhkUAtYhTIPs8HNK7JI7UuymvsgQrbSzW4WuhLSORLXYfvl jHfLKWFL5YmxHyTVMlMuYINIsYfs+fF6d8YQ2KGavn9rmdUOn1HVMYZeW42DSM5GtP8/ xCMw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=I9SeLB4Esv/VGpF2gaL5uBZcY5ygHirhoF1dyk4QpfY=; b=wv7ree+CLacODE92jfqDk7NJ8jbrL1vuSdHtT6WbFWKxxkYKSgWpZ1WUDy/wxoN+Nu WGeHQB5Bam7nWJ1EOgLf6g9a/q2gY5KUm3SVC5AdqPk0Vp2DQiYyL2Z7JZmXMqOmbAdS xcSlLhTeLRYcbxt3jgnwlzCzQgUSPtsyNR8++Joy+yQrWbILVwOh9TULg3uzVcljsR0F yNj3jM+kxNMGQPS0bfwJMy5Q7rRTJnzZZhmDSUZvQUGilqz0N13zOh4rkDMEdNAt5keP 332vJEW9baHd4PJqIUWoba2X4TdcjoyF/PMfmvZMSyqDPEhVzFiZZTPd1BT7SyOVyTPz lhGw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 18si12499083pgw.101.2019.07.02.05.30.44; Tue, 02 Jul 2019 05:30:59 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726930AbfGBM2h (ORCPT + 99 others); Tue, 2 Jul 2019 08:28:37 -0400 Received: from bmailout3.hostsharing.net ([176.9.242.62]:47591 "EHLO bmailout3.hostsharing.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725922AbfGBM2g (ORCPT ); Tue, 2 Jul 2019 08:28:36 -0400 X-Greylist: delayed 436 seconds by postgrey-1.27 at vger.kernel.org; Tue, 02 Jul 2019 08:28:35 EDT Received: from h08.hostsharing.net (h08.hostsharing.net [83.223.95.28]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.hostsharing.net", Issuer "COMODO RSA Domain Validation Secure Server CA" (not verified)) by bmailout3.hostsharing.net (Postfix) with ESMTPS id 787F8100D9405; Tue, 2 Jul 2019 14:21:18 +0200 (CEST) Received: by h08.hostsharing.net (Postfix, from userid 100393) id E20E6132E3E; Tue, 2 Jul 2019 14:21:17 +0200 (CEST) Date: Tue, 2 Jul 2019 14:21:17 +0200 From: Lukas Wunner To: linmiaohe Cc: "bhelgaas@google.com" , "andy.shevchenko@gmail.com" , "rafael.j.wysocki@intel.com" , "linux-pci@vger.kernel.org" , "linux-kernel@vger.kernel.org" , Mingfangsen Subject: Re: A question about shpcp. Message-ID: <20190702122117.vl2opo55zpsykjf6@wunner.de> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jun 27, 2019 at 12:16:18PM +0000, linmiaohe wrote: > In qemu+shpcp+pcie scene, hotplug a network card(virtio) would take more > than 5 seconds. It's because 5 seconds delayed_work in func > handle_button_press_event with case STATIC_STATE. And this will break some > protocols with timeout within 5 seconds. > It's very nice of you if you could tell me why is 5*HZ there and if this > delay can be reduced? According to Table 2-4 of the PCI Standard Hot-Plug Controller and Subsystem Specification, "System software is waiting 5 seconds to provide the user with an opportunity to cancel the hot-plug operation." (http://drydkim.com/MyDocuments/PCI%20Spec/specifications/shpc1_0.pdf) So the reason the delay can't be reduced or removed is because the spec mandates it. Thanks, Lukas