[dts] [PATH V1] framework/crb: optimization script

Jiale Song songx.jiale at intel.com
Fri Jan 14 14:38:04 CET 2022


the format of priv-flags may be like 'link-down-on-close: on',
so regular expressions need to be optimized

Signed-off-by: Jiale Song <songx.jiale at intel.com>
---
 framework/crb.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
 mode change 100755 => 100644 framework/crb.py

diff --git a/framework/crb.py b/framework/crb.py
old mode 100755
new mode 100644
index bd4f565d..c33edf14
--- a/framework/crb.py
+++ b/framework/crb.py
@@ -900,7 +900,7 @@ class Crb(object):
         '''
         check_flag = "ethtool --show-priv-flags %s" % intf
         out = self.send_expect(check_flag, "# ", timeout)
-        p = re.compile('%s\s+:\s+(\w+)' % flag)
+        p = re.compile('%s\s*:\s+(\w+)' % flag)
         state = re.search(p, out)
         if state:
             return state.group(1)
-- 
2.17.1



More information about the dts mailing list