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]
Date:	Tue, 11 Sep 2007 09:53:34 +1000
From:	Rusty Russell <rusty@...tcorp.com.au>
To:	Alexey Dobriyan <adobriyan@...il.com>
Cc:	akpm@...ux-foundation.org, linux-kernel@...r.kernel.org,
	Mathieu Desnoyers <mathieu.desnoyers@...ymtl.ca>
Subject: Re: [patch 1/8] Immediate Values - Global Modules List and Module
	Mutex

On Sat, 2007-09-08 at 11:28 +0400, Alexey Dobriyan wrote:
> On Thu, Sep 06, 2007 at 04:02:29PM -0400, Mathieu Desnoyers wrote:
> > Remove "static" from module_mutex and the modules list so it can be used by
> > other builtin objects in the kernel. Otherwise, every code depending on the
> > module list would have to be put in kernel/module.c. Since the immediate values
> > depends on the module list but can be considered as logically different, it
> > makes sense to implement them in their own file.

If I understand this code correctly, then changing immediate values
needs some exclusion to avoid patching live code.  You leave this to the
user with some very unclear rules.

The result is a real mess that has nothing to do with the module mutex
and list.  These patches need a lot more work 8(

1) The immediate types are just kind of silly.  See per-cpu for how it
handles this already.  DECLARE_IMMEDIATE(type, var) is probably enough.

2) immediate_if() needs an implementation before you introduce it.  Your
assumption that it's always unlikely seems non-orthogonal.

3) immediate_set(), _immediate_set() and immediate_set_early()?  No
thanks!  AFAICT you really want an "init_immediate(var, val)".  This
means "you can patch all the references now, they're not executing".
Later on we could possibly have a super-stop-machine version which
ensures noone's preempted and handles the concurrent case.  Maybe.

4) With an "init" interface not a "set" interface, you don't need
locking.  Simpler.

Hope that helps,
Rusty.


-
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