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: <20100224201354.GA3399@core2>
Date:	Wed, 24 Feb 2010 22:13:54 +0200
From:	Alexey Dobriyan <adobriyan@...il.com>
To:	Arnd Bergmann <arnd@...db.de>
Cc:	paulmck@...ux.vnet.ibm.com,
	Mathieu Desnoyers <mathieu.desnoyers@...icios.com>,
	linux-kernel@...r.kernel.org, mingo@...e.hu, laijs@...fujitsu.com,
	dipankar@...ibm.com, akpm@...ux-foundation.org,
	josh@...htriplett.org, dvhltc@...ibm.com, niv@...ibm.com,
	tglx@...utronix.de, peterz@...radead.org, rostedt@...dmis.org,
	Valdis.Kletnieks@...edu, dhowells@...hat.com
Subject: Re: [PATCH 07/10] module: __rcu annotations

On Wed, Feb 24, 2010 at 09:04:03PM +0100, Arnd Bergmann wrote:
> @@ -360,10 +360,12 @@ struct module *find_module(const char *name)
>  {
>  	struct module *mod;
>  
> -	list_for_each_entry(mod, &modules, list) {
> +	rcu_read_lock();
> +	list_for_each_entry_rcu(mod, &modules, list) {
>  		if (strcmp(mod->name, name) == 0)
>  			return mod;
>  	}
> +	rcu_read_unlock();
>  	return NULL;
>  }
>  EXPORT_SYMBOL_GPL(find_module);

modules list is under module_mutex, nothing should be done here.
--
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