lisa.wlgen.rta.UclampProperty#
- class lisa.wlgen.rta.UclampProperty(**kwargs)[source]#
Bases:
ComposableMultiConcretePropertyBase
Set util clamp (uclamp) values.
- Parameters:
Classes
__class__
inheritedMetaclass for properties.
Attributes
Subclasses can override this attribute so that
PropertyBase.from_key()
knows that it can call their_from_key()
method for that key.Configuration driving the JSON optimization, as a
dict(str, set(str))
.List of KCONFIG keys that need to be =Y on the target kernel for this property to be usable.
DEFAULT_JSON
inheritedProperties
key
inheritedKey of the instance.
logger
inheritedConvenience short-hand for
self.get_logger()
.val
inheritedValue “payload” of the property.
Methods
HASH_COERCE()
inheritedUsed to coerce the values of
self.__dict__
to hashable values.__and__()
inheritedCombine two instances of the same property together.
__getattr__()
inheritedLookup the attributes values defined in
_ATTRIBUTES
.__init_subclass__()
inheritedUpdate the docstring used as a
str.format()
template with the following keys:.check_kconfig()
inheritedCheck whether
plat_info
contains the kernel KCONFIG keys contained inREQUIRED_KCONFIG_KEYS
.find_cls()
inheritedFind which subclass can handle
key
.from_key()
inheritedAlternative constructor that is available with the same signature for all properties.
from_product()
inheritedTo be called the same way as the class itself, except that all values are expected to be iterables and the class will be called with all combinations, returning a list of instances.
get_logger()
inheritedProvides a
logging.Logger
named aftercls
.log_locals()
inheritedDebugging aid: log the local variables of the calling function.
to_default_json()
inheritedSimilar to
to_json()
but returns the default values for the keys set into_json()
.to_json()
inheritedSnippet of JSON content for that property as Python objects.
Classes#
- UclampProperty.__class__#
alias of
PropertyMeta
Attributes#
- UclampProperty.KEY = 'uclamp'#
Subclasses can override this attribute so that
PropertyBase.from_key()
knows that it can call their_from_key()
method for that key.Note
This class attribute will not be inherited automatically so that each class can be uniquely identified by its key. Subclass that do not override the value explicitly will get
None
.
- UclampProperty.OPTIMIZE_JSON_KEYS = {'util_max': {'policy', 'priority'}, 'util_min': {'policy', 'priority'}}#
Configuration driving the JSON optimization, as a
dict(str, set(str))
.This is a dictionary mapping JSON key names to set of “barrier” JSON keys. When successive phases of a given task share the same value for the keys of that dictionary, they will be removed in the later phases since rt-app settings are persistent across phases. When any of the barrier key listed in the set has a change in its value, it will be considered as an optimization barrier and the value will be set again, even if it means repeating the same value as earlier.
- UclampProperty.REQUIRED_KCONFIG_KEYS = ['CONFIG_UCLAMP_TASK']#
List of KCONFIG keys that need to be =Y on the target kernel for this property to be usable.
- UclampProperty.DEFAULT_JSON = None#
Properties#
- property UclampProperty.key#
Inherited property, see
lisa.wlgen.rta.PropertyBase.key
Key of the instance.
- property UclampProperty.logger#
Inherited property, see
lisa.utils.Loggable.logger
Convenience short-hand for
self.get_logger()
.
- property UclampProperty.val#
Inherited property, see
lisa.wlgen.rta.ComposableMultiConcretePropertyBase.val
Value “payload” of the property.
Methods#
- UclampProperty.HASH_COERCE(x, coerce)#
Inherited method, see
lisa.utils.SimpleHash.HASH_COERCE()
Used to coerce the values of
self.__dict__
to hashable values.
- UclampProperty.__and__(other)#
Inherited method, see
lisa.wlgen.rta.ComposableMultiConcretePropertyBase.__and__()
Combine two instances of the same property together.
- UclampProperty.__getattr__(attr)#
Inherited method, see
lisa.wlgen.rta.ComposableMultiConcretePropertyBase.__getattr__()
Lookup the attributes values defined in
_ATTRIBUTES
.
- classmethod UclampProperty.__init_subclass__(**kwargs)#
Inherited method, see
lisa.wlgen.rta.ComposableMultiConcretePropertyBase.__init_subclass__()
Update the docstring used as a
str.format()
template with the following keys:.
- classmethod UclampProperty.check_kconfig(plat_info, strict=True)#
Inherited method, see
lisa.wlgen.rta.ConcretePropertyBase.check_kconfig()
Check whether
plat_info
contains the kernel KCONFIG keys contained inREQUIRED_KCONFIG_KEYS
.
- classmethod UclampProperty.find_cls(key)#
Inherited method, see
lisa.wlgen.rta.PropertyBase.find_cls()
Find which subclass can handle
key
.
- classmethod UclampProperty.from_key(key, val)#
Inherited method, see
lisa.wlgen.rta.PropertyBase.from_key()
Alternative constructor that is available with the same signature for all properties.
- classmethod UclampProperty.from_product(**kwargs)#
Inherited method, see
lisa.wlgen.rta.ComposableMultiConcretePropertyBase.from_product()
To be called the same way as the class itself, except that all values are expected to be iterables and the class will be called with all combinations, returning a list of instances.
- classmethod UclampProperty.get_logger(suffix=None)#
Inherited method, see
lisa.utils.Loggable.get_logger()
Provides a
logging.Logger
named aftercls
.
- classmethod UclampProperty.log_locals(var_names=None, level='debug')#
Inherited method, see
lisa.utils.Loggable.log_locals()
Debugging aid: log the local variables of the calling function.
- classmethod UclampProperty.to_default_json(plat_info, properties)#
Inherited method, see
lisa.wlgen.rta.ConcretePropertyBase.to_default_json()
Similar to
to_json()
but returns the default values for the keys set into_json()
.
- UclampProperty.to_json(plat_info, **kwargs)#
Inherited method, see
lisa.wlgen.rta.ConcretePropertyBase.to_json()
Snippet of JSON content for that property as Python objects.