All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefano Stabellini <sstabellini@kernel.org>
To: Julien Grall <julien.grall@gmail.com>
Cc: artem_mygaiev@epam.com, lars.kurth@citrix.com,
	Stefano Stabellini <sstabellini@kernel.org>,
	andrii_anisov@epam.com, dfaggioli@suse.com, julien.grall@arm.com,
	xen-devel@lists.xen.org, volodymyr_babchuk@epam.com
Subject: Re: [PATCH v4 08/10] arm: add QEMU, Rcar3 and MPSoC configs
Date: Fri, 1 Jun 2018 13:51:53 -0700 (PDT)	[thread overview]
Message-ID: <alpine.DEB.2.10.1806010842320.23991@sstabellini-ThinkPad-X260> (raw)
In-Reply-To: <CAF3u54BTrLmE6BxvEKA2wdxHbDcHf+Y0DqNvP4xErGYns5x63A@mail.gmail.com>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 5293 bytes --]

On Fri, 1 Jun 2018, Julien Grall wrote:
> Hi Stefano,
> Sorry for formatting.
> 
> On Thu, 31 May 2018, 22:50 Stefano Stabellini, <sstabellini@kernel.org> wrote:
>       Add a "Platform Support" menu with three umbrella kconfig options: QEMU,
>       RCAR3 and MPSOC. They enable the required options for their hardware
>       platform.
> 
> 
> This patch is nothing close to what we discussed. As far as I can tell, the tiny.config will end up to select all the platforms
> with their driver. It will not be possible to deselect the driver selected for a platform afterwards.
> 
> I still think the best if providing a choice list where only one option can be selected. I would like to understand why you
> didn't go this path.

Yes, sorry, I didn't explain why I did this and what I told you on the
call was wrong, adding to the confusion.

