Message ID | 20201015065054.645567-1-anders.roxell@linaro.org |
---|---|
State | New |
Headers | show |
Series | [RTEVAL] rteval: misc.py: cpuinfo: set default value for 'model name' | expand |
diff --git a/rteval/misc.py b/rteval/misc.py index 0dd361ff19fd..d99b3c20ecda 100644 --- a/rteval/misc.py +++ b/rteval/misc.py @@ -75,6 +75,8 @@ def cpuinfo(): if key == 'processor': core = val info[core] = {} + # default model name if there isn't any in /proc/cpuinfo + info[core]["model name"] = "unknown CPU" continue info[core][key] = val return info
Set a default value to 'unknown CPU' for 'model name'. If 'cat /proc/cpuinfo' don't provide a 'model name' there will be a default set. Signed-off-by: Anders Roxell <anders.roxell@linaro.org> --- rteval/misc.py | 2 ++ 1 file changed, 2 insertions(+)