kernel-janitors.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/6] Remove CONFIG_EMBEDDED
@ 2022-09-08 10:43 Lukas Bulwahn
  2022-09-08 10:43 ` [PATCH 1/6] arm: make config ARM_PATCH_PHYS_VIRT visible with EXPERT Lukas Bulwahn
                   ` (6 more replies)
  0 siblings, 7 replies; 20+ messages in thread
From: Lukas Bulwahn @ 2022-09-08 10:43 UTC (permalink / raw)
  To: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, Mauro Carvalho Chehab,
	linux-media, Peter Chen, Greg Kroah-Hartman, linux-usb,
	Andrew Morton, Mike Rapoport, linux-mm, Masahiro Yamada,
	linux-kbuild
  Cc: kernel-janitors, linux-kernel, Lukas Bulwahn

Dear all,


While attempting to configure the kernel build, I encountered the option
CONFIG_EMBEDDED and I wondered what this option was all about:

config EMBEDDED
	bool "Embedded system"
	select EXPERT
	help
	  This option should be enabled if compiling the kernel for
	  an embedded system so certain expert options are available
	  for configuration.

In the end, I hopefully understood its history, evolution and all the
consequences, but I concluded that there is no point for anyone else in the
future to try to untangle the riddle behind this option, as I did in the
last few hours. It is much easier to just remove this whole riddle from the
kernel build configuration.

