lkml.org 
[lkml]   [2005]   [Sep]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: Tainted lsmod output
From
On Mon, Sep 12, 2005 at 05:27:03PM -0400, Horst von Brand wrote:
> Valdis.Kletnieks@vt.edu wrote:
> > Somebody had an automated log-parsing tool, and wanted to make sure there
> > were guaranteed at least 2 non-whitespace tokens on the line so they wouldn't
> > have to deal with parsing 'Tainted: \n'?
>
> That's a lame excuse for messing up the kernel and mistifying the heck out
> of users. Either "Tainted: <some gunk>" or "Not tainted" (or just nothing)?

That's precisely what is does. It's just that when there's taint other
than proprietary-module taint, it puts a "G" in that column instead of a
blank. Which is oddly inconsistent, but whatever.

--b.

const char *print_tainted(void)
{
static char buf[20];
if (tainted) {
snprintf(buf, sizeof(buf), "Tainted: %c%c%c%c%c%c",
tainted & TAINT_PROPRIETARY_MODULE ? 'P' : 'G',
tainted & TAINT_FORCED_MODULE ? 'F' : ' ',
tainted & TAINT_UNSAFE_SMP ? 'S' : ' ',
tainted & TAINT_FORCED_RMMOD ? 'R' : ' ',
tainted & TAINT_MACHINE_CHECK ? 'M' : ' ',
tainted & TAINT_BAD_PAGE ? 'B' : ' ');
}
else
snprintf(buf, sizeof(buf), "Not tainted");
return(buf);
}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-09-12 23:38    [W:0.024 / U:1.588 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site