From patchwork Sat Mar 28 01:08:06 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thiago Jung Bauermann X-Patchwork-Id: 1263136 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 48q0xv2GMHz9sSG for ; Sat, 28 Mar 2020 12:09:55 +1100 (AEDT) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=linux.ibm.com Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 48q0xv1hwRzDqrs for ; Sat, 28 Mar 2020 12:09:55 +1100 (AEDT) X-Original-To: skiboot@lists.ozlabs.org Delivered-To: skiboot@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=linux.ibm.com (client-ip=148.163.156.1; helo=mx0a-001b2d01.pphosted.com; envelope-from=bauerman@linux.ibm.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=linux.ibm.com Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) (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 48q0ww6sy6zDq8F for ; Sat, 28 Mar 2020 12:09:04 +1100 (AEDT) Received: from pps.filterd (m0187473.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 02S13Gke048563 for ; Fri, 27 Mar 2020 21:09:02 -0400 Received: from ppma01dal.us.ibm.com (83.d6.3fa9.ip4.static.sl-reverse.com [169.63.214.131]) by mx0a-001b2d01.pphosted.com with ESMTP id 2ywek1d2ux-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Fri, 27 Mar 2020 21:09:02 -0400 Received: from pps.filterd (ppma01dal.us.ibm.com [127.0.0.1]) by ppma01dal.us.ibm.com (8.16.0.27/8.16.0.27) with SMTP id 02S10ERA001692 for ; Sat, 28 Mar 2020 01:09:01 GMT Received: from b03cxnp08028.gho.boulder.ibm.com (b03cxnp08028.gho.boulder.ibm.com [9.17.130.20]) by ppma01dal.us.ibm.com with ESMTP id 2ywawmv1kn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Sat, 28 Mar 2020 01:09:01 +0000 Received: from b03ledav006.gho.boulder.ibm.com (b03ledav006.gho.boulder.ibm.com [9.17.130.237]) by b03cxnp08028.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 02S190tP41222534 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sat, 28 Mar 2020 01:09:00 GMT Received: from b03ledav006.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id F13FDC6057; Sat, 28 Mar 2020 01:08:59 +0000 (GMT) Received: from b03ledav006.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 15FBAC6055; Sat, 28 Mar 2020 01:08:56 +0000 (GMT) Received: from morokweng.localdomain.com (unknown [9.85.174.163]) by b03ledav006.gho.boulder.ibm.com (Postfix) with ESMTP; Sat, 28 Mar 2020 01:08:54 +0000 (GMT) From: Thiago Jung Bauermann To: skiboot@lists.ozlabs.org Date: Fri, 27 Mar 2020 22:08:06 -0300 Message-Id: <20200328010806.20621-4-bauerman@linux.ibm.com> X-Mailer: git-send-email 2.21.1 In-Reply-To: <20200328010806.20621-1-bauerman@linux.ibm.com> References: <20200328010806.20621-1-bauerman@linux.ibm.com> MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.138, 18.0.645 definitions=2020-03-27_09:2020-03-27, 2020-03-27 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_spam_definite policy=outbound score=100 malwarescore=0 clxscore=1015 suspectscore=0 spamscore=0 mlxscore=0 mlxlogscore=429 adultscore=0 bulkscore=0 phishscore=0 lowpriorityscore=0 priorityscore=1501 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2003280008 Subject: [Skiboot] [PATCH 3/3] doc/opal-uv-abi.rst: Add information about SBE commands 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: , Errors-To: skiboot-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "Skiboot" Signed-off-by: Thiago Jung Bauermann --- doc/opal-uv-abi.rst | 50 +++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 48 insertions(+), 2 deletions(-) diff --git a/doc/opal-uv-abi.rst b/doc/opal-uv-abi.rst index bf91e730b..57584fc58 100644 --- a/doc/opal-uv-abi.rst +++ b/doc/opal-uv-abi.rst @@ -362,6 +362,9 @@ UV_READ_SCOM Perform an XSCOM read and put the value in a buffer. +Some XSCOM addresses are restricted by the Ultravisor and will return +U_PERMISSION if they have been blocked. + Syntax ~~~~~~ @@ -376,7 +379,7 @@ Return values ~~~~~~~~~~~~~ * U_SUCCESS on success. -* U_PERMISSION if called from VM context. +* U_PERMISSION if called from VM context or if the XSCOM cannot be allowed. * U_PARAMETER if invalid partiton or address. * U_BUSY if unit is busy, need to retry. * U_XSCOM_CHIPLET_OFF if cpu is asleep. @@ -391,6 +394,9 @@ UV_WRITE_SCOM Perform an XSCOM write. +Some XSCOM addresses are restricted by the Ultravisor and will return +U_PERMISSION if they have been blocked. + Syntax ~~~~~~ @@ -407,7 +413,7 @@ Return values One of the following values: * U_SUCCESS on success. -* U_PERMISSION if called from VM context. +* U_PERMISSION if called from VM context or if the XSCOM cannot be allowed. * U_PARAMETER if invalid partiton. * U_BUSY if unit is busy, need to retry. * U_XSCOM_CHIPLET_OFF if cpu is asleep. @@ -417,6 +423,46 @@ One of the following values: * U_XSCOM_PARITY_ERROR if parity error. * U_XSCOM_TIMEOUT if timeout. +UV_SEND_SBE_COMMAND +------------------- + +Send a request to the SBE. These are the commands that can be sent: + +* SBE_CHIPOP_TIMER: Set the SBE timer to the target provided in the input + parameter. +* SBE_CHIPOP_HANDLE_INTERRUPT: Read the host doorbell register and returns in + the output parameter the bits that were set. The bits in the doorbell register + are cleared. The input parameter is unused and must be zero. +* SBE_CHIPOP_START_MPIPL: Send S0 interrupt to SBE. The input parameter is + unused and must be zero. + +Syntax +~~~~~~ + +.. code-block:: c + + enum sbe_chipop_ops { + SBE_CHIPOP_TIMER, + SBE_CHIPOP_HANDLE_INTERRUPT, + SBE_CHIPOP_START_MPIPL + }; + + long ucall(UV_SEND_SBE_COMMAND, + unsigned long *retbuf, + u64 chip_id, + enum sbe_chipop_ops opcode, + u64 input) + +Return values +~~~~~~~~~~~~~ + +The same return values as UV_READ_SCOM and UV_WRITE_SCOM, or one of the +following values: + +* U_SUCCESS on success. +* U_PERMISSION if called from VM context. +* U_PARAMETER if invalid chip_id, opcode or input value. + References ##########