First, it is true that `make olddefconfig' is run automatically on any
make target.

Except for `make menuconfig', that's special. If you copy a partial
config (like tiny.config) to .config, then execute `make menuconfig',
the menu gets automatically populated with the missing values using
defaults (as if olddefconfig was run), but it won't automatically save
them to file (fortunately!!).  That means that all the platform options
below (QEMU, RCAR3, MPSOC) will show as selected in the menu, but if the
user deselects two of them, for instance QEMU and RCAR3, the result is
that *only* MPSOC and related options will be written down to the
.config.

The kconfig infrastructure is not as bad as I initially thought :-)
In short, the following steps work:

- copy tiny.config to .config
- make menuconfig -> deselect QEMU and RCAR3, save .config
- as a results the final .config will have:

  CONFIG_MPSOC=y
  CONFIG_HAS_CADENCE_UART=y

but it won't have GICV3, any other platform options, or any other uart
drivers. Moreover, even NR_CPUS will be set correctly:
  
  CONFIG_NR_CPUS=4

I am attaching the .config for MPSOC produced using these steps as a
reference. More on the NR_CPUS topic in my next email reply.


>       In the case of the MPSOC that has a platform file under
>       arch/arm/platforms/, build the file if MPSOC.
> 
>       Signed-off-by: Stefano Stabellini <sstabellini@kernel.org>
>       CC: artem_mygaiev@epam.com
>       CC: volodymyr_babchuk@epam.com
> 
>       ---
>       Changes in v4:
>       - fix GICv3/GICV3
>       - default y to all options
>       - build xilinx-zynqmp if MPSOC
>       ---
>        xen/arch/arm/Kconfig            |  2 ++
>        xen/arch/arm/platforms/Kconfig  | 30 ++++++++++++++++++++++++++++++
>        xen/arch/arm/platforms/Makefile |  2 +-
>        3 files changed, 33 insertions(+), 1 deletion(-)
>        create mode 100644 xen/arch/arm/platforms/Kconfig
> 
>       diff --git a/xen/arch/arm/Kconfig b/xen/arch/arm/Kconfig
>       index 2b87111..75cacfb 100644
>       --- a/xen/arch/arm/Kconfig
>       +++ b/xen/arch/arm/Kconfig
>       @@ -213,6 +213,8 @@ config ARM64_HARDEN_BRANCH_PREDICTOR
>        config ARM32_HARDEN_BRANCH_PREDICTOR
>            def_bool y if ARM_32 && HARDEN_BRANCH_PREDICTOR
> 
>       +source "arch/arm/platforms/Kconfig"
>       +
>        source "common/Kconfig"
> 
>        source "drivers/Kconfig"
>       diff --git a/xen/arch/arm/platforms/Kconfig b/xen/arch/arm/platforms/Kconfig
>       new file mode 100644
>       index 0000000..fea8f9a
>       --- /dev/null
>       +++ b/xen/arch/arm/platforms/Kconfig
>       @@ -0,0 +1,30 @@
>       +menu "Platform Support"
>       +
>       +config QEMU
>       +       bool "QEMU aarch virt machine support"
>       +       default y
>       +       depends on ARM_64
>       +       select GICV3
>       +       select HAS_PL011
>       +       ---help---
>       +       Enable all the required drivers for QEMU aarch64 virt emulated
>       +       machine.
>       +
>       +config RCAR3
>       +       bool "Renesas RCar3 support"
>       +       default y
>       +       depends on ARM_64
>       +       select HAS_SCIF
>       +       ---help---
>       +       Enable all the required drivers for Renesas RCar3
>       +
>       +config MPSOC
>       +       bool "Xilinx Ultrascale+ MPSoC support"
>       +       default y
>       +       depends on ARM_64
>       +       select HAS_CADENCE_UART
>       +       select ARM_SMMU
>       +       ---help---
>       +       Enable all the required drivers for Xilinx Ultrascale+ MPSoC
>       +
>       +endmenu
>       diff --git a/xen/arch/arm/platforms/Makefile b/xen/arch/arm/platforms/Makefile
>       index 80e555c..f4ff411 100644
>       --- a/xen/arch/arm/platforms/Makefile
>       +++ b/xen/arch/arm/platforms/Makefile
>       @@ -8,4 +8,4 @@ obj-$(CONFIG_ARM_64) += seattle.o
>        obj-y += sunxi.o
>        obj-$(CONFIG_ARM_64) += thunderx.o
>        obj-$(CONFIG_ARM_64) += xgene-storm.o
>       -obj-$(CONFIG_ARM_64) += xilinx-zynqmp.o
>       +obj-$(CONFIG_MPSOC)  += xilinx-zynqmp.o
>       --
>       1.9.1
> 
> 
>       _______________________________________________
>       Xen-devel mailing list
>       Xen-devel@lists.xenproject.org
>       https://lists.xenproject.org/mailman/listinfo/xen-devel
> 
> 
> 

[-- Attachment #2: Type: TEXT/PLAIN, Size: 1875 bytes --]

#
# Automatically generated file; DO NOT EDIT.
# Xen/arm 4.11-unstable Configuration
#
CONFIG_64BIT=y
CONFIG_ARM_64=y
CONFIG_ARM=y
CONFIG_ARCH_DEFCONFIG="arch/arm/configs/arm64_defconfig"

#
# Architecture Features
#
CONFIG_NR_CPUS=4
# CONFIG_ACPI is not set
# CONFIG_GICV3 is not set
# CONFIG_NEW_VGIC is not set
# CONFIG_SBSA_VUART_CONSOLE is not set

#
# ARM errata workaround via the alternative framework
#
CONFIG_ARM64_ERRATUM_827319=y
CONFIG_ARM64_ERRATUM_824069=y
CONFIG_ARM64_ERRATUM_819472=y
CONFIG_ARM64_ERRATUM_832075=y
CONFIG_ARM64_ERRATUM_834220=y
CONFIG_HARDEN_BRANCH_PREDICTOR=y
CONFIG_ARM64_HARDEN_BRANCH_PREDICTOR=y

#
# Platform Support
#
# CONFIG_QEMU is not set
# CONFIG_RCAR3 is not set
CONFIG_MPSOC=y

#
# Common Features
#
CONFIG_HAS_ALTERNATIVE=y
CONFIG_HAS_DEVICE_TREE=y
# CONFIG_MEM_ACCESS is not set
CONFIG_HAS_PDX=y
# CONFIG_TMEM is not set
# CONFIG_XSM is not set

#
# Schedulers
#
CONFIG_SCHED_CREDIT=y
# CONFIG_SCHED_CREDIT2 is not set
# CONFIG_SCHED_RTDS is not set
# CONFIG_SCHED_ARINC653 is not set
CONFIG_SCHED_NULL=y
# CONFIG_SCHED_CREDIT_DEFAULT is not set
CONFIG_SCHED_NULL_DEFAULT=y
CONFIG_SCHED_DEFAULT="null"
# CONFIG_LIVEPATCH is not set
# CONFIG_SUPPRESS_DUPLICATE_SYMBOL_WARNINGS is not set
CONFIG_CMDLINE=""

#
# Device Drivers
#
# CONFIG_HAS_NS16550 is not set
CONFIG_HAS_CADENCE_UART=y
# CONFIG_HAS_MVEBU is not set
# CONFIG_HAS_PL011 is not set
# CONFIG_HAS_SCIF is not set
CONFIG_HAS_PASSTHROUGH=y
CONFIG_ARM_SMMU=y
CONFIG_DEFCONFIG_LIST="$ARCH_DEFCONFIG"

#
# Debugging Options
#
# CONFIG_DEBUG is not set
# CONFIG_FRAME_POINTER is not set
# CONFIG_COVERAGE is not set
# CONFIG_LOCK_PROFILE is not set
# CONFIG_PERF_COUNTERS is not set
# CONFIG_VERBOSE_DEBUG is not set
# CONFIG_DEVICE_TREE_DEBUG is not set
# CONFIG_SCRUB_DEBUG is not set

[-- Attachment #3: Type: text/plain, Size: 157 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

  reply	other threads:[~2018-06-01 20:51 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-31 21:48 [PATCH v4 0/10] arm: more kconfig configurability and small default configs Stefano Stabellini
2018-05-31 21:48 ` [PATCH v4 01/10] arm: remove the ARM HDLCD driver Stefano Stabellini
2018-05-31 21:48 ` [PATCH v4 02/10] arm: make it possible to disable HAS_GICV3 Stefano Stabellini
2018-05-31 21:48 ` [PATCH v4 03/10] arm: rename HAS_GICV3 to GICV3 Stefano Stabellini
2018-05-31 21:48 ` [PATCH v4 04/10] Make MEM_ACCESS configurable Stefano Stabellini
2018-06-01 10:52   ` Jan Beulich
2018-06-01 15:24     ` Stefano Stabellini
2018-06-01 15:42       ` Jan Beulich
2018-05-31 21:48 ` [PATCH v4 05/10] make it possible to enable/disable UART drivers Stefano Stabellini
2018-06-01 10:54   ` Jan Beulich
2018-06-01 15:28     ` Stefano Stabellini
2018-06-01 15:44       ` Jan Beulich
2018-05-31 21:48 ` [PATCH v4 06/10] arm: make it possible to disable the SMMU driver Stefano Stabellini
2018-05-31 21:48 ` [PATCH v4 07/10] arm: add a tiny kconfig configuration Stefano Stabellini
2018-06-01  2:39   ` Julien Grall
2018-06-01 20:51     ` Stefano Stabellini
2018-05-31 21:48 ` [PATCH v4 08/10] arm: add QEMU, Rcar3 and MPSoC configs Stefano Stabellini
2018-06-01  2:45   ` Julien Grall
2018-06-01 20:51     ` Stefano Stabellini [this message]
2018-06-04 15:58       ` Julien Grall
2018-06-01 11:38   ` Volodymyr Babchuk
2018-05-31 21:48 ` [PATCH v4 09/10] xen: add cloc target Stefano Stabellini
2018-06-01 10:57   ` Jan Beulich
2018-05-31 21:48 ` [PATCH v4 10/10] xen: add per-platform defaults for NR_CPUS Stefano Stabellini
2018-06-01  2:49   ` Julien Grall
2018-06-01 20:53     ` Stefano Stabellini
2018-06-04 16:07       ` Julien Grall
2018-06-01 10:59   ` Jan Beulich
2018-06-01 20:52     ` Stefano Stabellini
2018-06-01 19:17 ` [PATCH v4 0/10] arm: more kconfig configurability and small default configs Doug Goldstein

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.DEB.2.10.1806010842320.23991@sstabellini-ThinkPad-X260 \
    --to=sstabellini@kernel.org \
    --cc=andrii_anisov@epam.com \
    --cc=artem_mygaiev@epam.com \
    --cc=dfaggioli@suse.com \
    --cc=julien.grall@arm.com \
    --cc=julien.grall@gmail.com \
    --cc=lars.kurth@citrix.com \
    --cc=volodymyr_babchuk@epam.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.