#31 Add "context" variables

General (16)

The Linux kernel runs on many different architectures. The specific parts are located in subdirectories of /arch. This is easily handled with the 'a' (architecture) variable and one 'incprefix' and one 'maps' directives. However some architectures have variants with specific code in other subdirectories. These could also be handled by other variables, but this gives many, many buttons or link lines in the page header (leading to visual confusion and bad legibility).

Since these variables are meaningful only in the context of their associated 'a' value, it is much better to display them only if the 'a' variable has the appropriate value.

This could be done by defining a new attribute in 'variables' as 'when' => 'string containing a conditional expr'
{ 'arm_mach' =>
{ 'name' => 'Arm machine'
, 'when' => '"$a" eq "arm"
, 'range' => [qw(at91 bcmring ... )]

The 'when' attribute is evaluated when there is need to display variables list. Should it also be evaluated when variable value is substituted? Are there circumstances that require to drop meaningless variables?


  • Andre-Littoz

    Andre-Littoz - 2012-03-24
    • assigned_to: nobody --> ajlittoz
    • labels: --> General
    • status: open --> closed
  • Andre-Littoz

    Andre-Littoz - 2012-03-24

    This feature has been implemented in CVS, will be available in 0.12 release.
    To facilitate its use, a new script will be added to collect relevant information for kernel tree.


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks