[{"id":1769050,"web_url":"http://patchwork.ozlabs.org/comment/1769050/","msgid":"<20170915084018.GI5432@drishya.in.ibm.com>","list_archive_url":null,"date":"2017-09-15T08:40:18","subject":"Re: [Skiboot] [PATCH v4 8/8] Add Documenation for opal_slw_set_reg","submitter":{"id":497,"url":"http://patchwork.ozlabs.org/api/people/497/","name":"Vaidyanathan Srinivasan","email":"svaidy@linux.vnet.ibm.com"},"content":"* Akshay Adiga <akshay.adiga@linux.vnet.ibm.com> [2017-09-15 13:04:36]:\n\n> Signed-off-by: Akshay Adiga <akshay.adiga@linux.vnet.ibm.com>\n\nReviewed-by: Vaidyanathan Srinivasan <svaidy@linux.vnet.ibm.com>\n\n\n> ---\n>  doc/opal-api/opal-slw-set-reg-100.rst | 46 +++++++++++++++++++++++++++++++++++\n>  1 file changed, 46 insertions(+)\n>  create mode 100644 doc/opal-api/opal-slw-set-reg-100.rst\n> \n> diff --git a/doc/opal-api/opal-slw-set-reg-100.rst b/doc/opal-api/opal-slw-set-reg-100.rst\n> new file mode 100644\n> index 0000000..64ecdee\n> --- /dev/null\n> +++ b/doc/opal-api/opal-slw-set-reg-100.rst\n> @@ -0,0 +1,46 @@\n> +OPAL_SLW_SET_REG\n> +==============================\n> +::\n> +\n> +    int64_t opal_slw_set_reg(uint64_t cpu_pir, uint64_t sprn, uint64_t val)\n> +\n> +\n> +OPAL_SLW_SET_REG is used to inform low-level firmware to restore a\n> +given value of SPR when there is a state loss.  The actual set of SPR\n> +that is supported is platform dependent.\n> +\n> +\n> +In Power 8, it uses p8_pore_gen_cpufreq_fixed(), api provided by pore engine,\n> +to inform the spr with their corresponding values with which they\n> +must be restored.\n> +\n> +\n> +In Power 9, it uses p9_stop_save_cpureg(), api provided by self restore code,\n> +to inform the spr with their corresponding values with which they\n> +must be restored.\n> +\n> +\n> +Parameters\n> +----------\n> +\n> +``uint64_t cpu_pir``\n> +This parameter specifies the pir of the cpu for which the call is being made.\n> +\n> +``uint64_t sprn``\n> +This parameter specifies the spr number as mentioned in p9_stop_api.H for\n> +Power9 and p8_pore_table_gen_api.H for Power8.\n> +\n> +``uint64_t val``\n> +This parameter specifices value with which the spr should be restored.\n> +\n> +Returns\n> +-------\n> +\n> +``OPAL_INTERNAL_ERROR``\n> +On failure. The actual error code from the platform specific code is logged in the OPAL logs\n> +\n> +``OPAL_UNSUPPORTED``\n> +In power8 only, if spr restore is not supported by pore engine.\n\nIf the low-level firmware does not support this feature or the given SPR is not supported by the pore engine or stop api. \n\n> +\n> +``OPAL_SUCCESS``\n> +On success\n> -- \n> 2.5.5\n>","headers":{"Return-Path":"<skiboot-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org>","X-Original-To":["incoming@patchwork.ozlabs.org","skiboot@lists.ozlabs.org"],"Delivered-To":["patchwork-incoming@bilbo.ozlabs.org","skiboot@lists.ozlabs.org"],"Received":["from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\t(using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3xtpmK64Qhz9s3w\n\tfor <incoming@patchwork.ozlabs.org>;\n\tFri, 15 Sep 2017 18:41:53 +1000 (AEST)","from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3])\n\tby lists.ozlabs.org (Postfix) with ESMTP id 3xtpmK4btRzDrYf\n\tfor <incoming@patchwork.ozlabs.org>;\n\tFri, 15 Sep 2017 18:41:53 +1000 (AEST)","from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com\n\t[148.163.158.5])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256\n\tbits)) (No client certificate requested)\n\tby lists.ozlabs.org (Postfix) with ESMTPS id 3xtpkn0xcXzDrZX\n\tfor <skiboot@lists.ozlabs.org>; Fri, 15 Sep 2017 18:40:32 +1000 (AEST)","from pps.filterd (m0098414.ppops.net [127.0.0.1])\n\tby mx0b-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id\n\tv8F8dbBS041268\n\tfor <skiboot@lists.ozlabs.org>; Fri, 15 Sep 2017 04:40:29 -0400","from e23smtp04.au.ibm.com (e23smtp04.au.ibm.com [202.81.31.146])\n\tby mx0b-001b2d01.pphosted.com with ESMTP id 2d0b540ywh-1\n\t(version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT)\n\tfor <skiboot@lists.ozlabs.org>; Fri, 15 Sep 2017 04:40:29 -0400","from localhost\n\tby e23smtp04.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use\n\tOnly! Violators will be prosecuted\n\tfor <skiboot@lists.ozlabs.org> from <svaidy@linux.vnet.ibm.com>;\n\tFri, 15 Sep 2017 18:40:26 +1000","from d23relay06.au.ibm.com (202.81.31.225)\n\tby e23smtp04.au.ibm.com (202.81.31.210) with IBM ESMTP SMTP Gateway:\n\tAuthorized Use Only! Violators will be prosecuted; \n\tFri, 15 Sep 2017 18:40:25 +1000","from d23av06.au.ibm.com (d23av06.au.ibm.com [9.190.235.151])\n\tby d23relay06.au.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id\n\tv8F8ePkZ39256150\n\tfor <skiboot@lists.ozlabs.org>; Fri, 15 Sep 2017 18:40:25 +1000","from d23av06.au.ibm.com (localhost [127.0.0.1])\n\tby d23av06.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id\n\tv8F8ePSH004779\n\tfor <skiboot@lists.ozlabs.org>; Fri, 15 Sep 2017 18:40:25 +1000","from drishya.in.ibm.com ([9.102.2.33])\n\tby d23av06.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id\n\tv8F8eJvk004548\n\t(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256\n\tverify=NO); Fri, 15 Sep 2017 18:40:22 +1000"],"Authentication-Results":"ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=linux.vnet.ibm.com\n\t(client-ip=148.163.158.5; helo=mx0a-001b2d01.pphosted.com;\n\tenvelope-from=svaidy@linux.vnet.ibm.com; receiver=<UNKNOWN>)","Date":"Fri, 15 Sep 2017 14:10:18 +0530","From":"Vaidyanathan Srinivasan <svaidy@linux.vnet.ibm.com>","To":"Akshay Adiga <akshay.adiga@linux.vnet.ibm.com>","References":"<1505460876-7303-1-git-send-email-akshay.adiga@linux.vnet.ibm.com>\n\t<1505460876-7303-9-git-send-email-akshay.adiga@linux.vnet.ibm.com>","MIME-Version":"1.0","Content-Disposition":"inline","In-Reply-To":"<1505460876-7303-9-git-send-email-akshay.adiga@linux.vnet.ibm.com>","User-Agent":"Mutt/1.8.3 (2017-05-23)","X-TM-AS-MML":"disable","x-cbid":"17091508-0012-0000-0000-0000025E0B7C","X-IBM-AV-DETECTION":"SAVI=unused REMOTE=unused XFE=unused","x-cbparentid":"17091508-0013-0000-0000-0000077C165C","Message-Id":"<20170915084018.GI5432@drishya.in.ibm.com>","X-Proofpoint-Virus-Version":"vendor=fsecure engine=2.50.10432:, ,\n\tdefinitions=2017-09-15_03:, , signatures=0","X-Proofpoint-Spam-Details":"rule=outbound_notspam policy=outbound score=0\n\tspamscore=0 suspectscore=0\n\tmalwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam\n\tadjust=0 reason=mlx scancount=1 engine=8.0.1-1707230000\n\tdefinitions=main-1709150131","Subject":"Re: [Skiboot] [PATCH v4 8/8] Add Documenation for opal_slw_set_reg","X-BeenThere":"skiboot@lists.ozlabs.org","X-Mailman-Version":"2.1.24","Precedence":"list","List-Id":"Mailing list for skiboot development <skiboot.lists.ozlabs.org>","List-Unsubscribe":"<https://lists.ozlabs.org/options/skiboot>,\n\t<mailto:skiboot-request@lists.ozlabs.org?subject=unsubscribe>","List-Archive":"<http://lists.ozlabs.org/pipermail/skiboot/>","List-Post":"<mailto:skiboot@lists.ozlabs.org>","List-Help":"<mailto:skiboot-request@lists.ozlabs.org?subject=help>","List-Subscribe":"<https://lists.ozlabs.org/listinfo/skiboot>,\n\t<mailto:skiboot-request@lists.ozlabs.org?subject=subscribe>","Reply-To":"svaidy@linux.vnet.ibm.com","Cc":"ego@linux.vnet.ibm.com, shriyak@linux.vnet.ibm.com,\n\tskiboot@lists.ozlabs.org","Content-Type":"text/plain; charset=\"utf-8\"","Content-Transfer-Encoding":"base64","Errors-To":"skiboot-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org","Sender":"\"Skiboot\"\n\t<skiboot-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org>"}}]