On Sun, Mar 24, 2019 at 3:46 AM Peter Humphrey <[email protected]> wrote: > > On Sunday, 24 March 2019 01:03:23 GMT Walter Dnes wrote: > > When setting up a new kernel with "make oldconfig", almost all new > > device drivers default to "N". The glaring exception is network cards. > > They all seem to default to "Y". Is this a bug or a "feature"? > > It seems to be just to reveal the individual cards by that manufacturer. I > don't see why it should differ from any other hardware options. Perhaps it's a > leftover from a day long ago that no-one's thought to change. >
I suspect it is because these options basically work opposite normal ones. They're phased as "Do you want to see Acme network cards?" with a default of Yes. However, they way they effectively work is "Do you want to disable all Acme network cards?" with a default of No. Suppose you have an Acme model 1234 network card. You've previously answered Yes to enabling its driver, and No to enabling the Acme model 2345 card. Now a new option comes along to show/hide all the Acme cards. That is a new option, so it has no existing value as far as the config database design goes. If you answer No, then you disable your model 1234 card (without even being asked, because that isn't a new option). If you answer yes then effectively your previous choices remain in effect (model 1234 remains enabled, and model 2345 remains disabled). Now, obviously a more elegant solution would be to look at all the models of Acme cards in the database and see if you've selected any, and use that to set the default. However, that would require a change to how the entire config system works most likely. I might have a detail wrong and lkml is definitely where to go for the full answer, but I suspect this was the rationale behind this design decision. Those options effectively don't do anything but expose more options, so defaulting them to Yes probably made more sense, because defaulting to no would disable anything that depends on them. In any case, this is purely an upstream kernel issue, so you can always try to convince Linus that he has it wrong. :) -- Rich