The story all starts with commit 6a108a14fa35 ("kconfig: rename
CONFIG_EMBEDDED to CONFIG_EXPERT").

Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
and just gives that intent a much better name. That has been clearly a good
and long overdue renaming, and it is clearly an improvement to the kernel
build configuration that has shown to help managing the kernel build
configuration in the last decade.

However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
open for future contributors to implement that intended semantics:

    A new CONFIG_EMBEDDED option is added that automatically selects
    CONFIG_EXPERT when enabled and can be used in the future to isolate
    options that should only be considered for embedded systems (RISC
    architectures, SLOB, etc).

Since then, this CONFIG_EMBEDDED implicitly had two purposes:

  - It can make even more options visible beyond what CONFIG_EXPERT makes
    visible. In other words, it may introduce another level of enabling the
    visibility of configuration options: always visible, visible with
    CONFIG_EXPERT and visible with CONFIG_EMBEDDED.

  - Set certain default values of some configurations differently,
    following the assumption that configuring a kernel build for an
    embedded system generally starts with a different set of default values
    compared to kernel builds for all other kind of systems.

Considering the first purpose, at the point in time where CONFIG_EMBEDDED
was renamed to CONFIG_EXPERT, CONFIG_EXPERT already made 130 more options
become visible throughout all different menus for the kernel configuration.
Over the last decade, this has gradually increased, so that currently, with
CONFIG_EXPERT, roughly 170 more options become visible throughout all
different menus for the kernel configuration. In comparison, currently with
CONFIG_EMBEDDED enabled, just seven more options are visible, one in x86,
one in arm, and five for the ChipIdea Highspeed Dual Role Controller.

As the numbers suggest, these two levels of enabling the visibility of even
more configuration options---beyond what CONFIG_EXPERT enables---never
evolved to a good solution in the last decade. In other words, this
additional level of visibility of configuration option with CONFIG_EMBEDDED
compared to CONFIG_EXPERT has since its introduction never become really
valuable. It requires quite some investigation to actually understand what
is additionally visible and it does not differ significantly in complexity
compared to just enabling CONFIG_EXPERT. This CONFIG_EMBEDDED---or any
other config to show more detailed options beyond CONFIG_EXPERT---is
unlikely to be valuable unless somebody puts significant effort in
identifying how such visibility options can be properly split and creating
clear criteria, when some config option is visible with CONFIG_EXPERT and
when some config option is visible only with some further option enabled
beyond CONFIG_EXPERT, such as CONFIG_EMBEDDED attempted to do. For now, it
is much more reasonable to simply make those additional seven options that
visible with CONFIG_EMBEDDED, visible with CONFIG_EXPERT, and then remove
CONFIG_EMBEDDED. If anyone spends significant effort in structuring the
visibility of config options, they may re-introduce suitable new config
options simply as they see fit.

Considering the second purpose, note that already probably arguing that a
kernel build for an embedded system would choose some values differently is
already tricky: the set of embedded systems with Linux kernels is already
quite diverse. Many embedded system have powerful CPUs and it would not be
clear that all embedded systems just optimize towards one specific aspect,
e.g., a smaller kernel image size. So, it is unclear if starting with "one
set of default configuration" that is induced by CONFIG_EMBEDDED is a good
offer for developers configuring their kernels.

Also, the differences of needed user-space features in an embedded system
compared to a non-embedded system are probably difficult or even impossible
to name in some generic way.

So it is not surprising that in the last decade hardly anyone has
contributed changes to make something default differently in case of
CONFIG_EMBEDDED=y.

Currently, in v6.0-rc4, SECRETMEM is the only config switched off if
CONFIG_EMBEDDED=y.

As long as that is actually the only option that currently is selected or
deselected, it is better to just make SECRETMEM configurable at build time
by experts using menuconfig instead.


In summary, in the last decade, CONFIG_EMBEDDED never lived up to its
intended purpose defined above. Let us delete this config and live happily
ever after. It is needless to say that the kernel build configuration is
still highly complex, removing one needless bit of complexity might not
make a big difference, but let us get one bit of complexity out of the way
for good.

Patches 1 to 4 make the additional config options, that are visible with
CONFIG_EMBEDDED, visible with CONFIG_EXPERT instead.

Patch 5 makes secretmem configurable and visible with CONFIG_EXPERT.

Patch 6 finally removes the CONFIG_EMBEDDED, as it not used anymore
throughout the tree.

I am happy to get some feedback on this patch series.


For these minor changes in a few subsystems, I would hope that:

  Patch "arm: make config ARM_PATCH_PHYS_VIRT visible with EXPERT"
    is picked by arm architecture maintainer Russell King.

  Patch "x86: make config X86_FEATURE_NAMES visible with EXPERT"
    is picked by x86 architecture maintainers.

  Patch "media: remove reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER"
    is picked by media maintainer Mauro Carvalho Chehab.

  Patch "usb: chipidea: make configs for glue drivers visible with EXPERT"
    is picked by Peter Chen or usb maintainer Greg Kroah-Hartman.

  Patch "mm: Kconfig: make config SECRETMEM visible with EXPERT"
    is acked by Mike Rapoport, and
    is picked by mm maintainer Andrew Morton.

Once all of these patches above have been merged to mainline:

  Patch "init/Kconfig: remove confusing config EMBEDDED"
    can probably just be picked by the kbuild maintainer Masahiro


Best regards,

Lukas


Lukas Bulwahn (6):
  arm: make config ARM_PATCH_PHYS_VIRT visible with EXPERT
  x86: make config X86_FEATURE_NAMES visible with EXPERT
  media: remove reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER
  usb: chipidea: make configs for glue drivers visible with EXPERT
  mm: Kconfig: make config SECRETMEM visible with EXPERT
  init/Kconfig: remove confusing config EMBEDDED

 arch/arm/Kconfig             |  2 +-
 arch/x86/Kconfig             |  2 +-
 drivers/media/Kconfig        |  2 +-
 drivers/usb/chipidea/Kconfig | 10 +++++-----
 init/Kconfig                 |  8 --------
 mm/Kconfig                   |  8 +++++++-
 6 files changed, 15 insertions(+), 17 deletions(-)

-- 
2.17.1


^ permalink raw reply	[flat|nested] 20+ messages in thread

* [PATCH 1/6] arm: make config ARM_PATCH_PHYS_VIRT visible with EXPERT
  2022-09-08 10:43 [PATCH 0/6] Remove CONFIG_EMBEDDED Lukas Bulwahn
@ 2022-09-08 10:43 ` Lukas Bulwahn
  2022-09-09  6:21   ` Masahiro Yamada
  2022-09-08 10:43 ` [PATCH 2/6] x86: make config X86_FEATURE_NAMES " Lukas Bulwahn
                   ` (5 subsequent siblings)
  6 siblings, 1 reply; 20+ messages in thread
From: Lukas Bulwahn @ 2022-09-08 10:43 UTC (permalink / raw)
  To: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, Mauro Carvalho Chehab,
	linux-media, Peter Chen, Greg Kroah-Hartman, linux-usb,
	Andrew Morton, Mike Rapoport, linux-mm, Masahiro Yamada,
	linux-kbuild
  Cc: kernel-janitors, linux-kernel, Lukas Bulwahn

Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
and just gives that intent a much better name. That has been clearly a good
and long overdue renaming, and it is clearly an improvement to the kernel
build configuration that has shown to help managing the kernel build
configuration in the last decade.

However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
open for future contributors to implement that intended semantics:

    A new CONFIG_EMBEDDED option is added that automatically selects
    CONFIG_EXPERT when enabled and can be used in the future to isolate
    options that should only be considered for embedded systems (RISC
    architectures, SLOB, etc).

Since then, this CONFIG_EMBEDDED implicitly had two purposes:

  - It can make even more options visible beyond what CONFIG_EXPERT makes
    visible. In other words, it may introduce another level of enabling the
    visibility of configuration options: always visible, visible with
    CONFIG_EXPERT and visible with CONFIG_EMBEDDED.

  - Set certain default values of some configurations differently,
    following the assumption that configuring a kernel build for an
    embedded system generally starts with a different set of default values
    compared to kernel builds for all other kind of systems.

Considering the first purpose, at the point in time where CONFIG_EMBEDDED
was renamed to CONFIG_EXPERT, CONFIG_EXPERT already made 130 more options
become visible throughout all different menus for the kernel configuration.
Over the last decade, this has gradually increased, so that currently, with
CONFIG_EXPERT, roughly 170 more options become visible throughout all
different menus for the kernel configuration. In comparison, currently with
CONFIG_EMBEDDED enabled, just seven more options are visible, one in x86,
one in arm, and five for the ChipIdea Highspeed Dual Role Controller.

As the numbers suggest, these two levels of enabling the visibility of even
more configuration options---beyond what CONFIG_EXPERT enables---never
evolved to a good solution in the last decade. In other words, this
additional level of visibility of configuration option with CONFIG_EMBEDDED
compared to CONFIG_EXPERT has since its introduction never become really
valuable. It requires quite some investigation to actually understand what
is additionally visible and it does not differ significantly in complexity
compared to just enabling CONFIG_EXPERT. This CONFIG_EMBEDDED---or any
other config to show more detailed options beyond CONFIG_EXPERT---is
unlikely to be valuable unless somebody puts significant effort in
identifying how such visibility options can be properly split and creating
clear criteria, when some config option is visible with CONFIG_EXPERT and
when some config option is visible only with some further option enabled
beyond CONFIG_EXPERT, such as CONFIG_EMBEDDED attempted to do. For now, it
is much more reasonable to simply make those additional seven options that
visible with CONFIG_EMBEDDED, visible with CONFIG_EXPERT, and then remove
CONFIG_EMBEDDED. If anyone spends significant effort in structuring the
visibility of config options, they may re-introduce suitable new config
options simply as they see fit.

Make the config ARM_PATCH_PHYS_VIRT visible when CONFIG_EXPERT is enabled.

Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
---
 arch/arm/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 4adfa5dd3556..4b212ab1b281 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -243,7 +243,7 @@ config ARCH_MTD_XIP
 	bool
 
 config ARM_PATCH_PHYS_VIRT
-	bool "Patch physical to virtual translations at runtime" if EMBEDDED
+	bool "Patch physical to virtual translations at runtime" if EXPERT
 	default y
 	depends on !XIP_KERNEL && MMU
 	help
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [PATCH 2/6] x86: make config X86_FEATURE_NAMES visible with EXPERT
  2022-09-08 10:43 [PATCH 0/6] Remove CONFIG_EMBEDDED Lukas Bulwahn
  2022-09-08 10:43 ` [PATCH 1/6] arm: make config ARM_PATCH_PHYS_VIRT visible with EXPERT Lukas Bulwahn
@ 2022-09-08 10:43 ` Lukas Bulwahn
  2022-09-09  6:22   ` Masahiro Yamada
  2022-09-08 10:43 ` [PATCH 3/6] media: remove reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER Lukas Bulwahn
                   ` (4 subsequent siblings)
  6 siblings, 1 reply; 20+ messages in thread
From: Lukas Bulwahn @ 2022-09-08 10:43 UTC (permalink / raw)
  To: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, Mauro Carvalho Chehab,
	linux-media, Peter Chen, Greg Kroah-Hartman, linux-usb,
	Andrew Morton, Mike Rapoport, linux-mm, Masahiro Yamada,
	linux-kbuild
  Cc: kernel-janitors, linux-kernel, Lukas Bulwahn

Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
and just gives that intent a much better name. That has been clearly a good
and long overdue renaming, and it is clearly an improvement to the kernel
build configuration that has shown to help managing the kernel build
configuration in the last decade.

However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
open for future contributors to implement that intended semantics:

    A new CONFIG_EMBEDDED option is added that automatically selects
    CONFIG_EXPERT when enabled and can be used in the future to isolate
    options that should only be considered for embedded systems (RISC
    architectures, SLOB, etc).

Since then, this CONFIG_EMBEDDED implicitly had two purposes:

  - It can make even more options visible beyond what CONFIG_EXPERT makes
    visible. In other words, it may introduce another level of enabling the
    visibility of configuration options: always visible, visible with
    CONFIG_EXPERT and visible with CONFIG_EMBEDDED.

  - Set certain default values of some configurations differently,
    following the assumption that configuring a kernel build for an
    embedded system generally starts with a different set of default values
    compared to kernel builds for all other kind of systems.

Considering the first purpose, at the point in time where CONFIG_EMBEDDED
was renamed to CONFIG_EXPERT, CONFIG_EXPERT already made 130 more options
become visible throughout all different menus for the kernel configuration.
Over the last decade, this has gradually increased, so that currently, with
CONFIG_EXPERT, roughly 170 more options become visible throughout all
different menus for the kernel configuration. In comparison, currently with
CONFIG_EMBEDDED enabled, just seven more options are visible, one in x86,
one in arm, and five for the ChipIdea Highspeed Dual Role Controller.

As the numbers suggest, these two levels of enabling the visibility of even
more configuration options---beyond what CONFIG_EXPERT enables---never
evolved to a good solution in the last decade. In other words, this
additional level of visibility of configuration option with CONFIG_EMBEDDED
compared to CONFIG_EXPERT has since its introduction never become really
valuable. It requires quite some investigation to actually understand what
is additionally visible and it does not differ significantly in complexity
compared to just enabling CONFIG_EXPERT. This CONFIG_EMBEDDED---or any
other config to show more detailed options beyond CONFIG_EXPERT---is
unlikely to be valuable unless somebody puts significant effort in
identifying how such visibility options can be properly split and creating
clear criteria, when some config option is visible with CONFIG_EXPERT and
when some config option is visible only with some further option enabled
beyond CONFIG_EXPERT, such as CONFIG_EMBEDDED attempted to do. For now, it
is much more reasonable to simply make those additional seven options that
visible with CONFIG_EMBEDDED, visible with CONFIG_EXPERT, and then remove
CONFIG_EMBEDDED. If anyone spends significant effort in structuring the
visibility of config options, they may re-introduce suitable new config
options simply as they see fit.

Make the config X86_FEATURE_NAMES visible when CONFIG_EXPERT is enabled.

Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
---
 arch/x86/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index 2ec0b1eabe86..7807eb1c8df8 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -438,7 +438,7 @@ config SMP
 	  If you don't know what to do here, say N.
 
 config X86_FEATURE_NAMES
-	bool "Processor feature human-readable names" if EMBEDDED
+	bool "Processor feature human-readable names" if EXPERT
 	default y
 	help
 	  This option compiles in a table of x86 feature bits and corresponding
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [PATCH 3/6] media: remove reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER
  2022-09-08 10:43 [PATCH 0/6] Remove CONFIG_EMBEDDED Lukas Bulwahn
  2022-09-08 10:43 ` [PATCH 1/6] arm: make config ARM_PATCH_PHYS_VIRT visible with EXPERT Lukas Bulwahn
  2022-09-08 10:43 ` [PATCH 2/6] x86: make config X86_FEATURE_NAMES " Lukas Bulwahn
@ 2022-09-08 10:43 ` Lukas Bulwahn
  2022-09-08 11:13   ` Mauro Carvalho Chehab
  2022-09-08 10:43 ` [PATCH 4/6] usb: chipidea: make configs for glue drivers visible with EXPERT Lukas Bulwahn
                   ` (3 subsequent siblings)
  6 siblings, 1 reply; 20+ messages in thread
From: Lukas Bulwahn @ 2022-09-08 10:43 UTC (permalink / raw)
  To: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, Mauro Carvalho Chehab,
	linux-media, Peter Chen, Greg Kroah-Hartman, linux-usb,
	Andrew Morton, Mike Rapoport, linux-mm, Masahiro Yamada,
	linux-kbuild
  Cc: kernel-janitors, linux-kernel, Lukas Bulwahn

The config EMBEDDED selects EXPERT, i.e., when EMBEDDED is enabled, EXPERT
is usually also enabled. Hence, it sufficient to have the option
MEDIA_SUPPORT_FILTER set to y if !EXPERT.

This way, MEDIA_SUPPORT_FILTER does not refer to CONFIG_EMBEDDED anymore
and allows us to remove CONFIG_EMBEDDED in the close future.

Remove the reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER.

Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
---
 drivers/media/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/media/Kconfig b/drivers/media/Kconfig
index ba6592b3dab2..283b78b5766e 100644
--- a/drivers/media/Kconfig
+++ b/drivers/media/Kconfig
@@ -24,7 +24,7 @@ if MEDIA_SUPPORT
 
 config MEDIA_SUPPORT_FILTER
 	bool "Filter media drivers"
-	default y if !EMBEDDED && !EXPERT
+	default y if !EXPERT
 	help
 	   Configuring the media subsystem can be complex, as there are
 	   hundreds of drivers and other config options.
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [PATCH 4/6] usb: chipidea: make configs for glue drivers visible with EXPERT
  2022-09-08 10:43 [PATCH 0/6] Remove CONFIG_EMBEDDED Lukas Bulwahn
                   ` (2 preceding siblings ...)
  2022-09-08 10:43 ` [PATCH 3/6] media: remove reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER Lukas Bulwahn
@ 2022-09-08 10:43 ` Lukas Bulwahn
  2022-09-08 11:33   ` Greg Kroah-Hartman
  2022-09-08 10:43 ` [PATCH 5/6] mm: Kconfig: make config SECRETMEM " Lukas Bulwahn
                   ` (2 subsequent siblings)
  6 siblings, 1 reply; 20+ messages in thread
From: Lukas Bulwahn @ 2022-09-08 10:43 UTC (permalink / raw)
  To: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, Mauro Carvalho Chehab,
	linux-media, Peter Chen, Greg Kroah-Hartman, linux-usb,
	Andrew Morton, Mike Rapoport, linux-mm, Masahiro Yamada,
	linux-kbuild
  Cc: kernel-janitors, linux-kernel, Lukas Bulwahn

Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
and just gives that intent a much better name. That has been clearly a good
and long overdue renaming, and it is clearly an improvement to the kernel
build configuration that has shown to help managing the kernel build
configuration in the last decade.

However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
open for future contributors to implement that intended semantics:

    A new CONFIG_EMBEDDED option is added that automatically selects
    CONFIG_EXPERT when enabled and can be used in the future to isolate
    options that should only be considered for embedded systems (RISC
    architectures, SLOB, etc).

Since then, this CONFIG_EMBEDDED implicitly had two purposes:

  - It can make even more options visible beyond what CONFIG_EXPERT makes
    visible. In other words, it may introduce another level of enabling the
    visibility of configuration options: always visible, visible with
    CONFIG_EXPERT and visible with CONFIG_EMBEDDED.

  - Set certain default values of some configurations differently,
    following the assumption that configuring a kernel build for an
    embedded system generally starts with a different set of default values
    compared to kernel builds for all other kind of systems.

Considering the first purpose, at the point in time where CONFIG_EMBEDDED
was renamed to CONFIG_EXPERT, CONFIG_EXPERT already made 130 more options
become visible throughout all different menus for the kernel configuration.
Over the last decade, this has gradually increased, so that currently, with
CONFIG_EXPERT, roughly 170 more options become visible throughout all
different menus for the kernel configuration. In comparison, currently with
CONFIG_EMBEDDED enabled, just seven more options are visible, one in x86,
one in arm, and five for the ChipIdea Highspeed Dual Role Controller.

As the numbers suggest, these two levels of enabling the visibility of even
more configuration options---beyond what CONFIG_EXPERT enables---never
evolved to a good solution in the last decade. In other words, this
additional level of visibility of configuration option with CONFIG_EMBEDDED
compared to CONFIG_EXPERT has since its introduction never become really
valuable. It requires quite some investigation to actually understand what
is additionally visible and it does not differ significantly in complexity
compared to just enabling CONFIG_EXPERT. This CONFIG_EMBEDDED---or any
other config to show more detailed options beyond CONFIG_EXPERT---is
unlikely to be valuable unless somebody puts significant effort in
identifying how such visibility options can be properly split and creating
clear criteria, when some config option is visible with CONFIG_EXPERT and
when some config option is visible only with some further option enabled
beyond CONFIG_EXPERT, such as CONFIG_EMBEDDED attempted to do. For now, it
is much more reasonable to simply make those additional seven options that
visible with CONFIG_EMBEDDED, visible with CONFIG_EXPERT, and then remove
CONFIG_EMBEDDED. If anyone spends significant effort in structuring the
visibility of config options, they may re-introduce suitable new config
options simply as they see fit.

Make the configs for usb chipidea glue drivers visible when CONFIG_EXPERT
is enabled.

Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
---
 drivers/usb/chipidea/Kconfig | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/usb/chipidea/Kconfig b/drivers/usb/chipidea/Kconfig
index 661818e8fed6..c815824a0b2d 100644
--- a/drivers/usb/chipidea/Kconfig
+++ b/drivers/usb/chipidea/Kconfig
@@ -34,26 +34,26 @@ config USB_CHIPIDEA_HOST
 	  ChipIdea driver.
 
 config USB_CHIPIDEA_PCI
-	tristate "Enable PCI glue driver" if EMBEDDED
+	tristate "Enable PCI glue driver" if EXPERT
 	depends on USB_PCI
 	depends on NOP_USB_XCEIV
 	default USB_CHIPIDEA
 
 config USB_CHIPIDEA_MSM
-	tristate "Enable MSM hsusb glue driver" if EMBEDDED
+	tristate "Enable MSM hsusb glue driver" if EXPERT
 	default USB_CHIPIDEA
 
 config USB_CHIPIDEA_IMX
-	tristate "Enable i.MX USB glue driver" if EMBEDDED
+	tristate "Enable i.MX USB glue driver" if EXPERT
 	depends on OF
 	default USB_CHIPIDEA
 
 config USB_CHIPIDEA_GENERIC
-	tristate "Enable generic USB2 glue driver" if EMBEDDED
+	tristate "Enable generic USB2 glue driver" if EXPERT
 	default USB_CHIPIDEA
 
 config USB_CHIPIDEA_TEGRA
-	tristate "Enable Tegra USB glue driver" if EMBEDDED
+	tristate "Enable Tegra USB glue driver" if EXPERT
 	depends on OF
 	default USB_CHIPIDEA
 
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [PATCH 5/6] mm: Kconfig: make config SECRETMEM visible with EXPERT
  2022-09-08 10:43 [PATCH 0/6] Remove CONFIG_EMBEDDED Lukas Bulwahn
                   ` (3 preceding siblings ...)
  2022-09-08 10:43 ` [PATCH 4/6] usb: chipidea: make configs for glue drivers visible with EXPERT Lukas Bulwahn
@ 2022-09-08 10:43 ` Lukas Bulwahn
  2022-09-08 11:24   ` Mike Rapoport
  2022-09-08 10:43 ` [PATCH 6/6] init/Kconfig: remove confusing config EMBEDDED Lukas Bulwahn
  2022-09-08 15:21 ` [PATCH 0/6] Remove CONFIG_EMBEDDED Arnd Bergmann
  6 siblings, 1 reply; 20+ messages in thread
From: Lukas Bulwahn @ 2022-09-08 10:43 UTC (permalink / raw)
  To: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, Mauro Carvalho Chehab,
	linux-media, Peter Chen, Greg Kroah-Hartman, linux-usb,
	Andrew Morton, Mike Rapoport, linux-mm, Masahiro Yamada,
	linux-kbuild
  Cc: kernel-janitors, linux-kernel, Lukas Bulwahn

Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
and just gives that intent a much better name. That has been clearly a good
and long overdue renaming, and it is clearly an improvement to the kernel
build configuration that has shown to help managing the kernel build
configuration in the last decade.

However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
open for future contributors to implement that intended semantics:

    A new CONFIG_EMBEDDED option is added that automatically selects
    CONFIG_EXPERT when enabled and can be used in the future to isolate
    options that should only be considered for embedded systems (RISC
    architectures, SLOB, etc).

Since then, this CONFIG_EMBEDDED implicitly had two purposes:

  - It can make even more options visible beyond what CONFIG_EXPERT makes
    visible. In other words, it may introduce another level of enabling the
    visibility of configuration options: always visible, visible with
    CONFIG_EXPERT and visible with CONFIG_EMBEDDED.

  - Set certain default values of some configurations differently,
    following the assumption that configuring a kernel build for an
    embedded system generally starts with a different set of default values
    compared to kernel builds for all other kind of systems.

Considering the second purpose, note that already probably arguing that a
kernel build for an embedded system would choose some values differently is
already tricky: the set of embedded systems with Linux kernels is already
quite diverse. Many embedded system have powerful CPUs and it would not be
clear that all embedded systems just optimize towards one specific aspect,
e.g., a smaller kernel image size. So, it is unclear if starting with "one
set of default configuration" that is induced by CONFIG_EMBEDDED is a good
offer for developers configuring their kernels.

Also, the differences of needed user-space features in an embedded system
compared to a non-embedded system are probably difficult or even impossible
to name in some generic way.

So it is not surprising that in the last decade hardly anyone has
contributed changes to make something default differently in case of
CONFIG_EMBEDDED=y.

Currently, in v6.0-rc4, SECRETMEM is the only config switched off if
CONFIG_EMBEDDED=y.

As long as that is actually the only option that currently is selected or
deselected, it is better to just make SECRETMEM configurable at build time
by experts using menuconfig instead.

Make SECRETMEM configurable when EXPERT is set and otherwise default to
yes. Further, SECRETMEM needs ARCH_HAS_SET_DIRECT_MAP.

This allows us to remove CONFIG_EMBEDDED in the close future.

Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
---
 mm/Kconfig | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/mm/Kconfig b/mm/Kconfig
index ceec438c0741..aa154c20b129 100644
--- a/mm/Kconfig
+++ b/mm/Kconfig
@@ -1068,7 +1068,13 @@ config IO_MAPPING
 	bool
 
 config SECRETMEM
-	def_bool ARCH_HAS_SET_DIRECT_MAP && !EMBEDDED
+	default y
+	bool "Enable memfd_secret() system call" if EXPERT
+	depends on ARCH_HAS_SET_DIRECT_MAP
+	help
+	  Enable the memfd_secret() system call with the ability to create
+	  memory areas visible only in the context of the owning process and
+	  not mapped to other processes and other kernel page tables.
 
 config ANON_VMA_NAME
 	bool "Anonymous VMA name support"
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [PATCH 6/6] init/Kconfig: remove confusing config EMBEDDED
  2022-09-08 10:43 [PATCH 0/6] Remove CONFIG_EMBEDDED Lukas Bulwahn
                   ` (4 preceding siblings ...)
  2022-09-08 10:43 ` [PATCH 5/6] mm: Kconfig: make config SECRETMEM " Lukas Bulwahn
@ 2022-09-08 10:43 ` Lukas Bulwahn
  2022-09-09  6:24   ` Masahiro Yamada
  2022-09-09  9:23   ` Christophe Leroy
  2022-09-08 15:21 ` [PATCH 0/6] Remove CONFIG_EMBEDDED Arnd Bergmann
  6 siblings, 2 replies; 20+ messages in thread
From: Lukas Bulwahn @ 2022-09-08 10:43 UTC (permalink / raw)
  To: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, Mauro Carvalho Chehab,
	linux-media, Peter Chen, Greg Kroah-Hartman, linux-usb,
	Andrew Morton, Mike Rapoport, linux-mm, Masahiro Yamada,
	linux-kbuild
  Cc: kernel-janitors, linux-kernel, Lukas Bulwahn

Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
and just gives that intent a much better name. That has been clearly a good
and long overdue renaming, and it is clearly an improvement to the kernel
build configuration that has shown to help managing the kernel build
configuration in the last decade.

However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
open for future contributors to implement that intended semantics:

    A new CONFIG_EMBEDDED option is added that automatically selects
    CONFIG_EXPERT when enabled and can be used in the future to isolate
    options that should only be considered for embedded systems (RISC
    architectures, SLOB, etc).

Since then, this CONFIG_EMBEDDED implicitly had two purposes:

  - It can make even more options visible beyond what CONFIG_EXPERT makes
    visible. In other words, it may introduce another level of enabling the
    visibility of configuration options: always visible, visible with
    CONFIG_EXPERT and visible with CONFIG_EMBEDDED.

  - Set certain default values of some configurations differently,
    following the assumption that configuring a kernel build for an
    embedded system generally starts with a different set of default values
    compared to kernel builds for all other kind of systems.

Considering the first purpose, at the point in time where CONFIG_EMBEDDED
was renamed to CONFIG_EXPERT, CONFIG_EXPERT already made 130 more options
become visible throughout all different menus for the kernel configuration.
Over the last decade, this has gradually increased, so that currently, with
CONFIG_EXPERT, roughly 170 more options become visible throughout all
different menus for the kernel configuration. In comparison, currently with
CONFIG_EMBEDDED enabled, just seven more options are visible, one in x86,
one in arm, and five for the ChipIdea Highspeed Dual Role Controller.

As the numbers suggest, these two levels of enabling the visibility of even
more configuration options---beyond what CONFIG_EXPERT enables---never
evolved to a good solution in the last decade. In other words, this
additional level of visibility of configuration option with CONFIG_EMBEDDED
compared to CONFIG_EXPERT has since its introduction never become really
valuable. It requires quite some investigation to actually understand what
is additionally visible and it does not differ significantly in complexity
compared to just enabling CONFIG_EXPERT. This CONFIG_EMBEDDED---or any
other config to show more detailed options beyond CONFIG_EXPERT---is
unlikely to be valuable unless somebody puts significant effort in
identifying how such visibility options can be properly split and creating
clear criteria, when some config option is visible with CONFIG_EXPERT and
when some config option is visible only with some further option enabled
beyond CONFIG_EXPERT, such as CONFIG_EMBEDDED attempted to do. For now, it
is much more reasonable to simply make those additional seven options that
visible with CONFIG_EMBEDDED, visible with CONFIG_EXPERT, and then remove
CONFIG_EMBEDDED. If anyone spends significant effort in structuring the
visibility of config options, they may re-introduce suitable new config
options simply as they see fit.

Hence, all uses of CONFIG_EMBEDDED have been replaced with CONFIG_EXPERT.

Considering the second purpose, note that already probably arguing that a
kernel build for an embedded system would choose some values differently is
already tricky: the set of embedded systems with Linux kernels is already
quite diverse. Many embedded system have powerful CPUs and it would not be
clear that all embedded systems just optimize towards one specific aspect,
e.g., a smaller kernel image size. So, it is unclear if starting with "one
set of default configuration" that is induced by CONFIG_EMBEDDED is a good
offer for developers configuring their kernels.

Also, the differences of needed user-space features in an embedded system
compared to a non-embedded system are probably difficult or even impossible
to name in some generic way.

So it is not surprising that in the last decade hardly anyone has
contributed changes to make something default differently in case of
CONFIG_EMBEDDED=y.

In v6.0-rc4, SECRETMEM is the only config switched off if
CONFIG_EMBEDDED=y. That one use was removed as well, SECRETMEM was made
configurable at build time by experts using menuconfig instead.

As there are no further uses of CONFIG_EMBEDDED and CONFIG_EMBEDDED never
lived up to its intended purpose defined above, simply delete this
confusing CONFIG_EMBEDDED.

Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
---
 init/Kconfig | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/init/Kconfig b/init/Kconfig
index 9e3fd79b089c..d7429e0b8cae 100644
--- a/init/Kconfig
+++ b/init/Kconfig
@@ -1818,14 +1818,6 @@ config DEBUG_RSEQ
 
 	  If unsure, say N.
 
-config EMBEDDED
-	bool "Embedded system"
-	select EXPERT
-	help
-	  This option should be enabled if compiling the kernel for
-	  an embedded system so certain expert options are available
-	  for configuration.
-
 config HAVE_PERF_EVENTS
 	bool
 	help
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* Re: [PATCH 3/6] media: remove reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER
  2022-09-08 10:43 ` [PATCH 3/6] media: remove reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER Lukas Bulwahn
@ 2022-09-08 11:13   ` Mauro Carvalho Chehab
  2022-09-08 16:20     ` Mauro Carvalho Chehab
  0 siblings, 1 reply; 20+ messages in thread
From: Mauro Carvalho Chehab @ 2022-09-08 11:13 UTC (permalink / raw)
  To: Lukas Bulwahn
  Cc: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, linux-media, Peter Chen,
	Greg Kroah-Hartman, linux-usb, Andrew Morton, Mike Rapoport,
	linux-mm, Masahiro Yamada, linux-kbuild, kernel-janitors,
	linux-kernel

Em Thu,  8 Sep 2022 12:43:34 +0200
Lukas Bulwahn <lukas.bulwahn@gmail.com> escreveu:

> The config EMBEDDED selects EXPERT, i.e., when EMBEDDED is enabled, EXPERT
> is usually also enabled. Hence, it sufficient to have the option
> MEDIA_SUPPORT_FILTER set to y if !EXPERT.
> 
> This way, MEDIA_SUPPORT_FILTER does not refer to CONFIG_EMBEDDED anymore
> and allows us to remove CONFIG_EMBEDDED in the close future.
> 
> Remove the reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER.
> 
> Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
> ---
>  drivers/media/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/media/Kconfig b/drivers/media/Kconfig
> index ba6592b3dab2..283b78b5766e 100644
> --- a/drivers/media/Kconfig
> +++ b/drivers/media/Kconfig
> @@ -24,7 +24,7 @@ if MEDIA_SUPPORT
>  
>  config MEDIA_SUPPORT_FILTER
>  	bool "Filter media drivers"
> -	default y if !EMBEDDED && !EXPERT
> +	default y if !EXPERT
>  	help
>  	   Configuring the media subsystem can be complex, as there are
>  	   hundreds of drivers and other config options.

Reviewed-by: Mauro Carvalho Chehab <mchehab@kernel.org>

Thanks,
Mauro

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 5/6] mm: Kconfig: make config SECRETMEM visible with EXPERT
  2022-09-08 10:43 ` [PATCH 5/6] mm: Kconfig: make config SECRETMEM " Lukas Bulwahn
@ 2022-09-08 11:24   ` Mike Rapoport
  2022-09-09  6:22     ` Masahiro Yamada
  0 siblings, 1 reply; 20+ messages in thread
From: Mike Rapoport @ 2022-09-08 11:24 UTC (permalink / raw)
  To: Lukas Bulwahn
  Cc: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, Mauro Carvalho Chehab,
	linux-media, Peter Chen, Greg Kroah-Hartman, linux-usb,
	Andrew Morton, linux-mm, Masahiro Yamada, linux-kbuild,
	kernel-janitors, linux-kernel

On Thu, Sep 08, 2022 at 12:43:36PM +0200, Lukas Bulwahn wrote:
> Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
> introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
> and just gives that intent a much better name. That has been clearly a good
> and long overdue renaming, and it is clearly an improvement to the kernel
> build configuration that has shown to help managing the kernel build
> configuration in the last decade.
> 
> However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
> this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
> open for future contributors to implement that intended semantics:
> 
>     A new CONFIG_EMBEDDED option is added that automatically selects
>     CONFIG_EXPERT when enabled and can be used in the future to isolate
>     options that should only be considered for embedded systems (RISC
>     architectures, SLOB, etc).
> 
> Since then, this CONFIG_EMBEDDED implicitly had two purposes:
> 
>   - It can make even more options visible beyond what CONFIG_EXPERT makes
>     visible. In other words, it may introduce another level of enabling the
>     visibility of configuration options: always visible, visible with
>     CONFIG_EXPERT and visible with CONFIG_EMBEDDED.
> 
>   - Set certain default values of some configurations differently,
>     following the assumption that configuring a kernel build for an
>     embedded system generally starts with a different set of default values
>     compared to kernel builds for all other kind of systems.
> 
> Considering the second purpose, note that already probably arguing that a
> kernel build for an embedded system would choose some values differently is
> already tricky: the set of embedded systems with Linux kernels is already
> quite diverse. Many embedded system have powerful CPUs and it would not be
> clear that all embedded systems just optimize towards one specific aspect,
> e.g., a smaller kernel image size. So, it is unclear if starting with "one
> set of default configuration" that is induced by CONFIG_EMBEDDED is a good
> offer for developers configuring their kernels.
> 
> Also, the differences of needed user-space features in an embedded system
> compared to a non-embedded system are probably difficult or even impossible
> to name in some generic way.
> 
> So it is not surprising that in the last decade hardly anyone has
> contributed changes to make something default differently in case of
> CONFIG_EMBEDDED=y.
> 
> Currently, in v6.0-rc4, SECRETMEM is the only config switched off if
> CONFIG_EMBEDDED=y.
> 
> As long as that is actually the only option that currently is selected or
> deselected, it is better to just make SECRETMEM configurable at build time
> by experts using menuconfig instead.
> 
> Make SECRETMEM configurable when EXPERT is set and otherwise default to
> yes. Further, SECRETMEM needs ARCH_HAS_SET_DIRECT_MAP.
> 
> This allows us to remove CONFIG_EMBEDDED in the close future.
> 
> Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>

Acked-by: Mike Rapoport <rppt@linux.ibm.com>

> ---
>  mm/Kconfig | 8 +++++++-
>  1 file changed, 7 insertions(+), 1 deletion(-)
> 
> diff --git a/mm/Kconfig b/mm/Kconfig
> index ceec438c0741..aa154c20b129 100644
> --- a/mm/Kconfig
> +++ b/mm/Kconfig
> @@ -1068,7 +1068,13 @@ config IO_MAPPING
>  	bool
>  
>  config SECRETMEM
> -	def_bool ARCH_HAS_SET_DIRECT_MAP && !EMBEDDED
> +	default y
> +	bool "Enable memfd_secret() system call" if EXPERT
> +	depends on ARCH_HAS_SET_DIRECT_MAP
> +	help
> +	  Enable the memfd_secret() system call with the ability to create
> +	  memory areas visible only in the context of the owning process and
> +	  not mapped to other processes and other kernel page tables.
>  
>  config ANON_VMA_NAME
>  	bool "Anonymous VMA name support"
> -- 
> 2.17.1
> 

-- 
Sincerely yours,
Mike.

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 4/6] usb: chipidea: make configs for glue drivers visible with EXPERT
  2022-09-08 10:43 ` [PATCH 4/6] usb: chipidea: make configs for glue drivers visible with EXPERT Lukas Bulwahn
