Changes to debug behaviour

Live forum:


19-03-2007 15:42:54

The patch that fixes bug #1642144 - errors when in-kernel linkage for the compiled module is tried - also changes the way the debug variable can be used in three ways

1. *All* debug output is at the debug logging priority (level 7) and goes to /var/log/debug (or whatever you've specified for the debug priority in /etc/syslog.conf). Previously the various debug levels - RT_DEBUG_xxx - corresponded to different logging priorities. So different priority debug messages could end up in different files depending on what you specified in /etc/syslog.conf. This implies that "real" exceptions should now directly use the kernel printk facility.

2. The patch redefines the debug (i.e. RT_DEBUG_xxx) levels as positions in a bit mask. So the value you set the debug variable to is really a filter that lets you select one or several classes of debug messages in whatever combination you please (see the patched TESTING file for further details). This can be useful when you're more interested in getting an idea of program flow than in getting all the informational messages, for example. Also (FWIW), you can specify more than one debug criterion in a message - e.g. "DBGPRINT(RT_DEBUG_TRACE|RT_DEBUG_WARN, ..." - in case you want to make sure that something is included more often than not.

3. The debug mask can be changed in the running driver through the iwpriv command; e.g. "iwpriv ra0 set Debug=5". This can be useful if you don't want to lose a particular run-time configuration, but do want to drill down to some specific area if you're monitoring things through - say - xconsole, for instance.