From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 47E42C47083 for ; Wed, 2 Jun 2021 23:38:41 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id E47A7613D4 for ; Wed, 2 Jun 2021 23:38:40 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E47A7613D4 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Received: from list by lists.xenproject.org with outflank-mailman.136279.252741 (Exim 4.92) (envelope-from ) id 1loaRO-0005ZW-HJ; Wed, 02 Jun 2021 23:38:26 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 136279.252741; Wed, 02 Jun 2021 23:38:26 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1loaRO-0005ZP-Dg; Wed, 02 Jun 2021 23:38:26 +0000 Received: by outflank-mailman (input) for mailman id 136279; Wed, 02 Jun 2021 23:38:24 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1loaRM-0005ZJ-Mm for xen-devel@lists.xenproject.org; Wed, 02 Jun 2021 23:38:24 +0000 Received: from mail-oi1-x236.google.com (unknown [2607:f8b0:4864:20::236]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id dce48131-09a5-4356-be9d-2d4aa59caabb; Wed, 02 Jun 2021 23:38:23 +0000 (UTC) Received: by mail-oi1-x236.google.com with SMTP id u11so4459092oiv.1 for ; Wed, 02 Jun 2021 16:38:23 -0700 (PDT) Received: from localhost.localdomain (142-79-211-230.starry-inc.net. [142.79.211.230]) by smtp.gmail.com with ESMTPSA id z15sm301633otp.20.2021.06.02.16.38.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 02 Jun 2021 16:38:22 -0700 (PDT) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: dce48131-09a5-4356-be9d-2d4aa59caabb 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=85KPCJRDket6J5WaevzvN9WntHNCxbXkPkfTLkLbIWw=; b=ILt2LJXPmDifrF/NE1OgmCB1n5Pbw/1VjGPNgycVf0ZSzAPKT9sjpExW3Ho+HjLRLE iuR7oLxUoUydCS+PVSmFxN8w8lo0hlAuzpAeYWS2WZ4INrB2lYU1nP+fkrseuJFxv6RV 6lzBWkBGbAxUo/1bnkq7sZdciR/ZvSOf5ozgx/gvwKtUBJXfEutMPjd8puh0s2g+xK/I 0+a/xEX1TKU8WC47fs/we4F+vosZWDqhuy4gnZ87tPbMzUyDCLD+AXKPqpKQUV57u9Jn w3MPcJI4Qrcexpqb6MSluMLXlkQkLzJKQ9/wAgVtj4ED9DWiK/dVK6JkPLWp7uOvefwz zo9A== 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=85KPCJRDket6J5WaevzvN9WntHNCxbXkPkfTLkLbIWw=; b=bI4BiolphmsuOT602TbxgYlAAbJcJNlQ5WFUrLOdVQ3KfeSkEwIsCW1FQiK18MiWi6 iZoPaF68PI3fNWU7/IaJwxpFj3Iy2GauPIzadQDuC/poqvn/NL0HT+X2RuCPncX05OFM 1i+/U6TzeV2nyhXpDqtdb/fXTZj8O5N7rW66OST247SHL+0ZUccjIIk5IQTr5PRUViQ4 zrtZ57A+O5jcGi8Ea+kdnUTdGtsUsgN2dDf+zvBhmlzDzg2yBYKlGDiE6VMncT0T68Z1 UO7J8maZgV1Bd0tUCW9a4rjpfKRJDdgbeh3h0l6Jf6cjYrC95ybwlXaK3nmBiOEIqKoS 76zA== X-Gm-Message-State: AOAM531qKCjLeDbzOqdL1lNHdRMQvTnHBm0LqZpGGWbrmqf9Ckv02XTE 8Fj9v5Hvgl1vkG/k9aAHZIFrC4QzqmSg1A== X-Google-Smtp-Source: ABdhPJzlF0vYZW61JokFIIoU9OrUEJ0HX2WAzsZzupHu8Bv2ozomKot9K2li+V3JLviBRjM8Ohy7WA== X-Received: by 2002:aca:b506:: with SMTP id e6mr23465875oif.178.1622677102912; Wed, 02 Jun 2021 16:38:22 -0700 (PDT) From: Connor Davis To: xen-devel@lists.xenproject.org Cc: Bobby Eshleman , Alistair Francis , Connor Davis , Andrew Cooper , George Dunlap , Ian Jackson , Jan Beulich , Julien Grall , Stefano Stabellini , Wei Liu Subject: [PATCH v7 0/2] Minimal build for RISCV Date: Wed, 2 Jun 2021 17:38:08 -0600 Message-Id: X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Hi all, This series introduces a minimal build for RISCV. It is based on Bobby's previous work from last year[0] rebased onto current Xen. This series provides the patches necessary to get a minimal build working. The build is "minimal" in the sense that it only supports building TARGET=riscv64/head.o. The arch/riscv/riscv64/head.S is just a simple while(1). The first patch is a mod to non-RISCV bits that enable building a config with !CONFIG_HAS_NS16550. The second patch adds the make/Kconfig boilerplate alongside head.S and asm-riscv/config.h (head.S references ENTRY that is defined in asm-riscv/config.h). [0] https://lore.kernel.org/xen-devel/cover.1579615303.git.bobbyeshleman@gmail.com/ Thanks, Connor -- Changes since v6: - Make sure patch versions are consistent Changes since v5: - Added missing A-by from Jan to patch 1 Changes since v4: - Dropped patches 2 and 4 as these have been applied - Moved arch/riscv/head.S to arch/riscv/riscv64/head.S for consistency with ARM. - Added Bob and myself to MAINTAINERS Changes since v3: - Dropped "xen: Fix build when !CONFIG_GRANT_TABLE" since this was applied by Jan - Adjusted Kconfig condition for building NS16550 - Use bool rather than bool_t - Removed riscv memory map, as this should probably be done later once the frametable size is figured out - Consolidated 64-bit #defines in asm-riscv/config.h - Renamed riscv64_defconfig to tiny64_defconfig, added CONFIG_DEBUG and CONFIG_DEBUG_INFO - Fixed logic/alignment/whitespace issues in Kconfig files - Use upstream archlinux riscv64 cross-compiler packages instead of custom built toolchain in docker container Changes since v2: - Reduced number of riscv files added to ease review Changes since v1: - Dropped "xen/sched: Fix build when NR_CPUS == 1" since this was fixed for 4.15 - Moved #ifdef-ary around iommu_enabled to iommu.h - Moved struct grant_table declaration above ifdef CONFIG_GRANT_TABLE instead of defining an empty struct when !CONFIG_GRANT_TABLE -- Connor Davis (2): xen/char: Default HAS_NS16550 to y only for X86 and ARM xen: Add files needed for minimal riscv build MAINTAINERS | 8 +++++ config/riscv64.mk | 5 +++ xen/Makefile | 8 +++-- xen/arch/riscv/Kconfig | 47 +++++++++++++++++++++++++ xen/arch/riscv/Kconfig.debug | 0 xen/arch/riscv/Makefile | 2 ++ xen/arch/riscv/Rules.mk | 0 xen/arch/riscv/arch.mk | 14 ++++++++ xen/arch/riscv/configs/tiny64_defconfig | 13 +++++++ xen/arch/riscv/riscv64/asm-offsets.c | 0 xen/arch/riscv/riscv64/head.S | 6 ++++ xen/drivers/char/Kconfig | 1 + xen/include/asm-riscv/config.h | 47 +++++++++++++++++++++++++ 13 files changed, 149 insertions(+), 2 deletions(-) create mode 100644 config/riscv64.mk create mode 100644 xen/arch/riscv/Kconfig create mode 100644 xen/arch/riscv/Kconfig.debug create mode 100644 xen/arch/riscv/Makefile create mode 100644 xen/arch/riscv/Rules.mk create mode 100644 xen/arch/riscv/arch.mk create mode 100644 xen/arch/riscv/configs/tiny64_defconfig create mode 100644 xen/arch/riscv/riscv64/asm-offsets.c create mode 100644 xen/arch/riscv/riscv64/head.S create mode 100644 xen/include/asm-riscv/config.h -- 2.31.1