Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp2244999imm; Tue, 10 Jul 2018 16:20:48 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcz10o1fwumMq9upsQBDmRhFD6HgnFzu1daqS+L3hoJ6Tjk2YBre1HozItkA0X188CXeHr/ X-Received: by 2002:a17:902:d710:: with SMTP id w16-v6mr6472193ply.93.1531264848408; Tue, 10 Jul 2018 16:20:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531264848; cv=none; d=google.com; s=arc-20160816; b=trLId+RyySGSmeglbhS+iHJqxhpmdEU8DHStSdDJWuAf1R+ZMp4JkdNpn6awGChy/u ZNrH8U8PI8kaP+kM7lxUe9L665J7xsOZU0OvXq2jmUQd64GpuFerfUhhvWdMaalmTyjt fovZNGO9+Pu0GFxW+ElEvHW35tOGB2Gm5T3mmCoUKVdWGNFtbABY6gq9MFq5W8j4dRXy ADtHhaRmtFU1YV+TY/JTx4A+Uw9P4lbufI+bdpmoMdmyBJ+S5oUm2cmsT/tou0k7kaY/ 9qBqHto/5yv5Pb4qVjxGAXs1AW62S2nfX81E8O5sMqih3RxrTa3ovAQghOoAKKQJ7U82 upRQ== 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:dkim-signature:arc-authentication-results; bh=tonVP21nyRnanMdkXxVcpDB4IuJB2v4l3xw+zQmU/BI=; b=kBhX5DXjvbuZNoNPGoR549hwEC6bT1aMQLFi1oWXi+qG8tZwpH/8HyX4p/rlC2gj3c 8QViYwCRDza9x/J0XSXtguqW3wjKGTQnWBg6KePjRa4i70GpJ6Uvcd9xpn/OHkkp0rAw 1yseQ898g+GyQytWViEgR+weI7om7gsgmb5iyfav5GjFN540L3ZvI1wsXbwCcGNyQl4o FePUShML8NzkRgBgu7EaHzQETLMNySlRkxx0q2WfHRJUQPSG3k0wHqiUjffUWZQSgtOv DFwrlfjMgj8n6Mu1hlmhTzc3VESRpdB8gg6/jvBDVlKsGarGZ4ojBQgJ9WLAcgoyuDhD Qaag== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=XThm3uT5; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h65-v6si18932724pfg.197.2018.07.10.16.20.32; Tue, 10 Jul 2018 16:20:48 -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; dkim=pass header.i=@kernel.org header.s=default header.b=XThm3uT5; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732383AbeGJXVU (ORCPT + 99 others); Tue, 10 Jul 2018 19:21:20 -0400 Received: from mail.kernel.org ([198.145.29.99]:41606 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732291AbeGJXVT (ORCPT ); Tue, 10 Jul 2018 19:21:19 -0400 Received: from localhost (unknown [69.71.4.100]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id F3582208E3; Tue, 10 Jul 2018 23:19:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1531264798; bh=hDSOXMk/BJkfcShvgrNo1DmIU2HAnzmH3JNPJTrUxN0=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=XThm3uT5yVFWz+yzZQh3CHRPK3nu6UcToSobgcL8YiRMs2oeDNssav1vKC6bW2/It t+WcQs1po3eQ1x4M6cOd9l7/JUxSR34k4k33S198fPGGkBQVSZ8JIB8cZ4mRzIkJqT l+Gfqvy70y8HopbHpQPiVrkE7Tq3GvZFB+uOuBL0= Date: Tue, 10 Jul 2018 18:19:56 -0500 From: Bjorn Helgaas To: Alexandru Gagniuc Cc: bhelgaas@google.com, keith.busch@intel.com, alex_gagniuc@dellteam.com, austin_bolen@dell.com, shyam_iyer@dell.com, Frederick Lawler , Greg Kroah-Hartman , Oza Pawandeep , linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v4] PCI/AER: Fix aerdrv loading with "pcie_ports=native" parameter Message-ID: <20180710231956.GD188359@bhelgaas-glaptop.roam.corp.google.com> References: <20180703163854.GA61685@bhelgaas-glaptop.roam.corp.google.com> <20180703232755.2472-1-mr.nuke.me@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180703232755.2472-1-mr.nuke.me@gmail.com> User-Agent: Mutt/1.9.2 (2017-12-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jul 03, 2018 at 06:27:43PM -0500, Alexandru Gagniuc wrote: > According to the documentation, "pcie_ports=native", linux should use > native AER and DPC services. While that is true for the _OSC method > parsing, this is not the only place that is checked. Should the HEST > table list PCIe ports as firmware-first, linux will not use native > services. > > This happens because aer_acpi_firmware_first() doesn't take > 'pcie_ports' into account. This is wrong. DPC uses the same logic when > it decides whether to load or not, so fixing this also fixes DPC not > loading. > > Signed-off-by: Alexandru Gagniuc Applied to pci/aer for v4.19, thanks! > --- > drivers/pci/pcie/aer.c | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/drivers/pci/pcie/aer.c b/drivers/pci/pcie/aer.c > index a2e88386af28..63a66a3b2fb5 100644 > --- a/drivers/pci/pcie/aer.c > +++ b/drivers/pci/pcie/aer.c > @@ -303,6 +303,9 @@ int pcie_aer_get_firmware_first(struct pci_dev *dev) > if (!pci_is_pcie(dev)) > return 0; > > + if (pcie_ports_native) > + return 0; > + > if (!dev->__aer_firmware_first_valid) > aer_set_firmware_first(dev); > return dev->__aer_firmware_first; > @@ -323,6 +326,9 @@ bool aer_acpi_firmware_first(void) > .firmware_first = 0, > }; > > + if (pcie_ports_native) > + return 0; > + > if (!parsed) { > apei_hest_parse(aer_hest_parse, &info); > aer_firmware_first = info.firmware_first; > -- > 2.14.3 >