Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-22 Thread Kieran Mansley
On Mon, 2007-05-21 at 10:50 -0700, Stephen Hemminger wrote: Your mailer is word wrapping the patch so it won't apply as is. Apologies - I'll make sure it doesn't for the next revision. There should also have been a copy attached to the email that I would not expect to be wrapped. Thanks

Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-22 Thread Kieran Mansley
On Mon, 2007-05-21 at 10:52 -0700, Stephen Hemminger wrote: On Fri, 18 May 2007 14:16:48 +0100 Kieran Mansley [EMAIL PROTECTED] wrote: Add support to Xen netfront for accelerated plugin module +/* + * List of all netfront accelerator plugin modules available. Each + * list

Re: [Xen-devel] Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-22 Thread Kieran Mansley
On Tue, 2007-05-22 at 08:15 +0100, Kieran Mansley wrote: RCU on its own wouldn't prevent the accelerated plugin being unloaded while netfront was using one of the hooks. Hmm, actually I think it could be used to do that. I'll take a look. Kieran - To unsubscribe from this list: send the

Re: [Xen-devel] Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-22 Thread Keir Fraser
On 22/5/07 08:28, Kieran Mansley [EMAIL PROTECTED] wrote: On Tue, 2007-05-22 at 08:15 +0100, Kieran Mansley wrote: RCU on its own wouldn't prevent the accelerated plugin being unloaded while netfront was using one of the hooks. Hmm, actually I think it could be used to do that. I'll

Re: [Xen-devel] Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-22 Thread Kieran Mansley
On Tue, 2007-05-22 at 08:48 +0100, Keir Fraser wrote: On 22/5/07 08:28, Kieran Mansley [EMAIL PROTECTED] wrote: On Tue, 2007-05-22 at 08:15 +0100, Kieran Mansley wrote: RCU on its own wouldn't prevent the accelerated plugin being unloaded while netfront was using one of the hooks.

Re: [Xen-devel] Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-22 Thread Kieran Mansley
On Tue, 2007-05-22 at 08:48 +0100, Keir Fraser wrote: On 22/5/07 08:28, Kieran Mansley [EMAIL PROTECTED] wrote: On Tue, 2007-05-22 at 08:15 +0100, Kieran Mansley wrote: RCU on its own wouldn't prevent the accelerated plugin being unloaded while netfront was using one of the hooks.

Re: [Xen-devel] Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-22 Thread Kieran Mansley
On Tue, 2007-05-22 at 15:07 +0100, Keir Fraser wrote: On 22/5/07 13:44, Kieran Mansley [EMAIL PROTECTED] wrote: Eagerly zap the function pointers, then wait one RCU period so every CPU goes through a quiescent point before unloading the module? -- Keir Am I right in thinking that

Re: [Xen-devel] Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-22 Thread Keir Fraser
On 22/5/07 13:44, Kieran Mansley [EMAIL PROTECTED] wrote: Eagerly zap the function pointers, then wait one RCU period so every CPU goes through a quiescent point before unloading the module? -- Keir Am I right in thinking that if one of the functions that was protected by RCU was to

Re: [Xen-devel] Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-22 Thread Stephen Hemminger
On Tue, 22 May 2007 13:44:28 +0100 Kieran Mansley [EMAIL PROTECTED] wrote: On Tue, 2007-05-22 at 08:48 +0100, Keir Fraser wrote: On 22/5/07 08:28, Kieran Mansley [EMAIL PROTECTED] wrote: On Tue, 2007-05-22 at 08:15 +0100, Kieran Mansley wrote: RCU on its own wouldn't prevent

Re: [Xen-devel] Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-22 Thread Kieran Mansley
On Tue, 2007-05-22 at 08:05 -0700, Stephen Hemminger wrote: The same thing is already done to handle network protocols already. RCU is used for the object handle (including function pointers). You need to use: * put rcu structure in accelerator list member and initialize it to the

Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-21 Thread Stephen Hemminger
On Fri, 18 May 2007 14:16:48 +0100 Kieran Mansley [EMAIL PROTECTED] wrote: Add support to Xen netfront for accelerated plugin module diff -r ce3d5c548e67 linux-2.6-xen- sparse/drivers/xen/netfront/netfront.c --- a/linux-2.6-xen-sparse/drivers/xen/netfront/netfront.c Thu May 17 09:56:38

Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-21 Thread Stephen Hemminger
On Fri, 18 May 2007 14:16:48 +0100 Kieran Mansley [EMAIL PROTECTED] 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

Re: [PATCH 3/4] [Net] Support Xen accelerated network plugin modules

2007-05-21 Thread Stephen Hemminger
O + +/* + * Macro to call one of the accelerator's function hooks. The use + * count for the accelerator's hooks is incremented for the duration + * of the call to prevent the accelerator being able to modify the + * hooks in the middle (by, for example, unloading) + */ +#define