From patchwork Fri Sep 6 14:19:56 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nicholas Piggin X-Patchwork-Id: 1159025 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) (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 46Q0CT4p0hz9s7T for ; Sat, 7 Sep 2019 00:23:17 +1000 (AEST) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="RS7DB4AU"; 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 46Q0CT316fzDqLq for ; Sat, 7 Sep 2019 00:23:17 +1000 (AEST) X-Original-To: skiboot@lists.ozlabs.org Delivered-To: skiboot@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gmail.com (client-ip=2607:f8b0:4864:20::442; helo=mail-pf1-x442.google.com; envelope-from=npiggin@gmail.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="RS7DB4AU"; dkim-atps=neutral Received: from mail-pf1-x442.google.com (mail-pf1-x442.google.com [IPv6:2607:f8b0:4864:20::442]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 46Q09F2jrtzDqtr for ; Sat, 7 Sep 2019 00:21:20 +1000 (AEST) Received: by mail-pf1-x442.google.com with SMTP id r12so4610847pfh.1 for ; Fri, 06 Sep 2019 07:21:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=+FIJ3aPgghK2uRnpDWYVRJWLb2h6+y3MXMYaIXb7TCA=; b=RS7DB4AUKajH/OilBwCcMaijodLh4ZDueZXceF7KcD9H5/Iv9+7IUIDeAkGu0jE8v4 nnAl3cENwSQeQooVMSJ1/MBGr3q911kr0Cpoj3Bsuk5VorevSP6Ain0WrT7TW4ODU3BL 00Q+/UHrAHM70y1r3skqiSVk35smjkEOg3eJqi9yBxJ51VT0UzbqjdyJElKOdvHePOf2 UUVM7foadEzT0rsRI9WY9Lbcc9Kcv4WZD6OJ2zUV5zXhzMjqZisFFLrIjsPdVgGugdUO oEdU7gv26Wj5KgWTRitft3PVwyFzn47689Z88hKtcb5fsYUqGtZ1TwIOrvjyxWOlsSls ZJGg== 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:mime-version :content-transfer-encoding; bh=+FIJ3aPgghK2uRnpDWYVRJWLb2h6+y3MXMYaIXb7TCA=; b=gSsDhdtgxzvgr9dozfnRPVkZELgAmYx+8eWLKen0taJ1zcNo2K6GC7yvHM2e/B9L+K pZ9jGdUalLozUPQYwTCMTILtMlw3AZ0ob7yhS+wgZTGrVQ7yVJp29Y9+ycgBHncS9Yhv OLuu+faDJuaQFKYWl/vOulFxh668eEOl/f8288hxHPD0YBVE2ZGOjHsp6O9QKjCpQLtS NctDIepJjOC2q6WN+cUB9zsXff+sxJ3sXMODl1GDssj2jjY3fXFJ0hWMkUVJ03gA08CS 22OrgH06nIz423Jp1Vy98vzcDUbiR6jzE+3+vMxSXxAcwDkI6FVPvwNczF2IR0Oug2Wt GBJw== X-Gm-Message-State: APjAAAUxZHQtekeAIjzleO9VYYdoW1rCNmjR85XkIxFR35dbfWSxn+tp OJh3eFPqZCKtZnrbHtrsUb9QZsgW X-Google-Smtp-Source: APXvYqwZ6KqzX0ZB2Pnck0scypejEf07UuA7lwocBBHJdtXbQISQeGFAomsDIgdc/X0oHZq74cajZg== X-Received: by 2002:aa7:8c01:: with SMTP id c1mr11006866pfd.224.1567779676671; Fri, 06 Sep 2019 07:21:16 -0700 (PDT) Received: from bobo.local0.net ([203.63.189.78]) by smtp.gmail.com with ESMTPSA id n9sm5083895pjq.30.2019.09.06.07.21.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Sep 2019 07:21:16 -0700 (PDT) From: Nicholas Piggin To: skiboot@lists.ozlabs.org Date: Sat, 7 Sep 2019 00:19:56 +1000 Message-Id: <20190906141958.31626-1-npiggin@gmail.com> X-Mailer: git-send-email 2.22.0 MIME-Version: 1.0 Subject: [Skiboot] [PATCH 0/2] virtual memory for OPAL boot 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" This is pretty stable now on a witherspoon I have here, including going back into VM mode in fast reboot after CPUs are taken from the OS, so time to post it out again. Thanks, Nick Nicholas Piggin (2): core/exceptions.c: rearrange code to allow more interrupt types virtual memory for OPAL boot core/Makefile.inc | 2 +- core/cpu.c | 16 +- core/exceptions.c | 56 ++- core/fast-reboot.c | 30 +- core/flash.c | 1 + core/init.c | 169 +++++++-- core/mem_region.c | 89 +++-- core/opal.c | 20 +- core/vm.c | 829 +++++++++++++++++++++++++++++++++++++++++++ hdata/spira.c | 34 +- hw/fake-nvram.c | 12 +- hw/homer.c | 5 + hw/lpc-uart.c | 31 +- hw/lpc.c | 2 + hw/phb4.c | 9 +- hw/psi.c | 2 + hw/slw.c | 4 +- hw/xive.c | 5 + hw/xscom.c | 4 +- include/cmpxchg.h | 3 + include/cpu.h | 22 ++ include/elf-abi.h | 20 +- include/io.h | 57 ++- include/mem_region.h | 1 + include/processor.h | 13 +- include/skiboot.h | 28 ++ libstb/container.c | 12 +- libstb/cvc.c | 3 + libstb/secureboot.c | 5 +- libstb/trustedboot.c | 6 +- skiboot.lds.S | 56 +-- 31 files changed, 1411 insertions(+), 135 deletions(-) create mode 100644 core/vm.c