From patchwork Thu Nov 5 06:04:50 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Gautham R Shenoy X-Patchwork-Id: 1394744 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4CRY0S0zz2z9sTD for ; Thu, 5 Nov 2020 17:05:28 +1100 (AEDT) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=ibm.com header.i=@ibm.com header.a=rsa-sha256 header.s=pp1 header.b=QzdZrxmY; dkim-atps=neutral Received: from bilbo.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 4CRY0R6btxzDqg7 for ; Thu, 5 Nov 2020 17:05:27 +1100 (AEDT) X-Original-To: skiboot@lists.ozlabs.org Delivered-To: skiboot@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=linux.vnet.ibm.com (client-ip=148.163.158.5; helo=mx0b-001b2d01.pphosted.com; envelope-from=ego@linux.vnet.ibm.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=pass (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=ibm.com header.i=@ibm.com header.a=rsa-sha256 header.s=pp1 header.b=QzdZrxmY; dkim-atps=neutral Received: from mx0b-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 4CRY0C4xVmzDqfc for ; Thu, 5 Nov 2020 17:05:14 +1100 (AEDT) Received: from pps.filterd (m0127361.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 0A563dN2133775 for ; Thu, 5 Nov 2020 01:05:10 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=from : to : cc : subject : date : message-id; s=pp1; bh=P3YnBW467T9YWxK2d3hOaFO6GbWpO7YSgdT4dvHYpZw=; b=QzdZrxmYw81fGggfNElIK4kHmkMnFQG21zM7C2GqQVA9dnthIzgfWVRqu0d0wXbEkoXX +usqli4BIbA8NbwrYkEsEwop+r0brah++r6nkGhexF1QO6owClBYlX9Z/Hnx+w43+ZxY OIyPAt4lsEm1FS8wDeNJbLa4vy0j6PBj0MY5MQeJrGsiOT4X1gc/gKn+2kovv5WQz4e2 c7VK63WEjfj9XeFSJSKnoKfHjlNJIrAmHvbwGizTEHtzlhNhUx7JLfsad93oYYHbBzEU m3bPaEzZi5o9iepW5aQ9FQse8qg9cBJqQ/19rsgoCagL5i+9+/tS+wpgBZPTKIoYM0og Xw== Received: from ppma02dal.us.ibm.com (a.bd.3ea9.ip4.static.sl-reverse.com [169.62.189.10]) by mx0a-001b2d01.pphosted.com with ESMTP id 34m7tddcb9-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 05 Nov 2020 01:05:09 -0500 Received: from pps.filterd (ppma02dal.us.ibm.com [127.0.0.1]) by ppma02dal.us.ibm.com (8.16.0.42/8.16.0.42) with SMTP id 0A563Xno018395 for ; Thu, 5 Nov 2020 06:05:05 GMT Received: from b01cxnp22033.gho.pok.ibm.com (b01cxnp22033.gho.pok.ibm.com [9.57.198.23]) by ppma02dal.us.ibm.com with ESMTP id 34h022qkg8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 05 Nov 2020 06:05:05 +0000 Received: from b01ledav002.gho.pok.ibm.com (b01ledav002.gho.pok.ibm.com [9.57.199.107]) by b01cxnp22033.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 0A5655Ph12714510 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 5 Nov 2020 06:05:05 GMT Received: from b01ledav002.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 03D6E12405A; Thu, 5 Nov 2020 06:05:05 +0000 (GMT) Received: from b01ledav002.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id A3C27124055; Thu, 5 Nov 2020 06:05:04 +0000 (GMT) Received: from sofia.ibm.com (unknown [9.199.51.179]) by b01ledav002.gho.pok.ibm.com (Postfix) with ESMTP; Thu, 5 Nov 2020 06:05:04 +0000 (GMT) Received: by sofia.ibm.com (Postfix, from userid 1000) id ADB122E323C; Thu, 5 Nov 2020 11:34:58 +0530 (IST) From: "Gautham R. Shenoy" To: Vasant Hegde , skiboot@lists.ozlabs.org Date: Thu, 5 Nov 2020 11:34:50 +0530 Message-Id: <1604556290-28278-1-git-send-email-ego@linux.vnet.ibm.com> X-Mailer: git-send-email 1.8.3.1 X-TM-AS-GCONF: 00 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.312, 18.0.737 definitions=2020-11-05_01:2020-11-05, 2020-11-05 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 phishscore=0 impostorscore=0 clxscore=1015 mlxscore=0 malwarescore=0 mlxlogscore=999 priorityscore=1501 suspectscore=0 lowpriorityscore=0 bulkscore=0 spamscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2011050041 Subject: [Skiboot] [PATCH v2] xscom: Fix xscom error logging caused due to xscom OPAL call X-BeenThere: skiboot@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Mailing list for skiboot development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Pavaman Subramaniyam , "Gautham R. Shenoy" MIME-Version: 1.0 Errors-To: skiboot-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "Skiboot" From: "Gautham R. Shenoy" Commit 80fd2e963bd4 ("xscom: Don't log xscom errors caused by OPAL calls") ensured that xscom errors caused due to XSCOM read/write OPAL calls aren't logged in the error-log since the caller of the OPAL call is expected to handle it. However we are continuing to print the prerror() in the OPAL log regarding the same. This patch reduces the severity of the log from PR_ERROR to PR_INFO for the xscom read and write calls. Tested-by: Pavaman Subramaniyam Signed-off-by: Gautham R. Shenoy Reviewed-by: Dan HorĂ¡k --- hw/xscom.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/hw/xscom.c b/hw/xscom.c index 0eda567..8ef78aa 100644 --- a/hw/xscom.c +++ b/hw/xscom.c @@ -373,7 +373,12 @@ static int __xscom_read(uint32_t gcid, uint32_t pcb_addr, uint64_t *val) if (proc_gen == proc_gen_p9 && ret == OPAL_XSCOM_CHIPLET_OFF) return ret; - prerror("XSCOM: Read failed, ret = %lld\n", ret); + /* + * If an XSCOM read call fails, the OPAL-PRD will handle + * logging the error. Hence just print an informational + * message here. + */ + prlog(PR_INFO, "XSCOM: Read failed, ret = %lld\n", ret); return ret; } @@ -424,8 +429,12 @@ static int __xscom_write(uint32_t gcid, uint32_t pcb_addr, uint64_t val) */ if (proc_gen == proc_gen_p9 && ret == OPAL_XSCOM_CHIPLET_OFF) return ret; - - prerror("XSCOM: Write failed, ret = %lld\n", ret); + /* + * If an XSCOM write call fails, the OPAL-PRD will handle + * logging the error. Hence just print an informational + * message here. + */ + prlog(PR_INFO, "XSCOM: Write failed, ret = %lld\n", ret); return ret; }