Page 1 of 1

Edit the .config file when en/disabling a particular option?

Posted: Fri Jun 08, 2012 12:57 am
by AnishaKaul
From here: http://www.xenomai.org/index.php/FAQs#W ... avoided.3F
Which kernel settings should be avoided?
Note that Xenomai will warn you about known invalid combinations during kernel configuration.
- CONFIG_CPU_FREQ
- CONFIG_APM
- CONFIG_ACPI_PROCESSOR
The make menuconfig window do not present these options explicitly.

Now, when I look in the .config, I do find these options clearly but I don't know their dependencies.
So, it is wise to simply put a =n next to these options in the .config file? Will the make procedure take care of the dependencies?

Re: Edit the .config file when en/disabling a particular opt

Posted: Tue Jun 12, 2012 7:41 am
by Combuster
The make menuconfig window do not present these options explicitly.
You're kidding, right? Look at the fourth line.

Image

Re: Edit the .config file when en/disabling a particular opt

Posted: Tue Jun 12, 2012 12:49 pm
by Kazinsal
I'd be wary of not compiling the kernel with full ACPI and APM support... Remember this screen?

(Yes, I know there are like, a dozen CONFIG_ACPI options, but not being able to throttle the processor during "slow" times can waste a fair bit of electricity if you leave your computer on 24/7. Then again, I could be entirely wrong about the function of CONFIG_ACPI_PROCESSOR.)

Re: Edit the .config file when en/disabling a particular opt

Posted: Wed Jun 13, 2012 1:13 am
by Solar
Xenomai is a real-time framework for Linux. The link given by the OP directly gives the reason for disabling APM / ACPI, which are very valid if RT is your priority:
Xenomai wrote:CONFIG_APM

The APM model assigns power management control to the BIOS, and BIOS code is never written with RT-latency in mind. If configured, APM routines are invoked with SMI priority, which breaks the rule that adeos-ipipe must be in charge of such things. CONFIG_XENO_HW_SMI_WORKAROUND_* doesn't help here.

CONFIG_ACPI_PROCESSOR

For systems with ACPI support in the BIOS, this ACPI sub-option installs an 'idle' handler that uses ACPI C2 and C3 processor states to save power. The CPU must 'warm-up' from these sleep states, increasing latency in ways dependent upon both the BIOS's ACPI tables and code. You may be able to suppress the sleeping with 'idle=poll' boot-arg, test to find out. With recents versions of Linux (probably starting around Linux 2.6.21), the acpi processor module disables the local APIC when loaded. This will cause Xenomai timer initialization to fail. This makes a second reason for disabling this option.
As an aside, this shows why you simply cannot do "hard" RTOS on your average desktop OS. RTOS and desktop OS have vastly different requirements, and I always cringe when people write about how they want to implement RTOS features on their general-purpose OS. (Mind you, I've been one of them, once upon a time, but I talked to actual people in the actual RTOS trade, and they very quickly talked me out of it. ;-) )

Re: Edit the .config file when en/disabling a particular opt

Posted: Wed Jun 20, 2012 5:31 am
by AnishaKaul
From kernel configuration screen:
NOTE: Xenomai needs either X86_LOCAL_APIC enabled or HPET_TIMER disabled. ***
The / feature of make menuconfig shows this on searching for "X86_LOCAL_APIC":
Symbol: X86_LOCAL_APIC [=y] │
│ Type : boolean
Now, "if" I have to change this option, where do I do it?

Re: Edit the .config file when en/disabling a particular opt

Posted: Wed Jun 20, 2012 5:46 am
by Solar
...in menuconfig...?

:? :?:

Many of the kernel options have interdependencies. Editing .config manually is a recipee for desaster. That's why there are tools like "make menuconfig", "make xconfig", "make gconfig", "make config", and "make oldconfig".

Make sure you didn't have a borked .config in the build directory, because it is used as a starting point for the above tools, and if it is borked already, it is likely to be borked again.

Re: Edit the .config file when en/disabling a particular opt

Posted: Wed Jun 20, 2012 5:52 am
by AnishaKaul
Actually my point was that "/" is a "search" tool which shows the "location" of the item.

In this particular case, it doesn't show the location, so how do I find where is it?

Re: Edit the .config file when en/disabling a particular opt

Posted: Wed Jun 20, 2012 6:39 am
by Solar
http://how-to.wikia.com/wiki/How_to_con ... nux_kernel

Try "Processor type and features".
Option: X86_LOCAL_APIC
Kernel Versions: 2.6.15.6 ...
(on/off)
depends on X86_UP_APIC || ((X86_VISWS || SMP) && !X86_VOYAGER)
default y