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:	Mon, 21 May 2007 10:52:58 -0700
From:	Stephen Hemminger <shemminger@...ux-foundation.org>
To:	Kieran Mansley <kmansley@...arflare.com>
Cc:	xen-devel@...ts.xensource.com, netdev@...r.kernel.org,
	muli@...ibm.com, herbert@...dor.apana.org.au
Subject: Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin
 modules

On Fri, 18 May 2007 14:16:48 +0100
Kieran Mansley <kmansley@...arflare.com> wrote:

> Add support to Xen netfront for accelerated plugin module
> 
>
> 
> +/*
> + * List of all netfront accelerator plugin modules available.  Each
> + * list entry is of type struct netfront_accelerator.
> + */ 
> +static struct list_head accelerators_list;
> +/*
> + * Lock to protect access to accelerators_list, and also used to
> + * protect the hooks_usecount field in struct netfront_accelerator
> + * against concurrent access 
> + */
> +static spinlock_t accelerators_lock;
> +


Your locking model is more complex than it needs to be.
If you just used RCU for access, and depended on the existing RT netlink
mutex (a.k.a big network lock), for setup; then you wouldn't need to
do any of your own locking.

-- 
Stephen Hemminger <shemminger@...ux-foundation.org>
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