From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from frasgout.his.huawei.com (frasgout.his.huawei.com [185.176.79.56]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 216E719AE; Fri, 8 Dec 2023 06:38:06 -0800 (PST) Received: from mail.maildlp.com (unknown [172.18.186.31]) by frasgout.his.huawei.com (SkyGuard) with ESMTP id 4SmtzD3yjTz67XhB; Fri, 8 Dec 2023 22:38:00 +0800 (CST) Received: from lhrpeml500005.china.huawei.com (unknown [7.191.163.240]) by mail.maildlp.com (Postfix) with ESMTPS id 5CBDF140D37; Fri, 8 Dec 2023 22:38:04 +0800 (CST) Received: from localhost (10.126.175.81) by lhrpeml500005.china.huawei.com (7.191.163.240) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Fri, 8 Dec 2023 14:38:03 +0000 Date: Fri, 8 Dec 2023 14:38:02 +0000 From: Jonathan Cameron To: Bjorn Helgaas CC: , Mahesh J Salgaonkar , Oliver O'Halloran , Robert Richter , Terry Bowman , Kai-Heng Feng , , , Bjorn Helgaas Subject: Re: [PATCH 2/3] PCI/AER: Decode Requester ID when no error info found Message-ID: <20231208143802.00007c3e@Huawei.com> In-Reply-To: <20231206224231.732765-3-helgaas@kernel.org> References: <20231206224231.732765-1-helgaas@kernel.org> <20231206224231.732765-3-helgaas@kernel.org> Organization: Huawei Technologies Research and Development (UK) Ltd. X-Mailer: Claws Mail 4.1.0 (GTK 3.24.33; x86_64-w64-mingw32) Precedence: bulk X-Mailing-List: linux-pci@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-ClientProxiedBy: lhrpeml100005.china.huawei.com (7.191.160.25) To lhrpeml500005.china.huawei.com (7.191.163.240) On Wed, 6 Dec 2023 16:42:30 -0600 Bjorn Helgaas wrote: > From: Bjorn Helgaas > > When a device with AER detects an error, it logs error information in its > own AER Error Status registers. It may send an Error Message to the Root > Port (RCEC in the case of an RCiEP), which logs the fact that an Error > Message was received (Root Error Status) and the Requester ID of the > message source (Error Source Identification). > > aer_print_port_info() prints the Requester ID from the Root Port Error > Source in the usual Linux "bb:dd.f" format, but when find_source_device() > finds no error details in the hierarchy below the Root Port, it printed the > raw Requester ID without decoding it. > > Decode the Requester ID in the usual Linux format so it matches other > messages. > > Sample message changes: > > - pcieport 0000:00:1c.5: AER: Correctable error received: 0000:00:1c.5 > - pcieport 0000:00:1c.5: AER: can't find device of ID00e5 > + pcieport 0000:00:1c.5: AER: Correctable error message received from 0000:00:1c.5 > + pcieport 0000:00:1c.5: AER: found no error details for 0000:00:1c.5 > > Signed-off-by: Bjorn Helgaas LGTM Reviewed-by: Jonathan Cameron