[alsa-devel] [PATCH] hda-analyzer: Ignore unknown lines in proc file

David Henningsson david.henningsson at canonical.com
Wed Oct 17 09:36:09 CEST 2012


With newer kernels, the proc file sometimes add more information.
This makes hda-analyzer ignore such new additions by default,
instead of the current behaviour (which is to crash with a stack
trace). This way you can run an older hda-analyzer with a newer
kernel.

A recent example is the addition of "IEC Coding type" to all HDMI
codecs.

Signed-off-by: David Henningsson <david.henningsson at canonical.com>
---
 hda-analyzer/hda_proc.py |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hda-analyzer/hda_proc.py b/hda-analyzer/hda_proc.py
index a6dd3dc..7424365 100644
--- a/hda-analyzer/hda_proc.py
+++ b/hda-analyzer/hda_proc.py
@@ -721,7 +721,7 @@ class HDACodecProc(HDACodec, HDABaseProc):
         elif line.startswith('  Volume-Knob: '):
           node.add_volknob(line[15:])
         else:
-          self.wrongfile(line)
+          print 'Unknown line, ignored: (%s)' % line
         idx += 1
         if idx < len(lines):
           line = lines[idx]
-- 
1.7.9.5



More information about the Alsa-devel mailing list