lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20071001103958.GB15488@elte.hu>
Date:	Mon, 1 Oct 2007 12:39:58 +0200
From:	Ingo Molnar <mingo@...e.hu>
To:	Andrew Morton <akpm@...ux-foundation.org>
Cc:	Avi Kivity <avi@...ranet.com>, Andy Whitcroft <apw@...dowen.org>,
	linux-kernel@...r.kernel.org
Subject: Re: checkpatch and kernel/sched.c


* Andrew Morton <akpm@...ux-foundation.org> wrote:

> On Mon, 01 Oct 2007 09:48:25 +0200 Avi Kivity <avi@...ranet.com> wrote:
> 
> > Andrew Morton wrote:
> > >> this is actually a false positive - as the debug code constructs a 
> > >> printk output _without_ \n. So the script should check whether there's 
> > >> any \n in the printk string - if there is none, do not emit a warning. 
> > >> (if you implement that then i think it can remain a warning and does not 
> > >> need to move to CHECK.)
> > >>     
> > >
> > > Yeah, it does that sometimes.  I don't think it's fixable within the scope
> > > of checkpatch.  It needs to check whether some preceding printk which might
> > > not even be in the patch has a \n:
> > >
> > > 	printk(KERN_ERR "foo");
> > > 	<100 lines of whatever>
> > > +	printk("bar\n");
> > >
> > > we're screwed...
> > >
> > >   
> > 
> > Isn't that broken on SMP (or with preemption) anyway?
> 
> Yep.  Or with interrupts...

not if it's a boot-time only debug check before SMP bringup. (as it is 
in sched.c) We could make this intention explicit via a simple 
raw_printk() wrapper to printk, which could be used without KERN_.

	Ingo
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