Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp1110102pxx; Tue, 27 Oct 2020 08:28:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJylesJ3iO+X8kVyZSVqZlOadbWM8pBxySMDFX+xN1/lbiFUCqRwE1FNWUsZFYgKa95ugErI X-Received: by 2002:a17:906:e24a:: with SMTP id gq10mr2880749ejb.552.1603812493483; Tue, 27 Oct 2020 08:28:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603812493; cv=none; d=google.com; s=arc-20160816; b=A/MlVCg2lsMSJTIJlfdmBkXq+OVPRfpWsLfVWAb0/5jVnFov3CB33BOPdlooZlG6Sm TtLO+0VWubPc3P+pggXzifJQTY1UQaArYZ3hqEn4JkbiyIUmS315BV1rvEWGDIOF4kpB pYNjdWtRxNiLSCMR09+hgcZzwzUF1nxv8olqAAoG0wokRlt4MEmaIEULM6yHNLORNl05 8lklv2fZi0H3ReNF3no7S2whYgN1umOVH0Qi0UDmEtGRWaXarNSfIBx3z1gaLca63s9b XI3JcBVuKM8T4n+8qLURSDQ+N1vtHTZCg8v3mlc9dGFqkwc7yjoML1oiUWwyIuERntum PZQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:references :in-reply-to:subject:cc:to:dkim-signature:dkim-signature:from; bh=WHVWY8Pt2cBEbxM1Jxi63g2Hj3JS0/EEW2zyuVGEPSs=; b=lKTPcNM2/g+M3mxwpDrzqYIyOItzCdEFCKaJ6FVptPqOQP4S/awXUzb8u7d2GtWKw1 HAZlgyZHL/ci93P6X5Jp5SCm10cfHH1qyzfwpmupi4qTGpzYbCkypLhHGzE0Y01dxk+f jCeFWURVvNWL5LqWc0TvwGnnqQ6i3x6WvyupYYDoB3C3pifKmT0K8huZc1RwaTp0eZOu 2VzPU59xmb51h+8hN4hnhtWOr3fSY4dZ2BQR7kuE8LA3BmZlYtm0ehKYwsjDSFtss/oQ HrbLCtflum8b0tb48almOU3j4EY3rueVuq//rd93xrY+r6bzSeDrWAIio+GWclOKG62L 44VQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=2GQa6Ul8; dkim=neutral (no key) header.i=@linutronix.de header.b=iI4zzfmX; 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=linutronix.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id o17si1132014ejg.671.2020.10.27.08.27.51; Tue, 27 Oct 2020 08:28:13 -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=@linutronix.de header.s=2020 header.b=2GQa6Ul8; dkim=neutral (no key) header.i=@linutronix.de header.b=iI4zzfmX; 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=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2897627AbgJ0Ocw (ORCPT + 99 others); Tue, 27 Oct 2020 10:32:52 -0400 Received: from Galois.linutronix.de ([193.142.43.55]:47278 "EHLO galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759197AbgJ0O2S (ORCPT ); Tue, 27 Oct 2020 10:28:18 -0400 From: Thomas Gleixner DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1603808897; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=WHVWY8Pt2cBEbxM1Jxi63g2Hj3JS0/EEW2zyuVGEPSs=; b=2GQa6Ul8aOkAo3AXsA0aVITxroDZkL4AtCNdgNI3SDHsv3F+SU+7ED8PqGdbAeRfy0O4TB icKZgLCvuhTR1kJhp3uq+KN+rs4RZzZQK7odWgDfiXaSUfApcsaWUkjSb7TZbo1M0cF8Ys Ilcw/2OVZ4JEar/I/4TgEHp0ss+xXlb5kZcx2dZtVHI3WmN9kpwf10tXqdk4+lTtprnWUL rIX41oWtJ5VehAeaG/J+tjCqxsEdrZIip7AsZUAUd8upg+lfYoD61K8xt1A4hEOq0c51ET IqQ2a0jkuDj9QRkf8VK5YQABRVEB4rlGLAk8h9l8jbR5vJXlX+tBNT9AgUzSLw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1603808897; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=WHVWY8Pt2cBEbxM1Jxi63g2Hj3JS0/EEW2zyuVGEPSs=; b=iI4zzfmXqaQk8wTIlKzcoy2w3B7FkOtnUj2WNnQBCUCsHicUw1/TWMW/wUuiUSu0omFieQ T9rGsHQGnc8YCiBQ== To: Jacob Keller , Nitesh Narayan Lal , Marcelo Tosatti Cc: Peter Zijlstra , helgaas@kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, linux-pci@vger.kernel.org, intel-wired-lan@lists.osuosl.org, frederic@kernel.org, sassmann@redhat.com, jesse.brandeburg@intel.com, lihong.yang@intel.com, jeffrey.t.kirsher@intel.com, jlelli@redhat.com, hch@infradead.org, bhelgaas@google.com, mike.marciniszyn@intel.com, dennis.dalessandro@intel.com, thomas.lendacky@amd.com, jiri@nvidia.com, mingo@redhat.com, juri.lelli@redhat.com, vincent.guittot@linaro.org, lgoncalv@redhat.com, Jakub Kicinski Subject: Re: [PATCH v4 4/4] PCI: Limit pci_alloc_irq_vectors() to housekeeping CPUs In-Reply-To: <586e249a-1078-9fe9-22d4-b3c1ec0a3a5e@intel.com> References: <20201019111137.GL2628@hirez.programming.kicks-ass.net> <20201019140005.GB17287@fuller.cnet> <20201020073055.GY2611@hirez.programming.kicks-ass.net> <078e659e-d151-5bc2-a7dd-fe0070267cb3@redhat.com> <20201020134128.GT2628@hirez.programming.kicks-ass.net> <6736e643-d4ae-9919-9ae1-a73d5f31463e@redhat.com> <260f4191-5b9f-6dc1-9f11-085533ac4f55@redhat.com> <20201023085826.GP2611@hirez.programming.kicks-ass.net> <9ee77056-ef02-8696-5b96-46007e35ab00@redhat.com> <87ft6464jf.fsf@nanos.tec.linutronix.de> <20201026173012.GA377978@fuller.cnet> <875z6w4xt4.fsf@nanos.tec.linutronix.de> <86f8f667-bda6-59c4-91b7-6ba2ef55e3db@intel.com> <87v9ew3fzd.fsf@nanos.tec.linutronix.de> <85b5f53e-5be2-beea-269a-f70029bea298@intel.com> <87lffs3bd6.fsf@nanos.tec.linutronix.de> <959997ee-f393-bab0-45c0-4144c37b9185@redhat.com> <875z6w38n4.fsf@nanos.tec.linutronix.de> <586e249a-1078-9fe9-22d4-b3c1ec0a3a5e@intel.com> Date: Tue, 27 Oct 2020 15:28:16 +0100 Message-ID: <87mu07216n.fsf@nanos.tec.linutronix.de> MIME-Version: 1.0 Content-Type: text/plain Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Oct 26 2020 at 16:08, Jacob Keller wrote: > On 10/26/2020 3:49 PM, Thomas Gleixner wrote: >> On Mon, Oct 26 2020 at 18:22, Nitesh Narayan Lal wrote: >>> I don't think there is currently a way to control the enablement/disablement of >>> interrupts from the userspace. >> >> You cannot just disable the interrupt. You need to make sure that the >> associated queue is shutdown or quiesced _before_ the interrupt is shut >> down. > > Could this be handled with a callback to the driver/hw? I know Intel HW > should support this type of quiesce/shutdown. We can't have a callback from the interrupt shutdown code as you have to wait for the queue to drain packets in flight. Something like this mark queue as going down (no more tx queueing) tell hardware not to route RX packets to it consume pending RX wait for already queued TX packets to be sent Look what the block people did. They have a common multi-instance hotplug state and they register each context (queue) as an instance. The hotplug core invokes the corresponding callbacks when bringing a CPU up or when shutting it down. Thanks, tglx