@ 2022-09-08 11:33   ` Greg Kroah-Hartman
  2022-09-09  6:22     ` Masahiro Yamada
  0 siblings, 1 reply; 20+ messages in thread
From: Greg Kroah-Hartman @ 2022-09-08 11:33 UTC (permalink / raw)
  To: Lukas Bulwahn
  Cc: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, Mauro Carvalho Chehab,
	linux-media, Peter Chen, linux-usb, Andrew Morton, Mike Rapoport,
	linux-mm, Masahiro Yamada, linux-kbuild, kernel-janitors,
	linux-kernel

On Thu, Sep 08, 2022 at 12:43:35PM +0200, Lukas Bulwahn wrote:
> Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
> introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
> and just gives that intent a much better name. That has been clearly a good
> and long overdue renaming, and it is clearly an improvement to the kernel
> build configuration that has shown to help managing the kernel build
> configuration in the last decade.
> 
> However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
> this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
> open for future contributors to implement that intended semantics:
> 
>     A new CONFIG_EMBEDDED option is added that automatically selects
>     CONFIG_EXPERT when enabled and can be used in the future to isolate
>     options that should only be considered for embedded systems (RISC
>     architectures, SLOB, etc).
> 
> Since then, this CONFIG_EMBEDDED implicitly had two purposes:
> 
>   - It can make even more options visible beyond what CONFIG_EXPERT makes
>     visible. In other words, it may introduce another level of enabling the
>     visibility of configuration options: always visible, visible with
>     CONFIG_EXPERT and visible with CONFIG_EMBEDDED.
> 
>   - Set certain default values of some configurations differently,
>     following the assumption that configuring a kernel build for an
>     embedded system generally starts with a different set of default values
>     compared to kernel builds for all other kind of systems.
> 
> Considering the first purpose, at the point in time where CONFIG_EMBEDDED
> was renamed to CONFIG_EXPERT, CONFIG_EXPERT already made 130 more options
> become visible throughout all different menus for the kernel configuration.
> Over the last decade, this has gradually increased, so that currently, with
> CONFIG_EXPERT, roughly 170 more options become visible throughout all
> different menus for the kernel configuration. In comparison, currently with
> CONFIG_EMBEDDED enabled, just seven more options are visible, one in x86,
> one in arm, and five for the ChipIdea Highspeed Dual Role Controller.
> 
> As the numbers suggest, these two levels of enabling the visibility of even
> more configuration options---beyond what CONFIG_EXPERT enables---never
> evolved to a good solution in the last decade. In other words, this
> additional level of visibility of configuration option with CONFIG_EMBEDDED
> compared to CONFIG_EXPERT has since its introduction never become really
> valuable. It requires quite some investigation to actually understand what
> is additionally visible and it does not differ significantly in complexity
> compared to just enabling CONFIG_EXPERT. This CONFIG_EMBEDDED---or any
> other config to show more detailed options beyond CONFIG_EXPERT---is
> unlikely to be valuable unless somebody puts significant effort in
> identifying how such visibility options can be properly split and creating
> clear criteria, when some config option is visible with CONFIG_EXPERT and
> when some config option is visible only with some further option enabled
> beyond CONFIG_EXPERT, such as CONFIG_EMBEDDED attempted to do. For now, it
> is much more reasonable to simply make those additional seven options that
> visible with CONFIG_EMBEDDED, visible with CONFIG_EXPERT, and then remove
> CONFIG_EMBEDDED. If anyone spends significant effort in structuring the
> visibility of config options, they may re-introduce suitable new config
> options simply as they see fit.
> 
> Make the configs for usb chipidea glue drivers visible when CONFIG_EXPERT
> is enabled.
> 
> Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
> ---
>  drivers/usb/chipidea/Kconfig | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)

