From patchwork Wed Aug 14 17:57:36 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Radoslaw Biernacki X-Patchwork-Id: 171326 Delivered-To: patch@linaro.org Received: by 2002:a92:d204:0:0:0:0:0 with SMTP id y4csp1160499ily; Wed, 14 Aug 2019 11:05:00 -0700 (PDT) X-Google-Smtp-Source: APXvYqzQFpm3hpKVaMOd8NgNpajtmR1OBA/rq0xHTAr9XLRpJOxodW7ZjPXMZ41ihvutHrxaQbgs X-Received: by 2002:ad4:4423:: with SMTP id e3mr721712qvt.145.1565805900831; Wed, 14 Aug 2019 11:05:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565805900; cv=none; d=google.com; s=arc-20160816; b=vHy0RI3h3fwfXaGJlnc92DwiMfUeazz8icrf/FHBVPxKZCwpM/lslpW5mxaG4McJwL QHyp59TGpduZxAqGs8tiiQ/iWadibmoBnypa1F3oCa+04Y6n8pxHaiSSRSWcOOY64Aas CUqW2PyO6hVi1GRyIVZ5RDbt175EZiWmavKdFVCLkjYDV4fukdAyN5izK6CRzmnztbJO ovqcTshGtSnwYUPmA0h0UbIOq/VVbkVXA+PXvX2bmOZGLacLJdVbCJ+NEF9pXlIOF6yu M3NtwmEPo4O9HhBMExIBOI+Y/d0b6vfcblWF4WBhypNqlJ033BKaOdsK97dAc9tXE7xI 9M7g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:message-id:date:to:from:delivered-to; bh=PupNq00r6u/jZC5EjCPmbNlcYlSqJ5zyqqKUkQbXqiw=; b=BMIQi2XsWxjc+/fzvb+n1m32CYDe8vWsxe2j1Vuxg4DExGNVCEo6HSBJUtwJJvCeMt B7KhIpZsDtY5iHFW5Ik6N2sHqASDsDdnVYTHls9+TEBs+lZAENjz0ZVHfQEMTrdV0slr LiMGOD150zxB5xnY9r2V/CvnrxDogfVuBP5a5BDGB/idRQKFwMB7Ny2QRRG3rCZFm/rm sh4ifmUPxq5ObXLoQne/qN+cepMu2/6W9X+SgL7QGDPaIbnlsKY9dGEFT3+yyvoPVMbA nyAy7GoN8RtpB3Jc8wFyTHTHhQoNRQHG9bDP7a0v+n9ppdtfuJxcX1fn4iB/+XlRtjlf KaSw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linaro-uefi-bounces@lists.linaro.org designates 107.22.173.205 as permitted sender) smtp.mailfrom=linaro-uefi-bounces@lists.linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.linaro.org (lists.linaro.org. [107.22.173.205]) by mx.google.com with ESMTPS id z53si214824qta.355.2019.08.14.11.05.00 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 14 Aug 2019 11:05:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linaro-uefi-bounces@lists.linaro.org designates 107.22.173.205 as permitted sender) client-ip=107.22.173.205; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linaro-uefi-bounces@lists.linaro.org designates 107.22.173.205 as permitted sender) smtp.mailfrom=linaro-uefi-bounces@lists.linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from lists.linaro.org (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id E22DC61828; Wed, 14 Aug 2019 18:04:59 +0000 (UTC) Received: by lists.linaro.org (Postfix, from userid 109) id CF95361838; Wed, 14 Aug 2019 18:04:59 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on ip-10-150-125-211.ec2.internal X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00, MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2 autolearn=disabled version=3.4.2 Received: from lists.linaro.org (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id C26206188F; Wed, 14 Aug 2019 18:01:11 +0000 (UTC) X-Original-To: linaro-uefi@lists.linaro.org Delivered-To: linaro-uefi@lists.linaro.org Received: from lists.linaro.org (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 67B256180C for ; Wed, 14 Aug 2019 18:00:25 +0000 (UTC) Received: by lists.linaro.org (Postfix, from userid 109) id 55BF4617FC; Wed, 14 Aug 2019 18:00:25 +0000 (UTC) Received: from mail-lj1-f195.google.com (mail-lj1-f195.google.com [209.85.208.195]) by lists.linaro.org (Postfix) with ESMTPS id 499D661846 for ; Wed, 14 Aug 2019 17:57:51 +0000 (UTC) Received: by mail-lj1-f195.google.com with SMTP id t3so17077373ljj.12 for ; Wed, 14 Aug 2019 10:57:51 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=UTCR34U+4QqCRkQE9+BIbqMFMAla0hfZRYUC0VdzwVQ=; b=ftsG3Tiz4erD9OwhyGqbNqaJ0BR1GJskbaDmTSTNFYZJeQf+SPbLbI5Ao5wXlUMA3a wlFGBeifdKRqPv/+VaCvZWvPVhTLcWFUntxeZbEV/fkgBauCTH03hdqWNyzr7Rt5UkCQ uMdX8bFfF38zehy2i7+dInGra9t+UYzkiNI0KmaWOJvQSx8GP+zCLlk3BMh+7xrfmBiU bslqcD9VSwCdQk05xsa4ZVfHQWgzqrUuolEiQrsHPmFFOSqRzQZN701R0KRcSYmrSben +PuFM2pSvgm2WG/IRnrzBxU8rgr92XzgmIKTXR1QUYOht/vGzq3MagqcgmNVQKcDKvWF Gpmg== X-Gm-Message-State: APjAAAV9vGquz148tQfiNjitF1eTYsPtBLxS+IACinOhOlsb51tZWyq6 3/G3mn7Ovtu0foafTp+aJJHtiepaJGhGRGrf X-Received: by 2002:a2e:860d:: with SMTP id a13mr500084lji.215.1565805469826; Wed, 14 Aug 2019 10:57:49 -0700 (PDT) Received: from rad-H81M-S1.semihalf.local (31-172-191-173.noc.fibertech.net.pl. [31.172.191.173]) by smtp.gmail.com with ESMTPSA id s10sm62347ljm.35.2019.08.14.10.57.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Aug 2019 10:57:49 -0700 (PDT) From: Radoslaw Biernacki To: linaro-uefi@lists.linaro.org Date: Wed, 14 Aug 2019 19:57:36 +0200 Message-Id: <20190814175737.23120-1-radoslaw.biernacki@linaro.org> X-Mailer: git-send-email 2.17.1 X-Virus-Scanned: ClamAV using ClamSMTP Cc: tanmay.jagdale@linaro.org Subject: [Linaro-uefi] [RFC PATCH 0/1] SBSAQemu UEFI initial implementation X-BeenThere: linaro-uefi@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "For discussions about Linaro-related UEFI development. Not a substitute for edk2-devel." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linaro-uefi-bounces@lists.linaro.org Sender: "Linaro-uefi" X-Virus-Scanned: ClamAV using ClamSMTP This is RFC for UEFI implementation for new machine based on Qemu Virt which is faithful as possible to real hardware. In opposition to existing Qemu Virt machine which is suited for performing workloads, the purpose of this machine is development of firmware and OS for AARCH64 server alike platforms (like in situation where real HW is not available yet or the debugging is easier to control under emulation). The SBSAQemu name, was chosen because the modeled HW is aimed to follow way that server-style armv8 machines are recommended to be set up. Support for Sbsa-ref machine was added into Qemu in v4.1.0 Implementation does not use fw-cfg nor DT provided by Qemu. The ATF part is curently under review: https://review.trustedfirmware.org/c/TF-A/trusted-firmware-a/+/1568/1 The compilation of edk2-platforms is described under: Platform/Qemu/SbsaQemu/Readme.md This patch is provided as presentation for progress, not functional UEFI implementation. You cannot boot system at current state. To mention just few missing features: - Qemu <-> ATF <-> UEFI communication channel for dynamic parameters like DRAM size - Related dynamic initialization in UEFI is for now with static PCD's - ACPI platform driver - SMBIOS Support Please provide feedback which might be helpfull for future development. Radoslaw Biernacki (1): SbsaQemu: EFI implementation for SbsaQemu platform Silicon/Qemu/SbsaQemuPkg.dec | 45 ++ Platform/Qemu/SbsaQemu/SbsaQemu.dsc | 744 ++++++++++++++++++ Platform/Qemu/SbsaQemu/SbsaQemu.fdf | 328 ++++++++ .../SbsaQemuPlatformDxe.inf | 48 ++ .../Qemu/Library/SbsaQemuLib/SbsaQemuLib.inf | 53 ++ .../SbsaQemuNorFlashLib.inf | 35 + .../SbsaQemuPciHostBridgeLib.inf | 55 ++ .../SbsaQemuPlatformDxe/SbsaQemuPlatformDxe.c | 61 ++ .../Qemu/Library/SbsaQemuLib/SbsaQemuLib.c | 148 ++++ .../Qemu/Library/SbsaQemuLib/SbsaQemuMem.c | 109 +++ .../SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.c | 46 ++ .../SbsaQemuPciHostBridgeLib.c | 224 ++++++ Maintainers.txt | 12 + Platform/Qemu/SbsaQemu/Readme.md | 162 ++++ Readme.md | 3 + .../Qemu/Library/SbsaQemuLib/SbsaQemuHelper.S | 62 ++ 16 files changed, 2135 insertions(+) create mode 100644 Silicon/Qemu/SbsaQemuPkg.dec create mode 100644 Platform/Qemu/SbsaQemu/SbsaQemu.dsc create mode 100644 Platform/Qemu/SbsaQemu/SbsaQemu.fdf create mode 100644 Silicon/Qemu/Drivers/SbsaQemuPlatformDxe/SbsaQemuPlatformDxe.inf create mode 100644 Silicon/Qemu/Library/SbsaQemuLib/SbsaQemuLib.inf create mode 100644 Silicon/Qemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.inf create mode 100644 Silicon/Qemu/Library/SbsaQemuPciHostBridgeLib/SbsaQemuPciHostBridgeLib.inf create mode 100644 Silicon/Qemu/Drivers/SbsaQemuPlatformDxe/SbsaQemuPlatformDxe.c create mode 100644 Silicon/Qemu/Library/SbsaQemuLib/SbsaQemuLib.c create mode 100644 Silicon/Qemu/Library/SbsaQemuLib/SbsaQemuMem.c create mode 100644 Silicon/Qemu/Library/SbsaQemuNorFlashLib/SbsaQemuNorFlashLib.c create mode 100644 Silicon/Qemu/Library/SbsaQemuPciHostBridgeLib/SbsaQemuPciHostBridgeLib.c create mode 100644 Platform/Qemu/SbsaQemu/Readme.md create mode 100644 Silicon/Qemu/Library/SbsaQemuLib/SbsaQemuHelper.S