Lines Matching full:as

28 manually, as it's just a block of text that needs to be inserted near the other
85 These variables are referenced as of writing (Linux 4.18), together with sample
118 Kconfiglib has the same assignment semantics as the C implementation.
168 often get the same condition as the prompt due to dependency propagation.
179 symbols can be forced to a particular (minimum) value by a select as well.
182 non-n: m visibility acts the same as y visibility.
204 treated the same as the following assignment:
217 The menu structure, as seen in e.g. menuconfig, is represented by a tree of
252 As a convenience, the properties added at a particular definition location are
262 the expr_str() function (these are used internally as well). Evaluating an
263 expression always yields a tristate value, where n, m, and y are represented as
288 represented as constant symbols, so the only values that appear in expressions
291 ***For choice symbols, the parent Choice will appear in expressions as well,
292 but it's usually invisible as the value interfaces of Symbol and Choice are
307 For constant (as well as undefined) symbols, str_value matches the name of
309 'depends on SYM = "foo"' above works as expected.
332 supported by Linux kernel tools as of writing.
355 Using 'rsource', it can be rewritten as:
359 If an absolute path is given to 'rsource', it acts the same as 'source'.
377 The glob patterns accepted are the same as for the standard glob.glob()
430 The following attributes are available. They should be treated as
448 A list with all defined symbols, in the same order as they appear in the
466 A list with all choices, in the same order as they appear in the Kconfig
477 A list with all menus, in the same order as they appear in the Kconfig
481 A list with all comments, in the same order as they appear in the Kconfig
525 its tri_value will be 0 (n), as expected.
529 disabled by default in the kernel Kconfig files as of writing, though
542 $srctree/foo/defconfig is looked up as well.
555 Acts as the root of the menu tree.
570 Kconfig.enable/disable_stderr_warnings() functions as well. Note that
574 Just as for warnings printed to stderr, only optional warnings that are
581 behavior with os.path.join(), which treats "" as the current directory,
659 as .config files (which store configuration symbol values).
677 from the top-level directory, as environment variables will make sure
678 the right Kconfig is included from there (arch/$SRCARCH/Kconfig as of
692 is provided as a constructor argument since warnings might be
695 See the other Kconfig.enable_*_warnings() functions as well, which
788 # as part of Kconfig.eval_string().
808 # Not used internally. Provided as a convenience.
828 except IOError as e:
837 except UnicodeDecodeError as e:
893 with self._open_config(filename.str_value) as f:
928 except UnicodeDecodeError as e:
934 with self._open_config(filename) as f:
1020 # rstrip()'d, so blank lines show up as "" here.
1075 Writes out symbol values as a C header file, matching the format used
1080 table implementation as of writing, and so won't match.
1090 with self._open(filename, "w") as f:
1129 Symbols appear in the same order in generated .config files as they do
1145 with self._open(filename, "w") as f:
1176 configuration files can serve as a more manageable configuration format
1188 with self._open(filename, "w") as f:
1193 # non-choice symbols, as selects don't affect choice
1240 logically has the same effect as updating the entire
1268 implementation can be used as a template."""
1326 # Remember the current values as the "new old" values.
1343 with self._open("auto.conf", "w") as f:
1364 with self._open("auto.conf", "r") as f:
1393 As an example, the following code will produce a list equal to
1436 Returns the tristate value of the expression 's', represented as 0, 1,
1440 As an example, if FOO and BAR are tristate symbols at least one of
1470 Resets the user values of all symbols, as if Kconfig.load_config() or
1577 except IOError as e:
1582 except IOError as e2:
1609 # The parent Kconfig files are represented as a list of
1643 except IOError as e:
1668 # This also works as expected if _saved_line is "", indicating EOF:
1827 # reasonably safe as expandvars() leaves references to
1828 # undefined env. vars. as is.
2186 # args[1..len(args)-1]. Plain variables are treated as functions
2292 # property and discovering it isn't. self._has_tokens functions as a
2338 # join()'ing, as srctree might be an absolute path.
2612 "as it wouldn't be that hard to implement. "
2754 # It helps to think of the 'expr: and_expr' case as a single-operand OR
2755 # (no ||), and of the 'and_expr: factor' case as a single-operand AND
2759 # work as well. The straightforward implementation there gives a
2761 # expressions as (op, [list of operands]) instead goes nicely with that
2808 # _T_EQUAL, _T_UNEQUAL, etc., deliberately have the same values as
2833 # The calculated sets might be larger than necessary as we don't do any
2862 # The direct dependencies. This is usually redundant, as the direct
2995 # If the parent node holds a Choice, we use the Choice itself as the
2996 # parent dependency. This makes sense as the value (mode) of the choice
3000 # Due to the similar interface, Choice works as a drop-in replacement
3144 # - Due to Kconfig internals, numbers show up as undefined Kconfig
3209 The following attributes are available. They should be viewed as read-only,
3231 The type as given in the Kconfig file, without any magic applied. Used
3235 The value of the symbol as a string. Gives the value for string/int/hex
3243 directly as an int. Do int(int_sym.str_value) or
3247 The tristate value of the symbol as an integer. One of 0, 1, 2,
3264 visibility. menuconfig represents this as -M- and -*-, respectively.
3315 symbols. Doubles as a flag for whether a symbol is a choice symbol.
3319 example, 'default A && B if C || D' is represented as
3328 example, 'select A if B && C' is represented as (A, (AND, B, C)). If no
3339 example, 'range 1 2 if A' is represented as (1, 2, A). If there is no
3345 Gotcha: 1 and 2 above will be represented as (undefined) Symbols rather
3346 than plain integers. Undefined symbols get their name as their string
3456 # As a quirk of Kconfig, undefined symbols get their name as their
3511 # contraints, it is stored in exactly the same form as
3733 n/m/y can be specified either as 0/1/2 (the usual format for tristate
3734 values in Kconfiglib) or as one of the strings "n"/"m"/"y". For other
3737 Values that are invalid for the type (such as "foo" or 1 (m) for a
3769 # Display tristate values as n, m, y in the warning
3788 # guaranteed to match the actual selection of the choice, as
3800 Resets the user value of the symbol, as if the symbol had never gotten
3996 # Marks the symbol as needing to be recalculated
4011 # _cached_vis doubles as a flag that tells us whether 'item'
4012 # has cached values, because it's calculated as a side effect
4018 # item._cached_vis set as a side effect. It's therefore safe to
4035 # symbols, so we skip invalidation for them as an optimization.
4057 # the same algorithm as the C implementation (though a bit cleaned up),
4136 treated as read-only, and some are implemented through @property magic (but
4159 The type as given in the Kconfig file, without any magic applied. Used
4182 The C tools internally represent choices as a type of symbol, with
4189 Symbols within choices get the choice propagated as a dependency to
4247 example, 'default A if B && C' is represented as (A, (AND, B, C)). If
4382 # Display tristate values as n, m, y in the warning
4404 Resets the user value (mode) and user selection of the Choice, as if
4469 See Symbol.__str__() as well.
4591 Symbol/Choice.nodes attribute. Menus and comments are represented as plain
4596 be viewed as read-only.
4600 Menus and comments are represented as plain menu nodes. Ifs are collapsed
4630 as it include properties from all menu nodes (a symbol/choice can have
4992 MenuNode property. To evaluate an expression represented as a string, use
4995 Passing subexpressions of expressions to this function works as expected.
5002 # Short-circuit the n case as an optimization (~5% faster
5003 # allnoconfig.py and allyesconfig.py, as of writing)
5008 # Short-circuit the y case as an optimization
5015 # Implements <, <=, >, >= comparisons as well. These were added to
5026 # Otherwise, try to compare them as numbers
5031 # parse as numbers
5049 displays choices as <choice> (or <choice NAME>, for named choices).
5061 Returns the string representation of the expression 'expr', as in a Kconfig
5064 Passing subexpressions of expressions to this function works as expected.
5068 the expression, with the symbol/choice as the argument. It is expected to
5074 Note that quoted values are represented as constants symbols
5130 expression 'expr', in the same (left-to-right) order as they appear in
5139 (Having this as an operand might be more future-safe than having two
5154 # Parentheses don't matter as long as we stay at the top level (don't
5173 Escapes the string 's' in the same fashion as is done for display in
5192 Helper for tools. Loads the top-level Kconfig specified as the first
5216 # Symbols and Choices have a "visibility" that acts as an upper bound on
5245 # Adds 'sc' (symbol or choice) as a "dependee" to all symbols in 'expr'.
5246 # Constant symbols in 'expr' are skipped as they can never change value
5271 # as being spaced 8 characters apart.
5301 # (which numbers usually are) get their name as their value.
5303 # Only hex numbers that start with 0x/0X are classified as numbers.
5324 # For BOOL and TRISTATE, n/m/y count as 0/1/2. This mirrors 9059a3493ef
5460 # Finalizes a choice, marking each symbol whose menu node has the choice as
5461 # the parent as a choice symbol, and automatically determining types if not
5511 # Choices complicate things, as every choice symbol depends on every other
5556 # sym._visited == 1, found a dependency loop. Return the symbol as the
5567 # choice symbol, skip that one, as we'd get a false positive
5589 # choice._visited == 1, found a dependency loop. Return the choice as the
5723 # Returns True if the (possibly constant) symbol 'sym' is valid as a value
5829 except UnicodeDecodeError as e:
5981 # Keyword to token map, with the get() method assigned directly as a small
6033 # Identifier-like lexemes ("missing quotes") are also treated as strings after
6065 # matching function returned directly as a small optimization.