Now queued up in my USB tree, thanks.

greg k-h

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 0/6] Remove CONFIG_EMBEDDED
  2022-09-08 10:43 [PATCH 0/6] Remove CONFIG_EMBEDDED Lukas Bulwahn
                   ` (5 preceding siblings ...)
  2022-09-08 10:43 ` [PATCH 6/6] init/Kconfig: remove confusing config EMBEDDED Lukas Bulwahn
@ 2022-09-08 15:21 ` Arnd Bergmann
  6 siblings, 0 replies; 20+ messages in thread
From: Arnd Bergmann @ 2022-09-08 15:21 UTC (permalink / raw)
  To: Lukas Bulwahn, Russell King, linux-arm-kernel, Thomas Gleixner,
	Ingo Molnar, Borislav Petkov, Dave Hansen, x86,
	Mauro Carvalho Chehab, linux-media, Peter Chen,
	Greg Kroah-Hartman, linux-usb, Andrew Morton, Mike Rapoport,
	linux-mm, Masahiro Yamada, linux-kbuild
  Cc: kernel-janitors, linux-kernel

On Thu, Sep 8, 2022, at 12:43 PM, Lukas Bulwahn wrote:
>
> For these minor changes in a few subsystems, I would hope that:
>
>   Patch "arm: make config ARM_PATCH_PHYS_VIRT visible with EXPERT"
>     is picked by arm architecture maintainer Russell King.
>
>   Patch "x86: make config X86_FEATURE_NAMES visible with EXPERT"
>     is picked by x86 architecture maintainers.
>
>   Patch "media: remove reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER"
>     is picked by media maintainer Mauro Carvalho Chehab.
>
>   Patch "usb: chipidea: make configs for glue drivers visible with EXPERT"
>     is picked by Peter Chen or usb maintainer Greg Kroah-Hartman.
>
>   Patch "mm: Kconfig: make config SECRETMEM visible with EXPERT"
>     is acked by Mike Rapoport, and
>     is picked by mm maintainer Andrew Morton.
>
> Once all of these patches above have been merged to mainline:
>
>   Patch "init/Kconfig: remove confusing config EMBEDDED"
>     can probably just be picked by the kbuild maintainer Masahiro

Nice series!

Acked-by: Arnd Bergmann <arnd@arndb.de>

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 3/6] media: remove reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER
  2022-09-08 11:13   ` Mauro Carvalho Chehab
