0

I want to build phylink support (CONFIG_PHYLINK) as a module. In my config, some reverse dependencies of CONFIG_PHYLINK are configured as builtin (=y). Is there some tool that helps to switch all reverse dependencies to be build as a module, so CONFIG_PHYLINK can be set to =m?

asked Dec 16, 2025 at 16:32
4
  • 3
    Are you manually editing the .config file (a bad practice), or using make menuconfig (which is the "some tool" you seek)? Commented Dec 16, 2025 at 20:00
  • CONFIG_PHYLINK has no prompt in menuconfig, it is selected by its reverse dependencies if one of them is enabled. Menuconfig is of some help as it shows which reverse dependencies are set to "=y". But I just have to manually change all of them to "=m", as well as further recursive reverse dependencies. I'd like to know if there is another tool with less manual steps. Commented Dec 17, 2025 at 12:09
  • Maybe merge_config helps? Commented Dec 21, 2025 at 20:47
  • 1
    Meanwhile I manually went through all reverse dendencies and changed them to "=m". Commented Dec 22, 2025 at 10:44

1 Answer 1

0

make menuconfig or make nconfig are designed to do this for you - personally I find the latter nicer and may do what you're after by first enabling "all entries" F4 before searching with F8

I don't immediately have an instance to see if there's a flip-tree, but you can at least find the dependency graph this way

With the keys you could flip them manually or do something ugly like this (lightly tested) to flip a collection of CONFIG_ keys outside the tool, but beware not all keys support m and I generally don't suggest doing this and instead giving each full name explicitly if you're producing your own script!

cp .config config.bak$(date --iso-8601=s)
cat <<EOF | xargs -I{} sed -iE "s/^\(CONFIG_{}=\)./1円m/" .config
put
your
keys
here
EOF
answered Dec 22, 2025 at 11:44
Sign up to request clarification or add additional context in comments.

1 Comment

Thanks, this is basically the "manual" method I also mentioned today.

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.