Received: by 2002:ac0:98c7:0:0:0:0:0 with SMTP id g7-v6csp2320213imd; Fri, 2 Nov 2018 09:22:12 -0700 (PDT) X-Google-Smtp-Source: AJdET5dEbfNmCvoigXKUkvxcT3glvkywfej6LmrWLIMgKzge5uAkQ8jC+zpri9BhQOyP2jKC9nFi X-Received: by 2002:a62:cac4:: with SMTP id y65-v6mr12323930pfk.27.1541175732882; Fri, 02 Nov 2018 09:22:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1541175732; cv=none; d=google.com; s=arc-20160816; b=qUqTK6qRmxwP+T9mdavbtxPvHjnnYR3MXq6y0IRIbrvIkUaP0Du8HPXcFm4aopoCe3 mjsiPEkP4RaqS2ZVPMhENVnzBEoRG3w1kBUuUYbdNUaXSj9vpEZheYS5BkRKHnycy/yy Zqagjr5GbSb5wMgCNWkTcEtgAoBYbxIcQFaVlyBPp52l+rgh/NlJa9sE0ZKWEFZrmr4N zQFWYV4PNMiQLlciTW3whCn3PFrpgv14OBaqjR32+V00iHB9zyLOo3B1C2q9QqIEbG6l j1pUxpILyYAdCI9p6Y4K85DTcm0cx1ILhepPuxxa5Xi3D90E80R0Ziaz+3Bp2L4zW69v SRnw== 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=WmgqIs6UTMZT4QYeQ3w7gKHha0FoNE2VGX2Bp28KgMU=; b=QD01W3jBiw/NhIrW+1Pulne1TSbGjqsXvW3di8+q27S6EQ76EGtsozPhYI3WeQnceV YYklZWssxjxfqexvFUBCpnMpv4lfljd1PB1c+7eIljELPd9KF4tj3QaQQWe0eiEx5ukg 1QkfpMEFudH9/2ZVmnkgNDekGKCWsghEU7jTyLgHSGx2EmW5heOWz4kch10Q0ERLam3y CVs6/CPDV5Gs2WiwFuG6gO3MOn+nDw2u7wGvTk27m/SfJ34KjCbkNC12DqOECiCAZEaz V6QH4KwGkgWIaLpZW4oqsRj4Ltyr6upMaRRieM0BjlnjfcU+lDJUF2O7eOJiiqnjyIU7 fNZQ== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f7-v6si33728848pgn.108.2018.11.02.09.21.57; Fri, 02 Nov 2018 09:22:12 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728081AbeKCB10 (ORCPT + 99 others); Fri, 2 Nov 2018 21:27:26 -0400 Received: from mga06.intel.com ([134.134.136.31]:62347 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726098AbeKCB10 (ORCPT ); Fri, 2 Nov 2018 21:27:26 -0400 X-Amp-Result: UNSCANNABLE X-Amp-File-Uploaded: False Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 02 Nov 2018 09:19:46 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.54,456,1534834800"; d="scan'208";a="93244637" Received: from unknown (HELO localhost.localdomain) ([10.232.112.69]) by FMSMGA003.fm.intel.com with ESMTP; 02 Nov 2018 09:19:46 -0700 Date: Fri, 2 Nov 2018 10:17:30 -0600 From: Keith Busch To: Borislav Petkov Cc: Bjorn Helgaas , Jon Derrick , linux-pci@vger.kernel.org, Lorenzo Pieralisi , "Rafael J. Wysocki" , Len Brown , Tony Luck , Tyler Baicar , Christoph Hellwig , linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/3] PCI/AER: Option to leave System Error Interrupts as-is Message-ID: <20181102161730.GA26392@localhost.localdomain> References: <1540585146-31876-1-git-send-email-jonathan.derrick@intel.com> <20181029210651.GB13681@bhelgaas-glaptop.roam.corp.google.com> <20181102095300.GB14602@zn.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20181102095300.GB14602@zn.tnic> User-Agent: Mutt/1.9.1 (2017-09-22) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 02, 2018 at 10:53:00AM +0100, Borislav Petkov wrote: > On Mon, Oct 29, 2018 at 04:06:51PM -0500, Bjorn Helgaas wrote: > > If I squint hard enough this sort of makes sense, but it also makes me > > confused about the normal APEI firmware-first model works. > > > > In the NON-firmare-first case, firmware isn't involved in handling AER > > errors. The Linux AER driver fields an interrupt from a Root Port, > > reads AER log registers, etc. > > > > In the normal APEI firmware-first case, when the hardware reports an > > AER event, I think firmware gets control first, and *it* reads the AER > > log registers, packages them up, and generates an interrupt to the OS, > > which reads the packaged error state from the firmware via the HEST. > > > > If I understand this special Intel VMD firmware-first case correctly, > > firmware gets control first, reads the AER log registers, and > > synthesizes what looks to the OS like a normal AER interrupt. The > > Why? > > Why the faking? > > If firmware needs to get control, why doesn't it then *retain* control > and report the error through HEST, like others do? > > AFAIUC, fw wants to do something underneath. What's wrong with making it > a normal firmware-first case? VMD acts a bit like a host-bus adapter. The firmware knows about the adapter, but not about anything on the bus that it attaches to. This "hybrid" approach is basically saying that the firmware knows about the HBA, and it wants a chance to be notified of errors on the bus it attaches to, but the firmware can't do anything about such errors. The bus in this case is PCIe, where we have capable error handling in the kernel driver, so we ultimately want the AER driver handling the errors.