@ 2022-09-08 16:20     ` Mauro Carvalho Chehab
  2022-09-09  6:22       ` Masahiro Yamada
  0 siblings, 1 reply; 20+ messages in thread
From: Mauro Carvalho Chehab @ 2022-09-08 16:20 UTC (permalink / raw)
  To: Lukas Bulwahn
  Cc: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, linux-media, Peter Chen,
	Greg Kroah-Hartman, linux-usb, Andrew Morton, Mike Rapoport,
	linux-mm, Masahiro Yamada, linux-kbuild, kernel-janitors,
	linux-kernel

Em Thu, 8 Sep 2022 13:13:03 +0200
Mauro Carvalho Chehab <mchehab@kernel.org> escreveu:

> Em Thu,  8 Sep 2022 12:43:34 +0200
> Lukas Bulwahn <lukas.bulwahn@gmail.com> escreveu:
> 
> > The config EMBEDDED selects EXPERT, i.e., when EMBEDDED is enabled, EXPERT
> > is usually also enabled. Hence, it sufficient to have the option
> > MEDIA_SUPPORT_FILTER set to y if !EXPERT.
> > 
> > This way, MEDIA_SUPPORT_FILTER does not refer to CONFIG_EMBEDDED anymore
> > and allows us to remove CONFIG_EMBEDDED in the close future.
> > 
> > Remove the reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER.
> > 
> > Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
> > ---
> >  drivers/media/Kconfig | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/drivers/media/Kconfig b/drivers/media/Kconfig
> > index ba6592b3dab2..283b78b5766e 100644
> > --- a/drivers/media/Kconfig
> > +++ b/drivers/media/Kconfig
> > @@ -24,7 +24,7 @@ if MEDIA_SUPPORT
> >  
> >  config MEDIA_SUPPORT_FILTER
> >  	bool "Filter media drivers"
> > -	default y if !EMBEDDED && !EXPERT
> > +	default y if !EXPERT
> >  	help
> >  	   Configuring the media subsystem can be complex, as there are
> >  	   hundreds of drivers and other config options.  
> 
> Reviewed-by: Mauro Carvalho Chehab <mchehab@kernel.org>

As this is independent on the rest of the series, I just went ahead
and merged it on media tree.
> 
> Thanks,
> Mauro



Thanks,
Mauro

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 1/6] arm: make config ARM_PATCH_PHYS_VIRT visible with EXPERT
  2022-09-08 10:43 ` [PATCH 1/6] arm: make config ARM_PATCH_PHYS_VIRT visible with EXPERT Lukas Bulwahn
@ 2022-09-09  6:21   ` Masahiro Yamada
  0 siblings, 0 replies; 20+ messages in thread
From: Masahiro Yamada @ 2022-09-09  6:21 UTC (permalink / raw)
  To: Lukas Bulwahn
  Cc: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, X86 ML, Mauro Carvalho Chehab,
	Linux Media Mailing List, Peter Chen, Greg Kroah-Hartman,
	linux-usb, Andrew Morton, Mike Rapoport,
	Linux Memory Management List, Linux Kbuild mailing list,
	kernel-janitors, Linux Kernel Mailing List

On Thu, Sep 8, 2022 at 7:43 PM Lukas Bulwahn <lukas.bulwahn@gmail.com> wrote:
>
> Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
> introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
> and just gives that intent a much better name. That has been clearly a good
> and long overdue renaming, and it is clearly an improvement to the kernel
> build configuration that has shown to help managing the kernel build
> configuration in the last decade.
>
> However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
> this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
> open for future contributors to implement that intended semantics:
>
>     A new CONFIG_EMBEDDED option is added that automatically selects
>     CONFIG_EXPERT when enabled and can be used in the future to isolate
>     options that should only be considered for embedded systems (RISC
>     architectures, SLOB, etc).
>
> Since then, this CONFIG_EMBEDDED implicitly had two purposes:
>
>   - It can make even more options visible beyond what CONFIG_EXPERT makes
>     visible. In other words, it may introduce another level of enabling the
>     visibility of configuration options: always visible, visible with
>     CONFIG_EXPERT and visible with CONFIG_EMBEDDED.
>
>   - Set certain default values of some configurations differently,
>     following the assumption that configuring a kernel build for an
>     embedded system generally starts with a different set of default values
>     compared to kernel builds for all other kind of systems.
>
> Considering the first purpose, at the point in time where CONFIG_EMBEDDED
> was renamed to CONFIG_EXPERT, CONFIG_EXPERT already made 130 more options
> become visible throughout all different menus for the kernel configuration.
> Over the last decade, this has gradually increased, so that currently, with
> CONFIG_EXPERT, roughly 170 more options become visible throughout all
> different menus for the kernel configuration. In comparison, currently with
> CONFIG_EMBEDDED enabled, just seven more options are visible, one in x86,
> one in arm, and five for the ChipIdea Highspeed Dual Role Controller.
>
> As the numbers suggest, these two levels of enabling the visibility of even
> more configuration options---beyond what CONFIG_EXPERT enables---never
> evolved to a good solution in the last decade. In other words, this
> additional level of visibility of configuration option with CONFIG_EMBEDDED
> compared to CONFIG_EXPERT has since its introduction never become really
> valuable. It requires quite some investigation to actually understand what
> is additionally visible and it does not differ significantly in complexity
> compared to just enabling CONFIG_EXPERT. This CONFIG_EMBEDDED---or any
> other config to show more detailed options beyond CONFIG_EXPERT---is
> unlikely to be valuable unless somebody puts significant effort in
> identifying how such visibility options can be properly split and creating
> clear criteria, when some config option is visible with CONFIG_EXPERT and
> when some config option is visible only with some further option enabled
> beyond CONFIG_EXPERT, such as CONFIG_EMBEDDED attempted to do. For now, it
> is much more reasonable to simply make those additional seven options that
> visible with CONFIG_EMBEDDED, visible with CONFIG_EXPERT, and then remove
> CONFIG_EMBEDDED. If anyone spends significant effort in structuring the
> visibility of config options, they may re-introduce suitable new config
> options simply as they see fit.
>
> Make the config ARM_PATCH_PHYS_VIRT visible when CONFIG_EXPERT is enabled.
>
> Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>


Reviewed-by: Masahiro Yamada <masahiroy@kernel.org>

> ---
>  arch/arm/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
> index 4adfa5dd3556..4b212ab1b281 100644
> --- a/arch/arm/Kconfig
> +++ b/arch/arm/Kconfig
> @@ -243,7 +243,7 @@ config ARCH_MTD_XIP
>         bool
>
>  config ARM_PATCH_PHYS_VIRT
> -       bool "Patch physical to virtual translations at runtime" if EMBEDDED
> +       bool "Patch physical to virtual translations at runtime" if EXPERT
>         default y
>         depends on !XIP_KERNEL && MMU
>         help
> --
> 2.17.1
>


-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 2/6] x86: make config X86_FEATURE_NAMES visible with EXPERT
  2022-09-08 10:43 ` [PATCH 2/6] x86: make config X86_FEATURE_NAMES " Lukas Bulwahn
@ 2022-09-09  6:22   ` Masahiro Yamada
  0 siblings, 0 replies; 20+ messages in thread
From: Masahiro Yamada @ 2022-09-09  6:22 UTC (permalink / raw)
  To: Lukas Bulwahn
  Cc: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, X86 ML, Mauro Carvalho Chehab,
	Linux Media Mailing List, Peter Chen, Greg Kroah-Hartman,
	linux-usb, Andrew Morton, Mike Rapoport,
	Linux Memory Management List, Linux Kbuild mailing list,
	kernel-janitors, Linux Kernel Mailing List

