From patchwork Fri Apr 1 15:49:11 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shannon Zhao X-Patchwork-Id: 8726201 Return-Path: X-Original-To: patchwork-xen-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 7C8919F3D1 for ; Fri, 1 Apr 2016 15:53:53 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 83DDA203AB for ; Fri, 1 Apr 2016 15:53:52 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 70096203DC for ; Fri, 1 Apr 2016 15:53:51 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1am1MB-0005Cn-L8; Fri, 01 Apr 2016 15:51:31 +0000 Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1am1MA-0005BQ-D2 for xen-devel@lists.xen.org; Fri, 01 Apr 2016 15:51:30 +0000 Received: from [193.109.254.147] by server-15.bemta-14.messagelabs.com id C9/AB-02980-1099EF65; Fri, 01 Apr 2016 15:51:29 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrKIsWRWlGSWpSXmKPExsVyMfSOli7jzH9 hBlP2MFos+biYxYHR4+ju30wBjFGsmXlJ+RUJrBkNzQdZC+5LVjxp3sLYwHhdtIuRi0NIYBKj xLGdc9lBHBaBecwSU9u6WUAcCYF+VokVT/8COZxATozEzOb1jBB2tcTN51vBbCEBNYllhxcyQ 9hPGCVW3xIHsdkEdCReTNrJ1sXIwSEi4CGx52MtyExmgWNMEldbljOB1AgLhEv8PbibDcRmEV CV2D9lMzuIzQtU/2rKXjaIXXIS54//BJvPCRSf/O8VC8Qud4mHs2axT2AUWMDIsIpRvTi1qCy 1SNdSL6koMz2jJDcxM0fX0NBELze1uDgxPTUnMalYLzk/dxMjMLAYgGAHY/8U50OMkhxMSqK8 htP+hQnxJeWnVGYkFmfEF5XmpBYfYpTh4FCS4I2bAZQTLEpNT61Iy8wBhjhMWoKDR0mENxMkz VtckJhbnJkOkTrFaMyx5fe1tUwc26beW8skxJKXn5cqJc7rD1IqAFKaUZoHNwgWe5cYZaWEeR mBThPiKUgtys0sQZV/xSjOwagkzJsIMoUnM68Ebt8roFOYgE7pkAY7pSQRISXVwFjPcHPz6n2 sV3q2rlI3K9uneenhr1j1rusLIhwtXiRxH5xtFp3FVF8lFRDbb3VGmWlV+DI161+3eOsKveb/ tX5kI9n+sc3CQOPWh58OeU8YWf5Ut52tKVpbJ1K7Iv1w/8qaN/fCzjXPtZmt15xq7mlkzKnBu WM3j8FC8aIOvRn7Lc6WyPxIUGIpzkg01GIuKk4EAA6rRVq4AgAA X-Env-Sender: shannon.zhao@linaro.org X-Msg-Ref: server-8.tower-27.messagelabs.com!1459525887!31331839!1 X-Originating-IP: [209.85.220.42] X-SpamReason: No, hits=0.0 required=7.0 tests= X-StarScan-Received: X-StarScan-Version: 8.28; banners=-,-,- X-VirusChecked: Checked Received: (qmail 49703 invoked from network); 1 Apr 2016 15:51:28 -0000 Received: from mail-pa0-f42.google.com (HELO mail-pa0-f42.google.com) (209.85.220.42) by server-8.tower-27.messagelabs.com with AES128-GCM-SHA256 encrypted SMTP; 1 Apr 2016 15:51:28 -0000 Received: by mail-pa0-f42.google.com with SMTP id tt10so93809601pab.3 for ; Fri, 01 Apr 2016 08:51:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=6d3kD/k5+TjSkmmKOokdQE45WzF40+QUpM7HToUpHv8=; b=Rn9vB83dctfOgZc9aeJ5MYa1h+GwAudFtYP8mg3tim6YWBWeLoOS+mx3phvv/L8/wP LE61lvt8EqjnfcEnydo5j7kVrPvme0ew7rMTwChGDELYOeyNfwCZtnT3Hu3xyoC90/E2 RgzJxGLuB+K/yZdhMyTfAZUVuJoVGF0ck60tQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=6d3kD/k5+TjSkmmKOokdQE45WzF40+QUpM7HToUpHv8=; b=lbrryeA9iJa0JeNS6tcfJF3juNrYKsozOywFq5y0DxRzFLDOJA7pflgGhP/QkLv8jS HnPRKwc6AjU4t7WsnIA5Kh5r0TLl9VzseZOoWa6I3ulGwWE1H5MVvlo/+FJbGB2OHBLu uhsWta3UzRlKPOY0FhYcfasgq7yMjYHblc24N0h415t20Fdp+CIIsp88Sp/at/6fPqml g4q4m//U4OpK6C0+Gxl2RIQKduXzYFihUdk4NjeDEHbTK3e5c+Wsw6yzeLqGmicEWkDu FqY1MHisCGybb1/nkYz7i6xh7dKhka+pdKFpBKmVpAr3U3PD+Uw4bBU3Su+RNF/WrbW2 DEog== X-Gm-Message-State: AD7BkJLYcAluvVUL13hiVrtKzdwhd2BncTPTTMCmXtg/9q3valFEPp/M7oFXFD2pyAgYSGOM X-Received: by 10.66.189.166 with SMTP id gj6mr32133588pac.158.1459525887344; Fri, 01 Apr 2016 08:51:27 -0700 (PDT) Received: from localhost.localdomain ([167.160.116.218]) by smtp.gmail.com with ESMTPSA id yj1sm22536791pac.16.2016.04.01.08.51.18 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 01 Apr 2016 08:51:26 -0700 (PDT) From: Shannon Zhao To: linux-arm-kernel@lists.infradead.org, stefano.stabellini@citrix.com Date: Fri, 1 Apr 2016 23:49:11 +0800 Message-Id: <1459525755-36968-14-git-send-email-shannon.zhao@linaro.org> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1459525755-36968-1-git-send-email-shannon.zhao@linaro.org> References: <1459525755-36968-1-git-send-email-shannon.zhao@linaro.org> Cc: devicetree@vger.kernel.org, linux-efi@vger.kernel.org, Rob Herring , catalin.marinas@arm.com, will.deacon@arm.com, linux-kernel@vger.kernel.org, peter.huangpeng@huawei.com, julien.grall@arm.com, david.vrabel@citrix.com, zhaoshenglong@huawei.com, xen-devel@lists.xen.org, shannon.zhao@linaro.org Subject: [Xen-devel] [PATCH v10 13/17] ARM: Xen: Document UEFI support on Xen ARM virtual platforms X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add a "uefi" node under /hypervisor node in FDT, then Linux kernel could scan this to get the UEFI information. CC: Rob Herring Signed-off-by: Shannon Zhao Acked-by: Rob Herring Reviewed-by: Stefano Stabellini --- Documentation/devicetree/bindings/arm/xen.txt | 35 +++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/Documentation/devicetree/bindings/arm/xen.txt b/Documentation/devicetree/bindings/arm/xen.txt index 0f7b9c2..c9b9321 100644 --- a/Documentation/devicetree/bindings/arm/xen.txt +++ b/Documentation/devicetree/bindings/arm/xen.txt @@ -11,10 +11,32 @@ the following properties: memory where the grant table should be mapped to, using an HYPERVISOR_memory_op hypercall. The memory region is large enough to map the whole grant table (it is larger or equal to gnttab_max_grant_frames()). + This property is unnecessary when booting Dom0 using ACPI. - interrupts: the interrupt used by Xen to inject event notifications. A GIC node is also required. + This property is unnecessary when booting Dom0 using ACPI. +To support UEFI on Xen ARM virtual platforms, Xen populates the FDT "uefi" node +under /hypervisor with following parameters: + +________________________________________________________________________________ +Name | Size | Description +================================================================================ +xen,uefi-system-table | 64-bit | Guest physical address of the UEFI System + | | Table. +-------------------------------------------------------------------------------- +xen,uefi-mmap-start | 64-bit | Guest physical address of the UEFI memory + | | map. +-------------------------------------------------------------------------------- +xen,uefi-mmap-size | 32-bit | Size in bytes of the UEFI memory map + | | pointed to in previous entry. +-------------------------------------------------------------------------------- +xen,uefi-mmap-desc-size | 32-bit | Size in bytes of each entry in the UEFI + | | memory map. +-------------------------------------------------------------------------------- +xen,uefi-mmap-desc-ver | 32-bit | Version of the mmap descriptor format. +-------------------------------------------------------------------------------- Example (assuming #address-cells = <2> and #size-cells = <2>): @@ -22,4 +44,17 @@ hypervisor { compatible = "xen,xen-4.3", "xen,xen"; reg = <0 0xb0000000 0 0x20000>; interrupts = <1 15 0xf08>; + uefi { + xen,uefi-system-table = <0xXXXXXXXX>; + xen,uefi-mmap-start = <0xXXXXXXXX>; + xen,uefi-mmap-size = <0xXXXXXXXX>; + xen,uefi-mmap-desc-size = <0xXXXXXXXX>; + xen,uefi-mmap-desc-ver = <0xXXXXXXXX>; + }; }; + +The format and meaning of the "xen,uefi-*" parameters are similar to those in +Documentation/arm/uefi.txt, which are provided by the regular UEFI stub. However +they differ because they are provided by the Xen hypervisor, together with a set +of UEFI runtime services implemented via hypercalls, see +http://xenbits.xen.org/docs/unstable/hypercall/x86_64/include,public,platform.h.html.