On Thu, Sep 8, 2022 at 7:43 PM Lukas Bulwahn <lukas.bulwahn@gmail.com> wrote:
>
> Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
> introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
> and just gives that intent a much better name. That has been clearly a good
> and long overdue renaming, and it is clearly an improvement to the kernel
> build configuration that has shown to help managing the kernel build
> configuration in the last decade.
>
> However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
> this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
> open for future contributors to implement that intended semantics:
>
>     A new CONFIG_EMBEDDED option is added that automatically selects
>     CONFIG_EXPERT when enabled and can be used in the future to isolate
>     options that should only be considered for embedded systems (RISC
>     architectures, SLOB, etc).
>
> Since then, this CONFIG_EMBEDDED implicitly had two purposes:
>
>   - It can make even more options visible beyond what CONFIG_EXPERT makes
>     visible. In other words, it may introduce another level of enabling the
>     visibility of configuration options: always visible, visible with
>     CONFIG_EXPERT and visible with CONFIG_EMBEDDED.
>
>   - Set certain default values of some configurations differently,
>     following the assumption that configuring a kernel build for an
>     embedded system generally starts with a different set of default values
>     compared to kernel builds for all other kind of systems.
>
> Considering the first purpose, at the point in time where CONFIG_EMBEDDED
> was renamed to CONFIG_EXPERT, CONFIG_EXPERT already made 130 more options
> become visible throughout all different menus for the kernel configuration.
> Over the last decade, this has gradually increased, so that currently, with
> CONFIG_EXPERT, roughly 170 more options become visible throughout all
> different menus for the kernel configuration. In comparison, currently with
> CONFIG_EMBEDDED enabled, just seven more options are visible, one in x86,
> one in arm, and five for the ChipIdea Highspeed Dual Role Controller.
>
> As the numbers suggest, these two levels of enabling the visibility of even
> more configuration options---beyond what CONFIG_EXPERT enables---never
> evolved to a good solution in the last decade. In other words, this
> additional level of visibility of configuration option with CONFIG_EMBEDDED
> compared to CONFIG_EXPERT has since its introduction never become really
> valuable. It requires quite some investigation to actually understand what
> is additionally visible and it does not differ significantly in complexity
> compared to just enabling CONFIG_EXPERT. This CONFIG_EMBEDDED---or any
> other config to show more detailed options beyond CONFIG_EXPERT---is
> unlikely to be valuable unless somebody puts significant effort in
> identifying how such visibility options can be properly split and creating
> clear criteria, when some config option is visible with CONFIG_EXPERT and
> when some config option is visible only with some further option enabled
> beyond CONFIG_EXPERT, such as CONFIG_EMBEDDED attempted to do. For now, it
> is much more reasonable to simply make those additional seven options that
> visible with CONFIG_EMBEDDED, visible with CONFIG_EXPERT, and then remove
> CONFIG_EMBEDDED. If anyone spends significant effort in structuring the
> visibility of config options, they may re-introduce suitable new config
> options simply as they see fit.
>
> Make the config X86_FEATURE_NAMES visible when CONFIG_EXPERT is enabled.
>
> Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>


Reviewed-by: Masahiro Yamada <masahiroy@kernel.org>



> ---
>  arch/x86/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
> index 2ec0b1eabe86..7807eb1c8df8 100644
> --- a/arch/x86/Kconfig
> +++ b/arch/x86/Kconfig
> @@ -438,7 +438,7 @@ config SMP
>           If you don't know what to do here, say N.
>
>  config X86_FEATURE_NAMES
> -       bool "Processor feature human-readable names" if EMBEDDED
> +       bool "Processor feature human-readable names" if EXPERT
>         default y
>         help
>           This option compiles in a table of x86 feature bits and corresponding
> --
> 2.17.1
>


-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 3/6] media: remove reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER
  2022-09-08 16:20     ` Mauro Carvalho Chehab
@ 2022-09-09  6:22       ` Masahiro Yamada
  0 siblings, 0 replies; 20+ messages in thread
From: Masahiro Yamada @ 2022-09-09  6:22 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: Lukas Bulwahn, Russell King, linux-arm-kernel, Thomas Gleixner,
	Ingo Molnar, Borislav Petkov, Dave Hansen, X86 ML,
	Linux Media Mailing List, Peter Chen, Greg Kroah-Hartman,
	linux-usb, Andrew Morton, Mike Rapoport,
	Linux Memory Management List, Linux Kbuild mailing list,
	kernel-janitors, Linux Kernel Mailing List

On Fri, Sep 9, 2022 at 1:20 AM Mauro Carvalho Chehab <mchehab@kernel.org> wrote:
>
> Em Thu, 8 Sep 2022 13:13:03 +0200
> Mauro Carvalho Chehab <mchehab@kernel.org> escreveu:
>
> > Em Thu,  8 Sep 2022 12:43:34 +0200
> > Lukas Bulwahn <lukas.bulwahn@gmail.com> escreveu:
> >
> > > The config EMBEDDED selects EXPERT, i.e., when EMBEDDED is enabled, EXPERT
> > > is usually also enabled. Hence, it sufficient to have the option
> > > MEDIA_SUPPORT_FILTER set to y if !EXPERT.
> > >
> > > This way, MEDIA_SUPPORT_FILTER does not refer to CONFIG_EMBEDDED anymore
> > > and allows us to remove CONFIG_EMBEDDED in the close future.
> > >
> > > Remove the reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER.
> > >
> > > Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
> > > ---
> > >  drivers/media/Kconfig | 2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/media/Kconfig b/drivers/media/Kconfig
> > > index ba6592b3dab2..283b78b5766e 100644
> > > --- a/drivers/media/Kconfig
> > > +++ b/drivers/media/Kconfig
> > > @@ -24,7 +24,7 @@ if MEDIA_SUPPORT
> > >
> > >  config MEDIA_SUPPORT_FILTER
> > >     bool "Filter media drivers"
> > > -   default y if !EMBEDDED && !EXPERT
> > > +   default y if !EXPERT
> > >     help
> > >        Configuring the media subsystem can be complex, as there are
> > >        hundreds of drivers and other config options.
> >
> > Reviewed-by: Mauro Carvalho Chehab <mchehab@kernel.org>
>
> As this is independent on the rest of the series, I just went ahead
> and merged it on media tree.
> >
> > Thanks,
> > Mauro
>
>
>
> Thanks,
> Mauro

Reviewed-by: Masahiro Yamada <masahiroy@kernel.org>

-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 4/6] usb: chipidea: make configs for glue drivers visible with EXPERT
  2022-09-08 11:33   ` Greg Kroah-Hartman
@ 2022-09-09  6:22     ` Masahiro Yamada
  0 siblings, 0 replies; 20+ messages in thread
From: Masahiro Yamada @ 2022-09-09  6:22 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Lukas Bulwahn, Russell King, linux-arm-kernel, Thomas Gleixner,
	Ingo Molnar, Borislav Petkov, Dave Hansen, X86 ML,
	Mauro Carvalho Chehab, Linux Media Mailing List, Peter Chen,
	linux-usb, Andrew Morton, Mike Rapoport,
	Linux Memory Management List, Linux Kbuild mailing list,
	kernel-janitors, Linux Kernel Mailing List

On Thu, Sep 8, 2022 at 8:33 PM Greg Kroah-Hartman
<gregkh@linuxfoundation.org> wrote:
>
> On Thu, Sep 08, 2022 at 12:43:35PM +0200, Lukas Bulwahn wrote:
> > Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
> > introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
> > and just gives that intent a much better name. That has been clearly a good
> > and long overdue renaming, and it is clearly an improvement to the kernel
> > build configuration that has shown to help managing the kernel build
> > configuration in the last decade.
> >
> > However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
> > this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
> > open for future contributors to implement that intended semantics:
> >
> >     A new CONFIG_EMBEDDED option is added that automatically selects
> >     CONFIG_EXPERT when enabled and can be used in the future to isolate
> >     options that should only be considered for embedded systems (RISC
> >     architectures, SLOB, etc).
> >
> > Since then, this CONFIG_EMBEDDED implicitly had two purposes:
> >
> >   - It can make even more options visible beyond what CONFIG_EXPERT makes
> >     visible. In other words, it may introduce another level of enabling the
> >     visibility of configuration options: always visible, visible with
> >     CONFIG_EXPERT and visible with CONFIG_EMBEDDED.
> >
> >   - Set certain default values of some configurations differently,
> >     following the assumption that configuring a kernel build for an
> >     embedded system generally starts with a different set of default values
> >     compared to kernel builds for all other kind of systems.
> >
> > Considering the first purpose, at the point in time where CONFIG_EMBEDDED
> > was renamed to CONFIG_EXPERT, CONFIG_EXPERT already made 130 more options
> > become visible throughout all different menus for the kernel configuration.
> > Over the last decade, this has gradually increased, so that currently, with
> > CONFIG_EXPERT, roughly 170 more options become visible throughout all
> > different menus for the kernel configuration. In comparison, currently with
> > CONFIG_EMBEDDED enabled, just seven more options are visible, one in x86,
> > one in arm, and five for the ChipIdea Highspeed Dual Role Controller.
> >
> > As the numbers suggest, these two levels of enabling the visibility of even
> > more configuration options---beyond what CONFIG_EXPERT enables---never
> > evolved to a good solution in the last decade. In other words, this
> > additional level of visibility of configuration option with CONFIG_EMBEDDED
> > compared to CONFIG_EXPERT has since its introduction never become really
> > valuable. It requires quite some investigation to actually understand what
> > is additionally visible and it does not differ significantly in complexity
> > compared to just enabling CONFIG_EXPERT. This CONFIG_EMBEDDED---or any
> > other config to show more detailed options beyond CONFIG_EXPERT---is
> > unlikely to be valuable unless somebody puts significant effort in
> > identifying how such visibility options can be properly split and creating
> > clear criteria, when some config option is visible with CONFIG_EXPERT and
> > when some config option is visible only with some further option enabled
> > beyond CONFIG_EXPERT, such as CONFIG_EMBEDDED attempted to do. For now, it
> > is much more reasonable to simply make those additional seven options that
> > visible with CONFIG_EMBEDDED, visible with CONFIG_EXPERT, and then remove
> > CONFIG_EMBEDDED. If anyone spends significant effort in structuring the
> > visibility of config options, they may re-introduce suitable new config
> > options simply as they see fit.
> >
> > Make the configs for usb chipidea glue drivers visible when CONFIG_EXPERT
> > is enabled.
> >
> > Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
> > ---
> >  drivers/usb/chipidea/Kconfig | 10 +++++-----
> >  1 file changed, 5 insertions(+), 5 deletions(-)
>
> Now queued up in my USB tree, thanks.
>
> greg k-h


Reviewed-by: Masahiro Yamada <masahiroy@kernel.org>

-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 5/6] mm: Kconfig: make config SECRETMEM visible with EXPERT
  2022-09-08 11:24   ` Mike Rapoport
@ 2022-09-09  6:22     ` Masahiro Yamada
  0 siblings, 0 replies; 20+ messages in thread
From: Masahiro Yamada @ 2022-09-09  6:22 UTC (permalink / raw)
  To: Mike Rapoport
  Cc: Lukas Bulwahn, Russell King, linux-arm-kernel, Thomas Gleixner,
	Ingo Molnar, Borislav Petkov, Dave Hansen, X86 ML,
	Mauro Carvalho Chehab, Linux Media Mailing List, Peter Chen,
	Greg Kroah-Hartman, linux-usb, Andrew Morton,
	Linux Memory Management List, Linux Kbuild mailing list,
	kernel-janitors, Linux Kernel Mailing List

On Thu, Sep 8, 2022 at 8:24 PM Mike Rapoport <rppt@linux.ibm.com> wrote:
>
> On Thu, Sep 08, 2022 at 12:43:36PM +0200, Lukas Bulwahn wrote:
> > Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
> > introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
> > and just gives that intent a much better name. That has been clearly a good
> > and long overdue renaming, and it is clearly an improvement to the kernel
> > build configuration that has shown to help managing the kernel build
> > configuration in the last decade.
> >
> > However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
> > this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
> > open for future contributors to implement that intended semantics:
> >
> >     A new CONFIG_EMBEDDED option is added that automatically selects
> >     CONFIG_EXPERT when enabled and can be used in the future to isolate
> >     options that should only be considered for embedded systems (RISC
> >     architectures, SLOB, etc).
> >
> > Since then, this CONFIG_EMBEDDED implicitly had two purposes:
> >
> >   - It can make even more options visible beyond what CONFIG_EXPERT makes
> >     visible. In other words, it may introduce another level of enabling the
> >     visibility of configuration options: always visible, visible with
> >     CONFIG_EXPERT and visible with CONFIG_EMBEDDED.
> >
> >   - Set certain default values of some configurations differently,
> >     following the assumption that configuring a kernel build for an
> >     embedded system generally starts with a different set of default values
> >     compared to kernel builds for all other kind of systems.
> >
> > Considering the second purpose, note that already probably arguing that a
> > kernel build for an embedded system would choose some values differently is
> > already tricky: the set of embedded systems with Linux kernels is already
> > quite diverse. Many embedded system have powerful CPUs and it would not be
> > clear that all embedded systems just optimize towards one specific aspect,
> > e.g., a smaller kernel image size. So, it is unclear if starting with "one
> > set of default configuration" that is induced by CONFIG_EMBEDDED is a good
> > offer for developers configuring their kernels.
> >
> > Also, the differences of needed user-space features in an embedded system
> > compared to a non-embedded system are probably difficult or even impossible
> > to name in some generic way.
> >
> > So it is not surprising that in the last decade hardly anyone has
> > contributed changes to make something default differently in case of
> > CONFIG_EMBEDDED=y.
> >
> > Currently, in v6.0-rc4, SECRETMEM is the only config switched off if
> > CONFIG_EMBEDDED=y.
> >
> > As long as that is actually the only option that currently is selected or
> > deselected, it is better to just make SECRETMEM configurable at build time
> > by experts using menuconfig instead.
> >
> > Make SECRETMEM configurable when EXPERT is set and otherwise default to
> > yes. Further, SECRETMEM needs ARCH_HAS_SET_DIRECT_MAP.
> >
> > This allows us to remove CONFIG_EMBEDDED in the close future.
> >
> > Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
>
> Acked-by: Mike Rapoport <rppt@linux.ibm.com>
>
> > ---
> >  mm/Kconfig | 8 +++++++-
> >  1 file changed, 7 insertions(+), 1 deletion(-)
> >
> > diff --git a/mm/Kconfig b/mm/Kconfig
> > index ceec438c0741..aa154c20b129 100644
> > --- a/mm/Kconfig
> > +++ b/mm/Kconfig
> > @@ -1068,7 +1068,13 @@ config IO_MAPPING
> >       bool
> >
> >  config SECRETMEM
> > -     def_bool ARCH_HAS_SET_DIRECT_MAP && !EMBEDDED
> > +     default y
> > +     bool "Enable memfd_secret() system call" if EXPERT
> > +     depends on ARCH_HAS_SET_DIRECT_MAP
> > +     help
> > +       Enable the memfd_secret() system call with the ability to create
> > +       memory areas visible only in the context of the owning process and
> > +       not mapped to other processes and other kernel page tables.
> >
> >  config ANON_VMA_NAME
> >       bool "Anonymous VMA name support"
> > --
> > 2.17.1
> >
>
> --
> Sincerely yours,
> Mike.

Reviewed-by: Masahiro Yamada <masahiroy@kernel.org>

-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 6/6] init/Kconfig: remove confusing config EMBEDDED
  2022-09-08 10:43 ` [PATCH 6/6] init/Kconfig: remove confusing config EMBEDDED Lukas Bulwahn
@ 2022-09-09  6:24   ` Masahiro Yamada
  2022-09-09  9:23   ` Christophe Leroy
  1 sibling, 0 replies; 20+ messages in thread
From: Masahiro Yamada @ 2022-09-09  6:24 UTC (permalink / raw)
  To: Lukas Bulwahn
  Cc: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, X86 ML, Mauro Carvalho Chehab,
	Linux Media Mailing List, Peter Chen, Greg Kroah-Hartman,
	linux-usb, Andrew Morton, Mike Rapoport,
	Linux Memory Management List, Linux Kbuild mailing list,
	kernel-janitors, Linux Kernel Mailing List

On Thu, Sep 8, 2022 at 7:44 PM Lukas Bulwahn <lukas.bulwahn@gmail.com> wrote:
>
> Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
> introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
> and just gives that intent a much better name. That has been clearly a good
> and long overdue renaming, and it is clearly an improvement to the kernel
> build configuration that has shown to help managing the kernel build
> configuration in the last decade.
>
> However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
> this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
> open for future contributors to implement that intended semantics:
>
>     A new CONFIG_EMBEDDED option is added that automatically selects
>     CONFIG_EXPERT when enabled and can be used in the future to isolate
>     options that should only be considered for embedded systems (RISC
>     architectures, SLOB, etc).
>
> Since then, this CONFIG_EMBEDDED implicitly had two purposes:
>
>   - It can make even more options visible beyond what CONFIG_EXPERT makes
>     visible. In other words, it may introduce another level of enabling the
>     visibility of configuration options: always visible, visible with
>     CONFIG_EXPERT and visible with CONFIG_EMBEDDED.
>
>   - Set certain default values of some configurations differently,
>     following the assumption that configuring a kernel build for an
>     embedded system generally starts with a different set of default values
>     compared to kernel builds for all other kind of systems.
>
> Considering the first purpose, at the point in time where CONFIG_EMBEDDED
> was renamed to CONFIG_EXPERT, CONFIG_EXPERT already made 130 more options
> become visible throughout all different menus for the kernel configuration.
> Over the last decade, this has gradually increased, so that currently, with
> CONFIG_EXPERT, roughly 170 more options become visible throughout all
> different menus for the kernel configuration. In comparison, currently with
> CONFIG_EMBEDDED enabled, just seven more options are visible, one in x86,
> one in arm, and five for the ChipIdea Highspeed Dual Role Controller.
>
> As the numbers suggest, these two levels of enabling the visibility of even
> more configuration options---beyond what CONFIG_EXPERT enables---never
> evolved to a good solution in the last decade. In other words, this
> additional level of visibility of configuration option with CONFIG_EMBEDDED
> compared to CONFIG_EXPERT has since its introduction never become really
> valuable. It requires quite some investigation to actually understand what
> is additionally visible and it does not differ significantly in complexity
> compared to just enabling CONFIG_EXPERT. This CONFIG_EMBEDDED---or any
> other config to show more detailed options beyond CONFIG_EXPERT---is
> unlikely to be valuable unless somebody puts significant effort in
> identifying how such visibility options can be properly split and creating
> clear criteria, when some config option is visible with CONFIG_EXPERT and
> when some config option is visible only with some further option enabled
> beyond CONFIG_EXPERT, such as CONFIG_EMBEDDED attempted to do. For now, it
> is much more reasonable to simply make those additional seven options that
> visible with CONFIG_EMBEDDED, visible with CONFIG_EXPERT, and then remove
> CONFIG_EMBEDDED. If anyone spends significant effort in structuring the
> visibility of config options, they may re-introduce suitable new config
> options simply as they see fit.
>
> Hence, all uses of CONFIG_EMBEDDED have been replaced with CONFIG_EXPERT.
>
> Considering the second purpose, note that already probably arguing that a
> kernel build for an embedded system would choose some values differently is
> already tricky: the set of embedded systems with Linux kernels is already
> quite diverse. Many embedded system have powerful CPUs and it would not be
> clear that all embedded systems just optimize towards one specific aspect,
> e.g., a smaller kernel image size. So, it is unclear if starting with "one
> set of default configuration" that is induced by CONFIG_EMBEDDED is a good
> offer for developers configuring their kernels.
>
> Also, the differences of needed user-space features in an embedded system
> compared to a non-embedded system are probably difficult or even impossible
> to name in some generic way.
>
> So it is not surprising that in the last decade hardly anyone has
> contributed changes to make something default differently in case of
> CONFIG_EMBEDDED=y.
>
> In v6.0-rc4, SECRETMEM is the only config switched off if
> CONFIG_EMBEDDED=y. That one use was removed as well, SECRETMEM was made
> configurable at build time by experts using menuconfig instead.
>
> As there are no further uses of CONFIG_EMBEDDED and CONFIG_EMBEDDED never
> lived up to its intended purpose defined above, simply delete this
> confusing CONFIG_EMBEDDED.
>
> Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
> ---
>  init/Kconfig | 8 --------
>  1 file changed, 8 deletions(-)
>
> diff --git a/init/Kconfig b/init/Kconfig
> index 9e3fd79b089c..d7429e0b8cae 100644
> --- a/init/Kconfig
> +++ b/init/Kconfig
> @@ -1818,14 +1818,6 @@ config DEBUG_RSEQ
>
>           If unsure, say N.
>
> -config EMBEDDED
> -       bool "Embedded system"
> -       select EXPERT
> -       help
> -         This option should be enabled if compiling the kernel for
> -         an embedded system so certain expert options are available
> -         for configuration.
> -
>  config HAVE_PERF_EVENTS
>         bool
>         help
> --
> 2.17.1
>



So, I am supposed to pick this up after 01-05 land.

(please ping me if I forget about it).


For now,
Reviewed-by: Masahiro Yamada <masahiroy@kernel.org>



-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 6/6] init/Kconfig: remove confusing config EMBEDDED
  2022-09-08 10:43 ` [PATCH 6/6] init/Kconfig: remove confusing config EMBEDDED Lukas Bulwahn
  2022-09-09  6:24   ` Masahiro Yamada
@ 2022-09-09  9:23   ` Christophe Leroy
  2022-09-09  9:47     ` Lukas Bulwahn
  1 sibling, 1 reply; 20+ messages in thread
From: Christophe Leroy @ 2022-09-09  9:23 UTC (permalink / raw)
  To: Lukas Bulwahn, Russell King, linux-arm-kernel, Thomas Gleixner,
	Ingo Molnar, Borislav Petkov, Dave Hansen, x86,
	Mauro Carvalho Chehab, linux-media, Peter Chen,
	Greg Kroah-Hartman, linux-usb, Andrew Morton, Mike Rapoport,
	linux-mm, Masahiro Yamada, linux-kbuild, linuxppc-dev
  Cc: kernel-janitors, linux-kernel

+ linuxppc-dev

Le 08/09/2022 à 12:43, Lukas Bulwahn a écrit :
> Commit 6a108a14fa35 ("kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT")
> introduces CONFIG_EXPERT to carry the previous intent of CONFIG_EMBEDDED
> and just gives that intent a much better name. That has been clearly a good
> and long overdue renaming, and it is clearly an improvement to the kernel
> build configuration that has shown to help managing the kernel build
> configuration in the last decade.
> 
> However, rather than bravely and radically just deleting CONFIG_EMBEDDED,
> this commit gives CONFIG_EMBEDDED a new intended semantics, but keeps it
> open for future contributors to implement that intended semantics:
> 
>      A new CONFIG_EMBEDDED option is added that automatically selects
>      CONFIG_EXPERT when enabled and can be used in the future to isolate
>      options that should only be considered for embedded systems (RISC
>      architectures, SLOB, etc).
> 
> Since then, this CONFIG_EMBEDDED implicitly had two purposes:
> 
>    - It can make even more options visible beyond what CONFIG_EXPERT makes
>      visible. In other words, it may introduce another level of enabling the
>      visibility of configuration options: always visible, visible with
>      CONFIG_EXPERT and visible with CONFIG_EMBEDDED.
> 
>    - Set certain default values of some configurations differently,
>      following the assumption that configuring a kernel build for an
>      embedded system generally starts with a different set of default values
>      compared to kernel builds for all other kind of systems.
> 
> Considering the first purpose, at the point in time where CONFIG_EMBEDDED
> was renamed to CONFIG_EXPERT, CONFIG_EXPERT already made 130 more options
> become visible throughout all different menus for the kernel configuration.
> Over the last decade, this has gradually increased, so that currently, with
> CONFIG_EXPERT, roughly 170 more options become visible throughout all
> different menus for the kernel configuration. In comparison, currently with
> CONFIG_EMBEDDED enabled, just seven more options are visible, one in x86,
> one in arm, and five for the ChipIdea Highspeed Dual Role Controller.
> 
> As the numbers suggest, these two levels of enabling the visibility of even
> more configuration options---beyond what CONFIG_EXPERT enables---never
> evolved to a good solution in the last decade. In other words, this
> additional level of visibility of configuration option with CONFIG_EMBEDDED
> compared to CONFIG_EXPERT has since its introduction never become really
> valuable. It requires quite some investigation to actually understand what
> is additionally visible and it does not differ significantly in complexity
> compared to just enabling CONFIG_EXPERT. This CONFIG_EMBEDDED---or any
> other config to show more detailed options beyond CONFIG_EXPERT---is
> unlikely to be valuable unless somebody puts significant effort in
> identifying how such visibility options can be properly split and creating
> clear criteria, when some config option is visible with CONFIG_EXPERT and
> when some config option is visible only with some further option enabled
> beyond CONFIG_EXPERT, such as CONFIG_EMBEDDED attempted to do. For now, it
> is much more reasonable to simply make those additional seven options that
> visible with CONFIG_EMBEDDED, visible with CONFIG_EXPERT, and then remove
> CONFIG_EMBEDDED. If anyone spends significant effort in structuring the
> visibility of config options, they may re-introduce suitable new config
> options simply as they see fit.
> 
> Hence, all uses of CONFIG_EMBEDDED have been replaced with CONFIG_EXPERT.
> 
> Considering the second purpose, note that already probably arguing that a
> kernel build for an embedded system would choose some values differently is
> already tricky: the set of embedded systems with Linux kernels is already
> quite diverse. Many embedded system have powerful CPUs and it would not be
> clear that all embedded systems just optimize towards one specific aspect,
> e.g., a smaller kernel image size. So, it is unclear if starting with "one
> set of default configuration" that is induced by CONFIG_EMBEDDED is a good
> offer for developers configuring their kernels.
> 
> Also, the differences of needed user-space features in an embedded system
> compared to a non-embedded system are probably difficult or even impossible
> to name in some generic way.
> 
> So it is not surprising that in the last decade hardly anyone has
> contributed changes to make something default differently in case of
> CONFIG_EMBEDDED=y.
> 
> In v6.0-rc4, SECRETMEM is the only config switched off if
> CONFIG_EMBEDDED=y. That one use was removed as well, SECRETMEM was made
> configurable at build time by experts using menuconfig instead.
> 
> As there are no further uses of CONFIG_EMBEDDED and CONFIG_EMBEDDED never
> lived up to its intended purpose defined above, simply delete this
> confusing CONFIG_EMBEDDED.
> 
> Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
> ---
>   init/Kconfig | 8 --------
>   1 file changed, 8 deletions(-)
> 
> diff --git a/init/Kconfig b/init/Kconfig
> index 9e3fd79b089c..d7429e0b8cae 100644
> --- a/init/Kconfig
> +++ b/init/Kconfig
> @@ -1818,14 +1818,6 @@ config DEBUG_RSEQ
>   
>   	  If unsure, say N.
>   
> -config EMBEDDED
> -	bool "Embedded system"
> -	select EXPERT
> -	help
> -	  This option should be enabled if compiling the kernel for
> -	  an embedded system so certain expert options are available
> -	  for configuration.
> -
>   config HAVE_PERF_EVENTS
>   	bool
>   	help

That's fine, but what happens to existing defconfigs then ?

$ git grep -w CONFIG_EMBEDDED arch/powerpc/
arch/powerpc/configs/40x/klondike_defconfig:CONFIG_EMBEDDED=y
arch/powerpc/configs/44x/fsp2_defconfig:CONFIG_EMBEDDED=y
arch/powerpc/configs/52xx/tqm5200_defconfig:CONFIG_EMBEDDED=y
arch/powerpc/configs/mgcoge_defconfig:CONFIG_EMBEDDED=y
arch/powerpc/configs/microwatt_defconfig:CONFIG_EMBEDDED=y
arch/powerpc/configs/ps3_defconfig:CONFIG_EMBEDDED=y

They need to get converted to selecting CONFIG_EXPERT instead.

And that needs to be done before you remove CONFIG_EMBEDDED.

Christophe

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 6/6] init/Kconfig: remove confusing config EMBEDDED
  2022-09-09  9:23   ` Christophe Leroy
@ 2022-09-09  9:47     ` Lukas Bulwahn
  0 siblings, 0 replies; 20+ messages in thread
From: Lukas Bulwahn @ 2022-09-09  9:47 UTC (permalink / raw)
  To: Christophe Leroy
  Cc: Russell King, linux-arm-kernel, Thomas Gleixner, Ingo Molnar,
	Borislav Petkov, Dave Hansen, x86, Mauro Carvalho Chehab,
	linux-media, Peter Chen, Greg Kroah-Hartman, linux-usb,
	Andrew Morton, Mike Rapoport, linux-mm, Masahiro Yamada,
	linux-kbuild, linuxppc-dev, kernel-janitors, linux-kernel

> >   init/Kconfig | 8 --------
> >   1 file changed, 8 deletions(-)
> >
> > diff --git a/init/Kconfig b/init/Kconfig
> > index 9e3fd79b089c..d7429e0b8cae 100644
> > --- a/init/Kconfig
> > +++ b/init/Kconfig
> > @@ -1818,14 +1818,6 @@ config DEBUG_RSEQ
> >
> >         If unsure, say N.
> >
> > -config EMBEDDED
> > -     bool "Embedded system"
> > -     select EXPERT
> > -     help
> > -       This option should be enabled if compiling the kernel for
> > -       an embedded system so certain expert options are available
> > -       for configuration.
> > -
> >   config HAVE_PERF_EVENTS
> >       bool
> >       help
>
> That's fine, but what happens to existing defconfigs then ?
>
> $ git grep -w CONFIG_EMBEDDED arch/powerpc/
> arch/powerpc/configs/40x/klondike_defconfig:CONFIG_EMBEDDED=y
> arch/powerpc/configs/44x/fsp2_defconfig:CONFIG_EMBEDDED=y
> arch/powerpc/configs/52xx/tqm5200_defconfig:CONFIG_EMBEDDED=y
> arch/powerpc/configs/mgcoge_defconfig:CONFIG_EMBEDDED=y
> arch/powerpc/configs/microwatt_defconfig:CONFIG_EMBEDDED=y
> arch/powerpc/configs/ps3_defconfig:CONFIG_EMBEDDED=y
>
> They need to get converted to selecting CONFIG_EXPERT instead.
>
> And that needs to be done before you remove CONFIG_EMBEDDED.
>

Agree. Let us get the first five patches included. Then adjust the
configs for all architectures and then delete the CONFIG_EMBEDDED.

Lukas

^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2022-09-09  9:47 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-08 10:43 [PATCH 0/6] Remove CONFIG_EMBEDDED Lukas Bulwahn
2022-09-08 10:43 ` [PATCH 1/6] arm: make config ARM_PATCH_PHYS_VIRT visible with EXPERT Lukas Bulwahn
2022-09-09  6:21   ` Masahiro Yamada
2022-09-08 10:43 ` [PATCH 2/6] x86: make config X86_FEATURE_NAMES " Lukas Bulwahn
2022-09-09  6:22   ` Masahiro Yamada
2022-09-08 10:43 ` [PATCH 3/6] media: remove reference to CONFIG_EMBEDDED in MEDIA_SUPPORT_FILTER Lukas Bulwahn
2022-09-08 11:13   ` Mauro Carvalho Chehab
2022-09-08 16:20     ` Mauro Carvalho Chehab
2022-09-09  6:22       ` Masahiro Yamada
2022-09-08 10:43 ` [PATCH 4/6] usb: chipidea: make configs for glue drivers visible with EXPERT Lukas Bulwahn
2022-09-08 11:33   ` Greg Kroah-Hartman
2022-09-09  6:22     ` Masahiro Yamada
2022-09-08 10:43 ` [PATCH 5/6] mm: Kconfig: make config SECRETMEM " Lukas Bulwahn
2022-09-08 11:24   ` Mike Rapoport
2022-09-09  6:22     ` Masahiro Yamada
2022-09-08 10:43 ` [PATCH 6/6] init/Kconfig: remove confusing config EMBEDDED Lukas Bulwahn
2022-09-09  6:24   ` Masahiro Yamada
2022-09-09  9:23   ` Christophe Leroy
2022-09-09  9:47     ` Lukas Bulwahn
2022-09-08 15:21 ` [PATCH 0/6] Remove CONFIG_EMBEDDED Arnd Bergmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).